From e2a3544eb2712418a85ffb48fb5fe8614089e65c Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Wed, 19 Jul 2023 03:02:09 +0200 Subject: [PATCH 0001/1140] (#18630) Bump opencv requirements --- recipes/opencv/4.x/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/opencv/4.x/conanfile.py b/recipes/opencv/4.x/conanfile.py index 2e1ee11d66a591..895fee1eb01868 100644 --- a/recipes/opencv/4.x/conanfile.py +++ b/recipes/opencv/4.x/conanfile.py @@ -194,16 +194,16 @@ def requirements(self): # opencv < 4.5.3 doesn't support openexr >= 3 self.requires("openexr/2.5.7") else: - self.requires("openexr/3.1.7") + self.requires("openexr/3.1.9") if self.options.get_safe("with_tiff"): self.requires("libtiff/4.5.1") if self.options.with_eigen: self.requires("eigen/3.4.0") if self.options.get_safe("with_ffmpeg"): # opencv doesn't support ffmpeg >= 5.0.0 for the moment (until 4.5.5 at least) - self.requires("ffmpeg/4.4") + self.requires("ffmpeg/4.4.3") if self.options.parallel == "tbb": - self.requires("onetbb/2021.7.0") + self.requires("onetbb/2021.9.0") if self.options.with_ipp == "intel-ipp": self.requires("intel-ipp/2020") if self.options.with_webp: From 0536cb35035f7ee9828162bccc45cb6b1928a32f Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 19 Jul 2023 11:01:45 +0200 Subject: [PATCH 0002/1140] (#18593) [bot] Update authorized users list (2023-07-17) --- .c3i/authorized_users.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 1bab3d41b7d934..bb46de7b8ad443 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1199,3 +1199,5 @@ authorized_users: - owenkellogg - AndreaFinazzi - klausholstjacobsen +- xahon +- jeremy-rifkin From b164b065bf28865ef5be37a54830cdc1009a5cc2 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 19 Jul 2023 21:45:19 +0900 Subject: [PATCH 0003/1140] (#18218) platform.delegates: add version 0.3.7, support conan v2 --- recipes/platform.delegates/all/conandata.yml | 13 +-- recipes/platform.delegates/all/conanfile.py | 81 ++++++++++--------- .../all/test_package/CMakeLists.txt | 9 +-- .../all/test_package/conanfile.py | 21 +++-- recipes/platform.delegates/config.yml | 4 +- 5 files changed, 73 insertions(+), 55 deletions(-) diff --git a/recipes/platform.delegates/all/conandata.yml b/recipes/platform.delegates/all/conandata.yml index 474957e25d650f..ac581433698b27 100644 --- a/recipes/platform.delegates/all/conandata.yml +++ b/recipes/platform.delegates/all/conandata.yml @@ -1,7 +1,10 @@ sources: - "0.1.3": - url: https://github.com/linksplatform/Delegates/archive/refs/tags/0.1.3.zip - sha256: e30b2e3c8aff6ffaa366b1c66a7af79f6bc828822f428a4427a7a89e14412fec + "0.3.7": + url: "https://github.com/linksplatform/Delegates/archive/refs/tags/cpp_0.3.7.tar.gz" + sha256: "4b9c72f6fa40a7d968db47f61da302d77d865c07fc70e177b08b4bfeaedfb1c2" "0.2.7": - url: https://github.com/linksplatform/Delegates/archive/refs/tags/cpp_0.2.7.zip - sha256: 440e628dba541497a4d4075b0fd97e42279c5ed73a4156fbcb06556f09109435 + url: "https://github.com/linksplatform/Delegates/archive/refs/tags/cpp_0.2.7.tar.gz" + sha256: "b5e9d5b1094d90795cbd6f9c1377b49eaa6965f88b1730c0775381a3f4b6cb7f" + "0.1.3": + url: "https://github.com/linksplatform/Delegates/archive/refs/tags/0.1.3.tar.gz" + sha256: "0745eda77f900f9985dcfe7d66e5c2e5b15b0d762977c42433dc0345f8866e16" diff --git a/recipes/platform.delegates/all/conanfile.py b/recipes/platform.delegates/all/conanfile.py index bf72a495f89c9d..fd9b1cdcab90c4 100644 --- a/recipes/platform.delegates/all/conanfile.py +++ b/recipes/platform.delegates/all/conanfile.py @@ -1,68 +1,73 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.52.0" class PlatformDelegatesConan(ConanFile): name = "platform.delegates" + description = """platform.delegates is one of the libraries of the LinksPlatform modular framework, which uses + innovations from the C++17 standard, for easier use delegates/events in csharp style.""" license = "MIT" - homepage = "https://github.com/linksplatform/Delegates" url = "https://github.com/conan-io/conan-center-index" - description = """platform.delegates is one of the libraries of the LinksPlatform modular framework, which uses - innovations from the C++17 standard, for easier use delegates/events in csharp style.""" + homepage = "https://github.com/linksplatform/Delegates" topics = ("linksplatform", "cpp17", "delegates", "events", "header-only") - settings = "compiler" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _internal_cpp_subfolder(self): - return os.path.join(self._source_subfolder, "cpp", "Platform.Delegates") + def _min_cppstd(self): + return 17 @property def _compilers_minimum_version(self): return { "gcc": "8", "Visual Studio": "16", + "msvc": "192", "clang": "14", - "apple-clang": "14" + "apple-clang": "14", } - @property - def _minimum_cpp_standard(self): - return 17 - - def validate(self): - minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) - - if not minimum_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) + def layout(self): + basic_layout(self, src_folder="src") - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("platform.delegates/{} " - "requires C++{} with {}, " - "which is not supported " - "by {} {}.".format( - self.version, self._minimum_cpp_standard, self.settings.compiler, self.settings.compiler, - self.settings.compiler.version)) + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) - + 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): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*.h", dst="include", src=self._internal_cpp_subfolder) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy( + self, + "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "cpp", "Platform.Delegates") + ) + copy( + self, + "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder + ) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/platform.delegates/all/test_package/CMakeLists.txt b/recipes/platform.delegates/all/test_package/CMakeLists.txt index 4fcc24504de1ce..96e9a79f01ce82 100644 --- a/recipes/platform.delegates/all/test_package/CMakeLists.txt +++ b/recipes/platform.delegates/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ cmake_minimum_required(VERSION 3.8) -project(test_package) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(platform.delegates REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} CONAN_PKG::platform.delegates) -set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE platform.delegates::platform.delegates) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/platform.delegates/all/test_package/conanfile.py b/recipes/platform.delegates/all/test_package/conanfile.py index bd7165a553cf41..3a91c9439218e3 100644 --- a/recipes/platform.delegates/all/test_package/conanfile.py +++ b/recipes/platform.delegates/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/platform.delegates/config.yml b/recipes/platform.delegates/config.yml index b1a51775b387a0..6918e60ac86f1c 100644 --- a/recipes/platform.delegates/config.yml +++ b/recipes/platform.delegates/config.yml @@ -1,5 +1,7 @@ versions: - "0.1.3": + "0.3.7": folder: all "0.2.7": folder: all + "0.1.3": + folder: all From 26ef075060ced7608db6570aa3b587b82657bef3 Mon Sep 17 00:00:00 2001 From: William Behrens <35979547+wbehrens-on-gh@users.noreply.github.com> Date: Wed, 19 Jul 2023 18:06:44 -0500 Subject: [PATCH 0004/1140] (#18364) ffmpeg: bump libwebp version MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco Co-authored-by: Carlos Zoido --- recipes/ffmpeg/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/ffmpeg/all/conanfile.py b/recipes/ffmpeg/all/conanfile.py index 67048e13ce52b2..0ebfa544b38e23 100644 --- a/recipes/ffmpeg/all/conanfile.py +++ b/recipes/ffmpeg/all/conanfile.py @@ -289,7 +289,7 @@ def requirements(self): if self.options.with_libfdk_aac: self.requires("libfdk_aac/2.0.2") if self.options.with_libwebp: - self.requires("libwebp/1.3.0") + self.requires("libwebp/1.3.1") if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_libalsa"): From d7da970c81b8f100cf9efd005e49f8855bd9d335 Mon Sep 17 00:00:00 2001 From: Rasmus Thomsen Date: Thu, 20 Jul 2023 11:29:06 +0200 Subject: [PATCH 0005/1140] (#18315) ccache: add version 4.8.2 * ccache: add version 4.8.2 Also update the dependencies * ccache: never download ZSTD from the internet * ccache: set find_mode for zstd --- recipes/ccache/all/conandata.yml | 7 +++++++ recipes/ccache/all/conanfile.py | 6 ++++-- recipes/ccache/config.yml | 2 ++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/recipes/ccache/all/conandata.yml b/recipes/ccache/all/conandata.yml index d9b62b8f7eec8b..1eab23f47e9eba 100644 --- a/recipes/ccache/all/conandata.yml +++ b/recipes/ccache/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.8.2": + url: "https://github.com/ccache/ccache/releases/download/v4.8.2/ccache-4.8.2.tar.xz" + sha256: "3d3fb3f888a5b16c4fa7ee5214cca76348afd6130e8443de5f6f2424f2076a49" "4.8.1": url: "https://github.com/ccache/ccache/releases/download/v4.8.1/ccache-4.8.1.tar.xz" sha256: "87959b6819530b3dcaeb39992f585b9fc2c7120302809741378097774919fb6f" @@ -9,6 +12,10 @@ sources: url: "https://github.com/ccache/ccache/releases/download/v4.7.4/ccache-4.7.4.tar.xz" sha256: "df0c64d15d3efaf0b4f6837dd6b1467e40eeaaa807db25ce79c3a08a46a84e36" patches: + "4.8.2": + - patch_file: "patches/4.8-cmake-msvc-runtime.patch" + patch_description: "fixup MSVC runtime" + patch_type: "conan" "4.8.1": - patch_file: "patches/4.8-cmake-msvc-runtime.patch" patch_description: "fixup MSVC runtime" diff --git a/recipes/ccache/all/conanfile.py b/recipes/ccache/all/conanfile.py index d2852b89b924b7..8234bde469ffed 100644 --- a/recipes/ccache/all/conanfile.py +++ b/recipes/ccache/all/conanfile.py @@ -48,7 +48,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zstd/1.5.2") + self.requires("zstd/1.5.5") if self.options.redis_storage_backend: self.requires("hiredis/1.1.0") @@ -67,7 +67,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} requires C++ filesystem library, that is not supported by Clang 11 + libstdc++.") def build_requirements(self): - self.tool_requires("cmake/3.25.3") + self.tool_requires("cmake/[>=3.15 <4]") def source(self): get(self, **self.conan_data["sources"][self.version], @@ -77,6 +77,7 @@ def generate(self): tc = CMakeToolchain(self) tc.variables["REDIS_STORAGE_BACKEND"] = self.options.redis_storage_backend tc.variables["HIREDIS_FROM_INTERNET"] = False + tc.variables["ZSTD_FROM_INTERNET"] = False tc.variables["ENABLE_DOCUMENTATION"] = False tc.variables["ENABLE_TESTING"] = False tc.generate() @@ -85,6 +86,7 @@ def generate(self): deps.set_property("hiredis", "cmake_target_name", "HIREDIS::HIREDIS") deps.set_property("hiredis", "cmake_find_mode", "module") deps.set_property("zstd", "cmake_target_name", "ZSTD::ZSTD") + deps.set_property("zstd", "cmake_find_mode", "module") deps.generate() def build(self): diff --git a/recipes/ccache/config.yml b/recipes/ccache/config.yml index 6bdb34d995150b..a08cbff67b8116 100644 --- a/recipes/ccache/config.yml +++ b/recipes/ccache/config.yml @@ -1,4 +1,6 @@ versions: + "4.8.2": + folder: all "4.8.1": folder: all "4.8": From cd19c3099cdc3824fc393c1f16cbdd586d4f48e8 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Thu, 20 Jul 2023 13:42:12 +0200 Subject: [PATCH 0006/1140] (#18645) [changelog] C3I Jenkins Release - 19 July 2013 Signed-off-by: Uilian Ries --- docs/changelog.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 1f0425119cede9..4ea36e44e8667d 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,16 @@ # Changelog +### 19-Jul-2023 - 09:45 CEST + +- [fix] Fix message processing if no message is passed. +- [fix] Fix automatic merge priority to follow the correct PR order. +- [fix] Waiting for Conan 2.x result after building Conan 1.x. +- [fix] Bump version should not be tagged when removing old versions. +- [feature] Improve internal logs to get more information about epochs. +- [feature] Add an option to disable some jobs. +- [feature] Disable branch indexing job runs on cci multibranch job. +- [feature] Enable Conan 2.0.8 + ### 04-May-2023 - 16:05 CEST - [bugfix] Fix cppstd issues when selecting the value to use in profiles. From ddcaf3d0db27dba1b376e8b866d06aef4de0de07 Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Thu, 20 Jul 2023 14:07:25 +0200 Subject: [PATCH 0007/1140] (#18525) Re-added support for gtest/1.8.1 as this is the latest version supported by qnx 7.0 --- recipes/gtest/all/conandata.yml | 7 +++++++ recipes/gtest/all/patches/gtest-1.8.1.patch | 13 +++++++++++++ recipes/gtest/config.yml | 2 ++ 3 files changed, 22 insertions(+) create mode 100755 recipes/gtest/all/patches/gtest-1.8.1.patch diff --git a/recipes/gtest/all/conandata.yml b/recipes/gtest/all/conandata.yml index 70ff2819b4d9f3..1634a1e79e6fdf 100644 --- a/recipes/gtest/all/conandata.yml +++ b/recipes/gtest/all/conandata.yml @@ -8,6 +8,9 @@ sources: "1.10.0": url: "https://github.com/google/googletest/archive/release-1.10.0.tar.gz" sha256: "9dc9157a9a1551ec7a7e43daea9a694a0bb5fb8bec81235d8a1e6ef64c716dcb" + "1.8.1": + url: "https://github.com/google/googletest/archive/release-1.8.1.tar.gz" + sha256: "9bf1fe5182a604b4135edc1a425ae356c9ad15e9b23f9f12a02e80184c3a249c" patches: "1.10.0": - patch_file: "patches/gtest-1.10.0.patch" @@ -17,3 +20,7 @@ patches: patch_description: "prevent compiler from complaining while compiling" patch_type: "bugfix" patch_source: "https://github.com/google/googletest/pull/2507" + "1.8.1": + - patch_file: "patches/gtest-1.8.1.patch" + patch_description: "add CUSTOM_DEBUG_POSTFIX option" + patch_type: "conan" diff --git a/recipes/gtest/all/patches/gtest-1.8.1.patch b/recipes/gtest/all/patches/gtest-1.8.1.patch new file mode 100755 index 00000000000000..838ab42c89f02f --- /dev/null +++ b/recipes/gtest/all/patches/gtest-1.8.1.patch @@ -0,0 +1,13 @@ +diff --git a/googletest/cmake/internal_utils.cmake b/googletest/cmake/internal_utils.cmake +index 8c1f9ba..2203d3c 100644 +--- a/googletest/cmake/internal_utils.cmake ++++ b/googletest/cmake/internal_utils.cmake +@@ -166,7 +166,7 @@ function(cxx_library_with_type name type cxx_flags) + # Generate debug library name with a postfix. + set_target_properties(${name} + PROPERTIES +- DEBUG_POSTFIX "d") ++ DEBUG_POSTFIX "${CUSTOM_DEBUG_POSTFIX}") + if (BUILD_SHARED_LIBS OR type STREQUAL "SHARED") + set_target_properties(${name} + PROPERTIES diff --git a/recipes/gtest/config.yml b/recipes/gtest/config.yml index 6df56e900d95a5..ee070419b09c37 100644 --- a/recipes/gtest/config.yml +++ b/recipes/gtest/config.yml @@ -5,3 +5,5 @@ versions: folder: all "1.10.0": folder: all + "1.8.1": + folder: all From 5ef08656189412fe33184f70b92dc452607d5f9f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 20 Jul 2023 15:52:52 +0300 Subject: [PATCH 0008/1140] (#18700) forestdb: migrate to Conan v2 --- recipes/forestdb/all/CMakeLists.txt | 7 -- recipes/forestdb/all/conandata.yml | 1 - recipes/forestdb/all/conanfile.py | 83 ++++++++++--------- .../forestdb/all/test_package/CMakeLists.txt | 5 +- .../forestdb/all/test_package/conanfile.py | 22 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../forestdb/all/test_v1_package/conanfile.py | 18 ++++ 7 files changed, 87 insertions(+), 57 deletions(-) delete mode 100644 recipes/forestdb/all/CMakeLists.txt create mode 100644 recipes/forestdb/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/forestdb/all/test_v1_package/conanfile.py diff --git a/recipes/forestdb/all/CMakeLists.txt b/recipes/forestdb/all/CMakeLists.txt deleted file mode 100644 index 78b537ac50f883..00000000000000 --- a/recipes/forestdb/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.10) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/forestdb/all/conandata.yml b/recipes/forestdb/all/conandata.yml index 935f0559af3352..e15581c6eba7e8 100644 --- a/recipes/forestdb/all/conandata.yml +++ b/recipes/forestdb/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "cci.20220727": - patch_file: "patches/0001-proper-cxx-std-flag.patch" - base_path: "source_subfolder" diff --git a/recipes/forestdb/all/conanfile.py b/recipes/forestdb/all/conanfile.py index 526ab2f1f2069b..fd380e23358136 100644 --- a/recipes/forestdb/all/conanfile.py +++ b/recipes/forestdb/all/conanfile.py @@ -1,8 +1,13 @@ import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get + +required_conan_version = ">=1.53.0" + class ForestDBConan(ConanFile): name = "forestdb" @@ -11,12 +16,13 @@ class ForestDBConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/ForestDB-KVStore/forestdb" topics = ("kv-store", "mvcc", "wal") - settings = "os", "arch", "compiler", "build_type" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], - "with_snappy": [True, False] + "with_snappy": [True, False], } default_options = { "shared": False, @@ -24,64 +30,65 @@ class ForestDBConan(ConanFile): "with_snappy": False, } - generators = "cmake" + def export_sources(self): + export_conandata_patches(self) - @property - def _source_subfolder(self): - return "source_subfolder" + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") - def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_snappy: - self.requires("snappy/1.1.9") + self.requires("snappy/1.1.10") def validate(self): if self.settings.os == "Windows": raise ConanInvalidConfiguration("Windows Builds Unsupported") if self.settings.compiler == "clang": - if self.settings.compiler.libcxx == "libc++" and self.options.shared == False: + if self.settings.compiler.libcxx == "libc++" and not self.options.shared: raise ConanInvalidConfiguration("LibC++ Static Builds Unsupported") if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 11) - - def configure(self): - if self.options.shared: - del self.options.fPIC + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = CMake(self) - cmake.definitions["SNAPPY_OPTION"] = "Disable" + def generate(self): + tc = CMakeToolchain(self) + tc.variables["SNAPPY_OPTION"] = "Disable" if self.options.with_snappy: - cmake.definitions["SNAPPY_OPTION"] = "Enable" - cmake.configure() + tc.variables["SNAPPY_OPTION"] = "Enable" + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + apply_conandata_patches(self) lib_target = "forestdb" if not self.options.shared: lib_target = "static_lib" + cmake = CMake(self) + cmake.configure() cmake.build(target=lib_target) def package(self): - self.copy("LICENSE", dst="licenses/", src=self._source_subfolder ) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) # Parent Build system does not support library type selection # and will only install the shared object from cmake; so we must # handpick our libraries. - self.copy("*.a*", dst="lib", src="lib") - self.copy("*.lib", dst="lib", src="lib") - self.copy("*.so*", dst="lib", src="lib", symlinks=True) - self.copy("*.dylib*", dst="lib", src="lib", symlinks=True) - self.copy("*.dll*", dst="lib", src="lib") - self.copy("*.h", dst="include", src=os.path.join(self._source_subfolder, "include"), keep_path=True) + for pattern in ["*.a*", "*.lib", "*.so*", "*.dylib*", "*.dll*"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + keep_path=True) def package_info(self): self.cpp_info.libs = ["forestdb"] - self.cpp_info.system_libs.extend(["pthread", "m", "dl"]) - if self.settings.os == "Linux": - self.cpp_info.system_libs.extend(["rt"]) + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["pthread", "m", "dl", "rt"] diff --git a/recipes/forestdb/all/test_package/CMakeLists.txt b/recipes/forestdb/all/test_package/CMakeLists.txt index 9912b39ed8da5d..44b53f97f3be55 100644 --- a/recipes/forestdb/all/test_package/CMakeLists.txt +++ b/recipes/forestdb/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - find_package(forestdb REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/forestdb/all/test_package/conanfile.py b/recipes/forestdb/all/test_package/conanfile.py index 751b9d5bc7b9cd..fae501d0afb9e4 100644 --- a/recipes/forestdb/all/test_package/conanfile.py +++ b/recipes/forestdb/all/test_package/conanfile.py @@ -1,11 +1,19 @@ -from conans import ConanFile, CMake, tools, RunEnvironment -from conan.tools.build import cross_building +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/forestdb/all/test_v1_package/CMakeLists.txt b/recipes/forestdb/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/forestdb/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/forestdb/all/test_v1_package/conanfile.py b/recipes/forestdb/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..751b9d5bc7b9cd --- /dev/null +++ b/recipes/forestdb/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake, tools, RunEnvironment +from conan.tools.build import cross_building +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 8a8966a1ca011677f9389476050697c8d4a0a4e6 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 20 Jul 2023 22:34:34 +0900 Subject: [PATCH 0009/1140] (#18713) highway: add version 1.0.5 --- recipes/highway/all/conandata.yml | 3 +++ recipes/highway/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/highway/all/conandata.yml b/recipes/highway/all/conandata.yml index a0cdc4a6b19360..b0736b5e173506 100644 --- a/recipes/highway/all/conandata.yml +++ b/recipes/highway/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.5": + url: "https://github.com/google/highway/archive/1.0.5.tar.gz" + sha256: "99b7dad98b8fa088673b720151458fae698ae5df9154016e39de4afdc23bb927" "1.0.4": url: "https://github.com/google/highway/archive/1.0.4.tar.gz" sha256: "faccd343935c9e98afd1016e9d20e0b8b89d908508d1af958496f8c2d3004ac2" diff --git a/recipes/highway/config.yml b/recipes/highway/config.yml index d3cb7d334892fa..48d515416587a4 100644 --- a/recipes/highway/config.yml +++ b/recipes/highway/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.5": + folder: all "1.0.4": folder: all "1.0.3": From 9eabe0479c531211cb145f92393ca2eece8b900c Mon Sep 17 00:00:00 2001 From: whalien Date: Fri, 21 Jul 2023 00:11:27 +0800 Subject: [PATCH 0010/1140] (#18572) migrate tree-sitter to conan2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * build: update to conan2 * build: bump version v0.20.8 * fix: fix lint errors * fix: fix forgotten of bump version 0.20.8 * fix: migrate del to rm_safe in configure * style: add newline to test-pacaage.c * fix: add conan v1 test * Add missing test_type, remove test_v1_package * Dont import every tool * Tooooooools * some fixes * Update recipes/tree-sitter/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: czoido --- recipes/tree-sitter/all/CMakeLists.txt | 13 ++--- recipes/tree-sitter/all/conandata.yml | 3 ++ recipes/tree-sitter/all/conanfile.py | 47 ++++++++++--------- .../all/test_package/CMakeLists.txt | 3 -- .../tree-sitter/all/test_package/conanfile.py | 24 +++++++--- .../all/test_package/test_package.c | 9 ++-- recipes/tree-sitter/config.yml | 2 + 7 files changed, 56 insertions(+), 45 deletions(-) diff --git a/recipes/tree-sitter/all/CMakeLists.txt b/recipes/tree-sitter/all/CMakeLists.txt index 2d67e95f598b6b..5f48ce80be4666 100644 --- a/recipes/tree-sitter/all/CMakeLists.txt +++ b/recipes/tree-sitter/all/CMakeLists.txt @@ -1,21 +1,18 @@ cmake_minimum_required(VERSION 3.4) project(tree-sitter C) -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - # Use cmake script instead of Makefile to support MSVC + follow fPIC option -file(GLOB SOURCES RELATIVE "${PROJECT_SOURCE_DIR}" source_subfolder/lib/src/*.c) -list(REMOVE_ITEM SOURCES source_subfolder/lib/src/lib.c) +file(GLOB SOURCES RELATIVE "${PROJECT_SOURCE_DIR}" src/lib/src/*.c) +list(REMOVE_ITEM SOURCES src/lib/src/lib.c) -file(GLOB HEADERS source_subfolder/lib/include/tree_sitter/*.h) +file(GLOB HEADERS src/lib/include/tree_sitter/*.h) add_library(${PROJECT_NAME} ${SOURCES}) target_include_directories(${PROJECT_NAME} PRIVATE - $ - $ + $ + $ ) set_target_properties(${PROJECT_NAME} PROPERTIES diff --git a/recipes/tree-sitter/all/conandata.yml b/recipes/tree-sitter/all/conandata.yml index d0e08afc47bc99..43b71bcba5f69c 100644 --- a/recipes/tree-sitter/all/conandata.yml +++ b/recipes/tree-sitter/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.20.8": + url: "https://github.com/tree-sitter/tree-sitter/archive/refs/tags/v0.20.8.tar.gz" + sha256: "6181ede0b7470bfca37e293e7d5dc1d16469b9485d13f13a605baec4a8b1f791" "0.20.6": url: "https://github.com/tree-sitter/tree-sitter/archive/v0.20.6.tar.gz" sha256: "4d37eaef8a402a385998ff9aca3e1043b4a3bba899bceeff27a7178e1165b9de" diff --git a/recipes/tree-sitter/all/conanfile.py b/recipes/tree-sitter/all/conanfile.py index 0ab58caffc58fd..db16033332a0c3 100644 --- a/recipes/tree-sitter/all/conanfile.py +++ b/recipes/tree-sitter/all/conanfile.py @@ -1,7 +1,10 @@ -from conans import CMake, ConanFile, tools -import functools +import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, cmake_layout +from conan.tools.files import get, copy + +required_conan_version = ">=1.53.0" class TreeSitterConan(ConanFile): @@ -11,6 +14,7 @@ class TreeSitterConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://tree-sitter.github.io/tree-sitter" license = "MIT" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "fPIC": [True, False], @@ -21,42 +25,39 @@ class TreeSitterConan(ConanFile): "shared": False, } - generators = "cmake" + generators = "CMakeToolchain" exports_sources = "CMakeLists.txt" - @property - def _source_subfolder(self): - return "source_subfolder" - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") - def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + def layout(self): + cmake_layout(self, src_folder="src") - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy( + self, + "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + ) + cmake = CMake(self) cmake.install() def package_info(self): - self.cpp_info.names["pkg_config"] = "tree-sitter" self.cpp_info.libs = ["tree-sitter"] diff --git a/recipes/tree-sitter/all/test_package/CMakeLists.txt b/recipes/tree-sitter/all/test_package/CMakeLists.txt index 1f6c3d19b27a6a..c0b053bd23a365 100644 --- a/recipes/tree-sitter/all/test_package/CMakeLists.txt +++ b/recipes/tree-sitter/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ cmake_minimum_required(VERSION 3.1) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(tree-sitter REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/tree-sitter/all/test_package/conanfile.py b/recipes/tree-sitter/all/test_package/conanfile.py index 38f4483872d47f..a8ebbe0c45c365 100644 --- a/recipes/tree-sitter/all/test_package/conanfile.py +++ b/recipes/tree-sitter/all/test_package/conanfile.py @@ -1,17 +1,27 @@ -from conans import ConanFile, CMake, tools import os +from conan import ConanFile +from conan.tools.cmake import CMake, cmake_layout +from conan.tools.build import can_run -class TestPackageConan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + +class TestPacakgeConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) cmake.configure() cmake.build() + def layout(self): + cmake_layout(self) + def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tree-sitter/all/test_package/test_package.c b/recipes/tree-sitter/all/test_package/test_package.c index 6ed5f62951a826..08527638921d36 100644 --- a/recipes/tree-sitter/all/test_package/test_package.c +++ b/recipes/tree-sitter/all/test_package/test_package.c @@ -1,8 +1,9 @@ #include -//More detailed example search at https://tree-sitter.github.io/tree-sitter/using-parsers#getting-started +// More detailed example search at +// https://tree-sitter.github.io/tree-sitter/using-parsers#getting-started int main() { - TSParser *parser = ts_parser_new(); - ts_parser_delete(parser); - return 0; + TSParser *parser = ts_parser_new(); + ts_parser_delete(parser); + return 0; } diff --git a/recipes/tree-sitter/config.yml b/recipes/tree-sitter/config.yml index be011f8935f2a4..30720fc6f1016e 100644 --- a/recipes/tree-sitter/config.yml +++ b/recipes/tree-sitter/config.yml @@ -1,4 +1,6 @@ versions: + "0.20.8": + folder: all "0.20.6": folder: all "0.20.0": From c4ddd3028ab28c4b6b8d81677568146d9a3995e1 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Thu, 20 Jul 2023 22:28:05 +0200 Subject: [PATCH 0011/1140] (#18762) Add dav1d/1.2.1 --- recipes/dav1d/all/conandata.yml | 3 +++ recipes/dav1d/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/dav1d/all/conandata.yml b/recipes/dav1d/all/conandata.yml index 960fc25c0f85a4..7841b712b35c99 100644 --- a/recipes/dav1d/all/conandata.yml +++ b/recipes/dav1d/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.1": + url: "http://ftp.videolan.org/pub/videolan/dav1d/1.2.1/dav1d-1.2.1.tar.xz" + sha256: "4e33eb61ec54c768a16da0cf8fa0928b4c4593f5f804a3c887d4a21c318340b2" "1.1.0": url: "http://ftp.videolan.org/pub/videolan/dav1d/1.1.0/dav1d-1.1.0.tar.xz" sha256: "fb57aae7875f28c30fb3dbae4a3683d27e2f91dde09ce5c60c22cef9bc58dfd1" diff --git a/recipes/dav1d/config.yml b/recipes/dav1d/config.yml index 1807dabd0bac46..2ef77329e43db9 100644 --- a/recipes/dav1d/config.yml +++ b/recipes/dav1d/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.1": + folder: "all" "1.1.0": folder: "all" "1.0.0": From ceb0d5cec463cca78d958d08cade4b29df211241 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Fri, 21 Jul 2023 00:10:17 +0200 Subject: [PATCH 0012/1140] (#18763) Add libaom-av1 release 3.6.1 --- recipes/libaom-av1/all/conandata.yml | 7 +++++++ recipes/libaom-av1/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/libaom-av1/all/conandata.yml b/recipes/libaom-av1/all/conandata.yml index 17b677e8b1c9a1..bb3a5a205cc9ff 100644 --- a/recipes/libaom-av1/all/conandata.yml +++ b/recipes/libaom-av1/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.6.1": + url: "https://storage.googleapis.com/aom-releases/libaom-3.6.1.tar.gz" + sha256: "42b862f58b3d00bd3902d2dc469526574f5b012e5b178e6a9652845a113d6887" "3.6.0": url: "https://storage.googleapis.com/aom-releases/libaom-3.6.0.tar.gz" sha256: "a4a6c0fab685da743b796662a928fcdf7ae60594edc306efb73e78a17ea6cde6" @@ -21,6 +24,10 @@ sources: url: "https://storage.googleapis.com/aom-releases/libaom-2.0.1.tar.gz" sha256: "a0cff299621e2ef885aba219c498fa39a7d9a7ddf47585a118fd66c64ad1b312" patches: + "3.6.1": + - patch_file: "patches/0001-3.4.0-fix-install.patch" + patch_type: conan + patch_description: Install just aom library without aom_static. "3.6.0": - patch_file: "patches/0001-3.4.0-fix-install.patch" patch_type: conan diff --git a/recipes/libaom-av1/config.yml b/recipes/libaom-av1/config.yml index 55199e78919564..2ac5e2242b2d44 100644 --- a/recipes/libaom-av1/config.yml +++ b/recipes/libaom-av1/config.yml @@ -1,4 +1,6 @@ versions: + "3.6.1": + folder: all "3.6.0": folder: all "3.5.0": From 58ac0a13c5fe5a2ae1649329ffba02a8abf7685b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 04:45:42 +0300 Subject: [PATCH 0013/1140] (#18107) opentelemetry-proto: add package_type, clean up * opentelemetry-proto: add package_type, clean up * opentelemetry-proto: fix Conan v1 incompatibility * opentelemetry-proto: restore test_v1_package * opentelemetry-proto: apply PR suggestions, restore layout() * Update recipes/opentelemetry-proto/all/test_package/conanfile.py * Update recipes/opentelemetry-proto/all/test_package/conanfile.py * package_type = "build-scripts" Co-authored-by: Uilian Ries * bindirs = [] Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/opentelemetry-proto/all/conanfile.py | 32 ++++++++++--------- .../all/test_package/conanfile.py | 26 +++++---------- 2 files changed, 25 insertions(+), 33 deletions(-) diff --git a/recipes/opentelemetry-proto/all/conanfile.py b/recipes/opentelemetry-proto/all/conanfile.py index 05dc5d3a1f5cce..b24f1a700e4468 100644 --- a/recipes/opentelemetry-proto/all/conanfile.py +++ b/recipes/opentelemetry-proto/all/conanfile.py @@ -1,19 +1,22 @@ +import os + from conan import ConanFile -from conan.tools.files import get, copy, save +from conan.tools.files import get, copy from conan.tools.layout import basic_layout -import os required_conan_version = ">=1.52.0" + class OpenTelemetryProtoConan(ConanFile): name = "opentelemetry-proto" license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/open-telemetry/opentelemetry-proto" description = "Protobuf definitions for the OpenTelemetry protocol (OTLP)" - topics = ("opentelemetry", "telemetry", "otlp") + topics = ("opentelemetry", "telemetry", "otlp", "pre-built") + + package_type = "build-scripts" settings = "os", "arch", "compiler", "build_type" - no_copy_source = True def layout(self): basic_layout(self, src_folder="src") @@ -21,23 +24,22 @@ def layout(self): def package_id(self): self.info.clear() - def source(self): + def build(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) - copy( - self, - pattern="*.proto", - dst=os.path.join(self.package_folder, "res"), - src=self.source_folder, - ) - # satisfy KB-H014 (header_only recipes require headers) - save(self, os.path.join(self.package_folder, "include", "dummy_header.h"), "\n") + copy(self, pattern="LICENSE", + dst=os.path.join(self.package_folder, "licenses"), src=self.build_folder) + copy(self, pattern="*.proto", + dst=os.path.join(self.package_folder, "res"), src=self.build_folder) def package_info(self): - self.conf_info.define("user.opentelemetry-proto:proto_root", os.path.join(self.package_folder, "res")) + self.conf_info.define("user.opentelemetry-proto:proto_root", + os.path.join(self.package_folder, "res")) + self.cpp_info.resdirs = ["res"] + self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] self.cpp_info.includedirs = [] + # TODO: to remove in conan v2 self.user_info.proto_root = os.path.join(self.package_folder, "res") diff --git a/recipes/opentelemetry-proto/all/test_package/conanfile.py b/recipes/opentelemetry-proto/all/test_package/conanfile.py index 468f9bc6b74335..43eb202cc1d231 100644 --- a/recipes/opentelemetry-proto/all/test_package/conanfile.py +++ b/recipes/opentelemetry-proto/all/test_package/conanfile.py @@ -1,15 +1,14 @@ +import os + from conan import ConanFile -from conan.tools.cmake import CMakeDeps, CMakeToolchain -from conan.tools.env import VirtualBuildEnv +from conan.tools.files import save, load from conan.tools.layout import basic_layout -import os + class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" test_type = "explicit" - _res_folder = "" - def layout(self): basic_layout(self, src_folder="src") @@ -17,18 +16,9 @@ def requirements(self): self.requires(self.tested_reference_str) def generate(self): - tc = CMakeToolchain(self) - tc.generate() - tc = CMakeDeps(self) - tc.generate() - tc = VirtualBuildEnv(self) - tc.generate(scope="build") - - self._res_folder = self.dependencies["opentelemetry-proto"].conf_info.get("user.opentelemetry-proto:proto_root") + save(self, os.path.join(self.build_folder, "proto_root"), self.dependencies["opentelemetry-proto"].conf_info.get("user.opentelemetry-proto:proto_root")) def test(self): - # TODO: to remove in conan v2 - if self._res_folder == "": - self._res_folder = self.deps_user_info["opentelemetry-proto"].proto_root - - assert os.path.isfile(os.path.join(self._res_folder, "opentelemetry", "proto", "common", "v1", "common.proto")) + res_folder = load(self, os.path.join(self.build_folder, "proto_root")) + proto_path = os.path.join(res_folder, "opentelemetry", "proto", "common", "v1", "common.proto") + assert os.path.isfile(proto_path) From 9d6fda4d6a9ab5bbccf80cf27e3bba17020a9b17 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 05:25:44 +0300 Subject: [PATCH 0014/1140] (#18357) simple-yaml: migrate to Conan v2 * simple-yaml: migrate to Conan v2 * simple-yaml: restore test_v1_package * simple-yaml: set min MSVC version * simple-yaml: drop test_v1_package --- recipes/simple-yaml/all/conanfile.py | 98 +++++++++++-------- .../all/test_package/CMakeLists.txt | 6 +- .../simple-yaml/all/test_package/conanfile.py | 27 +++-- 3 files changed, 76 insertions(+), 55 deletions(-) diff --git a/recipes/simple-yaml/all/conanfile.py b/recipes/simple-yaml/all/conanfile.py index fea9f3e7e071f5..9573f235455af4 100644 --- a/recipes/simple-yaml/all/conanfile.py +++ b/recipes/simple-yaml/all/conanfile.py @@ -1,74 +1,88 @@ import os -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class SimpleYamlConan(ConanFile): name = "simple-yaml" + description = "Read configuration files in YAML format by code structure" license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/Rechip/simple-yaml" - description = "Read configuration files in YAML format by code structure" - topics = ("cpp", "yaml", "configuration") - settings = ["compiler"] - no_copy_source = True + topics = ("cpp", "yaml", "configuration", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" options = { "enable_enum": [True, False], } default_options = { - "enable_enum": True + "enable_enum": True, } + no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" - - def source(self): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) - - def requirements(self): - self.requires("pretty-name/1.0.0") - self.requires("yaml-cpp/0.7.0") - self.requires("source_location/0.2.0") - if self.options.enable_enum: - self.requires("magic_enum/0.7.3") - - def package(self): - self.copy(pattern="LICENSE", dst="licenses", - src=self._source_subfolder) - self.copy(pattern="*", dst="include", - src=os.path.join(self._source_subfolder, "include")) + def _min_cppstd(self): + return 20 @property def _minimum_compilers_version(self): return { - "Visual Studio": "16.3", "gcc": "10", "clang": "11", "apple-clang": "13.3", + "msvc": "193", + "Visual Studio": "16.3", } + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("pretty-name/1.0.0") + self.requires("yaml-cpp/0.7.0") + self.requires("source_location/0.2.1") + if self.options.enable_enum: + self.requires("magic_enum/0.7.3") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, "20") - if self.settings.compiler == "clang" and self.settings.compiler.libcxx in ["libstdc++", "libstdc++11"] and self.settings.compiler.version == "11": - raise ConanInvalidConfiguration("clang 11 with libstdc++ is not supported due to old libstdc++ missing C++17 support") - minimum_version = self._minimum_compilers_version.get( - str(self.settings.compiler), False) - if not minimum_version: - self.output.warn( - "simple-yaml requires C++20. Your compiler is unknown. Assuming it fully supports C++20.") - elif tools.Version(self.settings.compiler.version) < minimum_version: + check_min_cppstd(self, self._min_cppstd) + if ( + self.settings.compiler == "clang" + and self.settings.compiler.libcxx in ["libstdc++", "libstdc++11"] + and self.settings.compiler.version == "11" + ): raise ConanInvalidConfiguration( - "simple-yaml requires C++20, which your compiler does not support.") + "clang 11 with libstdc++ is not supported due to old libstdc++ missing C++17 support" + ) + minimum_version = self._minimum_compilers_version.get(str(self.settings.compiler), False) + if not minimum_version: + self.output.warning("simple-yaml requires C++20. Your compiler is unknown. Assuming it fully supports C++20.") + elif Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration("simple-yaml requires C++20, which your compiler does not support.") - def package_id(self): - self.info.header_only() + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "simple-yaml" - self.cpp_info.names["cmake_find_package_multi"] = "simple-yaml" + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/simple-yaml/all/test_package/CMakeLists.txt b/recipes/simple-yaml/all/test_package/CMakeLists.txt index 506dba003a47f7..08e8ff623e8945 100644 --- a/recipes/simple-yaml/all/test_package/CMakeLists.txt +++ b/recipes/simple-yaml/all/test_package/CMakeLists.txt @@ -1,10 +1,8 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(simple-yaml REQUIRED CONFIG) -find_package(simple-yaml CONFIG REQUIRED) add_executable(${PROJECT_NAME} src/test.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE simple-yaml::simple-yaml) diff --git a/recipes/simple-yaml/all/test_package/conanfile.py b/recipes/simple-yaml/all/test_package/conanfile.py index cbe0be23191a28..fae501d0afb9e4 100644 --- a/recipes/simple-yaml/all/test_package/conanfile.py +++ b/recipes/simple-yaml/all/test_package/conanfile.py @@ -1,17 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "arch", "build_type" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): - self.cmake = CMake(self) - self.cmake.configure() - self.cmake.build() + cmake = CMake(self) + cmake.configure() + cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") From da32e8025edb7c2a4679e97bf43ad74147f53c6a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 07:05:46 +0300 Subject: [PATCH 0015/1140] (#18169) aeron: add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * aeron: add package_type * aeron: restore test_v1_package --------- Co-authored-by: Rubén Rincón Blanco --- recipes/aeron/all/conanfile.py | 3 ++- recipes/aeron/all/test_v1_package/CMakeLists.txt | 6 +++--- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/recipes/aeron/all/conanfile.py b/recipes/aeron/all/conanfile.py index aef0519cfd69ad..4bf9894df2c4c4 100644 --- a/recipes/aeron/all/conanfile.py +++ b/recipes/aeron/all/conanfile.py @@ -20,6 +20,7 @@ class AeronConan(ConanFile): homepage = "https://github.com/real-logic/aeron/wiki" license = "Apache-2.0" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -47,7 +48,7 @@ def _compilers_minimum_version(self): } def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): diff --git a/recipes/aeron/all/test_v1_package/CMakeLists.txt b/recipes/aeron/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..91630d79f4abb3 100644 --- a/recipes/aeron/all/test_v1_package/CMakeLists.txt +++ b/recipes/aeron/all/test_v1_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) From f411bf6b84307b8771ee698dff05aeb283f9f7ee Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 07:46:12 +0300 Subject: [PATCH 0016/1140] (#18173) alembic: add package_type * alembic: add package_type * alembic: add transitive_headers=True to imath, bump deps --- recipes/alembic/all/conanfile.py | 5 +++-- recipes/alembic/all/test_v1_package/CMakeLists.txt | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes/alembic/all/conanfile.py b/recipes/alembic/all/conanfile.py index 73264829b63a37..96e5f773727fd8 100644 --- a/recipes/alembic/all/conanfile.py +++ b/recipes/alembic/all/conanfile.py @@ -15,6 +15,7 @@ class AlembicConan(ConanFile): description = "Open framework for storing and sharing scene data." topics = ("3d", "scene", "geometry", "graphics") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -42,9 +43,9 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("imath/3.1.6") + self.requires("imath/3.1.9", transitive_headers=True) if self.options.with_hdf5: - self.requires("hdf5/1.14.0") + self.requires("hdf5/1.14.1") def validate(self): if self.settings.compiler.get_safe("cppstd"): diff --git a/recipes/alembic/all/test_v1_package/CMakeLists.txt b/recipes/alembic/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/alembic/all/test_v1_package/CMakeLists.txt +++ b/recipes/alembic/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) From cc04ccb57706695569d1545bc276289f15546374 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 21 Jul 2023 14:26:45 +0900 Subject: [PATCH 0017/1140] (#18294) re2: add version 20230701, update icu, remove older versions --- recipes/re2/all/conandata.yml | 15 +++------------ recipes/re2/all/conanfile.py | 2 +- recipes/re2/config.yml | 10 ++-------- 3 files changed, 6 insertions(+), 21 deletions(-) diff --git a/recipes/re2/all/conandata.yml b/recipes/re2/all/conandata.yml index bc9a3a910cce54..6705ed6ddc2fa4 100644 --- a/recipes/re2/all/conandata.yml +++ b/recipes/re2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20230701": + url: "https://github.com/google/re2/releases/download/2023-07-01/re2-2023-07-01.tar.gz" + sha256: "18cf85922e27fad3ed9c96a27733037da445f35eb1a2744c306a37c6d11e95c4" "20230602": url: "https://github.com/google/re2/releases/download/2023-06-02/re2-2023-06-02.tar.gz" sha256: "4ccdd5aafaa1bcc24181e6dd3581c3eee0354734bb9f3cb4306273ffa434b94f" @@ -23,15 +26,3 @@ sources: "20210901": url: "https://github.com/google/re2/archive/refs/tags/2021-09-01.tar.gz" sha256: "42a2e1d56b5de252f5d418dc1cc0848e9e52ca22b056453988b18c6195ec7f8d" - "20210601": - url: "https://github.com/google/re2/archive/refs/tags/2021-06-01.tar.gz" - sha256: "26155e050b10b5969e986dab35654247a3b1b295e0532880b5a9c13c0a700ceb" - "20210401": - url: "https://github.com/google/re2/archive/refs/tags/2021-04-01.tar.gz" - sha256: "358aedf71dbf26506848905f5d4417b7adba5cf44d3bbcf70bf4ef68ccb0871e" - "20210202": - url: "https://github.com/google/re2/archive/2021-02-02.tar.gz" - sha256: "1396ab50c06c1a8885fb68bf49a5ecfd989163015fd96699a180d6414937f33f" - "20201101": - url: "https://github.com/google/re2/archive/2020-11-01.tar.gz" - sha256: "8903cc66c9d34c72e2bc91722288ebc7e3ec37787ecfef44d204b2d6281954d7" diff --git a/recipes/re2/all/conanfile.py b/recipes/re2/all/conanfile.py index ca615ecb2c5f0e..b0f960a2c6e3c2 100644 --- a/recipes/re2/all/conanfile.py +++ b/recipes/re2/all/conanfile.py @@ -60,7 +60,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_icu"): - self.requires("icu/73.1") + self.requires("icu/73.2") if Version(self.version) >= "20230601": self.requires("abseil/20230125.3", transitive_headers=True) diff --git a/recipes/re2/config.yml b/recipes/re2/config.yml index 6ecf995b443ace..4d4c9dcf9a641c 100644 --- a/recipes/re2/config.yml +++ b/recipes/re2/config.yml @@ -1,4 +1,6 @@ versions: + "20230701": + folder: all "20230602": folder: all "20230301": @@ -15,11 +17,3 @@ versions: folder: all "20210901": folder: all - "20210601": - folder: all - "20210401": - folder: all - "20210202": - folder: all - "20201101": - folder: all From 7dbff93fc3acd0c91d79ce0cab8e60b1737616a9 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 09:25:18 +0300 Subject: [PATCH 0018/1140] (#18181) archicad-apidevkit: add package_type, adjust package_id * archicad-apidevkit: add package_type, adjust package_id * archicad-apidevkit: remove redundant Visual Studio check --- recipes/archicad-apidevkit/all/conanfile.py | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) diff --git a/recipes/archicad-apidevkit/all/conanfile.py b/recipes/archicad-apidevkit/all/conanfile.py index 55e0ec99e9a6b8..2cdfa85c589273 100644 --- a/recipes/archicad-apidevkit/all/conanfile.py +++ b/recipes/archicad-apidevkit/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.tools.files import copy, get +from conan.tools.layout import basic_layout from conan.tools.microsoft import check_min_vs, is_msvc -from conan.tools.scm import Version from conan.errors import ConanInvalidConfiguration import os @@ -14,11 +14,20 @@ class ArchicadApidevkitConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://archicadapi.graphisoft.com/" license = "LicenseRef-LICENSE" - settings = "os", "compiler", "arch", "build_type" + topics = ("api", "archicad", "development", "pre-built") + + package_type = "application" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - topics = "api", "archicad", "development" short_paths = True + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + del self.info.settings.compiler + del self.info.settings.build_type + def validate(self): if self.settings.build_type == "Debug": raise ConanInvalidConfiguration("Debug configuration is not supported") @@ -31,9 +40,6 @@ def validate(self): if not str(self.settings.arch) in ("x86_64"): raise ConanInvalidConfiguration( f"{self.ref} is not supported yet.") - if self.settings.compiler == "Visual Studio" and Version(self.settings.compiler.version) < "16": - raise ConanInvalidConfiguration( - "This recipe does not support this compiler version") def build(self): devkit, licenses = self.conan_data["sources"][self.version][str(self.settings.os)][str(self.settings.arch)] From 9e90d35a50a66056d570c72506dcff65c9185719 Mon Sep 17 00:00:00 2001 From: Rasmus Thomsen Date: Fri, 21 Jul 2023 08:48:43 +0200 Subject: [PATCH 0019/1140] (#18313) turtle: fix lib/bindirs * turtle: fix lib/bindirs * turtle: package_id -> package_info --- recipes/turtle/all/conanfile.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/turtle/all/conanfile.py b/recipes/turtle/all/conanfile.py index a032a9c58db934..1f12c41eb77c7b 100644 --- a/recipes/turtle/all/conanfile.py +++ b/recipes/turtle/all/conanfile.py @@ -25,6 +25,10 @@ def requirements(self): def package_id(self): self.info.clear() + def package_info(self): + self.cpp_info.libdirs = [] + self.cpp_info.bindirs = [] + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 85775aa79a46487156b6f7414e462857e7364f4e Mon Sep 17 00:00:00 2001 From: krabbstek Date: Fri, 21 Jul 2023 09:30:13 +0200 Subject: [PATCH 0020/1140] (#18753) Added cmake 3.27 --- recipes/cmake/binary/conandata.yml | 19 +++++++++++++++++++ recipes/cmake/config.yml | 2 ++ 2 files changed, 21 insertions(+) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index b8c5dfe2bfbee8..c9e3ccde2563d7 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.0": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.0-linux-aarch64.tar.gz" + sha256: "97c2f8cf9e063a7acf9f15ed472d87c511bf5cb62d3e42b9c90524fb0c2e4748" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.0-linux-x86_64.tar.gz" + sha256: "89c7e74d29f442e4734954310e09dd12d13636991f2d90d0ed1bececb8bf9b9c" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.0-macos10.10-universal.tar.gz" + sha256: "dd9a7a8d5bd7d20b694eda8ff9c31147a5e1faa3bca1099836cfa0f81f8d5809" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.0-windows-arm64.zip" + sha256: "9345cbbb25cb5e8f3c68db067151a013c628783edbfc6fcf622ae58900aa8ad3" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.0-windows-x86_64.zip" + sha256: "fc5f901ef4d438eafbe35b24c608d5de11e517f157b3b7ab8ebbaa7c3c0171d2" "3.26.4": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 174b2ccab05518..0ed8eb6281e813 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -15,3 +15,5 @@ versions: folder: "binary" "3.26.4": folder: "binary" + "3.27.0": + folder: "binary" From 3dde02d48d85f36ec93bda899c30eee5a6b6713f Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Fri, 21 Jul 2023 01:07:04 -0700 Subject: [PATCH 0021/1140] (#18606) restinio: bump standalone asio & remove older versions --- recipes/restinio/all/conandata.yml | 27 --------------------------- recipes/restinio/all/conanfile.py | 17 +++-------------- recipes/restinio/config.yml | 18 ------------------ 3 files changed, 3 insertions(+), 59 deletions(-) diff --git a/recipes/restinio/all/conandata.yml b/recipes/restinio/all/conandata.yml index 8eaf747a395e36..ad2cb8100089c9 100644 --- a/recipes/restinio/all/conandata.yml +++ b/recipes/restinio/all/conandata.yml @@ -8,30 +8,3 @@ sources: "0.6.16": url: "https://github.com/Stiffstream/restinio/archive/v.0.6.16.tar.gz" sha256: "b3208d746087ba979f51b3a32e08463718c33d58720247d53ffb5bda99f4f92a" - "0.6.15": - url: "https://github.com/Stiffstream/restinio/archive/v.0.6.15.tar.gz" - sha256: "5977e7a21064a42dc690a644adc7ba03037eb4007bfbc36586faf715583967bd" - "0.6.14": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.14.tar.gz - sha256: 9742c051e7199d826697f86e6ba4a9fcb7f00c71a408b5c172134b2206404c4e - "0.6.13": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.13.tar.gz - sha256: 72d7ad40c8d34e69cd79f42145b4059e8a7356114fb13864c3c0ad5a5607b44f - "0.6.12": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.12.tar.gz - sha256: 7176d608afb8e5cd29eec2216e747be262215f5b3ab3df2b3c86e691f1cec79e - "0.6.11": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.11.tar.gz - sha256: 66c25c19efd9dc9683d60f540e9ac09b66245c5afde096fc05ec69cbb502fc5d - "0.6.10": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.10.tar.gz - sha256: dc9cad7e19f1bc255532cee53ab2027c93108c79e27f9fbe971f3ea0b10274a5 - "0.6.9": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.9.tar.gz - sha256: fcb05e15a346b4ff27757b89741289864f82f71affe61364325ce70dddefe31f - "0.6.8.1": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.8.1.tar.gz - sha256: 6a365ce645fc7188c287602886eba1a99c797e01b734f0c69bcb370b3494b54c - "0.6.8": - url: https://github.com/Stiffstream/restinio/archive/v.0.6.8.tar.gz - sha256: 92ab0faa9f9de582df787e133acf5c10fb6ab7cecbd96c128997554d8ceda0cd diff --git a/recipes/restinio/all/conanfile.py b/recipes/restinio/all/conanfile.py index 3d82682de55784..e65bd0d3bc7f99 100644 --- a/recipes/restinio/all/conanfile.py +++ b/recipes/restinio/all/conanfile.py @@ -38,27 +38,16 @@ def layout(self): def requirements(self): self.requires("http_parser/2.9.4") - - if Version(self.version) >= "0.6.16": - self.requires("fmt/10.0.0") - else: - self.requires("fmt/8.1.1") - + self.requires("fmt/10.0.0") self.requires("expected-lite/0.6.3") self.requires("optional-lite/3.5.0") self.requires("string-view-lite/1.7.0") self.requires("variant-lite/2.0.0") if self.options.asio == "standalone": - if Version(self.version) >= "0.6.9": - self.requires("asio/1.22.1") - else: - self.requires("asio/1.16.1") + self.requires("asio/1.28.0") else: - if Version(self.version) >= "0.6.9": - self.requires("boost/1.82.0") - else: - self.requires("boost/1.73.0") + self.requires("boost/1.82.0") if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") diff --git a/recipes/restinio/config.yml b/recipes/restinio/config.yml index c650402f2c5030..517f51717a3a84 100644 --- a/recipes/restinio/config.yml +++ b/recipes/restinio/config.yml @@ -5,21 +5,3 @@ versions: folder: all "0.6.16": folder: all - "0.6.15": - folder: all - "0.6.14": - folder: all - "0.6.13": - folder: all - "0.6.12": - folder: all - "0.6.11": - folder: all - "0.6.10": - folder: all - "0.6.9": - folder: all - "0.6.8.1": - folder: all - "0.6.8": - folder: all From 74400fb6d7baef609215ae58f9b1d232b1c9950e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 11:52:31 +0300 Subject: [PATCH 0022/1140] (#18682) cn-cbor: migrate to Conan v2 --- recipes/cn-cbor/all/CMakeLists.txt | 7 -- recipes/cn-cbor/all/conanfile.py | 83 +++++++++---------- .../cn-cbor/all/test_package/CMakeLists.txt | 9 +- recipes/cn-cbor/all/test_package/conanfile.py | 22 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../cn-cbor/all/test_v1_package/conanfile.py | 18 ++++ 6 files changed, 85 insertions(+), 62 deletions(-) delete mode 100644 recipes/cn-cbor/all/CMakeLists.txt create mode 100644 recipes/cn-cbor/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cn-cbor/all/test_v1_package/conanfile.py diff --git a/recipes/cn-cbor/all/CMakeLists.txt b/recipes/cn-cbor/all/CMakeLists.txt deleted file mode 100644 index 361b35d4c17d9a..00000000000000 --- a/recipes/cn-cbor/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/cn-cbor/all/conanfile.py b/recipes/cn-cbor/all/conanfile.py index 74e90a06cc919f..91eccd3167699e 100644 --- a/recipes/cn-cbor/all/conanfile.py +++ b/recipes/cn-cbor/all/conanfile.py @@ -1,82 +1,79 @@ import os -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir + +required_conan_version = ">=1.53.0" class CnCborStackConan(ConanFile): name = "cn-cbor" + description = "A constrained node implementation of CBOR in C" license = "MIT" - homepage = "https://github.com/jimsch/cn-cbor/" url = "https://github.com/conan-io/conan-center-index" - description = "A constrained node implementation of CBOR in C" - topics = "cbor", "nodes", "messaging" - exports_sources = ['CMakeLists.txt'] - settings = "os", "compiler", "build_type", "arch" + homepage = "https://github.com/jimsch/cn-cbor/" + topics = ("cbor", "nodes", "messaging") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } - generators = "cmake", "cmake_find_package" - - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) if self.settings.os == "Windows" and self.options.shared: raise ConanInvalidConfiguration("Windows shared builds are not supported right now") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["fatal_warnings"] = False - self._cmake.definitions["coveralls"] = False - self._cmake.definitions["build_tests"] = False - self._cmake.definitions["build_docs"] = False - - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["fatal_warnings"] = False + tc.variables["coveralls"] = False + tc.variables["build_tests"] = False + tc.variables["build_docs"] = False + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() os.remove(os.path.join(self.package_folder, "README.md")) os.remove(os.path.join(self.package_folder, "LICENSE")) - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.rmdir(os.path.join(self.package_folder, "lib", "cn-cbor", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cn-cbor", "cmake")) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = ["cn-cbor"] if self.settings.os == "Windows": self.cpp_info.system_libs = ["ws2_32"] diff --git a/recipes/cn-cbor/all/test_package/CMakeLists.txt b/recipes/cn-cbor/all/test_package/CMakeLists.txt index 33ae887aa6aea3..50e6a7de0b4eaf 100644 --- a/recipes/cn-cbor/all/test_package/CMakeLists.txt +++ b/recipes/cn-cbor/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(cn-cbor REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE cn-cbor::cn-cbor) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/cn-cbor/all/test_package/conanfile.py b/recipes/cn-cbor/all/test_package/conanfile.py index 933dbf96533ae4..fae501d0afb9e4 100644 --- a/recipes/cn-cbor/all/test_package/conanfile.py +++ b/recipes/cn-cbor/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" -class TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - bin_path = self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cn-cbor/all/test_v1_package/CMakeLists.txt b/recipes/cn-cbor/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cn-cbor/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cn-cbor/all/test_v1_package/conanfile.py b/recipes/cn-cbor/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..9de3689208f00b --- /dev/null +++ b/recipes/cn-cbor/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + bin_path = self.run(bin_path, run_environment=True) From 506f3b287cb4c8d051d9b85a98a2b9df5f2b299a Mon Sep 17 00:00:00 2001 From: Quentin Chateau Date: Fri, 21 Jul 2023 11:32:52 +0200 Subject: [PATCH 0023/1140] (#18773) aeron: add version 1.41.4 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) --- recipes/aeron/all/conandata.yml | 3 +++ recipes/aeron/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/aeron/all/conandata.yml b/recipes/aeron/all/conandata.yml index a888d0c7211200..c3ee6521cf6a55 100644 --- a/recipes/aeron/all/conandata.yml +++ b/recipes/aeron/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.41.4": + url: "https://github.com/real-logic/aeron/archive/1.41.4.tar.gz" + sha256: "681e2a045ca04672612b6edeb7a09c0d574e12c6875cfe26f677b12772d71ad5" "1.35.1": url: "https://github.com/real-logic/aeron/archive/1.35.1.tar.gz" sha256: "19b0f27c2cbc27b422e26a533e4a04a60592217e1c70fdbdd48a92a7b932cccb" diff --git a/recipes/aeron/config.yml b/recipes/aeron/config.yml index 0c20e51036f8b7..9f6aea7a8f54b5 100644 --- a/recipes/aeron/config.yml +++ b/recipes/aeron/config.yml @@ -1,4 +1,6 @@ versions: + "1.41.4": + folder: all "1.35.1": folder: all "1.34.0": From c8d2cf559a7b7114cefc8ffbe3c9c26fc208a5de Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 21 Jul 2023 13:22:23 +0200 Subject: [PATCH 0024/1140] (#18718) [bot] Update authorized users list (2023-07-20) --- .c3i/authorized_users.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index bb46de7b8ad443..f24e1eb3d8a3aa 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1201,3 +1201,5 @@ authorized_users: - klausholstjacobsen - xahon - jeremy-rifkin +- Christian-Prather +- Siarh199 From c5013168c3270993bdd4b1a19b07bc3f63e39931 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Fri, 21 Jul 2023 14:58:00 +0300 Subject: [PATCH 0025/1140] (#18675) snappy: add with_bmi2 and with_ssse3 options * add options * fix --- recipes/snappy/all/conanfile.py | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/recipes/snappy/all/conanfile.py b/recipes/snappy/all/conanfile.py index 0ce00288cff646..d60c8245273355 100644 --- a/recipes/snappy/all/conanfile.py +++ b/recipes/snappy/all/conanfile.py @@ -21,10 +21,14 @@ class SnappyConan(ConanFile): options = { "shared": [True, False], "fPIC": [True, False], + "with_bmi2": [True, False, "auto"], + "with_ssse3": [True, False, "auto"], } default_options = { "shared": False, "fPIC": True, + "with_bmi2": "auto", + "with_ssse3": "auto", } def export_sources(self): @@ -33,6 +37,9 @@ def export_sources(self): def config_options(self): if self.settings.os == 'Windows': del self.options.fPIC + if self.settings.arch not in ["x86", "x86_64"]: + del self.options.with_bmi2 + del self.options.with_ssse3 def configure(self): if self.options.shared: @@ -60,6 +67,11 @@ def generate(self): tc.variables["SNAPPY_INSTALL"] = True if Version(self.version) >= "1.1.9": tc.variables["SNAPPY_BUILD_BENCHMARKS"] = False + if self.settings.arch in ["x86", "x86_64"]: + if self.options.with_bmi2 != "auto": + tc.variables["SNAPPY_HAVE_BMI2"] = self.options.with_bmi2 + if self.options.with_ssse3 != "auto": + tc.variables["SNAPPY_HAVE_SSSE3"] = self.options.with_ssse3 tc.generate() def build(self): From c3500e48c3f3d02dac0df140fe387b2a12958d1b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 15:53:39 +0300 Subject: [PATCH 0026/1140] (#18345) pybind11_json: migrate to Conan v2 * pybind11_json: migrate to Conan v2 * pybind11_json: restore test_v1_package * pybind11_json: fix v1 support in test --- recipes/pybind11_json/all/conanfile.py | 59 +++++++++---------- .../all/test_package/CMakeLists.txt | 10 ++-- .../all/test_package/conanfile.py | 21 +++++-- .../all/test_package/test_package.cpp | 4 +- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 17 ++++++ 6 files changed, 75 insertions(+), 44 deletions(-) create mode 100644 recipes/pybind11_json/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/pybind11_json/all/test_v1_package/conanfile.py diff --git a/recipes/pybind11_json/all/conanfile.py b/recipes/pybind11_json/all/conanfile.py index 4c4feedd8416af..829dedced7271c 100644 --- a/recipes/pybind11_json/all/conanfile.py +++ b/recipes/pybind11_json/all/conanfile.py @@ -1,48 +1,47 @@ -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class Pybind11JsonConan(ConanFile): name = "pybind11_json" - homepage = "https://github.com/pybind/pybind11_json" description = "An nlohmann_json to pybind11 bridge" - topics = ( - "conan", - "header-only", - "json", - "nlohmann_json", - "pybind11", - "pybind11_json", - "python", - "python-binding", - ) - url = "https://github.com/conan-io/conan-center-index" - no_copy_source = True license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/pybind/pybind11_json" + topics = ("header-only", "json", "nlohmann_json", "pybind11", "pybind11_json", "python", "python-binding") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True - def package_id(self): - self.info.header_only() + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): - self.requires("nlohmann_json/3.9.1") - self.requires("pybind11/2.6.2") + self.requires("nlohmann_json/3.11.2") + self.requires("pybind11/2.10.4") + + def package_id(self): + self.info.clear() def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE*", src=self._source_subfolder, dst="licenses") - self.copy( - "*", dst="include", src=os.path.join(self._source_subfolder, "include") - ) + copy(self, "LICENSE*", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "pybind11_json" - self.cpp_info.names["cmake_find_package_multi"] = "pybind11_json" + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + self.cpp_info.set_property("cmake_target_aliases", ["pybind11_json"]) diff --git a/recipes/pybind11_json/all/test_package/CMakeLists.txt b/recipes/pybind11_json/all/test_package/CMakeLists.txt index d1ca457a18f131..f795a0bec71587 100644 --- a/recipes/pybind11_json/all/test_package/CMakeLists.txt +++ b/recipes/pybind11_json/all/test_package/CMakeLists.txt @@ -1,12 +1,10 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) set(CMAKE_CXX_STANDARD 11) find_package(pybind11_json REQUIRED CONFIG) add_executable(test_package test_package.cpp) -target_link_libraries(test_package PUBLIC pybind11_json::pybind11_json) # FIXME: target should be pybind11_json + # FIXME: target should be pybind11_json, replace once Conan v1 has been dropped +target_link_libraries(test_package PUBLIC pybind11_json::pybind11_json) diff --git a/recipes/pybind11_json/all/test_package/conanfile.py b/recipes/pybind11_json/all/test_package/conanfile.py index 7e2dfe859bb27b..fae501d0afb9e4 100644 --- a/recipes/pybind11_json/all/test_package/conanfile.py +++ b/recipes/pybind11_json/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pybind11_json/all/test_package/test_package.cpp b/recipes/pybind11_json/all/test_package/test_package.cpp index 1e50fae0cd666c..2ebca6ab52bbde 100644 --- a/recipes/pybind11_json/all/test_package/test_package.cpp +++ b/recipes/pybind11_json/all/test_package/test_package.cpp @@ -17,10 +17,10 @@ int main() { py::scoped_interpreter guard{}; const py::dict original_py_dict{"number"_a=1234, "hello"_a="world"}; - + const nl::json converted_nl_json{original_py_dict}; std::cout << "Converted nlohmann::json contents: " << converted_nl_json << std::endl; - + const py::dict converted_py_dict = converted_nl_json.front(); // assigning the only list element std::cout << "Converted py::dict contents: {hello:" << converted_py_dict["hello"].cast() diff --git a/recipes/pybind11_json/all/test_v1_package/CMakeLists.txt b/recipes/pybind11_json/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/pybind11_json/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/pybind11_json/all/test_v1_package/conanfile.py b/recipes/pybind11_json/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/pybind11_json/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 4c4bf4e2258cb887d52480782932a3e0a0630de1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 16:29:14 +0300 Subject: [PATCH 0027/1140] (#18347) tiny-dnn: migrate to Conan v2 * tiny-dnn: migrate to Conan v2 * tiny-dnn: restore test_v1_package * tiny-dnn: add msvc version, drop questionable comment --- recipes/tiny-dnn/all/CMakeLists.txt | 7 -- recipes/tiny-dnn/all/conanfile.py | 92 ++++++++++--------- .../tiny-dnn/all/test_package/CMakeLists.txt | 5 +- .../tiny-dnn/all/test_package/conanfile.py | 19 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../tiny-dnn/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 87 insertions(+), 61 deletions(-) delete mode 100644 recipes/tiny-dnn/all/CMakeLists.txt create mode 100644 recipes/tiny-dnn/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tiny-dnn/all/test_v1_package/conanfile.py diff --git a/recipes/tiny-dnn/all/CMakeLists.txt b/recipes/tiny-dnn/all/CMakeLists.txt deleted file mode 100644 index b71c882d9d33fc..00000000000000 --- a/recipes/tiny-dnn/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/tiny-dnn/all/conanfile.py b/recipes/tiny-dnn/all/conanfile.py index b3a57165d52a3f..d88cf7b9a6e9e4 100644 --- a/recipes/tiny-dnn/all/conanfile.py +++ b/recipes/tiny-dnn/all/conanfile.py @@ -1,35 +1,28 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, replace_in_file, rmdir +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class TinyDnnConan(ConanFile): name = "tiny-dnn" + description = "tiny-dnn is a C++14 implementation of deep learning." license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/tiny-dnn/tiny-dnn" - description = "tiny-dnn is a C++14 implementation of deep learning." topics = ("header-only", "deep-learning", "embedded", "iot", "computational") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - options = { - "with_tbb": [True, False], - } - default_options = { - "with_tbb": False, - } - - exports_sources = "CMakeLists.txt" - # TODO: if you move this recipe to CMakeDeps, be aware that tiny-dnn - # relies on CMake variables which are not defined in CMakeDeps, only - # in cmake_find_package. So patch it before. - generators = "cmake", "cmake_find_package" - - @property - def _source_subfolder(self): - return "source_subfolder" + options = {"with_tbb": [True, False]} + default_options = {"with_tbb": False} + no_copy_source = True @property def _min_cppstd(self): @@ -41,58 +34,71 @@ def _min_compilers_version(self): "gcc": "5", "clang": "3.4", "apple-clang": "10", - "Visual Studio": "14" + "msvc": "190", + "Visual Studio": "14", } + def layout(self): + cmake_layout(self, src_folder="src") + def requirements(self): self.requires("cereal/1.3.1") self.requires("stb/cci.20210713") if self.options.with_tbb: self.requires("onetbb/2020.3") + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._min_cppstd) + check_min_cppstd(self, self._min_cppstd) compiler = str(self.settings.compiler) - version = tools.Version(self.settings.compiler.version) + version = Version(self.settings.compiler.version) if compiler in self._min_compilers_version and version < self._min_compilers_version[compiler]: - raise ConanInvalidConfiguration( - "{} requires a compiler that supports at least C++{}".format( - self.name, self._min_cppstd, - ) - ) - - def package_id(self): - self.info.header_only() + raise ConanInvalidConfiguration(f"{self.name} requires a compiler that supports at least C++{self._min_cppstd}") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["USE_TBB"] = self.options.with_tbb + tc.variables["USE_GEMMLOWP"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - tools.replace_in_file( - os.path.join(self._source_subfolder, "tiny_dnn", "util", "image.h"), - "third_party/", "", - ) + replace_in_file(self, + os.path.join(self.source_folder, "tiny_dnn", "util", "image.h"), + "third_party/", "") def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) cmake = CMake(self) - cmake.definitions["USE_TBB"] = self.options.with_tbb - cmake.definitions["USE_GEMMLOWP"] = False cmake.configure() cmake.install() - tools.rmdir(os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "tinydnn") self.cpp_info.set_property("cmake_target_name", "TinyDNN::tiny_dnn") + # TODO: back to global scope in conan v2 once cmake_find_package* generators removed + self.cpp_info.components["tinydnn"].set_property("cmake_target_name", "TinyDNN::tiny_dnn") + self.cpp_info.components["tinydnn"].requires = ["cereal::cereal", "stb::stb"] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["tinydnn"].system_libs = ["pthread"] if self.options.with_tbb: self.cpp_info.components["tinydnn"].defines = ["CNN_USE_TBB=1"] + self.cpp_info.components["tinydnn"].requires.append("onetbb::onetbb") # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tinydnn" @@ -101,7 +107,3 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "TinyDNN" self.cpp_info.components["tinydnn"].names["cmake_find_package"] = "tiny_dnn" self.cpp_info.components["tinydnn"].names["cmake_find_package_multi"] = "tiny_dnn" - self.cpp_info.components["tinydnn"].set_property("cmake_target_name", "TinyDNN::tiny_dnn") - self.cpp_info.components["tinydnn"].requires = ["cereal::cereal", "stb::stb"] - if self.options.with_tbb: - self.cpp_info.components["tinydnn"].requires.append("onetbb::onetbb") diff --git a/recipes/tiny-dnn/all/test_package/CMakeLists.txt b/recipes/tiny-dnn/all/test_package/CMakeLists.txt index e2d99200a80ab1..efce3e2e319026 100644 --- a/recipes/tiny-dnn/all/test_package/CMakeLists.txt +++ b/recipes/tiny-dnn/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(tinydnn REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/tiny-dnn/all/test_package/conanfile.py b/recipes/tiny-dnn/all/test_package/conanfile.py index 38f4483872d47f..fae501d0afb9e4 100644 --- a/recipes/tiny-dnn/all/test_package/conanfile.py +++ b/recipes/tiny-dnn/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tiny-dnn/all/test_v1_package/CMakeLists.txt b/recipes/tiny-dnn/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/tiny-dnn/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/tiny-dnn/all/test_v1_package/conanfile.py b/recipes/tiny-dnn/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/tiny-dnn/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 8e2d581d6315808b9e568a7b0b5b74c99701c4a9 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 17:07:48 +0300 Subject: [PATCH 0028/1140] (#18705) marisa: migrate to Conan v2 --- recipes/marisa/all/CMakeLists.txt | 7 -- recipes/marisa/all/conandata.yml | 1 - recipes/marisa/all/conanfile.py | 75 ++++++++----------- .../marisa/all/test_package/CMakeLists.txt | 5 +- recipes/marisa/all/test_package/conanfile.py | 22 ++++-- .../marisa/all/test_package/test_package.cpp | 2 +- .../marisa/all/test_v1_package/CMakeLists.txt | 8 ++ .../marisa/all/test_v1_package/conanfile.py | 18 +++++ 8 files changed, 76 insertions(+), 62 deletions(-) delete mode 100644 recipes/marisa/all/CMakeLists.txt create mode 100644 recipes/marisa/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/marisa/all/test_v1_package/conanfile.py diff --git a/recipes/marisa/all/CMakeLists.txt b/recipes/marisa/all/CMakeLists.txt deleted file mode 100644 index 84887fbda2ddf1..00000000000000 --- a/recipes/marisa/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.8) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/marisa/all/conandata.yml b/recipes/marisa/all/conandata.yml index 087e45138b4998..6f5b0ae3b7c45c 100644 --- a/recipes/marisa/all/conandata.yml +++ b/recipes/marisa/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "0.2.6": - patch_file: "patches/0001-add-cmake.patch" - base_path: "source_subfolder" diff --git a/recipes/marisa/all/conanfile.py b/recipes/marisa/all/conanfile.py index 13b534d613bd93..05b8f1775310a9 100644 --- a/recipes/marisa/all/conanfile.py +++ b/recipes/marisa/all/conanfile.py @@ -1,20 +1,22 @@ import os -from conan import ConanFile, tools -from conan.tools.files import apply_conandata_patches -from conans import CMake -required_conan_version = ">=1.45.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir + +required_conan_version = ">=1.53.0" class MarisaConan(ConanFile): name = "marisa" - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://github.com/s-yata/marisa-trie" description = "Matching Algorithm with Recursively Implemented StorAge " license = ("BSD-2-Clause", "LGPL-2.1") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/s-yata/marisa-trie" topics = ("algorithm", "dictionary", "marisa") - exports_sources = "patches/**", "CMakeLists.txt" - settings = "os", "compiler", "build_type", "arch" + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -26,16 +28,8 @@ class MarisaConan(ConanFile): "tools": True, } - generators = "cmake" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -43,45 +37,42 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") - def source(self): - tools.files.get(**self.conan_data["sources"][self.version], - conanfile=self, destination=self._source_subfolder, strip_root=True) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) + def layout(self): + cmake_layout(self, src_folder="src") - self._cmake.definitions["BUILD_TOOLS"] = self.options.tools + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_TOOLS"] = self.options.tools + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): apply_conandata_patches(self) - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="COPYING.md", dst="licenses", - src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, pattern="COPYING.md", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.files.rmdir(self, os.path.join( - self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "marisa" - self.cpp_info.names["cmake_find_package_multi"] = "marisa" - self.cpp_info.names["pkgconfig"] = "marisa" + self.cpp_info.set_property("pkg_config_name", "marisa") self.cpp_info.libs = ["marisa"] - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["m"] + # TODO: to remove in conan v2 bin_path = os.path.join(self.package_folder, "bin") self.output.info(f"Appending PATH env var with : '{bin_path}'") self.env_info.PATH.append(bin_path) diff --git a/recipes/marisa/all/test_package/CMakeLists.txt b/recipes/marisa/all/test_package/CMakeLists.txt index 9bae1c0958b767..8f42c91d450eeb 100644 --- a/recipes/marisa/all/test_package/CMakeLists.txt +++ b/recipes/marisa/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - find_package(marisa REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/marisa/all/test_package/conanfile.py b/recipes/marisa/all/test_package/conanfile.py index 251bf8ae3e3ddc..fae501d0afb9e4 100644 --- a/recipes/marisa/all/test_package/conanfile.py +++ b/recipes/marisa/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import CMake, ConanFile, tools -from conan.tools.build import cross_building class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/marisa/all/test_package/test_package.cpp b/recipes/marisa/all/test_package/test_package.cpp index ba90951dd5e1b0..5180045c1a180a 100644 --- a/recipes/marisa/all/test_package/test_package.cpp +++ b/recipes/marisa/all/test_package/test_package.cpp @@ -1,6 +1,6 @@ -#include #include "marisa.h" +#include int main() { int x = 100; diff --git a/recipes/marisa/all/test_v1_package/CMakeLists.txt b/recipes/marisa/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/marisa/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/marisa/all/test_v1_package/conanfile.py b/recipes/marisa/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..251bf8ae3e3ddc --- /dev/null +++ b/recipes/marisa/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os +from conans import CMake, ConanFile, tools +from conan.tools.build import cross_building + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From bed40ca0a7eb45a7b1c8882ef4be2c79b48563b0 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 21 Jul 2023 23:50:40 +0900 Subject: [PATCH 0029/1140] (#18677) libcurl: add version 8.2.0, update libnghttp2, remove older versions * libcurl: add version 8.2.0, update libnghttp2 * fix brotli patch --- recipes/libcurl/all/conandata.yml | 9 +++------ recipes/libcurl/all/conanfile.py | 5 +++-- recipes/libcurl/config.yml | 6 ++---- 3 files changed, 8 insertions(+), 12 deletions(-) diff --git a/recipes/libcurl/all/conandata.yml b/recipes/libcurl/all/conandata.yml index ed67365a84b810..fa48006c6d92ff 100644 --- a/recipes/libcurl/all/conandata.yml +++ b/recipes/libcurl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.2.0": + url: "https://curl.se/download/curl-8.2.0.tar.gz" + sha256: "c67849462d171a3fee08b605cdd837d18ee22ecc3ee2c6a0393c9cec5d1a137e" "8.1.2": url: "https://curl.se/download/curl-8.1.2.tar.gz" sha256: "2e5a9b8fcdc095bdd2f079561f369de71c5eb3b80f00a702fbe9a8b8d9897891" @@ -38,9 +41,3 @@ sources: "7.78.0": url: "https://curl.se/download/curl-7.78.0.tar.gz" sha256: "ed936c0b02c06d42cf84b39dd12bb14b62d77c7c4e875ade022280df5dcc81d7" - "7.77.0": - url: "https://curl.se/download/curl-7.77.0.tar.gz" - sha256: "b0a3428acb60fa59044c4d0baae4e4fc09ae9af1d8a3aa84b2e3fbcd99841f77" - "7.76.0": - url: "https://curl.se/download/curl-7.76.0.tar.gz" - sha256: "3b4378156ba09e224008e81dcce854b7ce4d182b1f9cfb97fe5ed9e9c18c6bd3" diff --git a/recipes/libcurl/all/conanfile.py b/recipes/libcurl/all/conanfile.py index 6fc552c1f2f774..85bc4477130bef 100644 --- a/recipes/libcurl/all/conanfile.py +++ b/recipes/libcurl/all/conanfile.py @@ -185,7 +185,7 @@ def requirements(self): elif self.options.with_ssl == "wolfssl": self.requires("wolfssl/5.6.3") if self.options.with_nghttp2: - self.requires("libnghttp2/1.54.0") + self.requires("libnghttp2/1.55.1") if self.options.with_libssh2: self.requires("libssh2/1.11.0") if self.options.with_zlib: @@ -334,7 +334,8 @@ def _patch_cmake(self): "include(CurlSymbolHiding)", "") # brotli - replace_in_file(self, cmakelists, "find_package(Brotli QUIET)", "find_package(brotli REQUIRED CONFIG)") + if Version(self.version) < "8.2.0": + replace_in_file(self, cmakelists, "find_package(Brotli QUIET)", "find_package(brotli REQUIRED CONFIG)") replace_in_file(self, cmakelists, "if(BROTLI_FOUND)", "if(brotli_FOUND)") replace_in_file(self, cmakelists, "${BROTLI_LIBRARIES}", "brotli::brotli") replace_in_file(self, cmakelists, "${BROTLI_INCLUDE_DIRS}", "${brotli_INCLUDE_DIRS}") diff --git a/recipes/libcurl/config.yml b/recipes/libcurl/config.yml index cb27832872bdf3..29dfe667599fa6 100644 --- a/recipes/libcurl/config.yml +++ b/recipes/libcurl/config.yml @@ -1,4 +1,6 @@ versions: + "8.2.0": + folder: all "8.1.2": folder: all "8.1.1": @@ -25,7 +27,3 @@ versions: folder: all "7.78.0": folder: all - "7.77.0": - folder: all - "7.76.0": - folder: all From 0b168024b30a5e0ce5c7ac551a38a63308ed92e3 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 22 Jul 2023 02:12:02 +0900 Subject: [PATCH 0030/1140] (#18712) etl: add version 20.37.2, remove older versions --- recipes/etl/all/conandata.yml | 9 +++------ recipes/etl/config.yml | 6 ++---- 2 files changed, 5 insertions(+), 10 deletions(-) diff --git a/recipes/etl/all/conandata.yml b/recipes/etl/all/conandata.yml index d02bdeabb7ddbe..716bd8799f7d5f 100644 --- a/recipes/etl/all/conandata.yml +++ b/recipes/etl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20.37.2": + url: "https://github.com/ETLCPP/etl/archive/20.37.2.tar.gz" + sha256: "13bd5d9d1bfbc887e3182895ca0291df0008a1c5770ddd12ef6cd2215c2bc6af" "20.37.1": url: "https://github.com/ETLCPP/etl/archive/20.37.1.tar.gz" sha256: "73c29678e478eca9243c1d0c98e727a2249a7973d1429a847c669bccc65dca88" @@ -23,9 +26,3 @@ sources: "20.34.0": url: "https://github.com/ETLCPP/etl/archive/20.34.0.tar.gz" sha256: "56e25968f20167a161ee50c3eecda3daa91f696660ba59654c1afd22e502c465" - "20.33.0": - url: "https://github.com/ETLCPP/etl/archive/20.33.0.tar.gz" - sha256: "46068e44cc3cbd626fc8adc5344101b4654c675b9a5faec0c80989176419cd7d" - "20.32.1": - url: "https://github.com/ETLCPP/etl/archive/20.32.1.tar.gz" - sha256: "f39c8ccf33190303946dbcb2b251c86b4516234f57e0e87b83c0a28a1bdb059d" diff --git a/recipes/etl/config.yml b/recipes/etl/config.yml index 587b12dc52899e..b1fd5bf4caa620 100644 --- a/recipes/etl/config.yml +++ b/recipes/etl/config.yml @@ -1,4 +1,6 @@ versions: + "20.37.2": + folder: all "20.37.1": folder: all "20.37.0": @@ -15,7 +17,3 @@ versions: folder: all "20.34.0": folder: all - "20.33.0": - folder: all - "20.32.1": - folder: all From bab9d5518f12717380651becf469f26fec1a8bac Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 21 Jul 2023 21:10:50 +0300 Subject: [PATCH 0031/1140] (#18742) matio: migrate to Conan v2 --- recipes/matio/all/CMakeLists.txt | 7 -- recipes/matio/all/conandata.yml | 12 --- recipes/matio/all/conanfile.py | 98 ++++++++++--------- recipes/matio/all/test_package/CMakeLists.txt | 7 +- recipes/matio/all/test_package/conanfile.py | 25 +++-- .../matio/all/test_v1_package/CMakeLists.txt | 8 ++ .../matio/all/test_v1_package/conanfile.py | 17 ++++ 7 files changed, 96 insertions(+), 78 deletions(-) delete mode 100644 recipes/matio/all/CMakeLists.txt create mode 100644 recipes/matio/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/matio/all/test_v1_package/conanfile.py diff --git a/recipes/matio/all/CMakeLists.txt b/recipes/matio/all/CMakeLists.txt deleted file mode 100644 index bd3083b512cb93..00000000000000 --- a/recipes/matio/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/matio/all/conandata.yml b/recipes/matio/all/conandata.yml index 8a659653f91f9b..fec43221cc62a9 100644 --- a/recipes/matio/all/conandata.yml +++ b/recipes/matio/all/conandata.yml @@ -14,29 +14,17 @@ sources: patches: "1.5.18": - patch_file: "patches/require-cmake-3.10.patch" - base_path: "source_subfolder" - patch_file: "patches/disable-hdf5-target.patch" - base_path: "source_subfolder" - patch_file: "patches/patch-apple-no-undefined.patch" - base_path: "source_subfolder" - patch_file: "patches/cmake-install-bundle.patch" - base_path: "source_subfolder" "1.5.19": - patch_file: "patches/require-cmake-3.10.patch" - base_path: "source_subfolder" - patch_file: "patches/patch-apple-no-undefined.patch" - base_path: "source_subfolder" - patch_file: "patches/cmake-install-bundle.patch" - base_path: "source_subfolder" "1.5.21": - patch_file: "patches/require-cmake-3.10.patch" - base_path: "source_subfolder" - patch_file: "patches/patch-apple-no-undefined.patch" - base_path: "source_subfolder" - patch_file: "patches/cmake-install-bundle.patch" - base_path: "source_subfolder" "1.5.23": - patch_file: "patches/require-cmake-3.10.patch" - base_path: "source_subfolder" - patch_file: "patches/cmake-install-bundle.patch" - base_path: "source_subfolder" diff --git a/recipes/matio/all/conanfile.py b/recipes/matio/all/conanfile.py index 213dcdf0eba5bd..127218a42d2774 100644 --- a/recipes/matio/all/conanfile.py +++ b/recipes/matio/all/conanfile.py @@ -1,42 +1,43 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" class MatioConan(ConanFile): name = "matio" + description = "Matio is a C library for reading and writing binary MATLAB MAT files." license = "BSD-2-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://sourceforge.net/projects/matio/" - description = "Matio is a C library for reading and writing binary MATLAB MAT files." - topics = ("conan", "matlab", "mat-file", "file-format", "hdf5") - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" - exports_sources = "CMakeLists.txt", "patches/*" + topics = ("matlab", "mat-file", "file-format", "hdf5") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "extended_sparse": [True, False], "fPIC": [True, False], + "extended_sparse": [True, False], "mat73": [True, False], "with_hdf5": [True, False], "with_zlib": [True, False], } default_options = { "shared": False, - "extended_sparse": True, "fPIC": True, + "extended_sparse": True, "mat73": True, "with_hdf5": True, "with_zlib": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -44,61 +45,64 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_hdf5: - self.requires("hdf5/1.12.1") + self.requires("hdf5/1.14.1") if self.options.with_zlib: - self.requires("zlib/1.2.12") + self.requires("zlib/1.2.13") def validate(self): if not self.options.with_hdf5 and self.options.mat73: raise ConanInvalidConfiguration("Support of version 7.3 MAT files requires HDF5") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - - self._cmake = CMake(self) - self._cmake.definitions["MATIO_EXTENDED_SPARSE"] = self.options.extended_sparse - self._cmake.definitions["MATIO_PIC"] = self.options.get_safe("fPIC", True) - self._cmake.definitions["MATIO_SHARED"] = self.options.shared - self._cmake.definitions["MATIO_MAT73"] = self.options.mat73 - self._cmake.definitions["MATIO_WITH_HDF5"] = self.options.with_hdf5 - self._cmake.definitions["MATIO_WITH_ZLIB"] = self.options.with_zlib - self._cmake.definitions["HDF5_USE_STATIC_LIBRARIES"] = self.options.with_hdf5 and not self.options["hdf5"].shared - self._cmake.configure() - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["MATIO_EXTENDED_SPARSE"] = self.options.extended_sparse + tc.variables["MATIO_PIC"] = self.options.get_safe("fPIC", True) + tc.variables["MATIO_SHARED"] = self.options.shared + tc.variables["MATIO_MAT73"] = self.options.mat73 + tc.variables["MATIO_WITH_HDF5"] = self.options.with_hdf5 + tc.variables["MATIO_WITH_ZLIB"] = self.options.with_zlib + tc.variables["HDF5_USE_STATIC_LIBRARIES"] = ( + self.options.with_hdf5 and not self.dependencies["hdf5"].options.shared + ) + tc.generate() + + tc = CMakeDeps(self) + tc.generate() def build(self): - self._patch_sources() - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): - if self.settings.compiler == "Visual Studio": + if is_msvc(self): self.cpp_info.libs = ["libmatio"] else: self.cpp_info.libs = ["matio"] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["m"] + # TODO: remove in conan v2 bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_path)) + self.output.info(f"Appending PATH environment variable: {bin_path}") self.env_info.PATH.append(bin_path) diff --git a/recipes/matio/all/test_package/CMakeLists.txt b/recipes/matio/all/test_package/CMakeLists.txt index f8b971e2db3772..e5b668ec221781 100644 --- a/recipes/matio/all/test_package/CMakeLists.txt +++ b/recipes/matio/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(matio REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE matio::matio) diff --git a/recipes/matio/all/test_package/conanfile.py b/recipes/matio/all/test_package/conanfile.py index f96969845ae240..fae501d0afb9e4 100644 --- a/recipes/matio/all/test_package/conanfile.py +++ b/recipes/matio/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools -import os.path +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os -class MatioTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/matio/all/test_v1_package/CMakeLists.txt b/recipes/matio/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/matio/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/matio/all/test_v1_package/conanfile.py b/recipes/matio/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..3053c8502b32d6 --- /dev/null +++ b/recipes/matio/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os.path + + +class MatioTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 2034cf1f86e0db54356fbc63f910939223040104 Mon Sep 17 00:00:00 2001 From: Tobulus Date: Fri, 21 Jul 2023 21:28:32 +0200 Subject: [PATCH 0032/1140] (#18760) [libmnl] migrate to v2 * [libmnl] migrate to v2 * add package_type * fix indentation --- recipes/libmnl/all/conanfile.py | 58 +++++++++---------- .../libmnl/all/test_package/CMakeLists.txt | 5 +- recipes/libmnl/all/test_package/conanfile.py | 20 +++++-- 3 files changed, 42 insertions(+), 41 deletions(-) diff --git a/recipes/libmnl/all/conanfile.py b/recipes/libmnl/all/conanfile.py index 14628c1889b0d5..4542e12fe1d349 100644 --- a/recipes/libmnl/all/conanfile.py +++ b/recipes/libmnl/all/conanfile.py @@ -1,8 +1,12 @@ import os -from conans import ConanFile, tools, AutoToolsBuildEnvironment -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.29.1" +from conan import ConanFile +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.files import copy, get, rmdir, rm +from conan.tools.layout import basic_layout +from conan.errors import ConanInvalidConfiguration + +required_conan_version = ">=1.53.0" class LibmnlConan(ConanFile): name = "libmnl" @@ -14,50 +18,40 @@ class LibmnlConan(ConanFile): settings = "os", "compiler", "build_type", "arch" options = {"shared": [True, False], "fPIC": [True, False]} default_options = {"shared": False, "fPIC": True} - _autotools = None + package_type = "library" - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def configure(self): if self.settings.os != "Linux": raise ConanInvalidConfiguration("libmnl is only supported on Linux") if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd - - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self) - conf_args = [] - if self.options.shared: - conf_args.extend(["--enable-shared", "--disable-static"]) - else: - conf_args.extend(["--disable-shared", "--enable-static"]) - self._autotools.configure(configure_dir=self._source_subfolder, args=conf_args) - return self._autotools + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() def build(self): - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + autotools = Autotools(self) autotools.install() - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "etc")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", os.path.join(self.package_folder, "lib")) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "etc")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.libs = ["mnl"] diff --git a/recipes/libmnl/all/test_package/CMakeLists.txt b/recipes/libmnl/all/test_package/CMakeLists.txt index d4fdee1a8a79c3..941d5b3d99ff84 100644 --- a/recipes/libmnl/all/test_package/CMakeLists.txt +++ b/recipes/libmnl/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ cmake_minimum_required(VERSION 3.1) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libmnl REQUIRED) add_executable(example example.cpp) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example libmnl::libmnl) diff --git a/recipes/libmnl/all/test_package/conanfile.py b/recipes/libmnl/all/test_package/conanfile.py index 58e0d68615142a..39ac1b7b500082 100644 --- a/recipes/libmnl/all/test_package/conanfile.py +++ b/recipes/libmnl/all/test_package/conanfile.py @@ -1,11 +1,19 @@ import os -from conans import ConanFile, CMake, tools - +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake class LibmnlTestConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "example") + self.run(bin_path, env="conanrun") From 1ff9e0af57141bb476c471cb07d0955570111b8c Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 22 Jul 2023 05:32:06 +0900 Subject: [PATCH 0033/1140] (#18770) platform.hashing: add version 0.5.6 --- recipes/platform.hashing/all/conandata.yml | 3 +++ recipes/platform.hashing/all/conanfile.py | 6 ++++-- recipes/platform.hashing/config.yml | 2 ++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/recipes/platform.hashing/all/conandata.yml b/recipes/platform.hashing/all/conandata.yml index c156d1c289438c..f7e585564ab8a8 100644 --- a/recipes/platform.hashing/all/conandata.yml +++ b/recipes/platform.hashing/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.5.6": + url: "https://github.com/linksplatform/Hashing/archive/refs/tags/cpp_0.5.6.tar.gz" + sha256: "b387d772750eea2187ca7ca0651ddd701e8f2ef6eb8d86a6f8dfda00193a4123" "0.5.5": url: "https://github.com/linksplatform/Hashing/archive/refs/tags/cpp_0.5.5.tar.gz" sha256: "8155f1d0b18cfdad7b93f6c41aaabbe655c9f7ce6bfddb10eae86156cbff02cf" diff --git a/recipes/platform.hashing/all/conanfile.py b/recipes/platform.hashing/all/conanfile.py index 8e331fda1698f6..bb49b80ef8c5ee 100644 --- a/recipes/platform.hashing/all/conanfile.py +++ b/recipes/platform.hashing/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.files import get, copy from conan.tools.layout import basic_layout from conan.tools.scm import Version from conan.tools.microsoft import is_msvc @@ -47,7 +47,9 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - if Version(self.version) >= "0.5.0": + if Version(self.version) >= "0.5.6": + self.requires("cpuinfo/cci.20220228", transitive_headers=True) + elif Version(self.version) >= "0.5.0": self.requires("cpu_features/0.8.0", transitive_headers=True) def package_id(self): diff --git a/recipes/platform.hashing/config.yml b/recipes/platform.hashing/config.yml index ee55970fe3a0b7..4a9a6395456f81 100644 --- a/recipes/platform.hashing/config.yml +++ b/recipes/platform.hashing/config.yml @@ -1,4 +1,6 @@ versions: + "0.5.6": + folder: all "0.5.5": folder: all "0.4.0": From 247c1aa28707633adf61ca29c89ff44b179e2be1 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 22 Jul 2023 14:30:20 +0200 Subject: [PATCH 0034/1140] (#18805) cairo/all: bump deps --- recipes/cairo/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/cairo/all/conanfile.py b/recipes/cairo/all/conanfile.py index e1166eb30e7ea1..1e8675e64a203b 100644 --- a/recipes/cairo/all/conanfile.py +++ b/recipes/cairo/all/conanfile.py @@ -91,10 +91,10 @@ def requirements(self): if self.options.with_xlib or self.options.with_xlib_xrender or self.options.with_xcb: self.requires("xorg/system") if self.options.get_safe("with_glib", True): - self.requires("glib/2.76.2") + self.requires("glib/2.76.3") self.requires("zlib/1.2.13") self.requires("pixman/0.40.0") - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") def package_id(self): if self.options.get_safe("with_glib") and not self.dependencies["glib"].options.shared: From 0a504008f4c4d535d53a595c1113c5c9ce3a2d90 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Sat, 22 Jul 2023 16:04:58 +0200 Subject: [PATCH 0035/1140] (#18699) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 24a3d8f44d6475..d9f1bd61e113ac 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -242,6 +242,7 @@ required_for_references: - embree3 - emio - enet +- enhex-generic_serialization - entityx - entt - enum-flags @@ -637,6 +638,7 @@ required_for_references: - picojson - pixman - pkgconf +- platform.delegates - platform.hashing - plutovg - poco @@ -659,6 +661,7 @@ required_for_references: - pystring - qhull - qpdf +- qt - quantlib - quaternions - quill From 0a58ce0309739ab2a9c52d79529f0b66df09ad4e Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 23 Jul 2023 03:05:08 +0900 Subject: [PATCH 0036/1140] (#18153) st_tree: support conan v2 * st_tree: support conan v2 * Simplify st_tree Conan recipe The upstream cmake is very simple, only copies headers files to include folder. Plus, it has testing and install steps, but we can simplify a lot by copying directly to the include folder without CMake steps. Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/st_tree/all/conanfile.py | 44 ++++++++----------- .../st_tree/all/test_package/CMakeLists.txt | 13 +++--- recipes/st_tree/all/test_package/conanfile.py | 24 +++++++--- 3 files changed, 41 insertions(+), 40 deletions(-) diff --git a/recipes/st_tree/all/conanfile.py b/recipes/st_tree/all/conanfile.py index 2654379b52b95a..0f32eb68fb5486 100644 --- a/recipes/st_tree/all/conanfile.py +++ b/recipes/st_tree/all/conanfile.py @@ -1,42 +1,36 @@ +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy import os -from conans.errors import ConanInvalidConfiguration -from conans import ConanFile, CMake, tools -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.52.0" class STTreeConan(ConanFile): name = "st_tree" + description = "A fast and flexible c++ template class for tree data structures" license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" - description = "A fast and flexible c++ template class for tree data structures" - topics = ("stl", "container", "data-structures") homepage = "https://github.com/erikerlandson/st_tree" + topics = ("stl", "container", "data-structures", "tree", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - @property - def _source_subfolder(self): - return "source_subfolder" + def package_id(self): + self.info.clear() - def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, 11) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure(source_folder=self._source_subfolder) - return cmake + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", "licenses", self._source_subfolder) - - cmake = self._configure_cmake() - cmake.install() - - tools.rmdir(os.path.join(self.package_folder, "lib")) - - def package_id(self): - self.info.header_only() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, pattern="*.h", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include")) def package_info(self): - self.cpp_info.filenames["cmake_find_package"] = "st_tree" - self.cpp_info.filenames["cmake_find_package_multi"] = "st_tree" + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/st_tree/all/test_package/CMakeLists.txt b/recipes/st_tree/all/test_package/CMakeLists.txt index bce4a94d44821f..221a27bafd9eff 100644 --- a/recipes/st_tree/all/test_package/CMakeLists.txt +++ b/recipes/st_tree/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(st_tree CONFIG REQUIRED) +find_package(st_tree REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} st_tree::st_tree) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) +target_link_libraries(${PROJECT_NAME} PRIVATE st_tree::st_tree) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/st_tree/all/test_package/conanfile.py b/recipes/st_tree/all/test_package/conanfile.py index 5d1d0c318d32cb..ef5d7042163ecc 100644 --- a/recipes/st_tree/all/test_package/conanfile.py +++ b/recipes/st_tree/all/test_package/conanfile.py @@ -1,9 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class STTreeTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") From 4c0c17a4a0956d2c3d8b8610ceebeb7746b5301e Mon Sep 17 00:00:00 2001 From: Chris Mc Date: Sat, 22 Jul 2023 11:22:09 -0700 Subject: [PATCH 0037/1140] (#18566) docs: Improve license attribute guidelines * docs: Improve license attribute guidelines This follow @jcar87 comment https://github.com/conan-io/conan-center-index/pull/18481#discussion_r1260070682 wtih extra formatting The main issue is there was contridicting sections and advice * Apply suggestions from code review Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- docs/adding_packages/conanfile_attributes.md | 13 ++++++------- docs/faqs.md | 10 +++++----- 2 files changed, 11 insertions(+), 12 deletions(-) diff --git a/docs/adding_packages/conanfile_attributes.md b/docs/adding_packages/conanfile_attributes.md index 0044d960505ba4..dba2fb82308f0b 100644 --- a/docs/adding_packages/conanfile_attributes.md +++ b/docs/adding_packages/conanfile_attributes.md @@ -49,14 +49,13 @@ In order to create reproducible builds, we also "commit-lock" to the latest comm ### License Attribute -The mandatory license attribute of each recipe **should** be a [SPDX license](https://spdx.org/licenses/) [short Identifiers](https://spdx.dev/ids/) when applicable. - -Where the SPDX guidelines do not apply, packages should do the following: - -* Packages without a license or closed source cannot be accepted in ConanCenter, even if the code is publicly available in Github or other platforms. -* When some package is under the ["public domain"](https://fairuse.stanford.edu/overview/public-domain/welcome/) - these are not a license by itself. The author original intent and files should be respected, and the relevant files defining the "public domain" status should be the ones packaged in the "licenses" folder, for example the source repository README. The ``license`` field should be as close as the original one as possible, like ``license = "Public-domain"``. -* When a custom (e.g. project specific) license is given, the value should be set to `LicenseRef-` as a prefix, followed by the name of the file which contains the custom license. See [this example](https://github.com/conan-io/conan-center-index/blob/e604534bbe0ef56bdb1f8513b83404eff02aebc8/recipes/fft/all/conanfile.py#L8). For more details, [read this conversation](https://github.com/conan-io/conan-center-index/pull/4928/files#r596216206). +The license attribute is a mandatory field which provides the legal information that summarizes the contents saved in the package. These follow the +[SPDX license](https://spdx.org/licenses/) as a standard. This is for consummers, in particular in the enterprise sector, that do rely on SDPX compliant identifiers so that they can flag this as a custom license text. +* If the library has a license that has a SPDX identifier, use the [short Identifiers](https://spdx.dev/ids/). +* If the library has a license text that does not match a SPDX identifier, including custom wording disclaiming copyright or dedicating the words to the ["public domain"](https://fairuse.stanford.edu/overview/public-domain/welcome/), use the [SPDX License Expressions](https://spdx.github.io/spdx-spec/v2-draft/SPDX-license-expressions/), this can follow: + * `LicenseRef-` as a prefix, followed by the name of the library. For example:`LicenseRef-libfoo-public-domain` +* If the library makes no mention of a license and the terms of use - it **shall not be accepted in ConanCenter** , even if the code is publicly available in GitHub or any other platforms. ## Order of methods and attributes diff --git a/docs/faqs.md b/docs/faqs.md index b84d6e6a091023..8fc8cb331f1212 100644 --- a/docs/faqs.md +++ b/docs/faqs.md @@ -10,7 +10,6 @@ This section gathers the most common questions from the community related to pac * [What is the policy on creating packages from pre-compiled binaries?](#what-is-the-policy-on-creating-packages-from-pre-compiled-binaries) * [Should reference names use `-` or `_`?](#should-reference-names-use---or-_) * [Why are CMake find/config files and pkg-config files not packaged?](#why-are-cmake-findconfig-files-and-pkg-config-files-not-packaged) - * [Should recipes export a recipe's license?](#should-recipes-export-a-recipes-license) * [Why recipes that use build tools (like CMake) that have packages in Conan Center do not use it as a build require by default?](#why-recipes-that-use-build-tools-like-cmake-that-have-packages-in-conan-center-do-not-use-it-as-a-build-require-by-default) * [How are rare build systems without generators packaged?](#how-are-rare-build-systems-without-generators-packaged) * [Are python requires allowed in the `conan-center-index`?](#are-python-requires-allowed-in-the-conan-center-index) @@ -24,6 +23,7 @@ This section gathers the most common questions from the community related to pac * [Doesn't this make debug builds useless?](#doesnt-this-make-debug-builds-useless) * [Can I remove an option from a recipe?](#can-i-remove-an-option-from-a-recipe) * [Can I split a project into an installer and library package?](#can-i-split-a-project-into-an-installer-and-library-package) + * [Should recipes export a recipe's license?](#should-recipes-export-a-recipes-license) * [What license should I use for Public Domain?](#what-license-should-i-use-for-public-domain) * [What license should I use for a custom project specific license?](#what-license-should-i-use-for-a-custom-project-specific-license) * [How do I flag a problem to a recipe consumer?](#how-do-i-flag-a-problem-to-a-recipe-consumer) @@ -103,10 +103,6 @@ If you really think this is an issue and there is something missing to cover the \* Take a look at the integrations section to learn more: https://docs.conan.io/1/integrations/build_system/cmake/cmake_find_package_generator.html -## Should recipes export a recipe's license? - -No, recipes do not need to export a recipe license. Recipes and all files contributed to this repository are licensed under the license in the root of the repository. Using any recipe from this repository or directly from conan-center implies the same licensing. - ## Why recipes that use build tools (like CMake) that have packages in Conan Center do not use it as a build require by default? We generally consider tools like CMake as a standard tool to have installed in your system. Having the `cmake` package as a build require in **all** the recipes that use it will be an overkill, as every build requirement is installed like a requirement and takes time to download. However, `cmake` could still be useful to use in your profile: @@ -209,6 +205,10 @@ After one month, we will welcome a PR removing the option that was deprecated. No. Some projects provide more than a simple library, but also applications. For those projects, both libraries and executables should be kept together under the same Conan package. In the past, we tried to separate popular projects, like Protobuf, and it proved to be a complex and hard task to be maintained, requiring custom patches to disable parts of the building. Also, with the [context](https://docs.conan.io/1/systems_cross_building/cross_building.html#conan-v1-24-and-newer) feature, we can use the same package as build requirement, for the same build platform, and as a regular requirement, for the host platform, when cross-building. It's recommended using 2 profiles in that case, one for build platform (where the compilation tools are being executed) and one for host platform (where the generated binaries will run). +## Should recipes export a recipe's license? + +No, recipes do not need to export a recipe license. Recipes and all files contributed to this repository are licensed under the license in the root of the repository. Using any recipe from this repository or directly from conan-center implies the same licensing. + ## What license should I use for Public Domain? See [License Attribute](adding_packages/conanfile_attributes.md#license-attribute) for details. From b87f8aae742a40a71c39a81336015f66427f94b4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 22 Jul 2023 21:44:35 +0300 Subject: [PATCH 0038/1140] (#18262) glshaderpp: migrate to Conan v2 * glshaderpp: migrate to Conan v2 * glshaderpp: restore test_v1_package * glshaderpp: fix v1 test, add min msvc version --------- Co-authored-by: Uilian Ries --- recipes/glshaderpp/all/conanfile.py | 62 ++++++++++++------- .../all/test_package/CMakeLists.txt | 9 +-- .../glshaderpp/all/test_package/conanfile.py | 20 ++++-- .../{example.cpp => test_package.cpp} | 8 ++- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 19 ++++++ 6 files changed, 89 insertions(+), 37 deletions(-) rename recipes/glshaderpp/all/test_package/{example.cpp => test_package.cpp} (72%) create mode 100644 recipes/glshaderpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/glshaderpp/all/test_v1_package/conanfile.py diff --git a/recipes/glshaderpp/all/conanfile.py b/recipes/glshaderpp/all/conanfile.py index 5f5d7e6cc487c9..047572c5d5dc70 100644 --- a/recipes/glshaderpp/all/conanfile.py +++ b/recipes/glshaderpp/all/conanfile.py @@ -1,25 +1,26 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class GLShaderPPConan(ConanFile): name = "glshaderpp" - homepage = "https://gitlab-lepuy.iut.uca.fr/opengl/glshaderpp" description = "A lightweight header-only library to compile and link OpenGL GLSL shaders." - topics = ("opengl", "glsl", "shader", "header-only") - url = "https://github.com/conan-io/conan-center-index" - no_copy_source = True license = "LGPL-3.0-or-later" - settings = "compiler", "os", "arch", "build_type" - - @property - def _source_subfolder(self): - return "source_subfolder" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://gitlab-lepuy.iut.uca.fr/opengl/glshaderpp" + topics = ("opengl", "glsl", "shader", "header-only") - def package_id(self): - self.info.header_only() + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _minimum_cpp_standard(self): @@ -28,28 +29,45 @@ def _minimum_cpp_standard(self): @property def _minimum_compilers_version(self): return { - "Visual Studio": "17", "gcc": "7", "clang": "6", "apple-clang": "10", + "msvc": "193", + "Visual Studio": "17", } + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._minimum_cpp_standard) min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) if not min_version: - self.output.warn(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") else: - if tools.Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration(f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler {self.settings.compiler} {self.settings.compiler.version} does not support it.") + if Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" + f" {self.settings.compiler} {self.settings.compiler.version} does not support it." + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - self.copy("*", src=os.path.join(self._source_subfolder, "include"), dst="include") + copy(self, "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*", + src=os.path.join(self.source_folder, "include"), + dst=os.path.join(self.package_folder, "include")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.includedirs.append(os.path.join("include", "GLShaderPP")) diff --git a/recipes/glshaderpp/all/test_package/CMakeLists.txt b/recipes/glshaderpp/all/test_package/CMakeLists.txt index 7f0e01ff5256f0..36af631b4dd6a6 100644 --- a/recipes/glshaderpp/all/test_package/CMakeLists.txt +++ b/recipes/glshaderpp/all/test_package/CMakeLists.txt @@ -1,12 +1,9 @@ -cmake_minimum_required(VERSION 3.1) -project(PackageTest CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) find_package(glew CONFIG REQUIRED) find_package(glshaderpp CONFIG REQUIRED) -add_executable(${PROJECT_NAME} example.cpp) +add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} glshaderpp::glshaderpp GLEW::GLEW) set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 17 CXX_STANDARD_REQUIRED ON) diff --git a/recipes/glshaderpp/all/test_package/conanfile.py b/recipes/glshaderpp/all/test_package/conanfile.py index b5aad28ecae40b..8141b9ee65dbbb 100644 --- a/recipes/glshaderpp/all/test_package/conanfile.py +++ b/recipes/glshaderpp/all/test_package/conanfile.py @@ -1,19 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" def requirements(self): + self.requires(self.tested_reference_str) self.requires("glew/2.2.0") + def layout(self): + cmake_layout(self) + def build(self): cmake = CMake(self) cmake.configure() cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "PackageTest") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/glshaderpp/all/test_package/example.cpp b/recipes/glshaderpp/all/test_package/test_package.cpp similarity index 72% rename from recipes/glshaderpp/all/test_package/example.cpp rename to recipes/glshaderpp/all/test_package/test_package.cpp index eb8a668f50e890..e8dce6ff7068bd 100644 --- a/recipes/glshaderpp/all/test_package/example.cpp +++ b/recipes/glshaderpp/all/test_package/test_package.cpp @@ -1,11 +1,13 @@ -#include #include -#include #include #include +#include + +#include int main() { - GLShaderPP::CShaderException e("If you read this, GLShaderPP is happy :)", GLShaderPP::CShaderException::ExceptionType::LinkError); + GLShaderPP::CShaderException e("If you read this, GLShaderPP is happy :)", + GLShaderPP::CShaderException::ExceptionType::LinkError); std::cout << e.what() << '\n'; return EXIT_SUCCESS; } diff --git a/recipes/glshaderpp/all/test_v1_package/CMakeLists.txt b/recipes/glshaderpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/glshaderpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/glshaderpp/all/test_v1_package/conanfile.py b/recipes/glshaderpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6e16e1852823fd --- /dev/null +++ b/recipes/glshaderpp/all/test_v1_package/conanfile.py @@ -0,0 +1,19 @@ +import os +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def requirements(self): + self.requires("glew/2.2.0") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b7c8b17b6a07b501d35f39714904b299c6eaf3ae Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 22 Jul 2023 22:05:17 +0300 Subject: [PATCH 0039/1140] (#18272) seqan: migrate to Conan v2 * seqan: migrate to Conan v2 seqan: autoformat * seqan: restore test_v1_package * seqan: add cmake_find_package_multi to v1 * seqan: add -DNOMINMAX on Windows Otherwise std::min() and std::max() will fail. * configure() -> validate() Co-authored-by: Uilian Ries * seqan: fix indentation --------- Co-authored-by: Uilian Ries --- recipes/seqan/2.x.x/conanfile.py | 87 ++++++++++++------- .../seqan/2.x.x/test_package/CMakeLists.txt | 7 +- recipes/seqan/2.x.x/test_package/conanfile.py | 21 +++-- .../seqan/2.x.x/test_package/test_package.cpp | 5 +- .../2.x.x/test_v1_package/CMakeLists.txt | 8 ++ .../seqan/2.x.x/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 102 insertions(+), 43 deletions(-) create mode 100644 recipes/seqan/2.x.x/test_v1_package/CMakeLists.txt create mode 100644 recipes/seqan/2.x.x/test_v1_package/conanfile.py diff --git a/recipes/seqan/2.x.x/conanfile.py b/recipes/seqan/2.x.x/conanfile.py index 5f567373a4d1a7..fb2227d760d8f2 100644 --- a/recipes/seqan/2.x.x/conanfile.py +++ b/recipes/seqan/2.x.x/conanfile.py @@ -1,56 +1,81 @@ import os -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class SeqanConan(ConanFile): name = "seqan" + description = ( + "SeqAn is an open source C++ library of efficient algorithms and data structures for the analysis of sequences " + "with the focus on biological data. Our library applies a unique generic design that guarantees high performance, " + "generality, extensibility, and integration with other libraries. " + "SeqAn is easy to use and simplifies the development of new software tools with a minimal loss of performance." + ) + license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/seqan/seqan" - description = """ -SeqAn is an open source C++ library of efficient algorithms and data structures for the analysis of sequences -with the focus on biological data. Our library applies a unique generic design that guarantees high performance, -generality, extensibility, and integration with other libraries. -SeqAn is easy to use and simplifies the development of new software tools with a minimal loss of performance. -""" - topics = ("conan", "cpp98", "cpp11", "cpp14", "cpp17", - "algorithms", "data structures", "biological sequences") - license = "BSD-3-Clause" - settings = "compiler" + topics = ("algorithms", "data structures", "biological sequences", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 14 @property def _compilers_minimum_version(self): return { "gcc": "5", - "Visual Studio": "14", "clang": "3.4", - "apple-clang": "3.4" + "apple-clang": "3.4", + "msvc": "190", + "Visual Studio": "14", } - def configure(self): + def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 14) + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("seqan requires C++14, which your compiler does not fully support.") - else: - self.output.warn("seqan requires C++14. Your compiler is unknown. Assuming it supports C++14.") + if not minimum_version: + self.output.warning( + f"{self.name} requires C++{self._min_cppstd}. " + f"Your compiler is unknown. Assuming it supports C++{self._min_cppstd}." + ) + elif Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._min_cppstd}, which your compiler does not fully support." + ) + + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): + self.info.clear() def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "seqan-seqan-v" + self.version - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*", dst="include", - src=os.path.join(self._source_subfolder, "include"), keep_path=True) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + keep_path=True) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + if self.settings.os == "Windows": + self.cpp_info.defines = ["NOMINMAX"] diff --git a/recipes/seqan/2.x.x/test_package/CMakeLists.txt b/recipes/seqan/2.x.x/test_package/CMakeLists.txt index 64fd988616e274..6fdde597b12f49 100644 --- a/recipes/seqan/2.x.x/test_package/CMakeLists.txt +++ b/recipes/seqan/2.x.x/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(seqan REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} CONAN_PKG::seqan) +target_link_libraries(${PROJECT_NAME} PRIVATE seqan::seqan) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 14) diff --git a/recipes/seqan/2.x.x/test_package/conanfile.py b/recipes/seqan/2.x.x/test_package/conanfile.py index a59a26a52c8dcd..fae501d0afb9e4 100644 --- a/recipes/seqan/2.x.x/test_package/conanfile.py +++ b/recipes/seqan/2.x.x/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/seqan/2.x.x/test_package/test_package.cpp b/recipes/seqan/2.x.x/test_package/test_package.cpp index dd08405d3402d7..d9a44258b866dc 100644 --- a/recipes/seqan/2.x.x/test_package/test_package.cpp +++ b/recipes/seqan/2.x.x/test_package/test_package.cpp @@ -1,8 +1,9 @@ // Demo program for clipping with Gaps objects. -#include -#include #include +#include + +#include using namespace seqan; diff --git a/recipes/seqan/2.x.x/test_v1_package/CMakeLists.txt b/recipes/seqan/2.x.x/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/seqan/2.x.x/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/seqan/2.x.x/test_v1_package/conanfile.py b/recipes/seqan/2.x.x/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/seqan/2.x.x/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 793ba6f9a241c0ea32b551bb4d6f6c3263f6331d Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 22 Jul 2023 22:36:17 +0300 Subject: [PATCH 0040/1140] (#18637) aws-libfabric: migrate to Conan v2 * aws-libfabric: migrate to Conan v2 * Update recipes/aws-libfabric/all/conanfile.py --------- Co-authored-by: Carlos Zoido --- recipes/aws-libfabric/all/conanfile.py | 113 ++++++++++-------- .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 21 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ 5 files changed, 105 insertions(+), 63 deletions(-) create mode 100644 recipes/aws-libfabric/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/aws-libfabric/all/test_v1_package/conanfile.py diff --git a/recipes/aws-libfabric/all/conanfile.py b/recipes/aws-libfabric/all/conanfile.py index 134b19e72fb917..cdf0ee0dd31985 100644 --- a/recipes/aws-libfabric/all/conanfile.py +++ b/recipes/aws-libfabric/all/conanfile.py @@ -1,33 +1,44 @@ -from conans import ConanFile, AutoToolsBuildEnvironment, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.35.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.build import cross_building +from conan.tools.env import VirtualBuildEnv, VirtualRunEnv +from conan.tools.files import chdir, collect_libs, copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.microsoft import unix_path + +required_conan_version = ">=1.53.0" + class LibfabricConan(ConanFile): name = "aws-libfabric" description = "AWS Libfabric" - topics = ("fabric", "communication", "framework", "service") + license = ("BSD-2-Clause", "GPL-2.0-or-later") url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/aws/libfabric" - license = "BSD-2-Clause", "GPL-2.0-or-later" + topics = ("fabric", "communication", "framework", "service") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" _providers = ["gni", "psm", "psm2", "sockets", "rxm", "tcp", "udp", "usnic", "verbs", "bgq", "shm", "efa", "rxd", "mrail", "rstream", "perf", "hook_debug"] options = { + "shared": [True, False], + "fPIC": [True, False], **{ p: [True, False, "shared"] for p in _providers }, **{ - "shared": [True, False], - "fPIC": [True, False], "with_libnl": [True, False], "bgq_progress": ["auto", "manual"], "bgq_mr": ["basic", "scalable"] } } default_options = { + "shared": False, + "fPIC": True, **{ p: False for p in _providers }, **{ - "shared": False, - "fPIC": True, "tcp": True, "with_libnl": False, "bgq_progress": "manual", @@ -35,15 +46,6 @@ class LibfabricConan(ConanFile): } } - @property - def _source_subfolder(self): - return "source_subfolder" - - _autotools = None - - def build_requirements(self): - self.build_requires("libtool/2.4.6") - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -52,9 +54,12 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): if self.options.with_libnl: @@ -64,52 +69,56 @@ def validate(self): if self.settings.os == "Windows": raise ConanInvalidConfiguration("The libfabric package cannot be built on Windows.") - def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) - with tools.chdir(self._source_subfolder): - self.run("{} -fiv".format(tools.get_env("AUTORECONF")), win_bash=tools.os_info.is_windows) + def build_requirements(self): + self.tool_requires("libtool/2.4.7") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + if not cross_building(self): + env = VirtualRunEnv(self) + env.generate(scope="build") yes_no_dl = lambda v: {"True": "yes", "False": "no", "shared": "dl"}[str(v)] - yes_no = lambda v: "yes" if v else "no" - args = [ - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-static={}".format(yes_no(not self.options.shared)), + tc = AutotoolsToolchain(self) + tc.configure_args += [ "--with-bgq-progress={}".format(self.options.bgq_progress), "--with-bgq-mr={}".format(self.options.bgq_mr), ] for p in self._providers: - args.append("--enable-{}={}".format(p, yes_no_dl(getattr(self.options, p)))) + tc.configure_args.append("--enable-{}={}".format(p, yes_no_dl(getattr(self.options, p)))) if self.options.with_libnl: - args.append("--with-libnl={}".format(tools.unix_path(self.deps_cpp_info["libnl"].rootpath))), + tc.configure_args.append("--with-libnl={}".format(unix_path(self, self.dependencies["libnl"].package_folder))) else: - args.append("--with-libnl=no") + tc.configure_args.append("--with-libnl=no") if self.settings.build_type == "Debug": - args.append("--enable-debug") - self._autotools.configure(args=args, configure_dir=self._source_subfolder) - return self._autotools + tc.configure_args.append("--enable-debug") + tc.generate() + tc = AutotoolsDeps(self) + tc.generate() def build(self): - autotools = self._configure_autotools() - autotools.make() + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.autoreconf() + autotools.configure() + autotools.make() def package(self): - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() - autotools.install() - - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") + copy(self, pattern="COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.install() + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) + fix_apple_shared_install_name(self) def package_info(self): - self.cpp_info.names["pkg_config"] = "libfabric" - self.cpp_info.libs = self.collect_libs() + self.cpp_info.set_property("pkg_config_name", "libfabric") + self.cpp_info.libs = collect_libs(self) if self.settings.os in ("FreeBSD", "Linux"): self.cpp_info.system_libs = ["pthread", "m"] if not self.options.shared: diff --git a/recipes/aws-libfabric/all/test_package/CMakeLists.txt b/recipes/aws-libfabric/all/test_package/CMakeLists.txt index 34af13462f44f8..1af9ab7c6f511e 100644 --- a/recipes/aws-libfabric/all/test_package/CMakeLists.txt +++ b/recipes/aws-libfabric/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(aws-libfabric REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE aws-libfabric::aws-libfabric) diff --git a/recipes/aws-libfabric/all/test_package/conanfile.py b/recipes/aws-libfabric/all/test_package/conanfile.py index d4128b04507778..ef5d7042163ecc 100644 --- a/recipes/aws-libfabric/all/test_package/conanfile.py +++ b/recipes/aws-libfabric/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/aws-libfabric/all/test_v1_package/CMakeLists.txt b/recipes/aws-libfabric/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/aws-libfabric/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/aws-libfabric/all/test_v1_package/conanfile.py b/recipes/aws-libfabric/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/aws-libfabric/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 77e3b1907f1ec247981a1214052371eada61070c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 22 Jul 2023 23:07:55 +0300 Subject: [PATCH 0041/1140] (#18639) xsd: migrate to Conan v2 --- recipes/xsd/all/conandata.yml | 5 - recipes/xsd/all/conanfile.py | 116 +++++++++---------- recipes/xsd/all/test_package/conanfile.py | 11 +- recipes/xsd/all/test_v1_package/conanfile.py | 10 ++ 4 files changed, 73 insertions(+), 69 deletions(-) create mode 100644 recipes/xsd/all/test_v1_package/conanfile.py diff --git a/recipes/xsd/all/conandata.yml b/recipes/xsd/all/conandata.yml index d0b47cfe2aef66..342ac8fd08fed3 100644 --- a/recipes/xsd/all/conandata.yml +++ b/recipes/xsd/all/conandata.yml @@ -5,12 +5,7 @@ sources: patches: "4.0.0": - patch_file: "patches/0002-missing-include.patch" - base_path: "source_subfolder" - patch_file: "patches/0100-C++Parser_Expat_support.patch" - base_path: "source_subfolder" - patch_file: "patches/0105-Fix_path_handling_bug.patch" - base_path: "source_subfolder" - patch_file: "patches/0110-xerces-c3.2.patch" - base_path: "source_subfolder" - patch_file: "patches/0700_hurd_PATH_MAX.patch" - base_path: "source_subfolder" diff --git a/recipes/xsd/all/conanfile.py b/recipes/xsd/all/conanfile.py index 19183a5008e25f..8d9e15a3818f47 100644 --- a/recipes/xsd/all/conanfile.py +++ b/recipes/xsd/all/conanfile.py @@ -1,91 +1,87 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.40.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get, rmdir +from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class ConanXqilla(ConanFile): name = "xsd" - description = ( - "XSD is a W3C XML Schema to C++ translator. It generates vocabulary-specific, statically-typed C++ mappings (also called bindings) from XML Schema definitions. XSD supports two C++ mappings: in-memory C++/Tree and event-driven C++/Parser." + "XSD is a W3C XML Schema to C++ translator. " + "It generates vocabulary-specific, statically-typed C++ mappings (also called bindings) from XML Schema definitions. " + "XSD supports two C++ mappings: in-memory C++/Tree and event-driven C++/Parser." ) - topics = ("xsd", "xml", "c++") + license = ("GPL-2.0", "FLOSSE") url = "https://github.com/conan-io/conan-center-index" homepage = "https://codesynthesis.com/projects/xsd/" - license = ("GPL-2.0","FLOSSE") + topics = ("xml", "c++") + + package_type = "application" settings = "os", "arch", "compiler", "build_type" - exports_sources = "patches/**" + def export_sources(self): + export_conandata_patches(self) - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): self.requires("xerces-c/3.2.3") - @property - def _doc_folder(self): - return os.path.join(self._source_subfolder,"xsd","doc") - - @property - def _make_cmd(self): - return self._gnumake_cmd - - @property - def _make_program(self): - return tools.get_env('CONAN_MAKE_PROGRAM', tools.which('make')) - - @property - def _gnumake_cmd(self): - make_ldflags = "LDFLAGS='{libs} -pthread'".format( - libs=" ".join(["-L{}".format(os.path.join(self.deps_cpp_info["xerces-c"].rootpath, it)) for it in self.deps_cpp_info["xerces-c"].libdirs])) - flags = [] - flags.append(' '.join(["-I{}".format(os.path.join(self.deps_cpp_info["xerces-c"].rootpath, it)) for it in self.deps_cpp_info["xerces-c"].includedirs])) - if self.settings.compiler == "gcc": - flags.append('-std=c++11') - make_ccpflags = "CPPFLAGS='{}'".format(" ".join(flags)) - make_cmd = f'{make_ldflags} {make_ccpflags} {self._make_program} -j{tools.cpu_count()}' - return make_cmd + def package_id(self): + del self.info.settings.compiler def validate(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration("The xsd recipe currently only supports Linux.") if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 11) - - def package_id(self): - del self.info.settings.compiler + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, - destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.extra_cxxflags = ["-std=c++11"] + tc.extra_ldflags = ["-pthread"] + tc.generate() + tc = AutotoolsDeps(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - - with tools.chdir(self._source_subfolder): - self.run(self._make_cmd) + apply_conandata_patches(self) + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.make() def package(self): - self.copy("LICENSE", dst="licenses", src=os.path.join(self._source_subfolder, "xsd")) - self.copy("GPLv2", dst="licenses", src=os.path.join(self._source_subfolder, "xsd")) - self.copy("FLOSSE", dst="licenses", src=os.path.join(self._source_subfolder, "xsd")) - - with tools.chdir(self._source_subfolder): - self.run(self._make_install_cmd) - - tools.rmdir(os.path.join(self.package_folder, "share")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=os.path.join(self.source_folder, "xsd")) + copy(self, "GPLv2", + dst=os.path.join(self.package_folder, "licenses"), + src=os.path.join(self.source_folder, "xsd")) + copy(self, "FLOSSE", + dst=os.path.join(self.package_folder, "licenses"), + src=os.path.join(self.source_folder, "xsd")) + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.install(args=[f"install_prefix={self.package_folder}"]) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): + self.cpp_info.frameworkdirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = [] + self.cpp_info.includedirs = [] + + # TODO: to remove in conan v2 bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_path)) + self.output.info(f"Appending PATH environment variable: {bin_path}") self.env_info.path.append(bin_path) - - @property - def _make_install_cmd(self): - make_install_cmd = f'{self._make_cmd} install_prefix={self.package_folder} install' - return make_install_cmd diff --git a/recipes/xsd/all/test_package/conanfile.py b/recipes/xsd/all/test_package/conanfile.py index 7ea50ba1ad4306..fd802956c6269f 100644 --- a/recipes/xsd/all/test_package/conanfile.py +++ b/recipes/xsd/all/test_package/conanfile.py @@ -1,10 +1,13 @@ -from conans import ConanFile, tools -import os +from conan import ConanFile class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" + generators = "VirtualBuildEnv" + test_type = "explicit" + + def build_requirements(self): + self.tool_requires(self.tested_reference_str) def test(self): - if not tools.cross_building(self): - self.run("xsd --help", run_environment=True) + self.run("xsd --help") diff --git a/recipes/xsd/all/test_v1_package/conanfile.py b/recipes/xsd/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7ea50ba1ad4306 --- /dev/null +++ b/recipes/xsd/all/test_v1_package/conanfile.py @@ -0,0 +1,10 @@ +from conans import ConanFile, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + + def test(self): + if not tools.cross_building(self): + self.run("xsd --help", run_environment=True) From 4e1dc323256090b271aa2246f1e9ef4585b864de Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 22 Jul 2023 23:47:13 +0300 Subject: [PATCH 0042/1140] (#18648) pbtools: migrate to Conan v2 --- recipes/pbtools/all/CMakeLists.txt | 7 --- recipes/pbtools/all/conanfile.py | 59 +++++++++++-------- .../pbtools/all/test_package/CMakeLists.txt | 5 +- recipes/pbtools/all/test_package/conanfile.py | 24 +++++--- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../pbtools/all/test_v1_package/conanfile.py | 25 ++++++++ 6 files changed, 83 insertions(+), 45 deletions(-) delete mode 100644 recipes/pbtools/all/CMakeLists.txt create mode 100644 recipes/pbtools/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/pbtools/all/test_v1_package/conanfile.py diff --git a/recipes/pbtools/all/CMakeLists.txt b/recipes/pbtools/all/CMakeLists.txt deleted file mode 100644 index 432799d5aaab2e..00000000000000 --- a/recipes/pbtools/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder/lib) diff --git a/recipes/pbtools/all/conanfile.py b/recipes/pbtools/all/conanfile.py index 9aee2f753fe6d3..98670e16a72dc7 100644 --- a/recipes/pbtools/all/conanfile.py +++ b/recipes/pbtools/all/conanfile.py @@ -1,53 +1,60 @@ -import functools -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class PbtoolsConan(ConanFile): name = "pbtools" description = "A Google Protocol Buffers C library" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/eerimoq/pbtools" - license = "MIT" topics = ("protobuf", "serialization", "rpc", "protocol-buffers") - settings = ("os", "compiler", "build_type", "arch") - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - exports_sources = "CMakeLists.txt" - generators = "cmake" - - @property - def _source_subfolder(self): - return "source_subfolder" - @property - def _build_subfolder(self): - return "build_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): if self.settings.os == "Windows": raise ConanInvalidConfiguration("This library is not compatible with Windows") def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure(build_folder=self._build_subfolder) - return cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder="lib") cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/pbtools/all/test_package/CMakeLists.txt b/recipes/pbtools/all/test_package/CMakeLists.txt index 9f0ff5e7f11af5..cd447f6cc0d278 100644 --- a/recipes/pbtools/all/test_package/CMakeLists.txt +++ b/recipes/pbtools/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(pbtools REQUIRED CONFIG) add_executable(test_package test_package.c hello_world.c) diff --git a/recipes/pbtools/all/test_package/conanfile.py b/recipes/pbtools/all/test_package/conanfile.py index 1ed584307b354b..bd118a1d0023be 100644 --- a/recipes/pbtools/all/test_package/conanfile.py +++ b/recipes/pbtools/all/test_package/conanfile.py @@ -1,18 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class PbtoolsTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + def requirements(self): + self.requires(self.tested_reference_str) def build_requirements(self): if self.settings.os == "Macos" and self.settings.arch == "armv8": # Attempting to use @rpath without CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG being # set. This could be because you are using a Mac OS X version less than 10.5 # or because CMake's platform configuration is corrupt. - self.build_requires("cmake/3.20.1") + self.tool_requires("cmake/[>=3.20]") + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -20,6 +28,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pbtools/all/test_v1_package/CMakeLists.txt b/recipes/pbtools/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/pbtools/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/pbtools/all/test_v1_package/conanfile.py b/recipes/pbtools/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..1ed584307b354b --- /dev/null +++ b/recipes/pbtools/all/test_v1_package/conanfile.py @@ -0,0 +1,25 @@ +import os + +from conans import ConanFile, CMake, tools + + +class PbtoolsTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build_requirements(self): + if self.settings.os == "Macos" and self.settings.arch == "armv8": + # Attempting to use @rpath without CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG being + # set. This could be because you are using a Mac OS X version less than 10.5 + # or because CMake's platform configuration is corrupt. + self.build_requires("cmake/3.20.1") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 61564e7cf5d970ff8e004ce0105bc8256c3ce0ad Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 00:27:31 +0300 Subject: [PATCH 0043/1140] (#18649) parg: migrate to Conan v2 * parg: migrate to Conan v2 * parg: fix_apple_shared_install_name() --- recipes/parg/all/CMakeLists.txt | 12 +-- recipes/parg/all/conanfile.py | 80 ++++++++++--------- recipes/parg/all/test_package/CMakeLists.txt | 5 +- recipes/parg/all/test_package/conanfile.py | 21 +++-- .../parg/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/parg/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 88 insertions(+), 55 deletions(-) create mode 100644 recipes/parg/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/parg/all/test_v1_package/conanfile.py diff --git a/recipes/parg/all/CMakeLists.txt b/recipes/parg/all/CMakeLists.txt index ea07630def81d0..5aea9449b5c812 100644 --- a/recipes/parg/all/CMakeLists.txt +++ b/recipes/parg/all/CMakeLists.txt @@ -1,12 +1,6 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.15) project(cmake_wrapper) -include("conanbuildinfo.cmake") -conan_basic_setup() -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -add_subdirectory("source_subfolder") - -set_target_properties(parg PROPERTIES PUBLIC_HEADER "${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/parg.h") - +add_subdirectory(src) +set_target_properties(parg PROPERTIES PUBLIC_HEADER "${CMAKE_CURRENT_SOURCE_DIR}/src/parg.h") install(TARGETS parg) diff --git a/recipes/parg/all/conanfile.py b/recipes/parg/all/conanfile.py index 0e70a696cc0392..4947f721cb4dec 100644 --- a/recipes/parg/all/conanfile.py +++ b/recipes/parg/all/conanfile.py @@ -1,60 +1,68 @@ import os -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class PargConan(ConanFile): name = "parg" + description = "Parser for argv that works similarly to getopt" license = "CC0-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/jibsen/parg" - description = "Parser for argv that works similarly to getopt" - topics = ("conan", 'getopt', 'c') - settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], - "fPIC": [True, False]} - default_options = {"shared": False, - "fPIC": True} - exports_sources = ["CMakeLists.txt"] - generators = "cmake", - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + topics = ("getopt", "c") - def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - def configure(self): - if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - def _configure_cmake(self): - if self._cmake: - return self._cmake - cmake = CMake(self) - cmake.configure(build_folder=self._build_subfolder) - self._cmake = cmake - return self._cmake + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["parg"] diff --git a/recipes/parg/all/test_package/CMakeLists.txt b/recipes/parg/all/test_package/CMakeLists.txt index 187d95623fba10..ee46ccf27506c7 100644 --- a/recipes/parg/all/test_package/CMakeLists.txt +++ b/recipes/parg/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(parg REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/parg/all/test_package/conanfile.py b/recipes/parg/all/test_package/conanfile.py index 86f0279553123c..5030221edcc76f 100644 --- a/recipes/parg/all/test_package/conanfile.py +++ b/recipes/parg/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run("%s -h" % bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(f"{bin_path} -h", env="conanrun") diff --git a/recipes/parg/all/test_v1_package/CMakeLists.txt b/recipes/parg/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/parg/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/parg/all/test_v1_package/conanfile.py b/recipes/parg/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..86f0279553123c --- /dev/null +++ b/recipes/parg/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run("%s -h" % bin_path, run_environment=True) From ecd6a668b4f5438cd436070890a8d7fa8d18ddcf Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 01:06:45 +0300 Subject: [PATCH 0044/1140] (#18651) imguizmo: migrate to Conan v2 * imguizmo: migrate to Conan v2 * imguizmo: get rid of version range in dep --- recipes/imguizmo/all/CMakeLists.txt | 19 +++--- recipes/imguizmo/all/conanfile.py | 60 +++++++++++-------- .../imguizmo/all/test_package/CMakeLists.txt | 12 ++-- .../imguizmo/all/test_package/conanfile.py | 22 +++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../imguizmo/all/test_v1_package/conanfile.py | 16 +++++ 6 files changed, 86 insertions(+), 51 deletions(-) create mode 100644 recipes/imguizmo/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/imguizmo/all/test_v1_package/conanfile.py diff --git a/recipes/imguizmo/all/CMakeLists.txt b/recipes/imguizmo/all/CMakeLists.txt index 73784d828761a7..00a03f50329728 100644 --- a/recipes/imguizmo/all/CMakeLists.txt +++ b/recipes/imguizmo/all/CMakeLists.txt @@ -1,27 +1,22 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.15) project(imguizmo CXX) + set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) - -include(conanbuildinfo.cmake) -conan_basic_setup() - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) -set(SOURCE_DIR source_subfolder) +set(SOURCE_DIR src) file(GLOB SOURCE_FILES ${SOURCE_DIR}/*.cpp) file(GLOB HEADER_FILES ${SOURCE_DIR}/*.h) +find_package(imgui CONFIG REQUIRED) + add_library(${PROJECT_NAME} ${SOURCE_FILES}) target_include_directories(${PROJECT_NAME} PRIVATE ${SOURCE_DIR}) -target_link_libraries(${PROJECT_NAME} PUBLIC ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PUBLIC imgui::imgui) include(GNUInstallDirs) - -install(TARGETS ${PROJECT_NAME} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}) +install(TARGETS ${PROJECT_NAME}) install(FILES ${HEADER_FILES} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ) diff --git a/recipes/imguizmo/all/conanfile.py b/recipes/imguizmo/all/conanfile.py index 62c65e6489c8be..57281934555cff 100644 --- a/recipes/imguizmo/all/conanfile.py +++ b/recipes/imguizmo/all/conanfile.py @@ -1,31 +1,33 @@ -import functools -from conans import ConanFile, CMake, tools +import os + +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class ImGuizmoConan(ConanFile): name = "imguizmo" + description = "Immediate mode 3D gizmo for scene editing and other controls based on Dear Imgui" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/CedricGuillemet/ImGuizmo" - description = "Immediate mode 3D gizmo for scene editing and other controls based on Dear Imgui" topics = ("imgui", "3d", "graphics", "guizmo") - license = "MIT" - settings = "os", "arch", "compiler", "build_type" - - exports_sources = ["CMakeLists.txt"] - generators = "cmake" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False] + "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -33,28 +35,34 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("imgui/1.87") + # 1.89 is the newest imgui version compatible with imguizmo + self.requires("imgui/1.89.3", transitive_headers=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/imguizmo/all/test_package/CMakeLists.txt b/recipes/imguizmo/all/test_package/CMakeLists.txt index 4db4d9b97252ba..bca22087e39204 100644 --- a/recipes/imguizmo/all/test_package/CMakeLists.txt +++ b/recipes/imguizmo/all/test_package/CMakeLists.txt @@ -1,13 +1,11 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -find_package(imgui REQUIRED) -find_package(imguizmo REQUIRED) +find_package(imgui REQUIRED CONFIG) +find_package(imguizmo REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} imgui::imgui) diff --git a/recipes/imguizmo/all/test_package/conanfile.py b/recipes/imguizmo/all/test_package/conanfile.py index 23ba95e79f465d..ef5d7042163ecc 100644 --- a/recipes/imguizmo/all/test_package/conanfile.py +++ b/recipes/imguizmo/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/imguizmo/all/test_v1_package/CMakeLists.txt b/recipes/imguizmo/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/imguizmo/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/imguizmo/all/test_v1_package/conanfile.py b/recipes/imguizmo/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/imguizmo/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From ea21feadf70b8ff01a7754ee073bf6c19810c709 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 01:46:32 +0300 Subject: [PATCH 0045/1140] (#18653) libipt: migrate to Conan v2 --- recipes/libipt/all/CMakeLists.txt | 7 -- recipes/libipt/all/conanfile.py | 80 +++++++++---------- .../libipt/all/test_package/CMakeLists.txt | 5 +- recipes/libipt/all/test_package/conanfile.py | 20 +++-- .../libipt/all/test_package/test_package.cpp | 3 +- .../libipt/all/test_v1_package/CMakeLists.txt | 8 ++ .../libipt/all/test_v1_package/conanfile.py | 18 +++++ 7 files changed, 80 insertions(+), 61 deletions(-) delete mode 100644 recipes/libipt/all/CMakeLists.txt create mode 100644 recipes/libipt/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libipt/all/test_v1_package/conanfile.py diff --git a/recipes/libipt/all/CMakeLists.txt b/recipes/libipt/all/CMakeLists.txt deleted file mode 100644 index f62f6ae283c5ff..00000000000000 --- a/recipes/libipt/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.0) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/libipt/all/conanfile.py b/recipes/libipt/all/conanfile.py index 73c8a14fe3622e..e7687b6d7c00d7 100644 --- a/recipes/libipt/all/conanfile.py +++ b/recipes/libipt/all/conanfile.py @@ -1,30 +1,34 @@ -from conans import ConanFile, CMake, tools +import os + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get + +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.33.0" class LibIptConan(ConanFile): name = "libipt" + description = "Intel(R) Processor Trace Decoder Library" license = "BSD-3-Clause" - homepage = "https://github.com/intel/libipt" url = "https://github.com/conan-io/conan-center-index" - description = "Intel(R) Processor Trace Decoder Library" + homepage = "https://github.com/intel/libipt" topics = ("profiling", "tracing") - settings = "os", "compiler", "build_type", "arch" + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { - "shared": [True, False], - "fPIC": [True, False], + "shared": [True, False], + "fPIC": [True, False], } default_options = { - "shared": False, - "fPIC": True, + "shared": False, + "fPIC": True, } - generators = "cmake" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -32,43 +36,35 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): - pass + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - self._patch_sources() - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() def package_info(self): - self.cpp_info.libs = ["libipt"] if self.settings.os == "Windows" else ["ipt"] - self.cpp_info.set_property("cmake_file_name", "libipt") - self.cpp_info.set_property("cmake_target_name", "libipt::libipt") - + if self.settings.os == "Windows": + self.cpp_info.libs = ["libipt"] + else: + self.cpp_info.libs = ["ipt"] diff --git a/recipes/libipt/all/test_package/CMakeLists.txt b/recipes/libipt/all/test_package/CMakeLists.txt index 614fc23d88dda8..9f56367278f327 100644 --- a/recipes/libipt/all/test_package/CMakeLists.txt +++ b/recipes/libipt/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(libipt REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/libipt/all/test_package/conanfile.py b/recipes/libipt/all/test_package/conanfile.py index a8c92dea633357..ef5d7042163ecc 100644 --- a/recipes/libipt/all/test_package/conanfile.py +++ b/recipes/libipt/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools - class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libipt/all/test_package/test_package.cpp b/recipes/libipt/all/test_package/test_package.cpp index 6b9e18b8eb1337..26def6a295d25c 100644 --- a/recipes/libipt/all/test_package/test_package.cpp +++ b/recipes/libipt/all/test_package/test_package.cpp @@ -1,9 +1,8 @@ #include -int main(int argc, char **argv) +int main() { pt_config cfg; pt_config_init(&cfg); - return 0; } diff --git a/recipes/libipt/all/test_v1_package/CMakeLists.txt b/recipes/libipt/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libipt/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libipt/all/test_v1_package/conanfile.py b/recipes/libipt/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a8c92dea633357 --- /dev/null +++ b/recipes/libipt/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 9fd06ff6274bd443a27c4dd7fc4ca7bb7aa794da Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 02:26:23 +0300 Subject: [PATCH 0046/1140] (#18655) whereami: migrate to Conan v2 --- recipes/whereami/all/CMakeLists.txt | 14 ++-- recipes/whereami/all/conanfile.py | 68 ++++++++++--------- .../whereami/all/test_package/CMakeLists.txt | 5 +- .../whereami/all/test_package/conanfile.py | 21 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../whereami/all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 82 insertions(+), 51 deletions(-) create mode 100644 recipes/whereami/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/whereami/all/test_v1_package/conanfile.py diff --git a/recipes/whereami/all/CMakeLists.txt b/recipes/whereami/all/CMakeLists.txt index 9ad1b58bfdd925..4595ccd0654eb5 100644 --- a/recipes/whereami/all/CMakeLists.txt +++ b/recipes/whereami/all/CMakeLists.txt @@ -1,14 +1,11 @@ -cmake_minimum_required(VERSION 3.4.3) +cmake_minimum_required(VERSION 3.12) project(whereami C) -include(conanbuildinfo.cmake) -conan_basic_setup() - if (WIN32 AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() -set(WHEREAMI_SRC "${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder") +set(WHEREAMI_SRC "${CMAKE_CURRENT_SOURCE_DIR}/src") set(SOURCE_FILES ${WHEREAMI_SRC}/src/whereami.c) set(HEADER_FILES ${WHEREAMI_SRC}/src/whereami.h) @@ -17,9 +14,6 @@ add_library(${CMAKE_PROJECT_NAME} ${SOURCE_FILES} ${HEADER_FILES}) target_include_directories(${CMAKE_PROJECT_NAME} PUBLIC ${WHEREAMI_SRC}/src) set_property(TARGET ${CMAKE_PROJECT_NAME} PROPERTY C_STANDARD 99) -install(TARGETS ${CMAKE_PROJECT_NAME} - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib) - +include(GNUInstallDirs) +install(TARGETS ${CMAKE_PROJECT_NAME}) install(FILES ${HEADER_FILES} DESTINATION include) diff --git a/recipes/whereami/all/conanfile.py b/recipes/whereami/all/conanfile.py index 323a8747c8641c..6035268b447eec 100644 --- a/recipes/whereami/all/conanfile.py +++ b/recipes/whereami/all/conanfile.py @@ -1,58 +1,64 @@ -from conans import ConanFile, CMake, tools +import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class WhereamiConan(ConanFile): name = "whereami" description = "Locate the current executable and the current module/library on the file system" - topics = ("whereami", "introspection", "getmodulefilename", - "dladdr", "executable-path", "getexecutablepath") + license = ("MIT", "WTFPL") url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/gpakosz/whereami" - license = ("MIT", "WTFPL") - exports_sources = ["CMakeLists.txt"] - generators = "cmake" - settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} + topics = ("whereami", "introspection", "getmodulefilename", "dladdr", "executable-path", "getexecutablepath") - _cmake = None + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") - def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + def layout(self): + cmake_layout(self, src_folder="src") - def _configure_cmake(self): - if self._cmake: - return self._cmake + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy(pattern="LICENSE.*", dst="licenses", - src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE.*", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/whereami/all/test_package/CMakeLists.txt b/recipes/whereami/all/test_package/CMakeLists.txt index 7c0f4c847fb311..4789557edaa689 100644 --- a/recipes/whereami/all/test_package/CMakeLists.txt +++ b/recipes/whereami/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(whereami REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/whereami/all/test_package/conanfile.py b/recipes/whereami/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/whereami/all/test_package/conanfile.py +++ b/recipes/whereami/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/whereami/all/test_v1_package/CMakeLists.txt b/recipes/whereami/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/whereami/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/whereami/all/test_v1_package/conanfile.py b/recipes/whereami/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/whereami/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 29ad596337985938836bfa0037c0e3929b90d393 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 03:07:55 +0300 Subject: [PATCH 0047/1140] (#18658) rg-etc1: migrate to Conan v2 --- recipes/rg-etc1/all/CMakeLists.txt | 16 ++-- recipes/rg-etc1/all/conanfile.py | 75 ++++++++++--------- .../rg-etc1/all/test_package/CMakeLists.txt | 10 +-- recipes/rg-etc1/all/test_package/conanfile.py | 21 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../rg-etc1/all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 89 insertions(+), 58 deletions(-) create mode 100644 recipes/rg-etc1/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rg-etc1/all/test_v1_package/conanfile.py diff --git a/recipes/rg-etc1/all/CMakeLists.txt b/recipes/rg-etc1/all/CMakeLists.txt index 5f0b2b410ca60b..5d4d0f4829476e 100644 --- a/recipes/rg-etc1/all/CMakeLists.txt +++ b/recipes/rg-etc1/all/CMakeLists.txt @@ -1,22 +1,16 @@ cmake_minimum_required(VERSION 3.4) project(cmake_wrapper) -include(conanbuildinfo.cmake) -conan_basic_setup() - if(WIN32 AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() -file(GLOB SRCS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/*.cpp) -file(GLOB HDRS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/*.h) +file(GLOB SRCS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/src/*.cpp) +file(GLOB HDRS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/src/*.h) add_library(rg_etc1 ${SRCS_FILES}) -target_include_directories(rg_etc1 PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder) +target_include_directories(rg_etc1 PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/src) -install(TARGETS rg_etc1 - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib -) +include(GNUInstallDirs) +install(TARGETS rg_etc1) install(FILES ${HDRS_FILES} DESTINATION include) diff --git a/recipes/rg-etc1/all/conanfile.py b/recipes/rg-etc1/all/conanfile.py index 43c69a50b6b5c9..1a5ed53523f885 100644 --- a/recipes/rg-etc1/all/conanfile.py +++ b/recipes/rg-etc1/all/conanfile.py @@ -1,17 +1,22 @@ import os -import glob -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import collect_libs, copy, get, save + +required_conan_version = ">=1.53.0" class RgEtc1Conan(ConanFile): name = "rg-etc1" description = "A performant, easy to use, and high quality 4x4 pixel block packer/unpacker for the ETC1." - homepage = "https://github.com/richgel999/rg-etc1" - url = "https://github.com/conan-io/conan-center-index" - topics = ("conan", "etc1", "packer", "unpacker") license = "Zlib" - exports_sources = ["CMakeLists.txt"] - generators = "cmake" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/richgel999/rg-etc1" + topics = ("etc1", "packer", "unpacker") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -22,53 +27,51 @@ class RgEtc1Conan(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob('rg-etc1-*/')[0] - os.rename(extracted_dir, self._source_subfolder) + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, 11) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def _extract_license(self): - with open(os.path.join(self._source_subfolder, "rg_etc1.h")) as f: + with open(os.path.join(self.source_folder, "rg_etc1.h")) as f: content_lines = f.readlines() license_content = [] for i in range(52, 75): license_content.append(content_lines[i][2:-1]) - tools.save("LICENSE", "\n".join(license_content)) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), "\n".join(license_content)) def package(self): - cmake = self._configure_cmake() - cmake.install() self._extract_license() - self.copy(pattern="LICENSE", dst="licenses") + cmake = CMake(self) + cmake.install() def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = ["rg_etc1"] + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] diff --git a/recipes/rg-etc1/all/test_package/CMakeLists.txt b/recipes/rg-etc1/all/test_package/CMakeLists.txt index 196188113685c8..249e96fb582fbf 100644 --- a/recipes/rg-etc1/all/test_package/CMakeLists.txt +++ b/recipes/rg-etc1/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(rg-etc1 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE rg-etc1::rg-etc1) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/rg-etc1/all/test_package/conanfile.py b/recipes/rg-etc1/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/rg-etc1/all/test_package/conanfile.py +++ b/recipes/rg-etc1/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rg-etc1/all/test_v1_package/CMakeLists.txt b/recipes/rg-etc1/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rg-etc1/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rg-etc1/all/test_v1_package/conanfile.py b/recipes/rg-etc1/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/rg-etc1/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 43a907ca4c560e9a450326950c862812611531e3 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 03:47:27 +0300 Subject: [PATCH 0048/1140] (#18662) libslz: migrate to Conan v2 --- recipes/libslz/all/CMakeLists.txt | 17 ++---- recipes/libslz/all/conanfile.py | 54 ++++++++++--------- .../libslz/all/test_package/CMakeLists.txt | 7 +-- recipes/libslz/all/test_package/conanfile.py | 19 +++++-- .../libslz/all/test_v1_package/CMakeLists.txt | 8 +++ .../libslz/all/test_v1_package/conanfile.py | 17 ++++++ 6 files changed, 75 insertions(+), 47 deletions(-) create mode 100644 recipes/libslz/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libslz/all/test_v1_package/conanfile.py diff --git a/recipes/libslz/all/CMakeLists.txt b/recipes/libslz/all/CMakeLists.txt index 3086b45fa1be2a..84ba240aba82bf 100644 --- a/recipes/libslz/all/CMakeLists.txt +++ b/recipes/libslz/all/CMakeLists.txt @@ -1,24 +1,17 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.12) project(slz LANGUAGES C) -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -include(GNUInstallDirs) - -add_library(slz source_subfolder/src/slz.c) -include_directories(source_subfolder/src) +add_library(slz src/src/slz.c) +include_directories(src/src) set_target_properties(slz PROPERTIES - PUBLIC_HEADER source_subfolder/src/slz.h + PUBLIC_HEADER src/src/slz.h WINDOWS_EXPORT_ALL_SYMBOLS ON C_STANDARD 11 C_EXTENSIONS ON ) +include(GNUInstallDirs) install( TARGETS slz - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} ) diff --git a/recipes/libslz/all/conanfile.py b/recipes/libslz/all/conanfile.py index b33407244e1ebd..56bb34708956f1 100644 --- a/recipes/libslz/all/conanfile.py +++ b/recipes/libslz/all/conanfile.py @@ -1,17 +1,23 @@ -import functools -from conans import ConanFile, CMake, tools -from conans.tools import ConanInvalidConfiguration +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get from conan.tools.microsoft import is_msvc -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" + class LibslzConan(ConanFile): name = "libslz" description = "Simple, modern libpng alternative " - topics = ("zlib", "compression",) license = "X11" url = "https://github.com/conan-io/conan-center-index" homepage = "http://www.libslz.org/" + topics = ("zlib", "compression") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -21,14 +27,9 @@ class LibslzConan(ConanFile): "shared": False, "fPIC": True, } - generators = "cmake" - - @property - def _source_subfolder(self): - return "source_subfolder" def export_sources(self): - self.copy("CMakeLists.txt") + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -36,31 +37,34 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): if is_msvc(self): - raise ConanInvalidConfiguration("{}/{} does not support Visual Studio.".format(self.name, self.version)) + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC.") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses", ignore_case=True, keep_path=False) - cmake = self._configure_cmake() + copy(self, "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), keep_path=False) + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/libslz/all/test_package/CMakeLists.txt b/recipes/libslz/all/test_package/CMakeLists.txt index 13e3af8ad27912..14c66f6f3d628f 100644 --- a/recipes/libslz/all/test_package/CMakeLists.txt +++ b/recipes/libslz/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(libslz REQUIRED) +find_package(libslz REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} libslz::libslz) diff --git a/recipes/libslz/all/test_package/conanfile.py b/recipes/libslz/all/test_package/conanfile.py index 19e6a0c06e3d81..fae501d0afb9e4 100644 --- a/recipes/libslz/all/test_package/conanfile.py +++ b/recipes/libslz/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libslz/all/test_v1_package/CMakeLists.txt b/recipes/libslz/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libslz/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libslz/all/test_v1_package/conanfile.py b/recipes/libslz/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/libslz/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 2037dc950bd85fb76c76f15419b3c8b062f3098e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 04:26:59 +0300 Subject: [PATCH 0049/1140] (#18664) iqa: migrate to Conan v2 --- recipes/iqa/all/CMakeLists.txt | 18 ++--- recipes/iqa/all/conanfile.py | 65 +++++++++---------- recipes/iqa/all/test_package/CMakeLists.txt | 7 +- recipes/iqa/all/test_package/conanfile.py | 23 +++++-- .../iqa/all/test_v1_package/CMakeLists.txt | 8 +++ recipes/iqa/all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 80 insertions(+), 58 deletions(-) create mode 100644 recipes/iqa/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/iqa/all/test_v1_package/conanfile.py diff --git a/recipes/iqa/all/CMakeLists.txt b/recipes/iqa/all/CMakeLists.txt index 04c167a387fc10..6b7355d4159537 100644 --- a/recipes/iqa/all/CMakeLists.txt +++ b/recipes/iqa/all/CMakeLists.txt @@ -1,22 +1,16 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.12) project(cmake_wrapper) -include(conanbuildinfo.cmake) -conan_basic_setup() - if(MSVC AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() -file(GLOB IQA_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/source/*.c) -file(GLOB IQA_HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/include/*.h) +file(GLOB IQA_SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/src/source/*.c) +file(GLOB IQA_HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/src/include/*.h) add_library(iqa ${IQA_SOURCES}) -target_include_directories(iqa PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/include) +target_include_directories(iqa PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/src/include) -install(TARGETS iqa - ARCHIVE DESTINATION lib - LIBRARY DESTINATION lib - RUNTIME DESTINATION bin -) +include(GNUInstallDirs) +install(TARGETS iqa) install(FILES ${IQA_HEADERS} DESTINATION include) diff --git a/recipes/iqa/all/conanfile.py b/recipes/iqa/all/conanfile.py index 1f64617c876763..5fed7c16effcfd 100644 --- a/recipes/iqa/all/conanfile.py +++ b/recipes/iqa/all/conanfile.py @@ -1,16 +1,22 @@ import os -import glob -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import collect_libs, copy, get, save + +required_conan_version = ">=1.53.0" class IqaConan(ConanFile): name = "iqa" description = "Image Quality Analysis Library" license = "BSD-3-Clause" - topics = ("conan", "iqa", "image", "quality", "analysis") - homepage = "https://github.com/tjdistler/iqa" url = "https://github.com/conan-io/conan-center-index" - settings = "os", "compiler", "build_type", "arch" + homepage = "https://github.com/tjdistler/iqa" + topics = ("image", "quality", "analysis") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -19,18 +25,9 @@ class IqaConan(ConanFile): "shared": False, "fPIC": True, } - exports_sources = ["CMakeLists.txt"] - generators = "cmake" - - _cmake = None - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -38,40 +35,38 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob('iqa-*/')[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def _extract_license(self): - content_lines = open(os.path.join(self._source_subfolder, "include", "iqa.h")).readlines() + content_lines = open(os.path.join(self.source_folder, "include", "iqa.h")).readlines() license_content = [] for i in range(1, 31): license_content.append(content_lines[i][3:-1]) - tools.save("LICENSE", "\n".join(license_content)) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), "\n".join(license_content)) def package(self): - cmake = self._configure_cmake() - cmake.install() self._extract_license() - self.copy("LICENSE", dst="licenses") + cmake = CMake(self) + cmake.install() def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = collect_libs(self) if self.settings.os == "Linux": self.cpp_info.system_libs = ["m"] diff --git a/recipes/iqa/all/test_package/CMakeLists.txt b/recipes/iqa/all/test_package/CMakeLists.txt index 094a38e418f47a..54014934310409 100644 --- a/recipes/iqa/all/test_package/CMakeLists.txt +++ b/recipes/iqa/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(iqa REQUIRED CONFIG) add_executable(test_package test_package.c) -target_link_libraries(test_package ${CONAN_LIBS}) +target_link_libraries(test_package PRIVATE iqa::iqa) diff --git a/recipes/iqa/all/test_package/conanfile.py b/recipes/iqa/all/test_package/conanfile.py index 02bdaace3b783f..ef5d7042163ecc 100644 --- a/recipes/iqa/all/test_package/conanfile.py +++ b/recipes/iqa/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/iqa/all/test_v1_package/CMakeLists.txt b/recipes/iqa/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/iqa/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/iqa/all/test_v1_package/conanfile.py b/recipes/iqa/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..54e4743603cf39 --- /dev/null +++ b/recipes/iqa/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b91047ad2c32fa74ad00c9fd870d364c4abca815 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 05:08:04 +0300 Subject: [PATCH 0050/1140] (#18665) astro-informatics-so3: migrate to Conan v2 --- .../astro-informatics-so3/all/CMakeLists.txt | 7 -- .../astro-informatics-so3/all/conanfile.py | 81 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 87 insertions(+), 54 deletions(-) delete mode 100644 recipes/astro-informatics-so3/all/CMakeLists.txt create mode 100644 recipes/astro-informatics-so3/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/astro-informatics-so3/all/test_v1_package/conanfile.py diff --git a/recipes/astro-informatics-so3/all/CMakeLists.txt b/recipes/astro-informatics-so3/all/CMakeLists.txt deleted file mode 100644 index 0496b298385496..00000000000000 --- a/recipes/astro-informatics-so3/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.0) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/astro-informatics-so3/all/conanfile.py b/recipes/astro-informatics-so3/all/conanfile.py index 24be830f3db99a..e7486ed5b8c5a4 100644 --- a/recipes/astro-informatics-so3/all/conanfile.py +++ b/recipes/astro-informatics-so3/all/conanfile.py @@ -1,69 +1,78 @@ -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration +import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" class AstroInformaticsSO3(ConanFile): name = "astro-informatics-so3" + description = "Fast and accurate Wigner transforms" license = "GPL-3.0-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/astro-informatics/so3" - description = "Fast and accurate Wigner transforms" - settings = "os", "arch", "compiler", "build_type" topics = ("physics", "astrophysics", "radio interferometry") - options = {"fPIC": [True, False]} - default_options = {"fPIC": True} - - generators = "cmake", "cmake_find_package" - exports_sources = ["CMakeLists.txt"] - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): + self.requires("ssht/1.4.0", transitive_headers=True) self.requires("fftw/3.3.9") - self.requires("ssht/1.3.7") def validate(self): - if self.settings.compiler == "Visual Studio": + if is_msvc(self): raise ConanInvalidConfiguration( "Visual Studio not supported, since SO3 requires C99 support for complex numbers" ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - @property - def cmake(self): - if not hasattr(self, "_cmake"): - self._cmake = CMake(self) - self._cmake.definitions["conan_deps"] = False - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["conan_deps"] = False + tc.variables["CONAN_EXPORTED"] = True + tc.variables["BUILD_TESTING"] = False + tc.generate() + deps = CMakeDeps(self) + deps.set_property("fftw", "cmake_target_name", "FFTW3::FFTW3") + deps.generate() def build(self): - self.cmake.build() + cmake = CMake(self) + cmake.configure() + cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.cmake.install() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) + cmake.install() def package_info(self): self.cpp_info.libs = ["astro-informatics-so3"] diff --git a/recipes/astro-informatics-so3/all/test_package/CMakeLists.txt b/recipes/astro-informatics-so3/all/test_package/CMakeLists.txt index aecca63b59f686..6e7e3d57dba81f 100644 --- a/recipes/astro-informatics-so3/all/test_package/CMakeLists.txt +++ b/recipes/astro-informatics-so3/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -find_package(astro-informatics-so3 REQUIRED NO_MODULE) +find_package(astro-informatics-so3 REQUIRED CONFIG) add_executable(${PROJECT_NAME} example.c) target_compile_features(${PROJECT_NAME} PUBLIC c_std_99) diff --git a/recipes/astro-informatics-so3/all/test_package/conanfile.py b/recipes/astro-informatics-so3/all/test_package/conanfile.py index abcaeed3f89b67..ef5d7042163ecc 100644 --- a/recipes/astro-informatics-so3/all/test_package/conanfile.py +++ b/recipes/astro-informatics-so3/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/astro-informatics-so3/all/test_v1_package/CMakeLists.txt b/recipes/astro-informatics-so3/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/astro-informatics-so3/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/astro-informatics-so3/all/test_v1_package/conanfile.py b/recipes/astro-informatics-so3/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/astro-informatics-so3/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 2703f9515f6594d2de93f10c8ca72a719e35fd34 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 05:47:06 +0300 Subject: [PATCH 0051/1140] (#18671) libmbus: migrate to Conan v2 --- recipes/libmbus/all/CMakeLists.txt | 7 -- recipes/libmbus/all/conanfile.py | 87 +++++++++---------- .../libmbus/all/test_package/CMakeLists.txt | 9 +- recipes/libmbus/all/test_package/conanfile.py | 22 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../libmbus/all/test_v1_package/conanfile.py | 18 ++++ 6 files changed, 85 insertions(+), 66 deletions(-) delete mode 100644 recipes/libmbus/all/CMakeLists.txt create mode 100644 recipes/libmbus/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libmbus/all/test_v1_package/conanfile.py diff --git a/recipes/libmbus/all/CMakeLists.txt b/recipes/libmbus/all/CMakeLists.txt deleted file mode 100644 index 361b35d4c17d9a..00000000000000 --- a/recipes/libmbus/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/libmbus/all/conanfile.py b/recipes/libmbus/all/conanfile.py index 5c3ff6e87aae2c..841dbf22c8b0d9 100644 --- a/recipes/libmbus/all/conanfile.py +++ b/recipes/libmbus/all/conanfile.py @@ -1,36 +1,31 @@ import os -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir + +required_conan_version = ">=1.53.0" class LibMbusConan(ConanFile): name = "libmbus" + description = "Meter-bus library and utility programs" license = "BSD-3-Clause" - homepage = "https://github.com/rscada/libmbus" url = "https://github.com/conan-io/conan-center-index" - description = """Meter-bus library and utility programs""" - topics = "conan", "mbus", "metering", "iot", "meter", "bus", "protocol" - exports_sources = "CMakeLists.txt" - settings = "os", "compiler", "build_type", "arch" + homepage = "https://github.com/rscada/libmbus" + topics = ("mbus", "metering", "iot", "meter", "bus", "protocol") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False] + "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } - generators = "cmake", "cmake_find_package" - - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" def config_options(self): if self.settings.os == "Windows": @@ -38,43 +33,41 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): if self.settings.os not in ["Linux"]: - raise ConanInvalidConfiguration("Only Linux supported") - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + raise ConanInvalidConfiguration("Only Linux is supported") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + \ - os.path.basename( - self.conan_data["sources"][self.version]["url"]).split(".")[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions['LIBMBUS_ENABLE_COVERAGE'] = False - self._cmake.definitions['LIBMBUS_BUILD_TESTS'] = False - self._cmake.definitions['LIBMBUS_BUILD_EXAMPLES'] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LIBMBUS_ENABLE_COVERAGE"] = False + tc.variables["LIBMBUS_BUILD_TESTS"] = False + tc.variables["LIBMBUS_BUILD_EXAMPLES"] = False + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, - "lib", "libmbus", "cmake")) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "libmbus", "cmake")) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - if self.settings.os == "Linux": + self.cpp_info.libs = ["libmbus"] + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["pthread", "m"] diff --git a/recipes/libmbus/all/test_package/CMakeLists.txt b/recipes/libmbus/all/test_package/CMakeLists.txt index 34af13462f44f8..076d1645a34b0e 100644 --- a/recipes/libmbus/all/test_package/CMakeLists.txt +++ b/recipes/libmbus/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libmbus REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE libmbus::libmbus) diff --git a/recipes/libmbus/all/test_package/conanfile.py b/recipes/libmbus/all/test_package/conanfile.py index 933dbf96533ae4..fae501d0afb9e4 100644 --- a/recipes/libmbus/all/test_package/conanfile.py +++ b/recipes/libmbus/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" -class TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - bin_path = self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libmbus/all/test_v1_package/CMakeLists.txt b/recipes/libmbus/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libmbus/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libmbus/all/test_v1_package/conanfile.py b/recipes/libmbus/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..9de3689208f00b --- /dev/null +++ b/recipes/libmbus/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + bin_path = self.run(bin_path, run_environment=True) From 1214ee4ecc21e09c2bb471df8f4fd1249d0a0927 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 23 Jul 2023 06:27:12 +0300 Subject: [PATCH 0052/1140] (#18703) libgta: migrate to Conan v2 --- recipes/libgta/all/CMakeLists.txt | 7 -- recipes/libgta/all/conanfile.py | 102 ++++++++++-------- .../libgta/all/test_package/CMakeLists.txt | 7 +- recipes/libgta/all/test_package/conanfile.py | 21 ++-- .../libgta/all/test_v1_package/CMakeLists.txt | 8 ++ .../libgta/all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 103 insertions(+), 59 deletions(-) delete mode 100644 recipes/libgta/all/CMakeLists.txt create mode 100644 recipes/libgta/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libgta/all/test_v1_package/conanfile.py diff --git a/recipes/libgta/all/CMakeLists.txt b/recipes/libgta/all/CMakeLists.txt deleted file mode 100644 index 217b9530b904d4..00000000000000 --- a/recipes/libgta/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/libgta/all/conanfile.py b/recipes/libgta/all/conanfile.py index a0064e504c27d2..a15e741e867e1a 100644 --- a/recipes/libgta/all/conanfile.py +++ b/recipes/libgta/all/conanfile.py @@ -1,69 +1,87 @@ import os -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import collect_libs, copy, get, replace_in_file, rmdir +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" + class LibgtaConan(ConanFile): name = "libgta" description = "Library that reads and writes GTA (Generic Tagged Arrays) files." license = "LGPL-2.1-or-later" - topics = ("conan", "libgta", "gta") - homepage = "https://marlam.de/gta" url = "https://github.com/conan-io/conan-center-index" - exports_sources = "CMakeLists.txt" - generators = "cmake" - settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + homepage = "https://marlam.de/gta" + topics = ("gta",) - @property - def _build_subfolder(self): - return "build_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename(self.name + "-" + self.version, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["GTA_BUILD_STATIC_LIB"] = not self.options.shared + tc.variables["GTA_BUILD_SHARED_LIB"] = self.options.shared + tc.variables["GTA_BUILD_DOCUMENTATION"] = False + tc.generate() + + tc = CMakeDeps(self) + tc.generate() + + def _patch_sources(self): + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "${CMAKE_SOURCE_DIR}", + "${CMAKE_CURRENT_SOURCE_DIR}") def build(self): - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), - "${CMAKE_SOURCE_DIR}", "${CMAKE_CURRENT_SOURCE_DIR}") - cmake = self._configure_cmake() + self._patch_sources() + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["GTA_BUILD_STATIC_LIB"] = not self.options.shared - self._cmake.definitions["GTA_BUILD_SHARED_LIB"] = self.options.shared - self._cmake.definitions["GTA_BUILD_DOCUMENTATION"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): + # https://marlam.de/gta/documentation/ uses GTA as the package name + self.cpp_info.set_property("cmake_file_name", "GTA") + self.cpp_info.set_property("cmake_target_name", "GTA::GTA") + self.cpp_info.set_property("pkg_config_name", "gta") + self.cpp_info.libs = collect_libs(self) + if is_msvc(self) and not self.options.shared: + self.cpp_info.defines.append("GTA_STATIC") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.names["cmake_find_package"] = "GTA" self.cpp_info.names["cmake_find_package_multi"] = "GTA" - self.cpp_info.names["pkg_config"] = "gta" - self.cpp_info.libs = tools.collect_libs(self) - if self.settings.compiler == "Visual Studio" and not self.options.shared: - self.cpp_info.defines.append("GTA_STATIC") diff --git a/recipes/libgta/all/test_package/CMakeLists.txt b/recipes/libgta/all/test_package/CMakeLists.txt index 7b9b613cbb24a3..3bb9ae06e8bb8e 100644 --- a/recipes/libgta/all/test_package/CMakeLists.txt +++ b/recipes/libgta/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(GTA REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE GTA::GTA) diff --git a/recipes/libgta/all/test_package/conanfile.py b/recipes/libgta/all/test_package/conanfile.py index ea57a464900be9..ef5d7042163ecc 100644 --- a/recipes/libgta/all/test_package/conanfile.py +++ b/recipes/libgta/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libgta/all/test_v1_package/CMakeLists.txt b/recipes/libgta/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libgta/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libgta/all/test_v1_package/conanfile.py b/recipes/libgta/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..84ee68733e5167 --- /dev/null +++ b/recipes/libgta/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os + +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From eda10bab6beaaa2a079caeca765057f165a80ffa Mon Sep 17 00:00:00 2001 From: choll Date: Sun, 23 Jul 2023 23:10:42 +0100 Subject: [PATCH 0053/1140] (#18856) xtr: bump to 2.1.0 --- recipes/xtr/all/conandata.yml | 3 +++ recipes/xtr/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/xtr/all/conandata.yml b/recipes/xtr/all/conandata.yml index 73147ae0731499..c4c7a036934fc6 100644 --- a/recipes/xtr/all/conandata.yml +++ b/recipes/xtr/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.1.0": + url: "https://github.com/choll/xtr/archive/refs/tags/2.1.0.tar.gz" + sha256: "5abe2e53d91a893d63998968450d9bbfc23c45f552c81e2b7d17694699ab17c4" "2.0.1": url: "https://github.com/choll/xtr/archive/refs/tags/2.0.1.tar.gz" sha256: "92327264541900a2c9d43aaa3070d143d5e91879737fcea8cbf56065330af059" diff --git a/recipes/xtr/config.yml b/recipes/xtr/config.yml index 066b0d5ac74d1a..ecc6dca2fd252d 100644 --- a/recipes/xtr/config.yml +++ b/recipes/xtr/config.yml @@ -1,4 +1,6 @@ versions: + "2.1.0": + folder: all "2.0.1": folder: all "2.0.0": From 1d8e33a55811ffc5ea3f1135ccc7b07c79e74cf5 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 24 Jul 2023 08:02:53 +0200 Subject: [PATCH 0054/1140] (#18838) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 31 ++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index d9f1bd61e113ac..a660a23ab7baa0 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -13,6 +13,7 @@ required_for_references: - aeron - aggeom-agg - alac +- alembic - alpaca - amgcl - amqp-cpp @@ -25,6 +26,7 @@ required_for_references: - apr - apr-util - apriltag +- archicad-apidevkit - arcus - arduinojson - arg_router @@ -37,6 +39,7 @@ required_for_references: - arsenalgear - artery-font-format - asio +- asio-grpc - asmjit - astc-codec - async_simple @@ -57,6 +60,7 @@ required_for_references: - aws-c-mqtt - aws-c-sdkutils - aws-checksums +- aws-libfabric - b2 - b64 - backport-cpp @@ -143,6 +147,7 @@ required_for_references: - cmake - cmocka - cmp +- cn-cbor - cnpy - coin-cgl - coin-clp @@ -172,6 +177,7 @@ required_for_references: - cpptoml - cppunit - cpputest +- cppzmq - cpr - cpu_features - cpuinfo @@ -231,12 +237,15 @@ required_for_references: - earcut - eastl - easy_profiler +- easyhttpcpp - ecos - editline - edlib +- edyn - effcee - effolkronium-random - egl +- egl-headers - eigen - elfio - embree3 @@ -260,9 +269,13 @@ required_for_references: - fakeit - farmhash - fast-cdr +- fast-cpp-csv-parser - fast-dds +- fast_double_parser - fast_float - fastgltf +- fastpfor +- fastprng - fernandovelcic-hexdump - fff - ffmpeg @@ -278,6 +291,7 @@ required_for_references: - fontconfig - foonathan-lexy - foonathan-memory +- forestdb - foxglove-schemas-protobuf - fp16 - freeglut @@ -310,6 +324,7 @@ required_for_references: - glm - glog - glpk +- glshaderpp - glslang - glu - gmp @@ -354,6 +369,7 @@ required_for_references: - imake - imath - imgui +- imguizmo - incbin - indicators - indirect_value @@ -431,6 +447,7 @@ required_for_references: - libiberty - libiconv - libinterpolate +- libipt - libjpeg - libjpeg-turbo - libkml @@ -441,6 +458,7 @@ required_for_references: - libmediainfo - libmemcached - libmikmod +- libmnl - libmodbus - libmodplug - libmorton @@ -472,6 +490,7 @@ required_for_references: - libselinux - libserial - libsgp4 +- libslz - libsmacker - libsndfile - libsodium @@ -527,8 +546,10 @@ required_for_references: - mailio - make - mariadb-connector-c +- marisa - matchit - mathter +- matio - mattiasgustavsson-libs - maven - mawk @@ -626,7 +647,9 @@ required_for_references: - p-ranav-glob - paho-mqtt-c - paho-mqtt-cpp +- parg - patchelf +- pbtools - pcapplusplus - pcg-cpp - pcre @@ -658,6 +681,7 @@ required_for_references: - pugixml - pulseaudio - pybind11 +- pybind11_json - pystring - qhull - qpdf @@ -687,6 +711,7 @@ required_for_references: - replxx - restbed - restinio +- rg-etc1 - ring-span-lite - rmm - roaring @@ -711,6 +736,7 @@ required_for_references: - sentry-breakpad - sentry-crashpad - sentry-native +- seqan - serd - serdepp - sfml @@ -741,6 +767,7 @@ required_for_references: - sqlitecpp - sqlpp11 - ssht +- st_tree - status-code - stb - stlab @@ -768,6 +795,7 @@ required_for_references: - thrift - thrust - timsort +- tiny-dnn - tinycthread - tinycthreadpool - tinydir @@ -782,6 +810,7 @@ required_for_references: - tlx - toml11 - trantor +- tree-sitter - troldal-zippy - tsl-hopscotch-map - turtle @@ -826,6 +855,7 @@ required_for_references: - websocketpp - wg21-linear_algebra - wglext +- whereami - whisper-cpp - wil - winflexbison @@ -849,6 +879,7 @@ required_for_references: - xorg-makedepend - xorg-proto - xoshiro-cpp +- xsd - xsimd - xtensor - xtl From aafe6899408fecc46b52c992b1695a588dc3692d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 24 Jul 2023 08:23:03 +0200 Subject: [PATCH 0055/1140] (#18767) [bot] Update list of references (prod-v2/ListPackages) From 1b4b0279c9b20856f49cdb0cfbe7b308c243e8a1 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 24 Jul 2023 08:42:30 +0200 Subject: [PATCH 0056/1140] (#18774) [bot] Update list of references (prod-v2/ListPackages) From a3fae2a757f8a6fafc7c712510f4190dd8dd5329 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 24 Jul 2023 09:02:23 +0200 Subject: [PATCH 0057/1140] (#18851) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index a660a23ab7baa0..9b1a2220981186 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -42,6 +42,7 @@ required_for_references: - asio-grpc - asmjit - astc-codec +- astro-informatics-so3 - async_simple - asyncly - asyncplusplus @@ -281,10 +282,12 @@ required_for_references: - ffmpeg - fft - fftw +- fire-hpp - flac - flann - flatbuffers - flatbush +- flecs - flex - fmt - fmtlog @@ -293,10 +296,15 @@ required_for_references: - foonathan-memory - forestdb - foxglove-schemas-protobuf +- foxi - fp16 - freeglut +- freeimage - freetype +- freexl +- fribidi - frozen +- fruit - ftxui - function2 - fxdiv @@ -378,6 +386,7 @@ required_for_references: - inja - intel-neon2sse - inversify-cpp +- iqa - itlib - jasper - jbig @@ -443,6 +452,7 @@ required_for_references: - libgpg-error - libgphoto2 - libgpiod +- libgta - libharu - libiberty - libiconv @@ -455,6 +465,7 @@ required_for_references: - libltc - liblzf - libmad +- libmbus - libmediainfo - libmemcached - libmikmod From 8e73e146e9791c11b42693f2cb9b947b1df1715a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 24 Jul 2023 10:29:53 +0300 Subject: [PATCH 0058/1140] (#18709) cpp-ipc: migrate to Conan v2 * cpp-ipc: migrate to Conan v2 * cpp-ipc: restore is_apple_os usage * cpp-ipc: add m --- recipes/cpp-ipc/all/CMakeLists.txt | 7 -- recipes/cpp-ipc/all/conanfile.py | 90 +++++++++++-------- .../cpp-ipc/all/test_package/CMakeLists.txt | 5 +- recipes/cpp-ipc/all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../cpp-ipc/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 92 insertions(+), 56 deletions(-) delete mode 100644 recipes/cpp-ipc/all/CMakeLists.txt create mode 100644 recipes/cpp-ipc/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cpp-ipc/all/test_v1_package/conanfile.py diff --git a/recipes/cpp-ipc/all/CMakeLists.txt b/recipes/cpp-ipc/all/CMakeLists.txt deleted file mode 100644 index e17d82eddcc5dd..00000000000000 --- a/recipes/cpp-ipc/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.12) -project(cmake_wrapper LANGUAGES CXX) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/cpp-ipc/all/conanfile.py b/recipes/cpp-ipc/all/conanfile.py index b11041af3f5940..5baa058938b2bf 100644 --- a/recipes/cpp-ipc/all/conanfile.py +++ b/recipes/cpp-ipc/all/conanfile.py @@ -1,17 +1,26 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.33.0" class CppIPCConan(ConanFile): name = "cpp-ipc" description = "C++ IPC Library: A high-performance inter-process communication using shared memory on Linux/Windows." - topics = ("ipc", "shared memory", ) + license = ("MIT",) url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/mutouyun/cpp-ipc" - license = "MIT", + topics = ("ipc", "shared memory") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" - exports_sources = ["CMakeLists.txt"] options = { "shared": [True, False], "fPIC": [True, False], @@ -21,19 +30,18 @@ class CppIPCConan(ConanFile): "fPIC": True, } - generators = "cmake" - - _compiler_required_cpp17 = { - "Visual Studio": "17", - "gcc": "8", - "clang": "4", - } - - _cmake = None + @property + def _min_cppstd(self): + return 17 @property - def _source_subfolder(self): - return "source_subfolder" + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "4", + "msvc": "193", + "Visual Studio": "17", + } def config_options(self): if self.settings.os == "Windows": @@ -41,47 +49,51 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): - if tools.is_apple_os(self.settings.os): - raise ConanInvalidConfiguration("{} does not support Apple platform".format(self.name)) + if is_apple_os(self): + raise ConanInvalidConfiguration(f"{self.name} does not support Apple platform") if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) + check_min_cppstd(self, self._min_cppstd) - minimum_version = self._compiler_required_cpp17.get(str(self.settings.compiler), False) + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{} requires C++17, which your compiler does not support.".format(self.name)) + if Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration(f"{self.name} requires C++{self._min_cppstd}, " + "which your compiler does not support.") else: - self.output.warn("{0} requires C++17. Your compiler is unknown. Assuming it supports C++17.".format(self.name)) + self.output.warning(f"{self.name} requires C++{self._min_cppstd}. Your compiler is unknown. " + f"Assuming it supports C++{self._min_cppstd}.") if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": - raise ConanInvalidConfiguration("{} doesn't support clang with libc++".format(self.name)) + raise ConanInvalidConfiguration(f"{self.name} doesn't support clang with libc++") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["LIBIPC_BUILD_SHARED_LIBS"] = self.options.shared - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LIBIPC_BUILD_SHARED_LIBS"] = self.options.shared + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): self.cpp_info.libs = ["ipc"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["rt", "pthread"] + self.cpp_info.system_libs = ["rt", "pthread", "m"] diff --git a/recipes/cpp-ipc/all/test_package/CMakeLists.txt b/recipes/cpp-ipc/all/test_package/CMakeLists.txt index c258338b9324e3..ad0594de35161f 100644 --- a/recipes/cpp-ipc/all/test_package/CMakeLists.txt +++ b/recipes/cpp-ipc/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(cpp-ipc REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/cpp-ipc/all/test_package/conanfile.py b/recipes/cpp-ipc/all/test_package/conanfile.py index 49a3a66ea5bad4..fae501d0afb9e4 100644 --- a/recipes/cpp-ipc/all/test_package/conanfile.py +++ b/recipes/cpp-ipc/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cpp-ipc/all/test_v1_package/CMakeLists.txt b/recipes/cpp-ipc/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cpp-ipc/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cpp-ipc/all/test_v1_package/conanfile.py b/recipes/cpp-ipc/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/cpp-ipc/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From d32bd41c2ede09ffe33643c7e458e3c20e19aa48 Mon Sep 17 00:00:00 2001 From: Jacob Bandes-Storch Date: Mon, 24 Jul 2023 01:12:05 -0700 Subject: [PATCH 0059/1140] (#18784) mcap: add version 1.1.0 and 1.2.0 * mcap: add version 1.1.0 and 1.2.0 * add tested_reference_str --- recipes/mcap/all/conandata.yml | 6 ++++++ recipes/mcap/all/test_package/conanfile.py | 3 +++ recipes/mcap/config.yml | 4 ++++ 3 files changed, 13 insertions(+) diff --git a/recipes/mcap/all/conandata.yml b/recipes/mcap/all/conandata.yml index 4d475c04d971cc..a1bc6133e68c96 100644 --- a/recipes/mcap/all/conandata.yml +++ b/recipes/mcap/all/conandata.yml @@ -1,4 +1,10 @@ sources: + 1.2.0: + url: "https://github.com/foxglove/mcap/archive/refs/tags/releases/cpp/v1.2.0/main.tar.gz" + sha256: "11a6badecac2b10e9687e912648a6e9679ef8731e4ab9570346ae9845ae64a65" + 1.1.0: + url: "https://github.com/foxglove/mcap/archive/refs/tags/releases/cpp/v1.1.0/main.tar.gz" + sha256: "1cb2ae9f2e910eeb2e93b3ab722744d1805b9da45764e4fd88703b669413350d" 1.0.0: url: "https://github.com/foxglove/mcap/archive/refs/tags/releases/cpp/v1.0.0/main.tar.gz" sha256: "e36169e46a67a9431f73df335f67488461817bc423f9af63ac0af7f29e0bd696" diff --git a/recipes/mcap/all/test_package/conanfile.py b/recipes/mcap/all/test_package/conanfile.py index 14c16cdc02a92e..615cc1d54ffccc 100644 --- a/recipes/mcap/all/test_package/conanfile.py +++ b/recipes/mcap/all/test_package/conanfile.py @@ -11,6 +11,9 @@ class TestPackageConan(ConanFile): def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() diff --git a/recipes/mcap/config.yml b/recipes/mcap/config.yml index 8d906d6516e977..bfc72fea8d81a1 100644 --- a/recipes/mcap/config.yml +++ b/recipes/mcap/config.yml @@ -1,4 +1,8 @@ versions: + 1.2.0: + folder: all + 1.1.0: + folder: all 1.0.0: folder: all 0.9.0: From 4f03f6573bc2035ee42bc6d1a7c6a7af9b636767 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 24 Jul 2023 17:50:46 +0900 Subject: [PATCH 0060/1140] (#18825) xxhash: add version 0.8.2, add package_type --- recipes/xxhash/all/conandata.yml | 4 +++- recipes/xxhash/all/conanfile.py | 9 ++++----- recipes/xxhash/config.yml | 2 ++ 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/recipes/xxhash/all/conandata.yml b/recipes/xxhash/all/conandata.yml index a0b4d68deb6b49..06fb02fd0ae832 100644 --- a/recipes/xxhash/all/conandata.yml +++ b/recipes/xxhash/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.8.2": + url: "https://github.com/Cyan4973/xxHash/archive/v0.8.2.tar.gz" + sha256: "baee0c6afd4f03165de7a4e67988d16f0f2b257b51d0e3cb91909302a26a79c4" "0.8.1": url: "https://github.com/Cyan4973/xxHash/archive/v0.8.1.tar.gz" sha256: "3bb6b7d6f30c591dd65aaaff1c8b7a5b94d81687998ca9400082c739a690436c" @@ -10,7 +13,6 @@ patches: - patch_file: "patches/0.8.1-fix-cmakelists.patch" patch_description: "Update CMakeLists.txt to properly install manuals" patch_type: conan - - patch_file: "patches/0.8.1-fix-static-assert-link-error.patch" patch_source: "https://github.com/Cyan4973/xxHash/commit/6189ecd3d44a693460f86280ccf49d33cb4b18e1" patch_description: "Backport fix for link error" diff --git a/recipes/xxhash/all/conanfile.py b/recipes/xxhash/all/conanfile.py index 7ce90e1beb92a5..3e018a810c976a 100644 --- a/recipes/xxhash/all/conanfile.py +++ b/recipes/xxhash/all/conanfile.py @@ -8,12 +8,12 @@ class XxHashConan(ConanFile): name = "xxhash" + description = "Extremely fast non-cryptographic hash algorithm" + license = "BSD-2-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/Cyan4973/xxHash" - description = "Extremely fast non-cryptographic hash algorithm" topics = ("hash", "algorithm", "fast", "checksum", "hash-functions") - license = "BSD-2-Clause" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -43,8 +43,7 @@ def layout(self): cmake_layout(self, src_folder="src") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/xxhash/config.yml b/recipes/xxhash/config.yml index 20824a4afbb4d3..50595ee5e49136 100644 --- a/recipes/xxhash/config.yml +++ b/recipes/xxhash/config.yml @@ -1,4 +1,6 @@ versions: + "0.8.2": + folder: all "0.8.1": folder: all "0.8.0": From 2446b360494107ceae62dd885b3d6c52fdfdc453 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 25 Jul 2023 17:53:19 +0300 Subject: [PATCH 0061/1140] (#18740) libnfnetlink: migrate to Conan v2 Co-authored-by: Daniel --- recipes/libnfnetlink/all/conanfile.py | 87 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 22 +++-- .../libnfnetlink/all/test_package/example.cpp | 5 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 18 ++++ 6 files changed, 92 insertions(+), 55 deletions(-) create mode 100644 recipes/libnfnetlink/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libnfnetlink/all/test_v1_package/conanfile.py diff --git a/recipes/libnfnetlink/all/conanfile.py b/recipes/libnfnetlink/all/conanfile.py index 10540d39fbf9cb..3797ae3ceea3a6 100644 --- a/recipes/libnfnetlink/all/conanfile.py +++ b/recipes/libnfnetlink/all/conanfile.py @@ -1,67 +1,70 @@ import os -import functools -from conans import ConanFile, tools, AutoToolsBuildEnvironment -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.53.0" + class LibnfnetlinkConan(ConanFile): name = "libnfnetlink" + description = "low-level library for netfilter related kernel/userspace communication" license = "GPL-2.0-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://netfilter.org/projects/libnfnetlink/index.html" - description = "low-level library for netfilter related kernel/userspace communication" - topics = ("libnfnetlink", "netlink", "netfilter") - settings = "os", "compiler", "build_type", "arch" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} + topics = ("netlink", "netfilter") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration("libnfnetlink is only supported on Linux") - def configure(self): - if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_autotools(self): - autotools = AutoToolsBuildEnvironment(self) - conf_args = [] - if self.options.shared: - conf_args.extend(["--enable-shared", "--disable-static"]) - else: - conf_args.extend(["--disable-shared", "--enable-static"]) - autotools.configure(configure_dir=self._source_subfolder, args=conf_args) - return autotools + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() def build(self): - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + autotools = Autotools(self) autotools.install() - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "etc")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "etc")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.libs = ["nfnetlink"] - self.cpp_info.set_property("pkg_config_name", "libnfnetlink") - - # TODO: to remove in conan v2 once pkg_config generator is removed - self.cpp_info.names["pkg_config"] = "libnfnetlink" + self.cpp_info.set_property("pkg_config_name", "libnfnetlink") diff --git a/recipes/libnfnetlink/all/test_package/CMakeLists.txt b/recipes/libnfnetlink/all/test_package/CMakeLists.txt index d4fdee1a8a79c3..7e1aa1808dfd53 100644 --- a/recipes/libnfnetlink/all/test_package/CMakeLists.txt +++ b/recipes/libnfnetlink/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libnfnetlink REQUIRED CONFIG) add_executable(example example.cpp) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example libnfnetlink::libnfnetlink) diff --git a/recipes/libnfnetlink/all/test_package/conanfile.py b/recipes/libnfnetlink/all/test_package/conanfile.py index e4f1965959dece..e0f447388fa1b4 100644 --- a/recipes/libnfnetlink/all/test_package/conanfile.py +++ b/recipes/libnfnetlink/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain" + test_type = "explicit" -class LibnfnetlinkTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/libnfnetlink/all/test_package/example.cpp b/recipes/libnfnetlink/all/test_package/example.cpp index 95153d8532f515..395453bdde08aa 100644 --- a/recipes/libnfnetlink/all/test_package/example.cpp +++ b/recipes/libnfnetlink/all/test_package/example.cpp @@ -1,7 +1,8 @@ -#include -#include #include +#include +#include + int main() { struct nfnl_handle *nl = nfnl_open(); if (nl == NULL) { diff --git a/recipes/libnfnetlink/all/test_v1_package/CMakeLists.txt b/recipes/libnfnetlink/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libnfnetlink/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libnfnetlink/all/test_v1_package/conanfile.py b/recipes/libnfnetlink/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..c8689f282274d7 --- /dev/null +++ b/recipes/libnfnetlink/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class LibnfnetlinkTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From 108aa461a886be7a09ee5bf50faf91141e6fb2de Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Tue, 25 Jul 2023 19:46:00 +0200 Subject: [PATCH 0062/1140] (#18634) add svgpp library * add svgpp * add c++11 compiler feature to test_package fix * Update recipes/svgpp/all/conanfile.py --------- Co-authored-by: Carlos Zoido --- recipes/svgpp/all/conandata.yml | 4 ++ recipes/svgpp/all/conanfile.py | 59 +++++++++++++++++++ recipes/svgpp/all/test_package/CMakeLists.txt | 8 +++ recipes/svgpp/all/test_package/conanfile.py | 26 ++++++++ .../svgpp/all/test_package/test_package.cpp | 23 ++++++++ recipes/svgpp/config.yml | 3 + 6 files changed, 123 insertions(+) create mode 100644 recipes/svgpp/all/conandata.yml create mode 100644 recipes/svgpp/all/conanfile.py create mode 100644 recipes/svgpp/all/test_package/CMakeLists.txt create mode 100644 recipes/svgpp/all/test_package/conanfile.py create mode 100644 recipes/svgpp/all/test_package/test_package.cpp create mode 100644 recipes/svgpp/config.yml diff --git a/recipes/svgpp/all/conandata.yml b/recipes/svgpp/all/conandata.yml new file mode 100644 index 00000000000000..b4612b44411377 --- /dev/null +++ b/recipes/svgpp/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "cci.20221030": + url: "https://github.com/svgpp/svgpp/archive/1583a7b209038bfd0d98c6ce7d4c93986f7b235e.tar.gz" + sha256: "95f4145c43aada913e7b24e37d20d0eef5f170a7c70e00ffcb318a3910b43ca6" diff --git a/recipes/svgpp/all/conanfile.py b/recipes/svgpp/all/conanfile.py new file mode 100644 index 00000000000000..f683b8d50fc0bc --- /dev/null +++ b/recipes/svgpp/all/conanfile.py @@ -0,0 +1,59 @@ +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +import os + + +required_conan_version = ">=1.52.0" + + +class SvgPPConan(ConanFile): + name = "svgpp" + description = "SVG++ library contains parsers for various SVG syntaxes, " \ + "adapters that simplify handling of parsed data and a lot of other utilities and helpers for the most common tasks." + license = "BSL-1.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/svgpp/svgpp" + topics = ("svgpp", "svg", "parser", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("boost/1.82.0", transitive_headers=True) + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def build(self): + pass + + def package(self): + copy(self, pattern="LICENSE_1_0.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + self.cpp_info.requires.append("boost::headers") diff --git a/recipes/svgpp/all/test_package/CMakeLists.txt b/recipes/svgpp/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..366f84e91c3066 --- /dev/null +++ b/recipes/svgpp/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(svgpp REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE svgpp::svgpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/svgpp/all/test_package/conanfile.py b/recipes/svgpp/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/svgpp/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/svgpp/all/test_package/test_package.cpp b/recipes/svgpp/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..cb8c51e57fb338 --- /dev/null +++ b/recipes/svgpp/all/test_package/test_package.cpp @@ -0,0 +1,23 @@ +#include +#include +#include + +using namespace svgpp; + +struct Context +{ + void transform_matrix(const boost::array & matrix) + { + std::copy(matrix.begin(), matrix.end(), + std::ostream_iterator(std::cout, " ")); + std::cout << "\n"; + } +}; + +int main() +{ + Context context; + value_parser::parse(tag::attribute::transform(), context, + std::string("translate(-10,-20) scale(2) rotate(45) translate(5,10)"), tag::source::attribute()); + return 0; +} diff --git a/recipes/svgpp/config.yml b/recipes/svgpp/config.yml new file mode 100644 index 00000000000000..d6e527e7221f41 --- /dev/null +++ b/recipes/svgpp/config.yml @@ -0,0 +1,3 @@ +versions: + "cci.20221030": + folder: "all" From a547bc7a5c09a7108421c59cce729eeb70cad55b Mon Sep 17 00:00:00 2001 From: qwqbot Date: Wed, 26 Jul 2023 11:07:44 +0800 Subject: [PATCH 0063/1140] (#18858) add intx * add intx * fix * test v1 * compiler check * resolve comment * clean import --------- Co-authored-by: Carlos Zoido --- recipes/intx/all/conandata.yml | 4 ++ recipes/intx/all/conanfile.py | 65 +++++++++++++++++++ recipes/intx/all/test_package/CMakeLists.txt | 8 +++ recipes/intx/all/test_package/conanfile.py | 26 ++++++++ .../intx/all/test_package/test_package.cpp | 6 ++ .../intx/all/test_v1_package/CMakeLists.txt | 9 +++ recipes/intx/all/test_v1_package/conanfile.py | 18 +++++ recipes/intx/config.yml | 3 + 8 files changed, 139 insertions(+) create mode 100644 recipes/intx/all/conandata.yml create mode 100644 recipes/intx/all/conanfile.py create mode 100644 recipes/intx/all/test_package/CMakeLists.txt create mode 100644 recipes/intx/all/test_package/conanfile.py create mode 100644 recipes/intx/all/test_package/test_package.cpp create mode 100644 recipes/intx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/intx/all/test_v1_package/conanfile.py create mode 100644 recipes/intx/config.yml diff --git a/recipes/intx/all/conandata.yml b/recipes/intx/all/conandata.yml new file mode 100644 index 00000000000000..82ca4023ed3e56 --- /dev/null +++ b/recipes/intx/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.10.1": + url: "https://github.com/chfast/intx/archive/v0.10.1.tar.gz" + sha256: "4663073458b5e0564e92058e5aa1a7ce88634fc72827191856b17bd7335de29b" diff --git a/recipes/intx/all/conanfile.py b/recipes/intx/all/conanfile.py new file mode 100644 index 00000000000000..7d3e3dcf60652b --- /dev/null +++ b/recipes/intx/all/conanfile.py @@ -0,0 +1,65 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import get, copy +from conan.tools.build import check_min_cppstd +from conan.tools.scm import Version +from conan.tools.layout import basic_layout +import os + +required_conan_version = ">=1.51.1" + +class IntxConan(ConanFile): + name = "intx" + description = "Extended precision integer C++ library" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/chfast/intx" + topics = ("evm", "biginteger", "arbitrary-precision", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + + @property + def _min_cppstd(self): + return 20 + + def layout(self): + basic_layout(self, src_folder="src") + + @property + def _compilers_minimum_version(self): + return { + "Visual Studio": "16", + "msvc": "192", + "gcc": "12", + "clang": "15", + "apple-clang": "14.1", + } + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.get_safe("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) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/intx/all/test_package/CMakeLists.txt b/recipes/intx/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..460d6198ba06f5 --- /dev/null +++ b/recipes/intx/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.12) +project(test_package LANGUAGES CXX) + +find_package(intx REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE intx::intx) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20) diff --git a/recipes/intx/all/test_package/conanfile.py b/recipes/intx/all/test_package/conanfile.py new file mode 100644 index 00000000000000..a9fb96656f2039 --- /dev/null +++ b/recipes/intx/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/intx/all/test_package/test_package.cpp b/recipes/intx/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..e9521bde28299a --- /dev/null +++ b/recipes/intx/all/test_package/test_package.cpp @@ -0,0 +1,6 @@ +#include + +int main(int argc, char**) +{ + return static_cast(intx::uint512{argc} / (intx::uint512{1} << 111)); +} diff --git a/recipes/intx/all/test_v1_package/CMakeLists.txt b/recipes/intx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..9652e22fc19d54 --- /dev/null +++ b/recipes/intx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.12) + +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/intx/all/test_v1_package/conanfile.py b/recipes/intx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..5a05af3c2dfd2f --- /dev/null +++ b/recipes/intx/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake +from conan.tools.build import cross_building +import os + + +class TestPackageV1Conan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/intx/config.yml b/recipes/intx/config.yml new file mode 100644 index 00000000000000..36cf695df0df63 --- /dev/null +++ b/recipes/intx/config.yml @@ -0,0 +1,3 @@ +versions: + "0.10.1": + folder: all From a628dae46424b0bc7ce8089b66fb33bc08664de5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 2 Aug 2023 12:28:56 +0300 Subject: [PATCH 0064/1140] (#18754) upx: migrate to Conan v2 Co-authored-by: Carlos Zoido --- recipes/upx/all/conanfile.py | 56 ++++++++++++------- recipes/upx/all/test_package/CMakeLists.txt | 5 +- recipes/upx/all/test_package/conanfile.py | 24 +++++--- recipes/upx/all/test_package/test_package.c | 2 +- .../upx/all/test_v1_package/CMakeLists.txt | 8 +++ recipes/upx/all/test_v1_package/conanfile.py | 35 ++++++++++++ 6 files changed, 96 insertions(+), 34 deletions(-) create mode 100644 recipes/upx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/upx/all/test_v1_package/conanfile.py diff --git a/recipes/upx/all/conanfile.py b/recipes/upx/all/conanfile.py index ebbe1deba6846c..4a0f911cedf71e 100644 --- a/recipes/upx/all/conanfile.py +++ b/recipes/upx/all/conanfile.py @@ -1,23 +1,29 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get + +required_conan_version = ">=1.47.0" class UPXConan(ConanFile): name = "upx" description = "UPX - the Ultimate Packer for eXecutables " - license = "GPL-2.0-or-later", "special-exception-for-compressed-executables" + license = ("GPL-2.0-or-later", "special-exception-for-compressed-executables") url = "https://github.com/conan-io/conan-center-index" homepage = "https://upx.github.io/" - topics = ("packer", "executable", "compression", "size", "reduction", "small", "footprintt") - no_copy_source = True - settings = "os", "arch" + topics = ("packer", "executable", "compression", "size", "reduction", "small", "footprintt", "pre-built") + + package_type = "application" + settings = "os", "arch", "compiler", "build_type" + + def layout(self): + pass - @property - def _source_subfolder(self): - return "source_subfolder" + def package_id(self): + del self.info.settings.compiler + del self.info.settings.build_type def _conan_data_sources(self): # Don't surround this with try/catch to catch unknown versions @@ -32,24 +38,32 @@ def validate(self): raise ConanInvalidConfiguration(f"This recipe has no upx binary for os/arch={self.settings.os}/{self.settings.arch}") def build(self): - tools.get(**self._conan_data_sources(), - destination=self._source_subfolder, strip_root=True) + get(self, **self._conan_data_sources(), strip_root=True) def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - if self.settings.os == "Windows": - self.copy("upx.exe", src=self._source_subfolder, dst="bin") - else: - self.copy("upx", src=self._source_subfolder, dst="bin") + copy(self, "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "COPYING", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + extension = ".exe" if self.settings.os == "Windows" else "" + copy(self, f"upx{extension}", + src=self.source_folder, + dst=os.path.join(self.package_folder, "bin")) def package_info(self): + self.cpp_info.frameworkdirs = [] + self.cpp_info.resdirs = [] + self.cpp_info.includedirs = [] self.cpp_info.libdirs = [] bin_path = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bin_path}") - self.env_info.PATH.append(bin_path) - bin_ext = ".exe" if self.settings.os == "Windows" else "" upx = os.path.join(bin_path, f"upx{bin_ext}") + self.conf_info.define("user.upx:upx", upx) + + # TODO: to remove in conan v2 + self.output.info(f"Appending PATH environment variable: {bin_path}") + self.env_info.PATH.append(bin_path) self.user_info.upx = upx diff --git a/recipes/upx/all/test_package/CMakeLists.txt b/recipes/upx/all/test_package/CMakeLists.txt index f31cfe1e1aa8e2..e58a04fd19cf11 100644 --- a/recipes/upx/all/test_package/CMakeLists.txt +++ b/recipes/upx/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) if(CMAKE_C_COMPILER_ID MATCHES "AppleClang|Clang|GNU") add_link_options(-static) endif() -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/upx/all/test_package/conanfile.py b/recipes/upx/all/test_package/conanfile.py index 8274c17267c149..8d1367a88209a0 100644 --- a/recipes/upx/all/test_package/conanfile.py +++ b/recipes/upx/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def build_requirements(self): + self.tool_requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,21 +21,20 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self, skip_x64_x86=True): + if can_run(self): bin_ext = ".exe" if self.settings.os == "Windows" else "" - bin_path = os.path.join("bin", f"test_package{bin_ext}") + bin_path = os.path.join(self.cpp.build.bindir, f"test_package{bin_ext}") - upx_bin = self.deps_user_info["upx"].upx - self.run(f"{upx_bin} --help", run_environment=True) + self.run(f"upx --help") original_size = os.stat(bin_path).st_size - self.run(f"{upx_bin} {bin_path}", run_environment=True) + self.run(f"upx {bin_path}") packed_size = os.stat(bin_path).st_size # Run the packed executable to see whether it still works - self.run(bin_path, run_environment=True) + self.run(bin_path, env="conanrun") self.output.info(f"File: {bin_path}") self.output.info(f"Original size: {original_size:>9}") diff --git a/recipes/upx/all/test_package/test_package.c b/recipes/upx/all/test_package/test_package.c index 725533f119f429..f81e0540072d72 100644 --- a/recipes/upx/all/test_package/test_package.c +++ b/recipes/upx/all/test_package/test_package.c @@ -1,6 +1,6 @@ #include -int main(int argc, char *argv[]) { +int main() { puts("Hello world!"); return 0; } diff --git a/recipes/upx/all/test_v1_package/CMakeLists.txt b/recipes/upx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/upx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/upx/all/test_v1_package/conanfile.py b/recipes/upx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..2b7a8250c99373 --- /dev/null +++ b/recipes/upx/all/test_v1_package/conanfile.py @@ -0,0 +1,35 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self, skip_x64_x86=True): + bin_ext = ".exe" if self.settings.os == "Windows" else "" + bin_path = os.path.join("bin", f"test_package{bin_ext}") + + upx_bin = self.deps_user_info["upx"].upx + self.run(f"{upx_bin} --help", run_environment=True) + + original_size = os.stat(bin_path).st_size + + self.run(f"{upx_bin} {bin_path}", run_environment=True) + + packed_size = os.stat(bin_path).st_size + + # Run the packed executable to see whether it still works + self.run(bin_path, run_environment=True) + + self.output.info(f"File: {bin_path}") + self.output.info(f"Original size: {original_size:>9}") + self.output.info(f"Packed size: {packed_size:>9}") + self.output.info(f" ---------") + self.output.info(f"Size diff: {original_size-packed_size:>9}") From 4660fa8c40ef4827d529d73c201eb3d6854d6ad3 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 2 Aug 2023 18:59:29 +0900 Subject: [PATCH 0065/1140] (#18918) unordered_dense: add version 4.0.4, remove older versions --- recipes/unordered_dense/all/conandata.yml | 15 +++------------ recipes/unordered_dense/config.yml | 10 ++-------- 2 files changed, 5 insertions(+), 20 deletions(-) diff --git a/recipes/unordered_dense/all/conandata.yml b/recipes/unordered_dense/all/conandata.yml index b69698c93c08e0..5002689bc73b04 100644 --- a/recipes/unordered_dense/all/conandata.yml +++ b/recipes/unordered_dense/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.0.4": + url: "https://github.com/martinus/unordered_dense/archive/v4.0.4.tar.gz" + sha256: "b34a8c942963e3a647f1bbc192a6391cd56d7ae615b2ddc1601c1779b5792206" "4.0.1": url: "https://github.com/martinus/unordered_dense/archive/v4.0.1.tar.gz" sha256: "6c8be4f76fed592f8c1ae07ce07eaa8749ed3a929a84a502764564dcbcc53a76" @@ -14,24 +17,12 @@ sources: "3.0.2": url: "https://github.com/martinus/unordered_dense/archive/v3.0.2.tar.gz" sha256: "0c0b874e9682cce3c75a1152308bfbb108538aaf1e90824d7789e2b64122520b" - "3.0.0": - url: "https://github.com/martinus/unordered_dense/archive/v3.0.0.tar.gz" - sha256: "e73452d7c1e274b4a15b553c0904f1de4bcfa61b00514acd1eaad7deac805ef0" "2.0.1": url: "https://github.com/martinus/unordered_dense/archive/v2.0.1.tar.gz" sha256: "450d53bd8709f9476702a3c4975bf6e40d66059b25b125e480534228d7f5616d" - "2.0.0": - url: "https://github.com/martinus/unordered_dense/archive/v2.0.0.tar.gz" - sha256: "e838bdcf380a1aeb6f1fee17fbdf59d7a14b6b9fb6dfca32981e4cbd60739d20" "1.4.0": url: "https://github.com/martinus/unordered_dense/archive/v1.4.0.tar.gz" sha256: "36b6bfe2fe2633f9d9c537b9b808b4be6b77ff51c66d370d855f477517bc3bc9" "1.3.3": url: "https://github.com/martinus/unordered_dense/archive/v1.3.3.tar.gz" sha256: "621a984d7f1de156d3078ecb5e1252bcc2ebc875de6eb6b8635f6c2a0898e496" - "1.3.2": - url: "https://github.com/martinus/unordered_dense/archive/v1.3.2.tar.gz" - sha256: "f12db3b93f31f7f20f4d8cac6adc551f6ae17a5b9a16040abeee427f54427953" - "1.3.1": - url: "https://github.com/martinus/unordered_dense/archive/refs/tags/v1.3.1.tar.gz" - sha256: "d393168833d6609c9eaf54a05b19fc3120f68b85feffb282ab225119a86df1d4" diff --git a/recipes/unordered_dense/config.yml b/recipes/unordered_dense/config.yml index 50c688a80fb211..f99a8339fb5703 100644 --- a/recipes/unordered_dense/config.yml +++ b/recipes/unordered_dense/config.yml @@ -1,4 +1,6 @@ versions: + "4.0.4": + folder: all "4.0.1": folder: all "4.0.0": @@ -9,17 +11,9 @@ versions: folder: all "3.0.2": folder: all - "3.0.0": - folder: all "2.0.1": folder: all - "2.0.0": - folder: all "1.4.0": folder: all "1.3.3": folder: all - "1.3.2": - folder: all - "1.3.1": - folder: all From bf7fb309c2cc4becab033a24af9ca6364ee5524d Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 2 Aug 2023 19:16:01 +0900 Subject: [PATCH 0066/1140] (#18966) cpp-httplib: add version 0.13.3 * cpp-httplib: add version 0.13.2 * update 0.13.3 --- recipes/cpp-httplib/all/conandata.yml | 3 +++ recipes/cpp-httplib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cpp-httplib/all/conandata.yml b/recipes/cpp-httplib/all/conandata.yml index dff9808ae31f26..448d3a594468dc 100644 --- a/recipes/cpp-httplib/all/conandata.yml +++ b/recipes/cpp-httplib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.13.3": + url: "https://github.com/yhirose/cpp-httplib/archive/v0.13.3.tar.gz" + sha256: "2a4503f9f2015f6878baef54cd94b01849cc3ed19dfe95f2c9775655bea8b73f" "0.13.1": url: "https://github.com/yhirose/cpp-httplib/archive/v0.13.1.tar.gz" sha256: "9b837d290b61e3f0c4239da0b23bbf14c382922e2bf2a9bac21c1e3feabe1ff9" diff --git a/recipes/cpp-httplib/config.yml b/recipes/cpp-httplib/config.yml index 7af780ed5d22db..8e636ccafe3a6d 100644 --- a/recipes/cpp-httplib/config.yml +++ b/recipes/cpp-httplib/config.yml @@ -1,4 +1,6 @@ versions: + "0.13.3": + folder: all "0.13.1": folder: all "0.12.6": From cd917a34f0bc77e85891ca1bc7b478fea60d1685 Mon Sep 17 00:00:00 2001 From: trns1997 <17682846+trns1997@users.noreply.github.com> Date: Wed, 2 Aug 2023 12:30:18 +0200 Subject: [PATCH 0067/1140] (#18163) kickcat: add recipe Co-authored-by: Carlos Zoido --- recipes/kickcat/all/conandata.yml | 4 + recipes/kickcat/all/conanfile.py | 74 +++++++++++++++++++ .../kickcat/all/test_package/CMakeLists.txt | 9 +++ recipes/kickcat/all/test_package/conanfile.py | 25 +++++++ .../kickcat/all/test_package/test_package.cc | 32 ++++++++ recipes/kickcat/config.yml | 3 + 6 files changed, 147 insertions(+) create mode 100644 recipes/kickcat/all/conandata.yml create mode 100644 recipes/kickcat/all/conanfile.py create mode 100644 recipes/kickcat/all/test_package/CMakeLists.txt create mode 100644 recipes/kickcat/all/test_package/conanfile.py create mode 100644 recipes/kickcat/all/test_package/test_package.cc create mode 100644 recipes/kickcat/config.yml diff --git a/recipes/kickcat/all/conandata.yml b/recipes/kickcat/all/conandata.yml new file mode 100644 index 00000000000000..19c0f19034affa --- /dev/null +++ b/recipes/kickcat/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "v2-alpha3": + url: "https://github.com/Siviuze/KickCAT/archive/refs/tags/v2-alpha3.zip" + sha256: "dadd8518c3232162b7455fdcd837578120ece5a42c3bc2701147a68cbee60da4" diff --git a/recipes/kickcat/all/conanfile.py b/recipes/kickcat/all/conanfile.py new file mode 100644 index 00000000000000..abaf5d422d5881 --- /dev/null +++ b/recipes/kickcat/all/conanfile.py @@ -0,0 +1,74 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout +from conan.tools.files import get, copy +from conan.tools.scm import Version +import os + +required_conan_version = ">=1.55" + + +class KickCATRecipe(ConanFile): + name = "kickcat" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Siviuze/KickCAT" + description = "Thin EtherCAT stack designed to be embedded in a more complex software and with efficiency in mind" + license = "CeCILL-C" + topics = ("ethercat") + package_type = "library" + settings = "os", "compiler", "build_type", "arch" + options = {"shared": [True, False], "fPIC": [True, False]} + default_options = {"shared": False, "fPIC": True} + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def configure(self): + if self.options.get_safe("shared"): + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 17) + + if self.settings.os != "Linux": + raise ConanInvalidConfiguration( + f"{self.ref} is not supported on {self.settings.os}.") + + if self.settings.compiler != "gcc": + raise ConanInvalidConfiguration( + f"{self.ref} is not supported on {self.settings.compiler}.") + + if self.settings.compiler == 'gcc' and Version(self.settings.compiler.version) < "7": + raise ConanInvalidConfiguration("Building requires GCC >= 7") + + def generate(self): + tc = CMakeToolchain(self) + tc.cache_variables["BUILD_UNIT_TESTS"] = "OFF" + tc.cache_variables["BUILD_EXAMPLES"] = "OFF" + tc.cache_variables["BUILD_SIMULATION"] = "OFF" + tc.cache_variables["BUILD_TOOLS"] = "OFF" + tc.cache_variables["DEBUG"] = "OFF" + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "*.h", os.path.join(self.source_folder, "include"), + os.path.join(self.package_folder, "include")) + copy(self, "*.a", self.build_folder, + os.path.join(self.package_folder, "lib"), keep_path=False) + copy(self, "*.so", self.build_folder, + os.path.join(self.package_folder, "lib"), keep_path=False) + copy(self, "LICENSE", self.source_folder, + os.path.join(self.package_folder, "licenses")) + + def package_info(self): + self.cpp_info.libs = ["kickcat"] diff --git a/recipes/kickcat/all/test_package/CMakeLists.txt b/recipes/kickcat/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..8b77c31d9ca128 --- /dev/null +++ b/recipes/kickcat/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) + +set(CMAKE_CXX_STANDARD 17) + +find_package(kickcat REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cc) +target_link_libraries(${PROJECT_NAME} PRIVATE kickcat::kickcat) diff --git a/recipes/kickcat/all/test_package/conanfile.py b/recipes/kickcat/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e46a141327eede --- /dev/null +++ b/recipes/kickcat/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/kickcat/all/test_package/test_package.cc b/recipes/kickcat/all/test_package/test_package.cc new file mode 100644 index 00000000000000..a0ac4c8fdf423d --- /dev/null +++ b/recipes/kickcat/all/test_package/test_package.cc @@ -0,0 +1,32 @@ +#include "kickcat/Bus.h" +#include "kickcat/Link.h" +#include "kickcat/Prints.h" +#include "kickcat/SocketNull.h" + +#include + +using namespace kickcat; + +int main(int argc, char *argv[]) +{ + std::shared_ptr socket = std::make_shared(); + try + { + socket->open("null"); + } + catch (std::exception const &e) + { + std::cerr << e.what() << std::endl; + return 1; + } + + auto report_redundancy = []() { + }; + + std::shared_ptr link = std::make_shared(socket, socket, report_redundancy); + link->setTimeout(2ms); + link->checkRedundancyNeeded(); + + Bus bus(link); + return 0; +} diff --git a/recipes/kickcat/config.yml b/recipes/kickcat/config.yml new file mode 100644 index 00000000000000..7990d533925c9b --- /dev/null +++ b/recipes/kickcat/config.yml @@ -0,0 +1,3 @@ +versions: + "v2-alpha3": + folder: all From cc64809e4f39262077e27346436d45050f64e3cb Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 2 Aug 2023 12:50:02 +0200 Subject: [PATCH 0068/1140] (#19016) [bot] Update authorized users list (2023-08-02) --- .c3i/authorized_users.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index f24e1eb3d8a3aa..902e3fd4b97b9c 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1203,3 +1203,9 @@ authorized_users: - jeremy-rifkin - Christian-Prather - Siarh199 +- liquiddaniel +- seppeon +- SavenkovIgor +- aliaksei135 +- ibosnic00 +- Xav83 From d3883d5f94b981a28a8f8daab8f222379d315586 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 3 Aug 2023 16:19:46 +0900 Subject: [PATCH 0069/1140] (#18325) opentelemetry-proto: add version 1.0.0 Co-authored-by: Daniel --- recipes/opentelemetry-proto/all/conandata.yml | 3 +++ recipes/opentelemetry-proto/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/opentelemetry-proto/all/conandata.yml b/recipes/opentelemetry-proto/all/conandata.yml index 88d8d71b3c37a9..94ffeec1c78316 100644 --- a/recipes/opentelemetry-proto/all/conandata.yml +++ b/recipes/opentelemetry-proto/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.0": + url: "https://github.com/open-telemetry/opentelemetry-proto/archive/v1.0.0.tar.gz" + sha256: "a13a1a7b76a1f22a0ca2e6c293e176ffef031413ab8ba653a82a1dbc286a3a33" "0.20.0": url: "https://github.com/open-telemetry/opentelemetry-proto/archive/v0.20.0.tar.gz" sha256: "6ab267cf82832ed60ad075d574c78da736193eecb9693e8a8d02f65d6d3f3520" diff --git a/recipes/opentelemetry-proto/config.yml b/recipes/opentelemetry-proto/config.yml index f4d1c284073401..64c1fc73aecec0 100644 --- a/recipes/opentelemetry-proto/config.yml +++ b/recipes/opentelemetry-proto/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.0": + folder: all "0.20.0": folder: all "0.19.0": From f42fbae2ab256de710cb036a075983e78ec82a5f Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Thu, 3 Aug 2023 12:04:11 +0200 Subject: [PATCH 0070/1140] (#19026) [bx] Fix test package imports Signed-off-by: Uilian Ries --- recipes/bx/all/test_package/conanfile.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/bx/all/test_package/conanfile.py b/recipes/bx/all/test_package/conanfile.py index 7914baa4343981..d3dd545ae68baf 100644 --- a/recipes/bx/all/test_package/conanfile.py +++ b/recipes/bx/all/test_package/conanfile.py @@ -1,10 +1,8 @@ from conan import ConanFile from conan.tools.build import can_run -from conan.tools.layout import cmake_layout -from conan.tools.cmake import CMake +from conan.tools.cmake import CMake, cmake_layout import os -required_conan_version = ">=1.50.0" class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" From 5423b3589c3df50d8852ab0b1b4c53f441181039 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 3 Aug 2023 19:19:51 +0900 Subject: [PATCH 0071/1140] (#18425) msgpack-cxx: add version 6.1.0, use download tarballs, update boost --- recipes/msgpack-cxx/all/conandata.yml | 31 +++++++++++++++------------ recipes/msgpack-cxx/all/conanfile.py | 2 +- recipes/msgpack-cxx/config.yml | 2 ++ 3 files changed, 20 insertions(+), 15 deletions(-) diff --git a/recipes/msgpack-cxx/all/conandata.yml b/recipes/msgpack-cxx/all/conandata.yml index 64a5e6f43e3e63..6af577efebddf0 100644 --- a/recipes/msgpack-cxx/all/conandata.yml +++ b/recipes/msgpack-cxx/all/conandata.yml @@ -1,22 +1,25 @@ sources: + "6.1.0": + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-6.1.0/msgpack-cxx-6.1.0.tar.gz" + sha256: "23ede7e93c8efee343ad8c6514c28f3708207e5106af3b3e4969b3a9ed7039e7" "6.0.0": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-6.0.0.tar.gz" - sha256: "d02f7ffd28b1d38ab9f5f758c4744fadfae92150461fb8154c98ac49226cff90" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-6.0.0/msgpack-cxx-6.0.0.tar.gz" + sha256: "0948d2db98245fb97b9721cfbc3e44c1b832e3ce3b8cfd7485adc368dc084d14" "5.0.0": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-5.0.0.tar.gz" - sha256: "bd6b8e255f0a62cf8f50f1d292f979ac8ea9a4aa121938679d6f419d6df70ea3" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-5.0.0/msgpack-cxx-5.0.0.tar.gz" + sha256: "80f997575acff12b1b64158ef9dbad4cff32595f985532e16c6ea67e317452d5" "4.1.3": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-4.1.3.tar.gz" - sha256: "fd0a685656f11b8aa09ed33bcbdcad3105d25d0034ca3dba9fe957623a42d253" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-4.1.3/msgpack-cxx-4.1.3.tar.gz" + sha256: "2539075ea2f35c15cab5c50ecba00d76fc4cbdcd485840257f15ebb04e8e3e1a" "4.1.2": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-4.1.2.tar.gz" - sha256: "7460ad43552c9d9b56a75f20e1f4fedf18fff1c48715d6cfa91d779b26ca3795" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-4.1.2/msgpack-cxx-4.1.2.tar.gz" + sha256: "eeddd7faeacbc12e10052bd1e3ec78bd26c69bfbbea9f9264c7ffce9b1ede7b1" "4.1.1": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-4.1.1.tar.gz" - sha256: "221cc539e77f5ca02f4f0bbb1edafa9ca8c08de7ba8072d7baf2139930d99182" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-4.1.1/msgpack-cxx-4.1.1.tar.gz" + sha256: "8115c5edcf20bc1408c798a6bdaec16c1e52b1c34859d4982a0fb03300438f0b" "4.1.0": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-4.1.0.tar.gz" - sha256: "634762502a192026bd5db773f9e18d900ad04cfc312b52faee350a5c76e5ccfb" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-4.1.0/msgpack-cxx-4.1.0.tar.gz" + sha256: "11e042ffdafda6fc4ebdc5f4f63b352229b89796c2f8aa3e813116ec1dd8377d" "4.0.3": - url: "https://github.com/msgpack/msgpack-c/archive/cpp-4.0.3.tar.gz" - sha256: "23d737b1e959dfb6ca420564563f098e758adacc0b18003c56abf1b945bd1d4a" + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-4.0.3/msgpack-cxx-4.0.3.tar.gz" + sha256: "9b3c1803b9855b7b023d7f181f66ebb0d6941275ba41d692037e0aa27736443f" diff --git a/recipes/msgpack-cxx/all/conanfile.py b/recipes/msgpack-cxx/all/conanfile.py index 2bcaa82b381e69..0431bac108f83f 100644 --- a/recipes/msgpack-cxx/all/conanfile.py +++ b/recipes/msgpack-cxx/all/conanfile.py @@ -34,7 +34,7 @@ def layout(self): def requirements(self): if self.options.get_safe("use_boost", True): - self.requires("boost/1.81.0") + self.requires("boost/1.82.0") def package_id(self): self.info.clear() diff --git a/recipes/msgpack-cxx/config.yml b/recipes/msgpack-cxx/config.yml index 1c632d41b23dd6..934a0432a27c72 100644 --- a/recipes/msgpack-cxx/config.yml +++ b/recipes/msgpack-cxx/config.yml @@ -1,4 +1,6 @@ versions: + "6.1.0": + folder: all "6.0.0": folder: all "5.0.0": From e72d332dc8c1751cf957bc176baecaa374346ad1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 3 Aug 2023 13:45:05 +0300 Subject: [PATCH 0072/1140] (#18346) cprocessing: migrate to Conan v2, disable interactive GUI in test_package * cprocessing: migrate to Conan v2 * cprocessing: disable GUI creation in test_package * cprocessing: restore test_v1_package * cprocessing: restore VirtualRunEnv in test_package --- recipes/cprocessing/all/conanfile.py | 81 ++++++++++-------- .../all/test_package/CMakeLists.txt | 5 +- .../cprocessing/all/test_package/conanfile.py | 20 +++-- .../all/test_package/test_package.cpp | 85 ++++++++++--------- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 18 ++++ 6 files changed, 131 insertions(+), 86 deletions(-) create mode 100644 recipes/cprocessing/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cprocessing/all/test_v1_package/conanfile.py diff --git a/recipes/cprocessing/all/conanfile.py b/recipes/cprocessing/all/conanfile.py index f1d8d20922d764..c9ae209b2576ff 100644 --- a/recipes/cprocessing/all/conanfile.py +++ b/recipes/cprocessing/all/conanfile.py @@ -1,33 +1,45 @@ -from conans import ConanFile, tools -from conans.tools import ConanInvalidConfiguration import os import re -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, load, replace_in_file, save +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class CProcessingConan(ConanFile): name = "cprocessing" - description = "Processsing programming for C++ " + description = "Processing programming for C++ " license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/maksmakuta/CProcessing" - topics = ("processing", "opengl", "sketch") + topics = ("processing", "opengl", "sketch", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 20 @property def _compilers_minimum_version(self): return { - "gcc": "9", - "Visual Studio": "16.2", - "msvc": "19.22", - "clang": "10", - "apple-clang": "11" + "gcc": "9", + "Visual Studio": "16.2", + "msvc": "19.22", + "clang": "10", + "apple-clang": "11", } + def layout(self): + basic_layout(self, src_folder="src") + def requirements(self): self.requires("glfw/3.3.7") self.requires("glm/0.9.9.8") @@ -36,44 +48,39 @@ def requirements(self): self.requires("opengl/system") def package_id(self): - self.info.header_only() + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 20) - - def lazy_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] - - compiler_version = str(self.settings.compiler.version) - + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("{} requires C++20. Your compiler is unknown. Assuming it supports C++20.".format(self.name)) - elif lazy_lt_semver(compiler_version, minimum_version): - raise ConanInvalidConfiguration("{} requires some C++20 features,".format(self.name)) + if minimum_version and Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.ref} requires some C++{self._min_cppstd} features, which your compiler does not support." + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, - destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): - tools.replace_in_file(os.path.join(self._source_subfolder, "lib", "PImage.h"), - "stb/stb_image.h", - "stb_image.h") - - def package(self): - self.copy("*.h", "include", os.path.join(self._source_subfolder, "lib")) + replace_in_file(self, os.path.join(self.source_folder, "lib", "PImage.h"), "stb/stb_image.h", "stb_image.h") + def _extract_license(self): # Extract the License/s from README.md to a file - tmp = tools.load(os.path.join(self._source_subfolder, "README.md")) + tmp = load(self, os.path.join(self.source_folder, "README.md")) license_contents = re.search("(## Author.*)", tmp, re.DOTALL)[1] - tools.save(os.path.join(self.package_folder, "licenses", "LICENSE.md"), license_contents) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE.md"), license_contents) + + def package(self): + self._extract_license() + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "lib")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "CProcessing") self.cpp_info.set_property("cmake_target_name", "CProcessing::CProcessing") diff --git a/recipes/cprocessing/all/test_package/CMakeLists.txt b/recipes/cprocessing/all/test_package/CMakeLists.txt index 05121b9bfe4148..eeeb2f9006cc86 100644 --- a/recipes/cprocessing/all/test_package/CMakeLists.txt +++ b/recipes/cprocessing/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.12) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(CProcessing REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/cprocessing/all/test_package/conanfile.py b/recipes/cprocessing/all/test_package/conanfile.py index 51cf79f1d6887b..ef5d7042163ecc 100644 --- a/recipes/cprocessing/all/test_package/conanfile.py +++ b/recipes/cprocessing/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,7 +21,6 @@ def build(self): cmake.build() def test(self): - test_file = os.path.join("bin", "test_package") - if self.settings.os == "Windows": - test_file += ".exe" - assert os.path.exists(test_file) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cprocessing/all/test_package/test_package.cpp b/recipes/cprocessing/all/test_package/test_package.cpp index 479e221b8ea06e..e8aaee04efe2bf 100644 --- a/recipes/cprocessing/all/test_package/test_package.cpp +++ b/recipes/cprocessing/all/test_package/test_package.cpp @@ -6,67 +6,74 @@ * Part 2: https://youtube.com/shorts/IS6_apBewlI */ +// Disable the main function from from processing.h +// to disable the interactive GUI for the purposes of this test +#define main _main #include +#undef main float speed; -class Star{ +class Star { private: - float x,y,z,pz; + float x, y, z, pz; + public: - Star(){ - this->x = random(-width,width); - this->y = random(-height,height); - this->z = random(width); - this->pz = z; + Star() { + this->x = random(-width, width); + this->y = random(-height, height); + this->z = random(width); + this->pz = z; } - void update(){ - this->z -= speed; - if(this->z < 1.f){ - this->z = width; - this->x = random(-width,width); - this->y = random(-height,height); - this->pz = z; - } + void update() { + this->z -= speed; + if (this->z < 1.f) { + this->z = width; + this->x = random(-width, width); + this->y = random(-height, height); + this->pz = z; + } } - void show(){ - fill(255); + void show() { + fill(255); - float sx = map(this->x / this->z,0,1,0, width); - float sy = map(this->y / this->z,0,1,0,height); + float sx = map(this->x / this->z, 0, 1, 0, width); + float sy = map(this->y / this->z, 0, 1, 0, height); - float r = map(this->z,0,width,16,0); - circle(sx,sy,r); + float r = map(this->z, 0, width, 16, 0); + circle(sx, sy, r); - float zx = map(this->x / this->pz,0,1,0, width); - float zy = map(this->y / this->pz,0,1,0,height); + float zx = map(this->x / this->pz, 0, 1, 0, width); + float zy = map(this->y / this->pz, 0, 1, 0, height); - this->pz = z; + this->pz = z; - stroke(255); - line(zx,zy,sx,sy); + stroke(255); + line(zx, zy, sx, sy); } - }; std::vector stars; -void setup(){ - size(640,480); - for(int a = 0;a < 100;a++) - stars.push_back(Star()); +void setup() { + size(640, 480); + for (int a = 0; a < 100; a++) + stars.push_back(Star()); } -void draw(){ - speed = map(mouseX,0,width,0.f,50.f); - background(0); - translate(width/2,height/2); +void draw() { + speed = map(mouseX, 0, width, 0.f, 50.f); + background(0); + translate(width / 2, height / 2); - for(int a = 0;a < stars.size();a++){ - stars[a].update(); - stars[a].show(); - } + for (int a = 0; a < stars.size(); a++) { + stars[a].update(); + stars[a].show(); + } +} +int main() { + return 0; } diff --git a/recipes/cprocessing/all/test_v1_package/CMakeLists.txt b/recipes/cprocessing/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cprocessing/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cprocessing/all/test_v1_package/conanfile.py b/recipes/cprocessing/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..51cf79f1d6887b --- /dev/null +++ b/recipes/cprocessing/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + test_file = os.path.join("bin", "test_package") + if self.settings.os == "Windows": + test_file += ".exe" + assert os.path.exists(test_file) From 243374c8b66df5c95d631ce297afb7b8f3906dbd Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 3 Aug 2023 13:05:30 +0200 Subject: [PATCH 0073/1140] (#18417) libjpeg-turbo: add version 3.0.0 * libjpeg-turbo: add version 3.0.0 * simplify version comparison * libjpeg-turbo: remove older versions per https://github.com/conan-io/conan-center-index/blob/master/docs/adding_packages/sources_and_patches.md#removing-old-versions --- recipes/libjpeg-turbo/all/conandata.yml | 21 +++------------------ recipes/libjpeg-turbo/all/conanfile.py | 18 +++++++++++------- recipes/libjpeg-turbo/config.yml | 14 ++------------ 3 files changed, 16 insertions(+), 37 deletions(-) diff --git a/recipes/libjpeg-turbo/all/conandata.yml b/recipes/libjpeg-turbo/all/conandata.yml index 1821235633f652..fed4921e77f53b 100644 --- a/recipes/libjpeg-turbo/all/conandata.yml +++ b/recipes/libjpeg-turbo/all/conandata.yml @@ -1,25 +1,10 @@ sources: + "3.0.0": + url: "https://sourceforge.net/projects/libjpeg-turbo/files/3.0.0/libjpeg-turbo-3.0.0.tar.gz" + sha256: "c77c65fcce3d33417b2e90432e7a0eb05f59a7fff884022a9d931775d583bfaa" "2.1.5": url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.5/libjpeg-turbo-2.1.5.tar.gz" sha256: "bc12bc9dce55300c6bf4342bc233bcc26bd38bf289eedf147360d731c668ddaf" - "2.1.4": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.4/libjpeg-turbo-2.1.4.tar.gz" - sha256: "d3ed26a1131a13686dfca4935e520eb7c90ae76fbc45d98bb50a8dc86230342b" - "2.1.3": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.3/libjpeg-turbo-2.1.3.tar.gz" - sha256: "467b310903832b033fe56cd37720d1b73a6a3bd0171dbf6ff0b620385f4f76d0" - "2.1.2": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.2/libjpeg-turbo-2.1.2.tar.gz" - sha256: "09b96cb8cbff9ea556a9c2d173485fd19488844d55276ed4f42240e1e2073ce5" - "2.1.1": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.1/libjpeg-turbo-2.1.1.tar.gz" - sha256: "b76aaedefb71ba882cbad4e9275b30c2ae493e3195be0a099425b5c6b99bd510" - "2.1.0": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.1.0/libjpeg-turbo-2.1.0.tar.gz" - sha256: "bef89803e506f27715c5627b1e3219c95b80fc31465d4452de2a909d382e4444" "2.0.6": url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.0.6/libjpeg-turbo-2.0.6.tar.gz" sha256: "d74b92ac33b0e3657123ddcf6728788c90dc84dcb6a52013d758af3c4af481bb" - "2.0.5": - url: "https://sourceforge.net/projects/libjpeg-turbo/files/2.0.5/libjpeg-turbo-2.0.5.tar.gz" - sha256: "16f8f6f2715b3a38ab562a84357c793dd56ae9899ce130563c72cd93d8357b5d" diff --git a/recipes/libjpeg-turbo/all/conanfile.py b/recipes/libjpeg-turbo/all/conanfile.py index afc30df36cff23..9405b0c63aaf60 100644 --- a/recipes/libjpeg-turbo/all/conanfile.py +++ b/recipes/libjpeg-turbo/all/conanfile.py @@ -49,6 +49,9 @@ class LibjpegTurboConan(ConanFile): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) >= "3.0.0": + del self.options.enable12bit + del self.options.mem_src_dst def configure(self): if self.options.shared: @@ -56,22 +59,22 @@ def configure(self): self.settings.rm_safe("compiler.cppstd") self.settings.rm_safe("compiler.libcxx") - if self.options.enable12bit: + if self.options.get_safe("enable12bit"): del self.options.java del self.options.turbojpeg - if self.options.enable12bit or self.settings.os == "Emscripten": + if self.options.get_safe("enable12bit") or self.settings.os == "Emscripten": del self.options.SIMD - if self.options.enable12bit or self.options.libjpeg7_compatibility or self.options.libjpeg8_compatibility: + if self.options.get_safe("enable12bit") or self.options.libjpeg7_compatibility or self.options.libjpeg8_compatibility: del self.options.arithmetic_encoder del self.options.arithmetic_decoder if self.options.libjpeg8_compatibility: - del self.options.mem_src_dst + self.options.rm_safe("mem_src_dst") def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.options.enable12bit and (self.options.libjpeg7_compatibility or self.options.libjpeg8_compatibility): + if self.options.get_safe("enable12bit") and (self.options.libjpeg7_compatibility or self.options.libjpeg8_compatibility): raise ConanInvalidConfiguration("12-bit samples is not allowed with libjpeg v7/v8 API/ABI") if self.options.get_safe("java") and not self.options.shared: raise ConanInvalidConfiguration("java wrapper requires shared libjpeg-turbo") @@ -107,10 +110,11 @@ def generate(self): tc.variables["WITH_ARITH_DEC"] = self._is_arithmetic_decoding_enabled tc.variables["WITH_JPEG7"] = self.options.libjpeg7_compatibility tc.variables["WITH_JPEG8"] = self.options.libjpeg8_compatibility - tc.variables["WITH_MEM_SRCDST"] = self.options.get_safe("mem_src_dst", False) tc.variables["WITH_TURBOJPEG"] = self.options.get_safe("turbojpeg", False) tc.variables["WITH_JAVA"] = self.options.get_safe("java", False) - tc.variables["WITH_12BIT"] = self.options.enable12bit + if Version(self.version) < "3.0.0": + tc.variables["WITH_MEM_SRCDST"] = self.options.get_safe("mem_src_dst", False) + tc.variables["WITH_12BIT"] = self.options.enable12bit if is_msvc(self): tc.variables["WITH_CRT_DLL"] = True # avoid replacing /MD by /MT in compiler flags if Version(self.version) <= "2.1.0": diff --git a/recipes/libjpeg-turbo/config.yml b/recipes/libjpeg-turbo/config.yml index cdfe1237074c71..d646887ca99a39 100644 --- a/recipes/libjpeg-turbo/config.yml +++ b/recipes/libjpeg-turbo/config.yml @@ -1,17 +1,7 @@ versions: - "2.1.5": - folder: all - "2.1.4": - folder: all - "2.1.3": - folder: all - "2.1.2": + "3.0.0": folder: all - "2.1.1": - folder: all - "2.1.0": + "2.1.5": folder: all "2.0.6": folder: all - "2.0.5": - folder: all From a875c3c8a0be8bbc522dc8bac6206b453edf50d6 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 4 Aug 2023 01:17:50 +0900 Subject: [PATCH 0074/1140] (#18882) dice-template-library: add version 1.1.0 --- recipes/dice-template-library/all/conandata.yml | 3 +++ recipes/dice-template-library/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/dice-template-library/all/conandata.yml b/recipes/dice-template-library/all/conandata.yml index def2d951ef94ea..8bfdcb315eb922 100644 --- a/recipes/dice-template-library/all/conandata.yml +++ b/recipes/dice-template-library/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.0": + url: "https://github.com/dice-group/dice-template-library/archive/refs/tags/v1.1.0.tar.gz" + sha256: "a00ee401379eaf6c8af013fb39d6732fa68c3852e14b50789edde6f054647ca2" "1.0.0": url: "https://github.com/dice-group/dice-template-library/archive/refs/tags/v1.0.0.tar.gz" sha256: "485505ad3f9fb033083e2952bd8b4e68f6b4f123746b20f4ec3af46f4ce66cfe" diff --git a/recipes/dice-template-library/config.yml b/recipes/dice-template-library/config.yml index 930d790eeb4ba9..f1e3df07fed832 100644 --- a/recipes/dice-template-library/config.yml +++ b/recipes/dice-template-library/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.0": + folder: all "1.0.0": folder: all "0.3.0": From 384dcf89df6fa87f9999e0d553236ada370f8d0a Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 4 Aug 2023 08:34:27 +0200 Subject: [PATCH 0075/1140] (#18975) asio: add version 1.28.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/asio/all/conandata.yml | 3 +++ recipes/asio/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/asio/all/conandata.yml b/recipes/asio/all/conandata.yml index 46bc4f8f41b43e..d8865c47b5bf0d 100644 --- a/recipes/asio/all/conandata.yml +++ b/recipes/asio/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.28.1": + url: "https://github.com/chriskohlhoff/asio/archive/asio-1-28-1.tar.gz" + sha256: "5ff6111ec8cbe73a168d997c547f562713aa7bd004c5c02326f0e9d579a5f2ce" "1.28.0": url: "https://github.com/chriskohlhoff/asio/archive/asio-1-28-0.tar.gz" sha256: "226438b0798099ad2a202563a83571ce06dd13b570d8fded4840dbc1f97fa328" diff --git a/recipes/asio/config.yml b/recipes/asio/config.yml index 06fbadd587b1ab..33c8893e89fa5b 100644 --- a/recipes/asio/config.yml +++ b/recipes/asio/config.yml @@ -1,4 +1,6 @@ versions: + "1.28.1": + folder: all "1.28.0": folder: all "1.27.0": From 30e8234e38100d357c5f66cd5720ef7fdf5bfa05 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 4 Aug 2023 10:43:20 +0200 Subject: [PATCH 0076/1140] (#19035) [config] Update Conan client version: 1.60.2 and 2.0.9 Signed-off-by: Uilian Ries --- .c3i/config_v1.yml | 2 +- .c3i/config_v2.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index 5241e481d134fb..c28c0345e0824e 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -3,7 +3,7 @@ id: 'conan-io/conan-center-index' conan: - version: 1.60.1 + version: 1.60.2 artifactory: url: "https://c3i.jfrog.io/c3i" diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index 7aaabf1c918f16..b5ee3148ca00b6 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -3,7 +3,7 @@ id: 'conan-io/conan-center-index' conan: - version: 2.0.8 + version: 2.0.9 artifactory: url: "https://c3i.jfrog.io/c3i" From f14921c2dab30f659c6d576c108d866c59bcae81 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 4 Aug 2023 18:54:55 +0900 Subject: [PATCH 0077/1140] (#18841) usockets: add version 0.8.6 Co-authored-by: Carlos Zoido --- recipes/usockets/all/conandata.yml | 7 ++++ .../all/patches/0001-makefile_0.8.6.patch | 35 +++++++++++++++++++ recipes/usockets/config.yml | 2 ++ 3 files changed, 44 insertions(+) create mode 100644 recipes/usockets/all/patches/0001-makefile_0.8.6.patch diff --git a/recipes/usockets/all/conandata.yml b/recipes/usockets/all/conandata.yml index e6a17b330a5a44..1e162a7179edda 100644 --- a/recipes/usockets/all/conandata.yml +++ b/recipes/usockets/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.8.6": + url: "https://github.com/uNetworking/uSockets/archive/v0.8.6.tar.gz" + sha256: "16eba133dd33eade2f5f8dd87612c04b5dd711066e0471c60d641a2f6a988f16" "0.8.5": url: "https://github.com/uNetworking/uSockets/archive/v0.8.5.tar.gz" sha256: "c52c98b7ff2c24534c17ad97d5fea8ca0cb7ff38cc933b8d08bac6e498a2ea6b" @@ -21,6 +24,10 @@ sources: url: "https://github.com/uNetworking/uSockets/archive/v0.4.0.tar.gz" sha256: "f9f15b395def578cc79a5b32abc64fa9cff5dac873062911f515b984b90f7cc2" patches: + "0.8.6": + - patch_file: "patches/0001-makefile_0.8.6.patch" + patch_description: "remove lto options" + patch_type: "portability" "0.8.5": - patch_file: "patches/0001-makefile_0.8.3.patch" patch_description: "remove lto options" diff --git a/recipes/usockets/all/patches/0001-makefile_0.8.6.patch b/recipes/usockets/all/patches/0001-makefile_0.8.6.patch new file mode 100644 index 00000000000000..e77691ceeac478 --- /dev/null +++ b/recipes/usockets/all/patches/0001-makefile_0.8.6.patch @@ -0,0 +1,35 @@ +diff --git a/Makefile b/Makefile +index aa874b9..d58ac0a 100644 +--- a/Makefile ++++ b/Makefile +@@ -74,10 +74,10 @@ endif + # By default we build the uSockets.a static library + default: + rm -f *.o +- $(CC) $(CFLAGS) -O3 -c src/*.c src/eventing/*.c src/crypto/*.c src/io_uring/*.c ++ $(CC) $(CFLAGS) $(CPPFLAGS) -O3 -c src/*.c src/eventing/*.c src/crypto/*.c src/io_uring/*.c + # Also link in Boost Asio support + ifeq ($(WITH_ASIO),1) +- $(CXX) $(CXXFLAGS) -Isrc -std=c++14 -flto -O3 -c src/eventing/asio.cpp ++ $(CXX) $(CXXFLAGS) -Isrc -std=c++14 $(CPPFLAGS) -O3 -c src/eventing/asio.cpp + endif + + # For now we do rely on C++17 for OpenSSL support but we will be porting this work to C11 +@@ -88,7 +88,7 @@ ifeq ($(WITH_BORINGSSL),1) + $(CXX) $(CXXFLAGS) -std=c++17 -flto -O3 -c src/crypto/*.cpp + endif + # Create a static library (try windows, then unix) +- lib.exe /out:uSockets.a *.o || $(AR) rvs uSockets.a *.o ++ lib.exe /out:uSockets.lib *.obj || $(AR) rvs libuSockets.a *.o + + # BoringSSL needs cmake and golang + .PHONY: boringssl +@@ -98,7 +98,7 @@ boringssl: + # Builds all examples + .PHONY: examples + examples: default +- for f in examples/*.c; do $(CC) -O3 $(CFLAGS) -o $$(basename "$$f" ".c")$(EXEC_SUFFIX) "$$f" $(LDFLAGS); done ++ for f in examples/*.c; do $(CC) -O3 $(CFLAGS) $(CPPFLAGS) -o $$(basename "$$f" ".c")$(EXEC_SUFFIX) "$$f" $(LDFLAGS); done + + swift_examples: + swiftc -O -I . examples/swift_http_server/main.swift uSockets.a -o swift_http_server diff --git a/recipes/usockets/config.yml b/recipes/usockets/config.yml index c4f53d0a2aff05..ed2a319a00e8b3 100644 --- a/recipes/usockets/config.yml +++ b/recipes/usockets/config.yml @@ -1,4 +1,6 @@ versions: + "0.8.6": + folder: all "0.8.5": folder: all "0.8.3": From 0d22b4e75343a5a48281316af499bd9c9add4390 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 4 Aug 2023 12:21:58 +0200 Subject: [PATCH 0078/1140] (#18859) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 9b1a2220981186..1a5d515961ed7d 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -309,13 +309,18 @@ required_for_references: - function2 - fxdiv - g3log +- gainput - gamma +- gcem - gdbm - gdcm - gdk-pixbuf - gegles-spdlog_setup - gemmlowp +- genie +- geographiclib - geos +- geotrans - getopt-for-visual-studio - gettext - gflags @@ -326,6 +331,9 @@ required_for_references: - gklib - glad - glaze +- glbinding +- glew +- glext - glfw - gli - glib From ad47e864c041bc92f294067c9ce10030ea64fa39 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 4 Aug 2023 20:12:40 +0900 Subject: [PATCH 0079/1140] (#19009) imgui: add version 1.89.8, 1.89.8-docking --- recipes/imgui/all/conandata.yml | 6 ++++++ recipes/imgui/config.yml | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/recipes/imgui/all/conandata.yml b/recipes/imgui/all/conandata.yml index 82db7f4c7e4b5b..18b830b59f3648 100644 --- a/recipes/imgui/all/conandata.yml +++ b/recipes/imgui/all/conandata.yml @@ -1,4 +1,10 @@ sources: + "1.89.8": + url: "https://github.com/ocornut/imgui/archive/v1.89.8.tar.gz" + sha256: "6680ccc32430009a8204291b1268b2367d964bd6d1b08a4e0358a017eb8e8c9e" + "1.89.8-docking": + url: "https://github.com/ocornut/imgui/archive/v1.89.8-docking.tar.gz" + sha256: "d48c4856e42a8fa3e6df3efae7eae86012fa65d9dceb03d1a2080a2386063635" "1.89.7": url: "https://github.com/ocornut/imgui/archive/v1.89.7.tar.gz" sha256: "115ee9e242af98a884302ac0f6ca3b2b26b1f10c660205f5e7ad9f1d1c96d269" diff --git a/recipes/imgui/config.yml b/recipes/imgui/config.yml index 737cb8b3dbc2cf..d3d7aaa4e4a686 100644 --- a/recipes/imgui/config.yml +++ b/recipes/imgui/config.yml @@ -1,4 +1,8 @@ versions: + "1.89.8": + folder: all + "1.89.8-docking": + folder: all "1.89.7": folder: all "1.89.7-docking": From bedaf1a4ae5b4a341be350dda700ad5686af0af8 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 4 Aug 2023 20:50:14 +0900 Subject: [PATCH 0080/1140] (#18437) asio-grpc: add version 2.5.1, update dependencies --- recipes/asio-grpc/all/conandata.yml | 3 +++ recipes/asio-grpc/all/conanfile.py | 5 +++-- recipes/asio-grpc/config.yml | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/recipes/asio-grpc/all/conandata.yml b/recipes/asio-grpc/all/conandata.yml index 67c8b715cb2d32..2e070194bef3fd 100644 --- a/recipes/asio-grpc/all/conandata.yml +++ b/recipes/asio-grpc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.5.1": + url: "https://github.com/Tradias/asio-grpc/archive/refs/tags/v2.5.1.tar.gz" + sha256: "571779a25be6eed77a345088e3ded2cccf880c16800ee0075ece57116f14fc35" "2.4.0": url: "https://github.com/Tradias/asio-grpc/archive/refs/tags/v2.4.0.tar.gz" sha256: "d71de4f8de91dc0ad44d6a161fc628496b80622a6f9030dcd4c53b516629b8b7" diff --git a/recipes/asio-grpc/all/conanfile.py b/recipes/asio-grpc/all/conanfile.py index 41ebfbae5f918b..a0e6d608281c48 100644 --- a/recipes/asio-grpc/all/conanfile.py +++ b/recipes/asio-grpc/all/conanfile.py @@ -38,6 +38,7 @@ def _compilers_minimum_version(self): return { "gcc": "7", "Visual Studio": "15.7", + "msvc": "191", "clang": "6", "apple-clang": "11", } @@ -57,9 +58,9 @@ def configure(self): def requirements(self): self.requires("grpc/1.50.1") if self._local_allocator_option == "boost_container" or self.options.backend == "boost": - self.requires("boost/1.81.0") + self.requires("boost/1.82.0") if self.options.backend == "asio": - self.requires("asio/1.24.0") + self.requires("asio/1.28.0") if self.options.backend == "unifex": self.requires("libunifex/cci.20220430") diff --git a/recipes/asio-grpc/config.yml b/recipes/asio-grpc/config.yml index 25e51279385fd9..9952741d8464da 100644 --- a/recipes/asio-grpc/config.yml +++ b/recipes/asio-grpc/config.yml @@ -1,4 +1,6 @@ versions: + "2.5.1": + folder: all "2.4.0": folder: all "2.3.0": From a290187f7e7779286d2da3c7a518d3af9f9fbeff Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 4 Aug 2023 21:31:29 +0900 Subject: [PATCH 0081/1140] (#19033) gtest: add version 1.14.0 --- recipes/gtest/all/conandata.yml | 3 +++ recipes/gtest/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/gtest/all/conandata.yml b/recipes/gtest/all/conandata.yml index 1634a1e79e6fdf..b22247dc8573db 100644 --- a/recipes/gtest/all/conandata.yml +++ b/recipes/gtest/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.14.0": + url: "https://github.com/google/googletest/archive/refs/tags/v1.14.0.tar.gz" + sha256: "8ad598c73ad796e0d8280b082cebd82a630d73e73cd3c70057938a6501bba5d7" "1.13.0": url: "https://github.com/google/googletest/archive/refs/tags/v1.13.0.tar.gz" sha256: "ad7fdba11ea011c1d925b3289cf4af2c66a352e18d4c7264392fead75e919363" diff --git a/recipes/gtest/config.yml b/recipes/gtest/config.yml index ee070419b09c37..fa66f2eb7d4d78 100644 --- a/recipes/gtest/config.yml +++ b/recipes/gtest/config.yml @@ -1,4 +1,6 @@ versions: + "1.14.0": + folder: all "1.13.0": folder: all "1.12.1": From 6e32eb389b3cb0f5859ca33c6de66e576164bc01 Mon Sep 17 00:00:00 2001 From: Raven Szewczyk Date: Fri, 4 Aug 2023 14:08:39 +0100 Subject: [PATCH 0082/1140] (#19040) emsdk: add version 3.1.44 --- recipes/emsdk/all/conandata.yml | 3 +++ recipes/emsdk/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/emsdk/all/conandata.yml b/recipes/emsdk/all/conandata.yml index 8a32427b651c26..72c3415a7c7c25 100644 --- a/recipes/emsdk/all/conandata.yml +++ b/recipes/emsdk/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.1.44": + url: "https://github.com/emscripten-core/emsdk/archive/3.1.44.tar.gz" + sha256: "cb8cded78f6953283429d724556e89211e51ac4d871fcf38e0b32405ee248e91" "3.1.31": url: "https://github.com/emscripten-core/emsdk/archive/3.1.31.tar.gz" sha256: "1d38b7375e12e85197165a4c51d76d90e1d9db8c2c593b64cfaec4338af54750" diff --git a/recipes/emsdk/config.yml b/recipes/emsdk/config.yml index 82752e0f1209d8..f990e1dc35d29e 100644 --- a/recipes/emsdk/config.yml +++ b/recipes/emsdk/config.yml @@ -1,4 +1,6 @@ versions: + "3.1.44": + folder: all "3.1.31": folder: all "3.1.30": From e976ac6b8782a90a5d6493184018109cd9af5450 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Fri, 4 Aug 2023 16:28:24 +0300 Subject: [PATCH 0083/1140] (#19043) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 876c188b63e354..e4f01057df7709 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.9": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.9.tar.gz" + sha256: "5b00c997eb33e877ca54468a101345e3a9986ce1b61b0919fa8632efabc51b6d" "2.0.8": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.8.tar.gz" sha256: "50a47d407acf1ca6a5b96af0386da74f7cfb66322ec7453cbb543f4f66251683" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 9e06767160daf1..c184130e67ed4c 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.9": + folder: all "2.0.8": folder: all "2.0.7": From c3046a2b65cc060b790f3015f0e7b187e8afe8d8 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 4 Aug 2023 21:09:28 +0200 Subject: [PATCH 0084/1140] (#19025) harfbuzz: add version 8.1.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/harfbuzz/all/conandata.yml | 3 +++ recipes/harfbuzz/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/harfbuzz/all/conandata.yml b/recipes/harfbuzz/all/conandata.yml index 807ef3305d9859..d165dd235addde 100644 --- a/recipes/harfbuzz/all/conandata.yml +++ b/recipes/harfbuzz/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.1.1": + url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.1.1/harfbuzz-8.1.1.tar.xz" + sha256: "0305ad702e11906a5fc0c1ba11c270b7f64a8f5390d676aacfd71db129d6565f" "8.0.1": url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.0.1/harfbuzz-8.0.1.tar.xz" sha256: "c1ce780acd385569f25b9a29603d1d5bc71e6940e55bfdd4f7266fad50e42620" diff --git a/recipes/harfbuzz/config.yml b/recipes/harfbuzz/config.yml index b575f01311eb48..502391a71084d7 100644 --- a/recipes/harfbuzz/config.yml +++ b/recipes/harfbuzz/config.yml @@ -1,4 +1,6 @@ versions: + "8.1.1": + folder: all "8.0.1": folder: all "8.0.0": From fa28c8ea366db978953ccd9b8a63b26c347774c3 Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Fri, 4 Aug 2023 23:49:39 +0200 Subject: [PATCH 0085/1140] (#19011) msgpack-c/3.3.0: Added version 3.3.0 --- recipes/msgpack-c/all/conandata.yml | 3 +++ recipes/msgpack-c/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/msgpack-c/all/conandata.yml b/recipes/msgpack-c/all/conandata.yml index dc158b2bf02e6a..0062926e73ac99 100644 --- a/recipes/msgpack-c/all/conandata.yml +++ b/recipes/msgpack-c/all/conandata.yml @@ -8,3 +8,6 @@ sources: "4.0.0": url: "https://github.com/msgpack/msgpack-c/releases/download/c-4.0.0/msgpack-c-4.0.0.tar.gz" sha256: "420fe35e7572f2a168d17e660ef981a589c9cbe77faa25eb34a520e1fcc032c8" + "3.3.0": + url: "https://github.com/msgpack/msgpack-c/releases/download/cpp-3.3.0/msgpack-3.3.0.tar.gz" + sha256: "6e114d12a5ddb8cb11f669f83f32246e484a8addd0ce93f274996f1941c1f07b" diff --git a/recipes/msgpack-c/config.yml b/recipes/msgpack-c/config.yml index c43afaf0f726ab..08e152a5c47d06 100644 --- a/recipes/msgpack-c/config.yml +++ b/recipes/msgpack-c/config.yml @@ -5,3 +5,5 @@ versions: folder: all "4.0.0": folder: all + "3.3.0": + folder: all From 5c83d68549e6dd45fb978e91809f989199eb95f2 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 5 Aug 2023 10:05:57 +0300 Subject: [PATCH 0086/1140] (#18748) perf: migrate to Conan v2 * perf: migrate to Conan v2 * perf: restore VirtualRunEnv in test_package --------- Co-authored-by: Carlos Zoido --- recipes/perf/all/conandata.yml | 1 - recipes/perf/all/conanfile.py | 75 ++++++++++++------- recipes/perf/all/test_package/conanfile.py | 14 ++-- recipes/perf/all/test_v1_package/conanfile.py | 9 +++ 4 files changed, 67 insertions(+), 32 deletions(-) create mode 100644 recipes/perf/all/test_v1_package/conanfile.py diff --git a/recipes/perf/all/conandata.yml b/recipes/perf/all/conandata.yml index 72be9d8648e782..7cffe456681aec 100644 --- a/recipes/perf/all/conandata.yml +++ b/recipes/perf/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "5.13": - patch_file: patches/0001-Wno-strict-prototypes.patch - base_path: source_subfolder diff --git a/recipes/perf/all/conanfile.py b/recipes/perf/all/conanfile.py index 2b1346904f2b52..cfea4cd9b1a61c 100644 --- a/recipes/perf/all/conanfile.py +++ b/recipes/perf/all/conanfile.py @@ -1,51 +1,74 @@ -from conans import ConanFile, AutoToolsBuildEnvironment, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.47.0" + class Perf(ConanFile): name = "perf" description = "Linux profiling with performance counters" - topics = ("linux", "profiling") + license = "GPL-2.0 WITH Linux-syscall-note" url = "https://github.com/conan-io/conan-center-index" homepage = "https://perf.wiki.kernel.org/index.php" - license = "GPL-2.0 WITH Linux-syscall-note" - settings = "os", "compiler", "build_type", "arch" - exports_sources = "patches/*" + topics = ("linux", "profiling") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "application" + settings = "os", "arch", "compiler", "build_type" + def export_sources(self): + export_conandata_patches(self) + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + del self.info.settings.compiler def validate(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration("perf is supported only on Linux") def build_requirements(self): - self.build_requires("flex/2.6.4") - self.build_requires("bison/3.5.3") + self.tool_requires("flex/2.6.4") + self.tool_requires("bison/3.8.2") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.make_args += ["NO_LIBPYTHON=1"] + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - autotools = AutoToolsBuildEnvironment(self) - with tools.chdir(os.path.join(self.build_folder, self._source_subfolder, "tools", "perf")): - vars=autotools.vars - vars["NO_LIBPYTHON"] = "1" - autotools.make(vars=vars) + apply_conandata_patches(self) + autotools = Autotools(self) + with chdir(self, os.path.join(self.source_folder, "tools", "perf")): + autotools.make() def package(self): - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - self.copy("LICENSES/**", src=self._source_subfolder, dst="licenses") - - self.copy("perf", src=os.path.join(self._source_subfolder, "tools", "perf"), dst="bin") + copy(self, "COPYING", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "LICENSES/**", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "perf", + src=os.path.join(self.source_folder, "tools", "perf"), + dst=os.path.join(self.package_folder, "bin")) def package_info(self): + self.cpp_info.frameworkdirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = [] + self.cpp_info.includedirs = [] + + # TODO: remove in conan v2 bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: %s" % bin_path) + self.output.info(f"Appending PATH environment variable: {bin_path}") self.env_info.PATH.append(bin_path) diff --git a/recipes/perf/all/test_package/conanfile.py b/recipes/perf/all/test_package/conanfile.py index 4001f8991b6768..451dee24987b03 100644 --- a/recipes/perf/all/test_package/conanfile.py +++ b/recipes/perf/all/test_package/conanfile.py @@ -1,9 +1,13 @@ -from conans import ConanFile, tools +from conan import ConanFile -class TestPackage(ConanFile): +class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - + generators = "VirtualBuildEnv" + test_type = "explicit" + + def build_requirements(self): + self.tool_requires(self.tested_reference_str) + def test(self): - if not tools.cross_building(self): - self.run("perf version") + self.run("perf version") diff --git a/recipes/perf/all/test_v1_package/conanfile.py b/recipes/perf/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..4001f8991b6768 --- /dev/null +++ b/recipes/perf/all/test_v1_package/conanfile.py @@ -0,0 +1,9 @@ +from conans import ConanFile, tools + + +class TestPackage(ConanFile): + settings = "os", "arch", "compiler", "build_type" + + def test(self): + if not tools.cross_building(self): + self.run("perf version") From 850a3544fdf179d741a79aab35aace6fbaa18806 Mon Sep 17 00:00:00 2001 From: Beartama <8091245+uyha@users.noreply.github.com> Date: Sat, 5 Aug 2023 10:26:45 +0300 Subject: [PATCH 0087/1140] (#18880) luajit: specify `provides` attribute --- recipes/luajit/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/luajit/all/conanfile.py b/recipes/luajit/all/conanfile.py index 5271897d749e21..47079e98290b1d 100644 --- a/recipes/luajit/all/conanfile.py +++ b/recipes/luajit/all/conanfile.py @@ -20,6 +20,7 @@ class LuajitConan(ConanFile): homepage = "http://luajit.org" description = "LuaJIT is a Just-In-Time Compiler (JIT) for the Lua programming language." topics = ("lua", "jit") + provides = "lua" settings = "os", "arch", "compiler", "build_type" options = {"shared": [True, False], "fPIC": [True, False]} default_options = {"shared": False, "fPIC": True} From 9e5b00044fce3db4a39932c05639a566d75719c6 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 5 Aug 2023 12:25:29 +0200 Subject: [PATCH 0088/1140] (#18499) gdal/post_3.5.0: bump deps * gdal/post_3.5.0: bump deps * build with cmake>=3.18 * fix build when with_libdeflate=True or when with_cryptopp=True and cryptopp is shared * fix_apple_shared_install_name --------- Co-authored-by: Carlos Zoido --- recipes/gdal/post_3.5.0/CMakeLists.txt | 4 +-- recipes/gdal/post_3.5.0/conanfile.py | 41 +++++++++++++++----------- 2 files changed, 25 insertions(+), 20 deletions(-) diff --git a/recipes/gdal/post_3.5.0/CMakeLists.txt b/recipes/gdal/post_3.5.0/CMakeLists.txt index c0e666f41f1de8..7c7f67a48db89a 100644 --- a/recipes/gdal/post_3.5.0/CMakeLists.txt +++ b/recipes/gdal/post_3.5.0/CMakeLists.txt @@ -26,12 +26,12 @@ endif() if (${GDAL_USE_CRYPTOPP}) find_package(cryptopp REQUIRED) - add_library(CRYPTOPP::CRYPTOPP ALIAS cryptopp::cryptopp-static) + add_library(CRYPTOPP::CRYPTOPP ALIAS ${TARGET_FOR_CRYPTOPP}) endif() if (${GDAL_USE_DEFLATE}) find_package(libdeflate REQUIRED) - add_library(Deflate::Deflate ALIAS libdeflate::libdeflate) + add_library(Deflate::Deflate ALIAS ${TARGET_FOR_DEFLATE}) endif() if (${GDAL_USE_LZ4}) diff --git a/recipes/gdal/post_3.5.0/conanfile.py b/recipes/gdal/post_3.5.0/conanfile.py index d03de4e5125cc1..3e0847981c026c 100644 --- a/recipes/gdal/post_3.5.0/conanfile.py +++ b/recipes/gdal/post_3.5.0/conanfile.py @@ -1,4 +1,5 @@ from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name from conan.tools.files import apply_conandata_patches, get, files from conan.errors import ConanInvalidConfiguration from conans import CMake @@ -172,23 +173,23 @@ def requirements(self): self.requires("cryptopp/8.7.0") if self.options.with_curl: - self.requires("libcurl/7.85.0") + self.requires("libcurl/8.2.0") if self.options.with_dds: self.requires("crunch/cci.20190615") if self.options.with_expat: - self.requires("expat/2.4.9") + self.requires("expat/2.5.0") if self.options.with_exr: - self.requires("openexr/3.1.5") - self.requires("imath/3.1.5") + self.requires("openexr/3.1.9") + self.requires("imath/3.1.9") if self.options.with_freexl: self.requires("freexl/1.0.6") if self.options.with_geos: - self.requires("geos/3.11.0") + self.requires("geos/3.11.1") if self.options.with_gif: self.requires("giflib/5.2.1") @@ -208,13 +209,13 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.4") + self.requires("libjpeg-turbo/2.1.5") if self.options.with_kea: self.requires("kealib/1.4.14") if self.options.with_libdeflate: - self.requires("libdeflate/1.12") + self.requires("libdeflate/1.18") if self.options.with_libiconv: self.requires("libiconv/1.17") @@ -223,7 +224,7 @@ def requirements(self): self.requires("libkml/1.3.0") if self.options.with_libtiff: - self.requires("libtiff/4.4.0") + self.requires("libtiff/4.5.1") if self.options.with_lz4: self.requires("lz4/1.9.4") @@ -246,19 +247,19 @@ def requirements(self): self.requires("openjpeg/2.5.0") if self.options.with_openssl: - self.requires("openssl/1.1.1q") + self.requires("openssl/1.1.1u") if self.options.with_pcre: self.requires("pcre/8.45") if self.options.with_pcre2: - self.requires("pcre2/10.40") + self.requires("pcre2/10.42") if self.options.with_pg: self.requires("libpq/14.5") if self.options.with_png: - self.requires("libpng/1.6.38") + self.requires("libpng/1.6.40") if self.options.with_podofo: self.requires("podofo/0.9.7") @@ -267,28 +268,32 @@ def requirements(self): self.requires("poppler/21.07.0") if self.options.with_proj: - self.requires("proj/9.0.1") + self.requires("proj/9.1.1") if self.options.with_qhull: self.requires("qhull/8.0.1") if self.options.with_sqlite3: - self.requires("sqlite3/3.39.3") + self.requires("sqlite3/3.42.0") if self.options.with_webp: - self.requires("libwebp/1.2.4") + self.requires("libwebp/1.3.1") if self.options.with_xerces: self.requires("xerces-c/3.2.3") if self.options.with_xml2: - self.requires("libxml2/2.9.14") + self.requires("libxml2/2.10.3") if self.options.with_zlib: - self.requires("zlib/1.2.12") + self.requires("zlib/1.2.13") if self.options.with_zstd: - self.requires("zstd/1.5.2") + self.requires("zstd/1.5.5") + + def build_requirements(self): + # https://github.com/conan-io/conan/issues/3482#issuecomment-662284561 + self.tool_requires("cmake/[>=3.18 <4]") def package_id(self): del self.info.options.with_crypto @@ -724,10 +729,10 @@ def package(self): self.copy("LICENSE.TXT", dst="licenses", src=self._source_subfolder) cmake = self._configure_cmake() cmake.install() - files.rmdir(self, os.path.join(self.package_folder, "share")) files.rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) files.rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + fix_apple_shared_install_name(self) def package_info(self): From af3b6ce7431c820d9de18c3c4f0cbd53a096e750 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 5 Aug 2023 15:27:26 +0200 Subject: [PATCH 0089/1140] (#18974) libunwind: add version 1.7.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libunwind/all/conandata.yml | 3 +++ recipes/libunwind/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libunwind/all/conandata.yml b/recipes/libunwind/all/conandata.yml index 933dd5e18e6e00..baa8d36f9cd17a 100644 --- a/recipes/libunwind/all/conandata.yml +++ b/recipes/libunwind/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.7.2": + url: "https://github.com/libunwind/libunwind/releases/download/v1.7.2/libunwind-1.7.2.tar.gz" + sha256: "a18a6a24307443a8ace7a8acc2ce79fbbe6826cd0edf98d6326d0225d6a5d6e6" "1.7.0": url: "https://github.com/libunwind/libunwind/releases/download/v1.7.0/libunwind-1.70.tar.gz" sha256: "c24c913d2337d6eff851b6ab32aadfb683a86fee48d28fe1fc9cd56c8e9dfa58" diff --git a/recipes/libunwind/config.yml b/recipes/libunwind/config.yml index 06062bdf416822..ce44762c05da15 100644 --- a/recipes/libunwind/config.yml +++ b/recipes/libunwind/config.yml @@ -1,4 +1,6 @@ versions: + "1.7.2": + folder: all "1.7.0": folder: all "1.6.2": From d0b45c9664437b9e4924098674d0b67f45dc100c Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 5 Aug 2023 15:48:27 +0200 Subject: [PATCH 0090/1140] (#19052) cairo/meson: bump deps --- recipes/cairo/meson/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cairo/meson/conanfile.py b/recipes/cairo/meson/conanfile.py index 22c79e1b6951e7..f45ccd7290ad42 100644 --- a/recipes/cairo/meson/conanfile.py +++ b/recipes/cairo/meson/conanfile.py @@ -107,7 +107,7 @@ def requirements(self): if self.options.with_png: self.requires("libpng/1.6.40") if self.options.with_glib: - self.requires("glib/2.76.3") + self.requires("glib/2.77.0") if self.settings.os == "Linux": if self.options.with_xlib or self.options.with_xlib_xrender or self.options.with_xcb: self.requires("xorg/system") From 0eea54acc08b78922dd57f3ee3e97dcacfb5031c Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 5 Aug 2023 23:07:56 +0900 Subject: [PATCH 0091/1140] (#19053) simdjson: add version 3.2.2 --- recipes/simdjson/all/conandata.yml | 3 +++ recipes/simdjson/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/simdjson/all/conandata.yml b/recipes/simdjson/all/conandata.yml index 68f7a88456dcd1..4dd45c1bc80bce 100644 --- a/recipes/simdjson/all/conandata.yml +++ b/recipes/simdjson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.2": + url: "https://github.com/simdjson/simdjson/archive/v3.2.2.tar.gz" + sha256: "13a702536e051db612cdca82bf8585f2c69d9c6fd156ef291b170f13202c1b4c" "3.2.1": url: "https://github.com/simdjson/simdjson/archive/v3.2.1.tar.gz" sha256: "121206c9bfe972a2202a74d4cddb8cb0561932427f96d6c4b70fb49a2a74560e" diff --git a/recipes/simdjson/config.yml b/recipes/simdjson/config.yml index 5a66369f45d95a..cda9ed23f089a0 100644 --- a/recipes/simdjson/config.yml +++ b/recipes/simdjson/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.2": + folder: all "3.2.1": folder: all "3.2.0": From a08f778e4c7cbf7995d3fbc38ca7ba6c3749fc11 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Sat, 5 Aug 2023 16:47:16 +0200 Subject: [PATCH 0092/1140] (#18973) aws-c-common: add version 0.9.0 * aws-c-common: add version 0.9.0 * cleanup: remove test_v1_package folder * add version 0.9.0 to config.yml * add patch_type and patch_description --- recipes/aws-c-common/all/conandata.yml | 7 +++++++ .../all/test_v1_package/CMakeLists.txt | 8 -------- .../all/test_v1_package/conanfile.py | 17 ----------------- recipes/aws-c-common/config.yml | 2 ++ 4 files changed, 9 insertions(+), 25 deletions(-) delete mode 100644 recipes/aws-c-common/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/aws-c-common/all/test_v1_package/conanfile.py diff --git a/recipes/aws-c-common/all/conandata.yml b/recipes/aws-c-common/all/conandata.yml index 773702bbe2c98e..6929bedbf2e128 100644 --- a/recipes/aws-c-common/all/conandata.yml +++ b/recipes/aws-c-common/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.9.0": + url: "https://github.com/awslabs/aws-c-common/archive/v0.9.0.tar.gz" + sha256: "9b62ab1dcece3107810ea4f4511fe8e1e010a83cb0cb502b6ec685ce752a7b0c" "0.8.2": url: "https://github.com/awslabs/aws-c-common/archive/v0.8.2.tar.gz" sha256: "36edc6e486c43bbb34059dde227e872c0d41ab54f0b3609d38f188cfbbc6d1f8" @@ -53,4 +56,8 @@ sources: patches: "0.4.25": - patch_file: "patches/0001-disable-fPIC.patch" + patch_description: "Don't enable position independent code (will be handled by conan)" + patch_type: "conan" - patch_file: "patches/0002-no-warnings-as-errors.patch" + patch_description: "Don't make all warnings into errors" + patch_type: "portability" diff --git a/recipes/aws-c-common/all/test_v1_package/CMakeLists.txt b/recipes/aws-c-common/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 0d20897301b68b..00000000000000 --- a/recipes/aws-c-common/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/aws-c-common/all/test_v1_package/conanfile.py b/recipes/aws-c-common/all/test_v1_package/conanfile.py deleted file mode 100644 index 38f4483872d47f..00000000000000 --- a/recipes/aws-c-common/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,17 +0,0 @@ -from conans import ConanFile, CMake, tools -import os - - -class TestPackageConan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) diff --git a/recipes/aws-c-common/config.yml b/recipes/aws-c-common/config.yml index 5a8e794412c2ff..472e641908fd07 100644 --- a/recipes/aws-c-common/config.yml +++ b/recipes/aws-c-common/config.yml @@ -1,4 +1,6 @@ versions: + "0.9.0": + folder: all "0.8.2": folder: all "0.7.5": From 8d74df2c59a66ebb951273a163903e77e634bad4 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 5 Aug 2023 18:07:03 +0200 Subject: [PATCH 0093/1140] (#18972) glib: add version 2.77.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/glib/all/conandata.yml | 3 +++ recipes/glib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glib/all/conandata.yml b/recipes/glib/all/conandata.yml index a457da4866ed6c..861fdaf0233953 100644 --- a/recipes/glib/all/conandata.yml +++ b/recipes/glib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.77.1": + url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.1.tar.xz" + sha256: "dce8d0c9e916d8c81a64436bd4ee4d6515a52dd3d157c994e1cdb9b3d6300a03" "2.77.0": url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.0.tar.xz" sha256: "1897fd8ad4ebb523c32fabe7508c3b0b039c089661ae1e7917df0956a320ac4d" diff --git a/recipes/glib/config.yml b/recipes/glib/config.yml index 709e827338b68f..f86b1571991633 100644 --- a/recipes/glib/config.yml +++ b/recipes/glib/config.yml @@ -1,4 +1,6 @@ versions: + "2.77.1": + folder: all "2.77.0": folder: all "2.76.3": From 11c6c5bc221329aa2e6cea1a9a3d465000cf69f6 Mon Sep 17 00:00:00 2001 From: Marcin Zdun Date: Sun, 6 Aug 2023 00:03:41 +0200 Subject: [PATCH 0094/1140] (#17825) add mbits-lngs/0.7.5 * add mbits-lngs/0.7.5 * fix: take a better build system * fix: add encoding to open * fix: follow forced tag * fix: follow another force tag * fix: follow yet another forced tag * fix: will this compile with Clang? * fix: dependencies do not like Clang * fix: take forced tag compilable with clang/libc++ * build: yes to M1, not to cross-compilation * fix: allow cross-compile for M1 * fix: build test on M1 and support VirtualRunEnv * fix: detect cross-compilation in universal way * build: add note from protobuf' conanfile.py * simplify executable usage Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Daniel Co-authored-by: Uilian Ries --- recipes/mbits-lngs/all/conandata.yml | 4 + recipes/mbits-lngs/all/conanfile.py | 142 ++++++++++++++++++ .../all/test_package/CMakeLists.txt | 22 +++ .../mbits-lngs/all/test_package/conanfile.py | 43 ++++++ .../all/test_package/test_package.cpp | 10 ++ .../all/test_package/translations.idl | 9 ++ recipes/mbits-lngs/config.yml | 3 + 7 files changed, 233 insertions(+) create mode 100644 recipes/mbits-lngs/all/conandata.yml create mode 100644 recipes/mbits-lngs/all/conanfile.py create mode 100644 recipes/mbits-lngs/all/test_package/CMakeLists.txt create mode 100644 recipes/mbits-lngs/all/test_package/conanfile.py create mode 100644 recipes/mbits-lngs/all/test_package/test_package.cpp create mode 100644 recipes/mbits-lngs/all/test_package/translations.idl create mode 100644 recipes/mbits-lngs/config.yml diff --git a/recipes/mbits-lngs/all/conandata.yml b/recipes/mbits-lngs/all/conandata.yml new file mode 100644 index 00000000000000..a85ddd2561b528 --- /dev/null +++ b/recipes/mbits-lngs/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.7.6": + url: "https://github.com/mbits-os/lngs/archive/v0.7.6.tar.gz" + sha256: "85c9fd3afd5b6d5446a294f4de11221ae7fa160a62d1115a7ea0c1af17633a0b" diff --git a/recipes/mbits-lngs/all/conanfile.py b/recipes/mbits-lngs/all/conanfile.py new file mode 100644 index 00000000000000..2db7f9f7b6cca7 --- /dev/null +++ b/recipes/mbits-lngs/all/conanfile.py @@ -0,0 +1,142 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.files import get, copy, save, rmdir +from conan.tools.build import check_min_cppstd, cross_building +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +import os +import textwrap + + +required_conan_version = ">=1.53.0" + + +class MBitsLngsConan(ConanFile): + name = "mbits-lngs" + description = "Language strings support" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/mbits-os/lngs" + topics = ("gettext", "locale",) + settings = "os", "arch", "compiler", "build_type" + package_type = "static-library" + options = { + "fPIC": [True, False], + } + default_options = { + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "11", + "clang": "12", + "Visual Studio": "16", + "msvc": "192", + "apple-clang": "11.0.3", + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("fmt/9.1.0") + self.requires("mbits-utfconv/1.0.3") + self.requires("mbits-diags/0.9.6") + self.requires("mbits-mstch/1.0.4") + self.requires("mbits-args/0.12.3") + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 192) + if not is_msvc(self): + 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) + + @property + def _settings_build(self): + return self.settings_build if hasattr(self, "settings_build") else self.settings + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LNGS_TESTING"] = False + tc.variables["LNGS_LITE"] = False + tc.variables["LNGS_LINKED_RESOURCES"] = True + tc.variables["LNGS_NO_PKG_CONFIG"] = True + if cross_building(self) and hasattr(self, "settings_build"): + tc.variables["LNGS_REBUILD_RESOURCES"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + @property + def _cmake_install_base_path(self): + return os.path.join("lib", "cmake") + + @property + def _cmake_targets_module_file(self): + return os.path.join(self._cmake_install_base_path, "mbits-lngs-targets.cmake") + + def package(self): + copy( + self, + pattern="LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder, + ) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, self._cmake_install_base_path)) + + + # Provide relocatable mbits::lngs target and Mbitslngs_LNGS_EXECUTABLE cache variable + # TODO: some of the following logic might be disabled when conan will + # allow to create executable imported targets in package_info() + module_folder_depth = len(os.path.normpath(self._cmake_install_base_path).split(os.path.sep)) + lngs_rel_path = "{}bin/{}".format("".join(["../"] * module_folder_depth), "lngs") + save(self, os.path.join(self.package_folder, self._cmake_targets_module_file), + textwrap.dedent( + f"""\ + if(NOT TARGET mbits::lngs) + if(CMAKE_CROSSCOMPILING) + find_program(LNGS_PROGRAM lngs PATHS ENV PATH NO_DEFAULT_PATH) + endif() + if(NOT LNGS_PROGRAM) + set(LNGS_PROGRAM "${{CMAKE_CURRENT_LIST_DIR}}/{lngs_rel_path}") + endif() + get_filename_component(LNGS_PROGRAM "${{LNGS_PROGRAM}}" ABSOLUTE) + set(Mbitslngs_LNGS_EXECUTABLE ${{LNGS_PROGRAM}} CACHE FILEPATH "The lngs tool") + add_executable(mbits::lngs IMPORTED) + set_property(TARGET mbits::lngs PROPERTY IMPORTED_LOCATION ${{Mbitslngs_LNGS_EXECUTABLE}}) + endif() + """) + ) + + def package_info(self): + self.cpp_info.builddirs = [self._cmake_install_base_path ] + self.cpp_info.set_property("cmake_build_modules", [self._cmake_targets_module_file]) + self.cpp_info.set_property("cmake_file_name", "mbits-lngs") + + comp = self.cpp_info.components["liblngs"] + comp.set_property("cmake_target_name", "mbits::liblngs") + comp.libs = ["lngs"] diff --git a/recipes/mbits-lngs/all/test_package/CMakeLists.txt b/recipes/mbits-lngs/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..de4330a77c2a63 --- /dev/null +++ b/recipes/mbits-lngs/all/test_package/CMakeLists.txt @@ -0,0 +1,22 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package CXX) + +find_package(mbits-lngs REQUIRED CONFIG) + +set(IDL ${CMAKE_CURRENT_SOURCE_DIR}/translations.idl) +set(CPP ${CMAKE_CURRENT_BINARY_DIR}/translations.cpp) +set(HPP ${CMAKE_CURRENT_BINARY_DIR}/translations.hpp) + +add_custom_target( + make_lngs + COMMAND mbits::lngs res ${IDL} -o ${CPP} --include "translations.hpp" + COMMAND mbits::lngs enums -r ${IDL} -o ${HPP} + BYPRODUCTS ${CPP} ${HPP} + DEPENDS ${IDL} +) + +add_executable(${PROJECT_NAME} test_package.cpp ${CPP} ${HPP}) +target_link_libraries(${PROJECT_NAME} PRIVATE mbits::liblngs) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_CURRENT_BINARY_DIR}) +add_dependencies(${PROJECT_NAME} make_lngs) diff --git a/recipes/mbits-lngs/all/test_package/conanfile.py b/recipes/mbits-lngs/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e3b64136d43e7b --- /dev/null +++ b/recipes/mbits-lngs/all/test_package/conanfile.py @@ -0,0 +1,43 @@ +from conan import ConanFile +from conan.tools.build import can_run, cross_building +from conan.tools.cmake import cmake_layout, CMake, CMakeDeps, CMakeToolchain +from conan.tools.env import VirtualRunEnv, VirtualBuildEnv +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def build_requirements(self): + if cross_building(self) and hasattr(self, "settings_build"): + self.tool_requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def generate(self): + tc = VirtualRunEnv(self) + tc.generate() + tc = VirtualBuildEnv(self) + if cross_building(self) and hasattr(self, "settings_build"): + tc.generate() + else: + tc.generate(scope="build") + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/mbits-lngs/all/test_package/test_package.cpp b/recipes/mbits-lngs/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..54cfa70731d8d9 --- /dev/null +++ b/recipes/mbits-lngs/all/test_package/test_package.cpp @@ -0,0 +1,10 @@ +#include "translations.hpp" +#include + +int main() { + lngs::test::Strings tr{}; + tr.init_builtin(); + tr.path_manager(".", "example"); + + std::cout << tr(lngs::test::lng::MESSAGE) << '\n'; +} diff --git a/recipes/mbits-lngs/all/test_package/translations.idl b/recipes/mbits-lngs/all/test_package/translations.idl new file mode 100644 index 00000000000000..52b142116a7003 --- /dev/null +++ b/recipes/mbits-lngs/all/test_package/translations.idl @@ -0,0 +1,9 @@ +[ + project("lngs-test"), + namespace("lngs::test"), + version("0.1"), + serial(1) +] strings { + [help("Hello world string"), id(1001)] + MESSAGE = "Hello, world!"; +} diff --git a/recipes/mbits-lngs/config.yml b/recipes/mbits-lngs/config.yml new file mode 100644 index 00000000000000..1d3599e3efc2ee --- /dev/null +++ b/recipes/mbits-lngs/config.yml @@ -0,0 +1,3 @@ +versions: + "0.7.6": + folder: all From 70ca6dc14675c9a17374ef96c1a4d75deb89c702 Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Sun, 6 Aug 2023 02:06:56 +0200 Subject: [PATCH 0095/1140] (#18953) [cgal] add cgal/5.5.3 * [cgal] add cgal/5.5.3 * i forgot config.yml --- recipes/cgal/all/conandata.yml | 8 ++++++++ recipes/cgal/config.yml | 2 ++ 2 files changed, 10 insertions(+) diff --git a/recipes/cgal/all/conandata.yml b/recipes/cgal/all/conandata.yml index 243b9320511a51..74b2b15e01e387 100644 --- a/recipes/cgal/all/conandata.yml +++ b/recipes/cgal/all/conandata.yml @@ -11,6 +11,9 @@ sources: "5.5.2": sha256: b2b05d5616ecc69facdc24417cce0b04fb4321491d107db45103add520e3d8c3 url: https://github.com/CGAL/cgal/releases/download/v5.5.2/CGAL-5.5.2.tar.xz + "5.5.3": + sha256: 0a04f662693256328b05babfabb5e3a5b7db2f5a58d52e3c520df9d0828ddd73 + url: https://github.com/CGAL/cgal/releases/download/v5.5.3/CGAL-5.5.3.tar.xz patches: "5.3.2": - patch_file: "patches/0001-fix-for-conan.patch" @@ -32,3 +35,8 @@ patches: patch_type: bugfix patch_source: https://github.com/CGAL/cgal/pull/7502 patch_description: Fix Eigen3 support in CGAL + "5.5.3": + - patch_file: "patches/0001-fix-for-conan.patch" + patch_type: bugfix + patch_source: https://github.com/CGAL/cgal/pull/7502 + patch_description: Fix Eigen3 support in CGAL diff --git a/recipes/cgal/config.yml b/recipes/cgal/config.yml index 48232844708f0d..e8e1391dbacd37 100644 --- a/recipes/cgal/config.yml +++ b/recipes/cgal/config.yml @@ -7,3 +7,5 @@ versions: folder: all "5.5.2": folder: all + "5.5.3": + folder: all From 7efe2fda18e986c41debfe2bce2010d8280c50ff Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sun, 6 Aug 2023 07:22:37 +0200 Subject: [PATCH 0096/1140] (#19042) [docs] Add changelog 2023-Aug-04 Signed-off-by: Uilian Ries --- docs/changelog.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 4ea36e44e8667d..24c6950d686aad 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,12 @@ # Changelog +### 04-Aug-2023 - 10:26 CEST + +- [feature] Enable Conan 2.0.8 +- [feature] Enable Conan 1.60.2 +- [feature] Update Jenkins server version +- [hotfix] Better error management when having CI build timeout + ### 19-Jul-2023 - 09:45 CEST - [fix] Fix message processing if no message is passed. From 89e0b7bffe5bdad217492ffc5ded1162ef50941b Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sun, 6 Aug 2023 08:02:08 +0200 Subject: [PATCH 0097/1140] (#19036) [bimg] Fix imports for test package Signed-off-by: Uilian Ries --- recipes/bimg/all/test_package/conanfile.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/bimg/all/test_package/conanfile.py b/recipes/bimg/all/test_package/conanfile.py index 4100c3ff4959c1..17cae798801223 100644 --- a/recipes/bimg/all/test_package/conanfile.py +++ b/recipes/bimg/all/test_package/conanfile.py @@ -1,10 +1,8 @@ from conan import ConanFile from conan.tools.build import can_run -from conan.tools.layout import cmake_layout -from conan.tools.cmake import CMake +from conan.tools.cmake import CMake, cmake_layout import os -required_conan_version = ">=1.50.0" class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" From bc1eb9037ecab0d1455367efada63dcd3f2aab9f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 6 Aug 2023 09:25:06 +0300 Subject: [PATCH 0098/1140] (#17933) gtsam: add v4.2.0a9, update package options MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gtsam: add missing Boost::program_options requirement See https://github.com/borglab/gtsam/blob/4.1.1/cmake/HandleBoost.cmake#L26 * gtsam: add transitive_headers/libs to deps * gtsam: drop test_v1_package * gtsam: backport a patch for C++17 compatibility * gtsam: add v4.2.0a9 https://github.com/borglab/gtsam/releases/tag/4.2a9 * gtsam: update package options - Covers all options that could be found in GTSAM build scripts. - Added links to source code since they are hard to find otherwise. - Added `allow_deprecated` option and deprecated `allow_deprecated_since_V4` as the wording of the GTSAM variable keeps changing but the meaning has stayed the same. - Added vars: GTSAM_DEFAULT_ALLOCATOR GTSAM_SLOW_BUT_CORRECT_BETWEENFACTOR GTSAM_USE_SYSTEM_METIS GTSAM_MEX_BUILD_STATIC_MODULE * gtsam: tweak formatting * gtsam: get rid of a duplicate patch * gtsam: handle `build_type_postfixes` option correctly * gtsam: correct metis lib name in 4.0 * gtsam: correct build_type_postfixes behavior * gtsam: fix a bug in 4.2.0a9 * gtsam: add 'lib' prefix to libraries on Windows * gtsam: add patch_source info to conandata.yml * gtsam: apply "lib" prefix on Windows correctly * gtsam: drop v4.0.2 To limit the load on CI. Superseded by v4.0.3. * gtsam: update onetbb and boost versions onetbb/2020.3 did not support Conan v2. * gtsam: better TBB validation * gtsam: add tcmalloc support with gperftools * gtsam: fix Eigen version check * gtsam: enable shared builds on Windows for v4.2 * gtsam: shared builds on Windows are broken in v4.2.0a9 * gtsam: document options with options_description * gtsam: add use_vendored_metis option * gtsam: simplify Conan v1 boilerplate * gtsam: improve default_allocator handling * gtsam: remove use_vendored_metis option It no longer builds with the new metis recipe. --------- Co-authored-by: Francisco Ramírez --- recipes/gtsam/all/conandata.yml | 40 ++- recipes/gtsam/all/conanfile.py | 334 +++++++++++++----- .../all/patches/4.0.2-0001-cmake-boost.patch | 61 ---- .../all/patches/4.0.2-0002-cmake-eigen.patch | 20 -- .../all/patches/4.0.2-0003-macos-rpath.patch | 34 -- ...t.patch => 4.0.3-0004-cmake-project.patch} | 0 .../patches/4.1.1-0005-eigen3-version.patch | 21 ++ .../all/patches/4.2.0-0001-macos-rpath.patch | 30 ++ .../patches/4.2.0-0002-eigen3-version.patch | 20 ++ .../4.2.0a9-0001-fix-invalid-include.patch | 12 + .../gtsam/all/test_v1_package/CMakeLists.txt | 8 - .../gtsam/all/test_v1_package/conanfile.py | 17 - recipes/gtsam/config.yml | 4 +- 13 files changed, 348 insertions(+), 253 deletions(-) delete mode 100644 recipes/gtsam/all/patches/4.0.2-0001-cmake-boost.patch delete mode 100644 recipes/gtsam/all/patches/4.0.2-0002-cmake-eigen.patch delete mode 100644 recipes/gtsam/all/patches/4.0.2-0003-macos-rpath.patch rename recipes/gtsam/all/patches/{4.0.2-0003-cmake-project.patch => 4.0.3-0004-cmake-project.patch} (100%) create mode 100644 recipes/gtsam/all/patches/4.1.1-0005-eigen3-version.patch create mode 100644 recipes/gtsam/all/patches/4.2.0-0001-macos-rpath.patch create mode 100644 recipes/gtsam/all/patches/4.2.0-0002-eigen3-version.patch create mode 100644 recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch delete mode 100644 recipes/gtsam/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/gtsam/all/test_v1_package/conanfile.py diff --git a/recipes/gtsam/all/conandata.yml b/recipes/gtsam/all/conandata.yml index a7ab46e7ea6fbd..eecf7c3eb615ed 100644 --- a/recipes/gtsam/all/conandata.yml +++ b/recipes/gtsam/all/conandata.yml @@ -1,14 +1,28 @@ sources: + "4.2.0a9": + url: "https://github.com/borglab/gtsam/archive/refs/tags/4.2a9.tar.gz" + sha256: "a9790e5132bfb2705a5985a1505c3cf9cdf95b711be8352ffa9a9299b279f2f8" "4.1.1": url: "https://github.com/borglab/gtsam/archive/4.1.1.tar.gz" sha256: "c7b5e6cdad52b141c272778f47baf628975457be3e26ed96a7bc2ae685a00af0" "4.0.3": url: "https://github.com/borglab/gtsam/archive/4.0.3.tar.gz" sha256: "eaa561749edf7a2d402981828253e28aed6c717dae35738301c5ab23e2595f25" - "4.0.2": - url: "https://github.com/borglab/gtsam/archive/4.0.2.tar.gz" - sha256: "8770a440f1af98c3f0d9d4dffd568de2d4c21b245e7231e987e26bc236aeb5aa" patches: + "4.2.0a9": + - patch_file: "patches/4.1.1-0001-cmake-boost.patch" + patch_description: "Use boost targets" + patch_type: "conan" + - patch_file: "patches/4.2.0-0001-macos-rpath.patch" + patch_description: "Relocatable shared libs on Apple OS" + patch_type: "conan" + - patch_file: "patches/4.2.0-0002-eigen3-version.patch" + patch_description: "Get Eigen3 version info from Conan" + patch_type: "conan" + - patch_file: "patches/4.2.0a9-0001-fix-invalid-include.patch" + patch_description: "Fix an invalid include for pre-C++17 compatibility" + patch_type: "portability" + patch_source: "https://github.com/borglab/gtsam/pull/1545" "4.1.1": - patch_file: "patches/4.1.1-0001-cmake-boost.patch" patch_description: "Use boost targets" @@ -19,9 +33,12 @@ patches: - patch_file: "patches/4.1.1-0003-macos-rpath.patch" patch_description: "Relocatable shared libs on Apple OS" patch_type: "conan" - - patch_file: "patches/4.0.2-0003-cmake-project.patch" + - patch_file: "patches/4.0.3-0004-cmake-project.patch" patch_description: "CMake: move project() after cmake_minimum_required()" patch_type: "conan" + - patch_file: "patches/4.1.1-0005-eigen3-version.patch" + patch_description: "Get Eigen3 version info from Conan" + patch_type: "conan" "4.0.3": - patch_file: "patches/4.0.3-0001-cmake-boost.patch" patch_description: "Use boost targets" @@ -32,19 +49,6 @@ patches: - patch_file: "patches/4.0.3-0003-macos-rpath.patch" patch_description: "Relocatable shared libs on Apple OS" patch_type: "conan" - - patch_file: "patches/4.0.2-0003-cmake-project.patch" - patch_description: "CMake: move project() after cmake_minimum_required()" - patch_type: "conan" - "4.0.2": - - patch_file: "patches/4.0.2-0001-cmake-boost.patch" - patch_description: "Use boost targets" - patch_type: "conan" - - patch_file: "patches/4.0.2-0002-cmake-eigen.patch" - patch_description: "Use Eigen include variable from CMakeDeps" - patch_type: "conan" - - patch_file: "patches/4.0.2-0003-macos-rpath.patch" - patch_description: "Relocatable shared libs on Apple OS" - patch_type: "conan" - - patch_file: "patches/4.0.2-0003-cmake-project.patch" + - patch_file: "patches/4.0.3-0004-cmake-project.patch" patch_description: "CMake: move project() after cmake_minimum_required()" patch_type: "conan" diff --git a/recipes/gtsam/all/conanfile.py b/recipes/gtsam/all/conanfile.py index 6ed583d1786ac9..4320c2bbb7e698 100644 --- a/recipes/gtsam/all/conanfile.py +++ b/recipes/gtsam/all/conanfile.py @@ -15,58 +15,100 @@ class GtsamConan(ConanFile): license = "BSD-3-Clause" homepage = "https://github.com/borglab/gtsam" url = "https://github.com/conan-io/conan-center-index" - description = ("GTSAM is a library of C++ classes that implement\ - smoothing and mapping (SAM) in robotics and vision") - topics = ("mapping", "smoothing") + description = ("GTSAM is a library of C++ classes that implement " + "smoothing and mapping (SAM) in robotics and vision") + topics = ("mapping", "smoothing", "optimization", "factor-graphs") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], - "use_quaternions": [True, False], + "allow_deprecated": [True, False], + "allow_deprecated_since_V4": [True, False, "deprecated"], + "build_type_postfixes": [True, False], + "build_unstable": [True, False], + "build_with_march_native": [True, False], + "default_allocator": [None, "STL", "BoostPool", "TBB", "tcmalloc"], + "disable_new_timers": [True, False], + "enable_consistency_checks": [True, False], + "install_cppunitlite": [True, False], + "install_matlab_toolbox": [True, False], "pose3_expmap": [True, False], "rot3_expmap": [True, False], - "enable_consistency_checks": [True, False], + "slow_but_correct_betweenfactor": [True, False], + "support_nested_dissection": [True, False], + "tangent_preintegration": [True, False], + "throw_cheirality_exception": [True, False], + "use_quaternions": [True, False], "with_TBB": [True, False], "with_eigen_MKL": [True, False], "with_eigen_MKL_OPENMP": [True, False], - "throw_cheirality_exception": [True, False], - "allow_deprecated_since_V4": [True, False], - "typedef_points_to_vectors": [True, False], - "support_nested_dissection": [True, False], - "tangent_preintegration": [True, False], + + # Removed since v4.1 "build_wrap": [True, False], - "wrap_serialization": [True, False], - "build_unstable": [True, False], - "disable_new_timers": [True, False], - "build_type_postfixes": [True, False], - "install_matlab_toolbox": [True, False], "install_cython_toolbox": [True, False], - "install_cppunitlite": [True, False], + "typedef_points_to_vectors": [True, False], + "wrap_serialization": [True, False], } default_options = { "shared": False, "fPIC": True, - "use_quaternions": False, + "allow_deprecated": True, + "allow_deprecated_since_V4": "deprecated", + "build_type_postfixes": True, + "build_unstable": True, + "build_with_march_native": False, + "default_allocator": None, + "disable_new_timers": False, + "enable_consistency_checks": False, + "install_cppunitlite": True, + "install_matlab_toolbox": False, "pose3_expmap": False, "rot3_expmap": False, - "enable_consistency_checks": False, + "slow_but_correct_betweenfactor": False, + "support_nested_dissection": False, + "tangent_preintegration": False, + "throw_cheirality_exception": True, + "use_quaternions": False, "with_TBB": False, "with_eigen_MKL": False, "with_eigen_MKL_OPENMP": False, - "throw_cheirality_exception": True, - "allow_deprecated_since_V4": True, - "typedef_points_to_vectors": False, - "support_nested_dissection": False, - "tangent_preintegration": False, + + # < v4.1 only "build_wrap": False, - "wrap_serialization": True, - "build_unstable": True, - "disable_new_timers": False, - "build_type_postfixes": True, - "install_matlab_toolbox": False, "install_cython_toolbox": False, - "install_cppunitlite": True, + "typedef_points_to_vectors": False, + "wrap_serialization": True, + } + options_description = { + "allow_deprecated": "Allow use of deprecated methods/functions", + "build_type_postfixes": "Append the build type to the name of compiled libraries", + "build_unstable": "Enable building of gtsam_unstable", + "build_with_march_native": "Build with all instructions supported by native architecture (binary may not be portable!)", + "default_allocator": "Set preferred memory allocator. If unset, defaults to STL or to TBB, if with_TBB is enabled", + "disable_new_timers": "Disables using Boost.chrono for timing", + "enable_consistency_checks": "Enable expensive consistency checks", + "install_cppunitlite": "Install CppUnitLite library as a component", + "install_matlab_toolbox": "Install MATLAB toolbox", + "pose3_expmap": "Use Pose3::EXPMAP as the default mode. If disabled, Pose3::FIRST_ORDER will be used.", + "rot3_expmap": ("Ignore if GTSAM_USE_QUATERNIONS is OFF (Rot3::EXPMAP by default). " + "Otherwise, enable Rot3::EXPMAP, or if disabled, use Rot3::CAYLEY."), + "slow_but_correct_betweenfactor": "Use the slower but correct version of BetweenFactor", + "support_nested_dissection": "Support Metis-based nested dissection", + "tangent_preintegration": "Use the new ImuFactor with integration on tangent space", + "throw_cheirality_exception": "Throw exception when a triangulated point is behind a camera", + "use_quaternions": ("Enable an internal Quaternion representation for rotations instead of rotation matrices. " + "If enabled, Rot3::EXPMAP is enforced by default."), + "with_TBB": "Use Intel Threaded Building Blocks (TBB)", + "with_eigen_MKL": "Eigen will use Intel MKL if available", + "with_eigen_MKL_OPENMP": "Eigen, when using Intel MKL, will also use OpenMP for multithreading if available", + + # < v4.1 only + "build_wrap": "Build Matlab/Cython wrap utility (necessary for Matlab/Cython interface)", + "install_cython_toolbox": "Install Cython toolbox", + "typedef_points_to_vectors": "Typedef Point2 and Point3 to Eigen::Vector equivalents", + "wrap_serialization": "Allow wrapped objects to be saved via boost.serialization", } def export_sources(self): @@ -75,43 +117,90 @@ def export_sources(self): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) >= "4.1": + del self.options.build_wrap + del self.options.install_cython_toolbox + del self.options.typedef_points_to_vectors + del self.options.wrap_serialization + else: + del self.options.slow_but_correct_betweenfactor def configure(self): if self.options.shared: self.options.rm_safe("fPIC") if self.options.with_TBB: self.options["onetbb"].tbbmalloc = True + if self.options.allow_deprecated_since_V4 != "deprecated": + self.output.warn("'allow_deprecated_since_V4' option is deprecated. Use 'allow_deprecated' instead.") + def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.81.0") - self.requires("eigen/3.4.0") + self.requires("boost/1.82.0", transitive_headers=True) + self.requires("eigen/3.4.0", transitive_headers=True) if self.options.with_TBB: - self.requires("onetbb/2020.3") + self.requires("onetbb/2021.9.0", transitive_headers=True) + if self.options.default_allocator == "tcmalloc": + self.requires("gperftools/2.10.0") + # TODO: add use_vendored_metis=False option + # if self.options.support_nested_dissection and not self.options.use_vendored_metis: + # # Used in a public header here: + # # https://github.com/borglab/gtsam/blob/4.2a9/gtsam_unstable/partition/FindSeparator-inl.h#L23-L27 + # self.requires("metis/5.1.1", transitive_headers=True) @property def _required_boost_components(self): - return ["serialization", "system", "filesystem", "thread", "date_time", "regex", "timer", "chrono"] + # Based on https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleBoost.cmake#L26 + return [ + "chrono", + "date_time", + "filesystem", + "program_options", + "regex", + "serialization", + "system", + "thread", + "timer", + ] def validate(self): - miss_boost_required_comp = any(self.dependencies["boost"].options.get_safe(f"without_{boost_comp}", True) - for boost_comp in self._required_boost_components) + miss_boost_required_comp = any( + self.dependencies["boost"].options.get_safe(f"without_{boost_comp}", True) + for boost_comp in self._required_boost_components + ) if self.dependencies["boost"].options.header_only or miss_boost_required_comp: raise ConanInvalidConfiguration( f"{self.ref} requires non header-only boost with these components: " f"{', '.join(self._required_boost_components)}" ) - if self.options.with_TBB and not self.dependencies["onetbb"].options.tbbmalloc: - raise ConanInvalidConfiguration("gtsam with tbb requires onetbb:tbbmalloc=True") + if self.options.with_TBB: + if self.options.default_allocator in [None, "TBB"]: + if not self.dependencies["onetbb"].options.tbbmalloc: + raise ConanInvalidConfiguration("GTSAM with TBB requires onetbb/*:tbbmalloc=True") + elif self.options.default_allocator != "tcmalloc": + raise ConanInvalidConfiguration( + "with_TBB option cannot be used with" + f" default_allocator={self.options.default_allocator}" + ) + elif self.options.default_allocator == "TBB": + raise ConanInvalidConfiguration("default_allocator=TBB requires with_TBB=True") check_min_vs(self, "191") - if Version(self.version) >= "4.1.0" and is_msvc(self) and self.options.shared: + if Version(self.version) >= "4.1" and is_msvc(self) and self.options.shared: raise ConanInvalidConfiguration( - f"{self.ref} does not support shared builds with MSVC. See https://github.com/borglab/gtsam/issues/1087" + f"{self.ref} does not support shared builds with MSVC. See" + "https://github.com/borglab/gtsam/issues/1087" + if Version(self.version) < "4.2" + else "https://github.com/borglab/gtsam/issues/1541" + ) + + if self.options.allow_deprecated_since_V4 != "deprecated": + self.output.warn( + "'allow_deprecated_since_V4' option is deprecated. Use 'allow_deprecated' instead." ) def source(self): @@ -120,6 +209,10 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["BUILD_SHARED_LIBS"] = self.options.shared + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleGeneralOptions.cmake + tc.variables["GTSAM_BUILD_UNSTABLE"] = self.options.build_unstable + tc.variables["GTSAM_UNSTABLE_BUILD_PYTHON"] = False + tc.variables["GTSAM_UNSTABLE_INSTALL_MATLAB_TOOLBOX"] = self.options.install_matlab_toolbox tc.variables["GTSAM_USE_QUATERNIONS"] = self.options.use_quaternions tc.variables["GTSAM_POSE3_EXPMAP"] = self.options.pose3_expmap tc.variables["GTSAM_ROT3_EXPMAP"] = self.options.rot3_expmap @@ -128,41 +221,89 @@ def generate(self): tc.variables["GTSAM_WITH_EIGEN_MKL"] = self.options.with_eigen_MKL tc.variables["GTSAM_WITH_EIGEN_MKL_OPENMP"] = self.options.with_eigen_MKL_OPENMP tc.variables["GTSAM_THROW_CHEIRALITY_EXCEPTION"] = self.options.throw_cheirality_exception - tc.variables["GTSAM_ALLOW_DEPRECATED_SINCE_V4"] = self.options.allow_deprecated_since_V4 - tc.variables["GTSAM_TYPEDEF_POINTS_TO_VECTORS"] = self.options.typedef_points_to_vectors + tc.variables["GTSAM_BUILD_PYTHON"] = False + tc.variables["GTSAM_INSTALL_MATLAB_TOOLBOX"] = self.options.install_matlab_toolbox + tc.variables["GTSAM_ALLOW_DEPRECATED_SINCE_V4"] = self.options.allow_deprecated + if self.options.allow_deprecated_since_V4 != "deprecated": + tc.variables["GTSAM_ALLOW_DEPRECATED_SINCE_V4"] = self.options.allow_deprecated_since_V4 + tc.variables["GTSAM_ALLOW_DEPRECATED_SINCE_V41"] = self.options.allow_deprecated + tc.variables["GTSAM_ALLOW_DEPRECATED_SINCE_V42"] = self.options.allow_deprecated tc.variables["GTSAM_SUPPORT_NESTED_DISSECTION"] = self.options.support_nested_dissection tc.variables["GTSAM_TANGENT_PREINTEGRATION"] = self.options.tangent_preintegration + # Added in 4.1+ + if Version(self.version) >= "4.1": + tc.variables["GTSAM_SLOW_BUT_CORRECT_BETWEENFACTOR"] = self.options.slow_but_correct_betweenfactor tc.variables["GTSAM_BUILD_WITH_CCACHE"] = False - tc.variables["GTSAM_BUILD_UNSTABLE"] = self.options.build_unstable - tc.variables["GTSAM_DISABLE_NEW_TIMERS"] = self.options.disable_new_timers + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleAllocators.cmake + if self.options.default_allocator is not None: + tc.variables["GTSAM_DEFAULT_ALLOCATOR"] = self.options.default_allocator + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/GtsamBuildTypes.cmake#L59 tc.variables["GTSAM_BUILD_TYPE_POSTFIXES"] = self.options.build_type_postfixes + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/GtsamBuildTypes.cmake#L193 + tc.variables["GTSAM_BUILD_WITH_MARCH_NATIVE"] = self.options.build_with_march_native + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleBoost.cmake#L36 + tc.variables["GTSAM_DISABLE_NEW_TIMERS"] = self.options.disable_new_timers + # https://github.com/borglab/gtsam/blob/4.2a9/CppUnitLite/CMakeLists.txt#L13 + tc.variables["GTSAM_INSTALL_CPPUNITLITE"] = self.options.install_cppunitlite + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleEigen.cmake#L3 + tc.variables["GTSAM_USE_SYSTEM_EIGEN"] = True + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/HandleMetis.cmake#L11 + tc.variables["GTSAM_USE_SYSTEM_METIS"] = False + # https://github.com/borglab/gtsam/blob/4.2a9/gtsam/3rdparty/CMakeLists.txt#L76 + tc.variables["GTSAM_INSTALL_GEOGRAPHICLIB"] = False + # https://github.com/borglab/gtsam/blob/4.2a9/matlab/CMakeLists.txt#L14-L15 + tc.variables["GTSAM_MEX_BUILD_STATIC_MODULE"] = False + # https://github.com/borglab/gtsam/blob/4.2a9/cmake/GtsamTesting.cmake#L89-L91 tc.variables["GTSAM_BUILD_TESTS"] = False - tc.variables["Boost_USE_STATIC_LIBS"] = not self.dependencies["boost"].options.shared - tc.variables["Boost_NO_SYSTEM_PATHS"] = True + tc.variables["GTSAM_BUILD_EXAMPLES_ALWAYS"] = False + tc.variables["GTSAM_BUILD_TIMING_ALWAYS"] = False + # https://github.com/borglab/gtsam/blob/4.2a9/doc/CMakeLists.txt tc.variables["GTSAM_BUILD_DOCS"] = False tc.variables["GTSAM_BUILD_DOC_HTML"] = False - tc.variables["GTSAM_BUILD_EXAMPLES_ALWAYS"] = False - tc.variables["GTSAM_BUILD_WRAP"] = self.options.build_wrap - tc.variables["GTSAM_BUILD_WITH_MARCH_NATIVE"] = False - tc.variables["GTSAM_WRAP_SERIALIZATION"] = self.options.wrap_serialization - tc.variables["GTSAM_INSTALL_MATLAB_TOOLBOX"] = self.options.install_matlab_toolbox - tc.variables["GTSAM_INSTALL_CYTHON_TOOLBOX"] = self.options.install_cython_toolbox - tc.variables["GTSAM_INSTALL_CPPUNITLITE"] = self.options.install_cppunitlite - tc.variables["GTSAM_INSTALL_GEOGRAPHICLIB"] = False - tc.variables["GTSAM_USE_SYSTEM_EIGEN"] = True - tc.variables["GTSAM_BUILD_TYPE_POSTFIXES"] = False + tc.variables["GTSAM_BUILD_DOC_LATEX"] = False + + # Removed in 4.1+ + if Version(self.version) < "4.1": + # https://github.com/borglab/gtsam/blob/4.0.3/CMakeLists.txt + tc.variables["GTSAM_BUILD_WRAP"] = self.options.build_wrap + tc.variables["GTSAM_INSTALL_CYTHON_TOOLBOX"] = self.options.install_cython_toolbox + tc.variables["GTSAM_TYPEDEF_POINTS_TO_VECTORS"] = self.options.typedef_points_to_vectors + # https://github.com/borglab/gtsam/blob/4.0.3/wrap/CMakeLists.txt#L15 + tc.variables["GTSAM_WRAP_SERIALIZATION"] = self.options.wrap_serialization + + tc.variables["Boost_USE_STATIC_LIBS"] = not self.dependencies["boost"].options.shared + tc.variables["Boost_NO_SYSTEM_PATHS"] = True tc.generate() + deps = CMakeDeps(self) deps.generate() def _patch_sources(self): apply_conandata_patches(self) + # Honor vc runtime if is_msvc(self): gtsam_build_types_cmake = os.path.join(self.source_folder, "cmake", "GtsamBuildTypes.cmake") replace_in_file(self, gtsam_build_types_cmake, "/MD ", f"/{msvc_runtime_flag(self)} ") replace_in_file(self, gtsam_build_types_cmake, "/MDd ", f"/{msvc_runtime_flag(self)} ") + if self.options.default_allocator == "tcmalloc": + handle_allocators_path = os.path.join(self.source_folder, "cmake", "HandleAllocators.cmake") + if Version(self.version) < "4.1": + handle_allocators_path = os.path.join(self.source_folder, "CMakeLists.txt") + replace_in_file( + self, + handle_allocators_path, + "if(GOOGLE", + "find_package(gperftools REQUIRED)\nset(GOOGLE_PERFTOOLS_FOUND TRUE)\nif(GOOGLE", + ) + replace_in_file( + self, + handle_allocators_path, + 'GTSAM_ADDITIONAL_LIBRARIES "tcmalloc"', + 'GTSAM_ADDITIONAL_LIBRARIES "gperftools::gperftools"', + ) + def build(self): self._patch_sources() cmake = CMake(self) @@ -206,53 +347,60 @@ def _module_file_rel_path(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "GTSAM") - prefix = "lib" if is_msvc(self) and not self.options.shared else "" - - self.cpp_info.components["libgtsam"].set_property("cmake_target_name", "gtsam") - self.cpp_info.components["libgtsam"].libs = [f"{prefix}gtsam"] - self.cpp_info.components["libgtsam"].requires = [f"boost::{component}" for component in self._required_boost_components] - self.cpp_info.components["libgtsam"].requires.append("eigen::eigen") + gtsam = self.cpp_info.components["libgtsam"] + gtsam.set_property("cmake_target_name", "gtsam") + gtsam.libs = ["gtsam"] + gtsam.requires = [f"boost::{component}" for component in self._required_boost_components] + gtsam.requires.append("eigen::eigen") if self.options.with_TBB: - self.cpp_info.components["libgtsam"].requires.append("onetbb::onetbb") + gtsam.requires.append("onetbb::onetbb") + if self.options.default_allocator == "tcmalloc": + gtsam.requires.append("gperftools::gperftools") if self.options.support_nested_dissection: - self.cpp_info.components["libgtsam"].requires.append("libmetis-gtsam") - if self.settings.os == "Windows" and Version(self.version) >= "4.0.3": - self.cpp_info.components["libgtsam"].system_libs = ["dbghelp"] + gtsam.requires.append("libmetis-gtsam") + if self.settings.os == "Windows": + gtsam.system_libs = ["dbghelp"] if self.options.build_unstable: - self.cpp_info.components["libgtsam_unstable"].set_property("cmake_target_name", "gtsam_unstable") - self.cpp_info.components["libgtsam_unstable"].libs = [f"{prefix}gtsam_unstable"] - self.cpp_info.components["libgtsam_unstable"].requires = ["libgtsam"] + gtsam_unstable = self.cpp_info.components["libgtsam_unstable"] + gtsam_unstable.set_property("cmake_target_name", "gtsam_unstable") + gtsam_unstable.libs = ["gtsam_unstable"] + gtsam_unstable.requires = ["libgtsam"] if self.options.support_nested_dissection: - self.cpp_info.components["libmetis-gtsam"].set_property("cmake_target_name", "metis-gtsam") - self.cpp_info.components["libmetis-gtsam"].libs = ["metis-gtsam"] - self.cpp_info.components["libmetis-gtsam"].names["pkg_config"] = "metis-gtsam" + metis = self.cpp_info.components["libmetis-gtsam"] + metis.set_property("cmake_target_name", "metis-gtsam") + if Version(self.version) >= "4.1": + metis.libs = ["metis-gtsam"] + else: + metis.libs = ["metis"] + metis.names["pkg_config"] = "metis-gtsam" if self.options.install_cppunitlite: - self.cpp_info.components["gtsam_CppUnitLite"].set_property("cmake_target_name", "CppUnitLite") - self.cpp_info.components["gtsam_CppUnitLite"].libs = ["CppUnitLite"] - self.cpp_info.components["gtsam_CppUnitLite"].requires = ["boost::boost"] + cppunitlite = self.cpp_info.components["gtsam_CppUnitLite"] + cppunitlite.set_property("cmake_target_name", "CppUnitLite") + cppunitlite.libs = ["CppUnitLite"] + cppunitlite.requires = ["boost::boost"] + + if is_msvc(self) and not self.options.shared: + for component in self.cpp_info.components.values(): + component.libs = [f"lib{lib}" for lib in component.libs if lib.startswith("gtsam")] + if self.options.build_type_postfixes and self.settings.build_type != "Release": + for component in self.cpp_info.components.values(): + component.libs = [f"{lib}{self.settings.build_type}" for lib in component.libs] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.names["cmake_find_package"] = "GTSAM" self.cpp_info.names["cmake_find_package_multi"] = "GTSAM" - self.cpp_info.components["libgtsam"].names["cmake_find_package"] = "gtsam" - self.cpp_info.components["libgtsam"].names["cmake_find_package_multi"] = "gtsam" - self.cpp_info.components["libgtsam"].build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.components["libgtsam"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - if self.options.build_unstable: - self.cpp_info.components["libgtsam_unstable"].names["cmake_find_package"] = "gtsam_unstable" - self.cpp_info.components["libgtsam_unstable"].names["cmake_find_package_multi"] = "gtsam_unstable" - self.cpp_info.components["libgtsam_unstable"].build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.components["libgtsam_unstable"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - if self.options.support_nested_dissection: - self.cpp_info.components["libmetis-gtsam"].names["cmake_find_package"] = "metis-gtsam" - self.cpp_info.components["libmetis-gtsam"].names["cmake_find_package_multi"] = "metis-gtsam" - self.cpp_info.components["libmetis-gtsam"].build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.components["libmetis-gtsam"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - if self.options.install_cppunitlite: - self.cpp_info.components["gtsam_CppUnitLite"].names["cmake_find_package"] = "CppUnitLite" - self.cpp_info.components["gtsam_CppUnitLite"].names["cmake_find_package_multi"] = "CppUnitLite" - self.cpp_info.components["gtsam_CppUnitLite"].build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.components["gtsam_CppUnitLite"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] + for component_name, lib_name in [ + ("libgtsam", "gtsam"), + ("libgtsam_unstable", "gtsam_unstable"), + ("libmetis-gtsam", "metis-gtsam"), + ("gtsam_CppUnitLite", "CppUnitLite"), + ]: + if component_name in self.cpp_info.components: + component = self.cpp_info.components[component_name] + component.names["cmake_find_package"] = lib_name + component.names["cmake_find_package_multi"] = lib_name + component.build_modules["cmake_find_package"] = [self._module_file_rel_path] + component.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] diff --git a/recipes/gtsam/all/patches/4.0.2-0001-cmake-boost.patch b/recipes/gtsam/all/patches/4.0.2-0001-cmake-boost.patch deleted file mode 100644 index d19f34cd533272..00000000000000 --- a/recipes/gtsam/all/patches/4.0.2-0001-cmake-boost.patch +++ /dev/null @@ -1,61 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -163,13 +163,13 @@ - set(BOOST_FIND_MINIMUM_VERSION 1.43) - set(BOOST_FIND_MINIMUM_COMPONENTS serialization system filesystem thread program_options date_time timer chrono regex) - --find_package(Boost ${BOOST_FIND_MINIMUM_VERSION} COMPONENTS ${BOOST_FIND_MINIMUM_COMPONENTS}) -+find_package(Boost ${BOOST_FIND_MINIMUM_VERSION} COMPONENTS ${BOOST_FIND_MINIMUM_COMPONENTS} REQUIRED) - - # Required components --if(NOT Boost_SERIALIZATION_LIBRARY OR NOT Boost_SYSTEM_LIBRARY OR NOT Boost_FILESYSTEM_LIBRARY OR -- NOT Boost_THREAD_LIBRARY OR NOT Boost_DATE_TIME_LIBRARY) -- message(FATAL_ERROR "Missing required Boost components >= v1.43, please install/upgrade Boost or configure your search paths.") --endif() -+#if(NOT Boost_SERIALIZATION_LIBRARY OR NOT Boost_SYSTEM_LIBRARY OR NOT Boost_FILESYSTEM_LIBRARY OR -+# NOT Boost_THREAD_LIBRARY OR NOT Boost_DATE_TIME_LIBRARY) -+# message(FATAL_ERROR "Missing required Boost components >= v1.43, please install/upgrade Boost or configure your search paths.") -+#endif() - - # Allow for not using the timer libraries on boost < 1.48 (GTSAM timing code falls back to old timer library) - option(GTSAM_DISABLE_NEW_TIMERS "Disables using Boost.chrono for timing" OFF) -@@ -179,30 +179,22 @@ - # so we downgraded this to classic filenames-based variables, and manually adding - # the target_include_directories(xxx ${Boost_INCLUDE_DIR}) - set(GTSAM_BOOST_LIBRARIES -- optimized ${Boost_SERIALIZATION_LIBRARY_RELEASE} -- optimized ${Boost_SYSTEM_LIBRARY_RELEASE} -- optimized ${Boost_FILESYSTEM_LIBRARY_RELEASE} -- optimized ${Boost_THREAD_LIBRARY_RELEASE} -- optimized ${Boost_DATE_TIME_LIBRARY_RELEASE} -- optimized ${Boost_REGEX_LIBRARY_RELEASE} -- debug ${Boost_SERIALIZATION_LIBRARY_DEBUG} -- debug ${Boost_SYSTEM_LIBRARY_DEBUG} -- debug ${Boost_FILESYSTEM_LIBRARY_DEBUG} -- debug ${Boost_THREAD_LIBRARY_DEBUG} -- debug ${Boost_DATE_TIME_LIBRARY_DEBUG} -- debug ${Boost_REGEX_LIBRARY_DEBUG} -+ Boost::serialization -+ Boost::system -+ Boost::filesystem -+ Boost::thread -+ Boost::date_time -+ Boost::regex - ) - message(STATUS "GTSAM_BOOST_LIBRARIES: ${GTSAM_BOOST_LIBRARIES}") - if (GTSAM_DISABLE_NEW_TIMERS) - message("WARNING: GTSAM timing instrumentation manually disabled") - list_append_cache(GTSAM_COMPILE_DEFINITIONS_PUBLIC DGTSAM_DISABLE_NEW_TIMERS) - else() -- if(Boost_TIMER_LIBRARY) -+ if(TARGET Boost::timer) - list(APPEND GTSAM_BOOST_LIBRARIES -- optimized ${Boost_TIMER_LIBRARY_RELEASE} -- optimized ${Boost_CHRONO_LIBRARY_RELEASE} -- debug ${Boost_TIMER_LIBRARY_DEBUG} -- debug ${Boost_CHRONO_LIBRARY_DEBUG} -+ Boost::timer -+ Boost::chrono - ) - else() - list(APPEND GTSAM_BOOST_LIBRARIES rt) # When using the header-only boost timer library, need -lrt diff --git a/recipes/gtsam/all/patches/4.0.2-0002-cmake-eigen.patch b/recipes/gtsam/all/patches/4.0.2-0002-cmake-eigen.patch deleted file mode 100644 index 21c808ace60fd9..00000000000000 --- a/recipes/gtsam/all/patches/4.0.2-0002-cmake-eigen.patch +++ /dev/null @@ -1,20 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -292,7 +292,7 @@ if(GTSAM_USE_SYSTEM_EIGEN) - find_package(Eigen3 REQUIRED) - - # Use generic Eigen include paths e.g. -- set(GTSAM_EIGEN_INCLUDE_FOR_INSTALL "${EIGEN3_INCLUDE_DIR}") -+ set(GTSAM_EIGEN_INCLUDE_FOR_INSTALL "${Eigen3_INCLUDE_DIRS}") - - # check if MKL is also enabled - can have one or the other, but not both! - # Note: Eigen >= v3.2.5 includes our patches -@@ -307,7 +307,7 @@ if(GTSAM_USE_SYSTEM_EIGEN) - endif() - - # The actual include directory (for BUILD cmake target interface): -- set(GTSAM_EIGEN_INCLUDE_FOR_BUILD "${EIGEN3_INCLUDE_DIR}") -+ set(GTSAM_EIGEN_INCLUDE_FOR_BUILD "${Eigen3_INCLUDE_DIRS}") - else() - # Use bundled Eigen include path. - # Clear any variables set by FindEigen3 diff --git a/recipes/gtsam/all/patches/4.0.2-0003-macos-rpath.patch b/recipes/gtsam/all/patches/4.0.2-0003-macos-rpath.patch deleted file mode 100644 index 6bc74d30d7ff1a..00000000000000 --- a/recipes/gtsam/all/patches/4.0.2-0003-macos-rpath.patch +++ /dev/null @@ -1,34 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -4,7 +4,6 @@ cmake_minimum_required(VERSION 3.0) - # new feature to Cmake Version > 2.8.12 - # Mac ONLY. Define Relative Path on Mac OS - if(NOT DEFINED CMAKE_MACOSX_RPATH) -- set(CMAKE_MACOSX_RPATH 0) - endif() - - # Set the version number for the library ---- a/gtsam/CMakeLists.txt -+++ b/gtsam/CMakeLists.txt -@@ -177,9 +177,6 @@ if(WIN32) # Add 'lib' prefix to static library to avoid filename collision with - endif() - - if (APPLE AND BUILD_SHARED_LIBS) -- set_target_properties(gtsam PROPERTIES -- INSTALL_NAME_DIR -- "${CMAKE_INSTALL_PREFIX}/lib") - endif() - - install( ---- a/gtsam/3rdparty/metis/libmetis/CMakeLists.txt -+++ b/gtsam/3rdparty/metis/libmetis/CMakeLists.txt -@@ -16,9 +16,6 @@ if(WIN32) - endif() - - if (APPLE) -- set_target_properties(metis PROPERTIES -- INSTALL_NAME_DIR -- "${CMAKE_INSTALL_PREFIX}/lib") - endif() - - install(TARGETS metis EXPORT GTSAM-exports LIBRARY DESTINATION lib ARCHIVE DESTINATION lib RUNTIME DESTINATION bin) diff --git a/recipes/gtsam/all/patches/4.0.2-0003-cmake-project.patch b/recipes/gtsam/all/patches/4.0.3-0004-cmake-project.patch similarity index 100% rename from recipes/gtsam/all/patches/4.0.2-0003-cmake-project.patch rename to recipes/gtsam/all/patches/4.0.3-0004-cmake-project.patch diff --git a/recipes/gtsam/all/patches/4.1.1-0005-eigen3-version.patch b/recipes/gtsam/all/patches/4.1.1-0005-eigen3-version.patch new file mode 100644 index 00000000000000..8bd45c6d8f747b --- /dev/null +++ b/recipes/gtsam/all/patches/4.1.1-0005-eigen3-version.patch @@ -0,0 +1,21 @@ +Otherwise the Eigen version detection will fail due to the Eigen path variable containing a generator expression. +diff --git a/cmake/HandleEigen.cmake b/cmake/HandleEigen.cmake +--- a/cmake/HandleEigen.cmake ++++ b/cmake/HandleEigen.cmake +@@ -46,6 +46,8 @@ + endif() + + # Detect Eigen version: ++set(GTSAM_EIGEN_VERSION "${Eigen3_VERSION_STRING}") ++if (FALSE) + set(EIGEN_VER_H "${GTSAM_EIGEN_INCLUDE_FOR_BUILD}/Eigen/src/Core/util/Macros.h") + if (EXISTS ${EIGEN_VER_H}) + file(READ "${EIGEN_VER_H}" STR_EIGEN_VERSION) +@@ -67,6 +69,7 @@ + else() + message(WARNING "Cannot determine Eigen version, missing file: `${EIGEN_VER_H}`") + endif () ++endif() + + if (MSVC) + if (BUILD_SHARED_LIBS) diff --git a/recipes/gtsam/all/patches/4.2.0-0001-macos-rpath.patch b/recipes/gtsam/all/patches/4.2.0-0001-macos-rpath.patch new file mode 100644 index 00000000000000..2f60f9adaef8a6 --- /dev/null +++ b/recipes/gtsam/all/patches/4.2.0-0001-macos-rpath.patch @@ -0,0 +1,30 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -5,5 +5,4 @@ cmake_minimum_required(VERSION 3.0) + if(NOT DEFINED CMAKE_MACOSX_RPATH) +- set(CMAKE_MACOSX_RPATH 0) + endif() + + # Set the version number for the library +--- a/cmake/HandleGlobalBuildFlags.cmake ++++ b/cmake/HandleGlobalBuildFlags.cmake +@@ -20,7 +20,6 @@ endif() + + if (APPLE AND BUILD_SHARED_LIBS) + # Set the default install directory on macOS +- set(CMAKE_INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib") + endif() + + ############################################################################### +--- a/gtsam/3rdparty/metis/libmetis/CMakeLists.txt ++++ b/gtsam/3rdparty/metis/libmetis/CMakeLists.txt +@@ -17,9 +17,6 @@ if(WIN32) + endif() + + if (APPLE) +- set_target_properties(metis-gtsam PROPERTIES +- INSTALL_NAME_DIR +- "${CMAKE_INSTALL_PREFIX}/lib") + endif() + + install(TARGETS metis-gtsam EXPORT GTSAM-exports diff --git a/recipes/gtsam/all/patches/4.2.0-0002-eigen3-version.patch b/recipes/gtsam/all/patches/4.2.0-0002-eigen3-version.patch new file mode 100644 index 00000000000000..19bc6febd2db05 --- /dev/null +++ b/recipes/gtsam/all/patches/4.2.0-0002-eigen3-version.patch @@ -0,0 +1,20 @@ +diff --git a/cmake/HandleEigen.cmake b/cmake/HandleEigen.cmake +--- a/cmake/HandleEigen.cmake ++++ b/cmake/HandleEigen.cmake +@@ -59,6 +59,8 @@ + endif() + + # Detect Eigen version: ++set(GTSAM_EIGEN_VERSION "${Eigen3_VERSION_STRING}") ++if (FALSE) + set(EIGEN_VER_H "${GTSAM_EIGEN_INCLUDE_FOR_BUILD}/Eigen/src/Core/util/Macros.h") + if (EXISTS ${EIGEN_VER_H}) + file(READ "${EIGEN_VER_H}" STR_EIGEN_VERSION) +@@ -80,6 +82,7 @@ + else() + message(WARNING "Cannot determine Eigen version, missing file: `${EIGEN_VER_H}`") + endif () ++endif() + + if (MSVC) + if (BUILD_SHARED_LIBS) diff --git a/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch b/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch new file mode 100644 index 00000000000000..a0431a45e608d0 --- /dev/null +++ b/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch @@ -0,0 +1,12 @@ +diff --git a/gtsam/sfm/DsfTrackGenerator.h b/gtsam/sfm/DsfTrackGenerator.h +--- a/gtsam/sfm/DsfTrackGenerator.h (revision c57988fe554e7213c77fe379c1d7c483de26ad33) ++++ b/gtsam/sfm/DsfTrackGenerator.h (revision 26a37d62103a9b3b828d36e8b1a76f875ed842e3) +@@ -22,7 +22,7 @@ + + #include + #include +-#include ++#include + #include + + namespace gtsam { diff --git a/recipes/gtsam/all/test_v1_package/CMakeLists.txt b/recipes/gtsam/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 0d20897301b68b..00000000000000 --- a/recipes/gtsam/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/gtsam/all/test_v1_package/conanfile.py b/recipes/gtsam/all/test_v1_package/conanfile.py deleted file mode 100644 index 38f4483872d47f..00000000000000 --- a/recipes/gtsam/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,17 +0,0 @@ -from conans import ConanFile, CMake, tools -import os - - -class TestPackageConan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) diff --git a/recipes/gtsam/config.yml b/recipes/gtsam/config.yml index 6f380a83ebb140..9c6d4a9be25c5e 100644 --- a/recipes/gtsam/config.yml +++ b/recipes/gtsam/config.yml @@ -1,7 +1,7 @@ versions: + "4.2.0a9": + folder: all "4.1.1": folder: all "4.0.3": folder: all - "4.0.2": - folder: all From a31e544dd650d5fee78ab3f8fe736a42b0ecf787 Mon Sep 17 00:00:00 2001 From: nextsilicon-itay-bookstein <55076759+nextsilicon-itay-bookstein@users.noreply.github.com> Date: Sun, 6 Aug 2023 09:45:37 +0300 Subject: [PATCH 0099/1140] (#18676) mpfr: Add 4.2.0 Signed-off-by: Itay Bookstein Co-authored-by: Daniel --- recipes/mpfr/all/conandata.yml | 7 +++++ .../4.2.0-0001-configure.ac-fixes.patch | 10 +++++++ .../4.2.0-0002-windows-header-dll.patch | 27 +++++++++++++++++++ recipes/mpfr/config.yml | 2 ++ 4 files changed, 46 insertions(+) create mode 100644 recipes/mpfr/all/patches/4.2.0-0001-configure.ac-fixes.patch create mode 100644 recipes/mpfr/all/patches/4.2.0-0002-windows-header-dll.patch diff --git a/recipes/mpfr/all/conandata.yml b/recipes/mpfr/all/conandata.yml index dd4e8f905e5f9a..53fa206c24da17 100644 --- a/recipes/mpfr/all/conandata.yml +++ b/recipes/mpfr/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.2.0": + sha256: f1cc1c6bb14d18f0c61cc416e083f5e697b6e0e3cf9630b9b33e8e483fc960f0 + url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.2.0.tar.gz "4.1.0": sha256: 3127fe813218f3a1f0adf4e8899de23df33b4cf4b4b3831a5314f78e65ffa2d6 url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.1.0.tar.gz @@ -6,6 +9,10 @@ sources: sha256: ae26cace63a498f07047a784cd3b0e4d010b44d2b193bab82af693de57a19a78 url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.0.2.tar.gz patches: + "4.2.0": + - patch_file: "patches/4.2.0-0002-windows-header-dll.patch" + patch_description: "Windows header DLL" + patch_type: "portability" "4.1.0": - patch_file: "patches/4.1.0-0002-windows-header-dll.patch" patch_description: "Windows header DLL" diff --git a/recipes/mpfr/all/patches/4.2.0-0001-configure.ac-fixes.patch b/recipes/mpfr/all/patches/4.2.0-0001-configure.ac-fixes.patch new file mode 100644 index 00000000000000..59480e9bde74c1 --- /dev/null +++ b/recipes/mpfr/all/patches/4.2.0-0001-configure.ac-fixes.patch @@ -0,0 +1,10 @@ +--- configure.ac ++++ configure.ac +@@ -44,6 +44,7 @@ + dnl as it could cause confusion. But let's keep AC_CANONICAL_HOST here, + dnl since this may be a better place than later. + AC_CANONICAL_HOST ++AC_CANONICAL_TARGET + + dnl Older Automake versions than 1.13 may still be supported, but no longer + dnl tested, and many things have changed in 1.13. Moreover the INSTALL file diff --git a/recipes/mpfr/all/patches/4.2.0-0002-windows-header-dll.patch b/recipes/mpfr/all/patches/4.2.0-0002-windows-header-dll.patch new file mode 100644 index 00000000000000..8bd309400c5a6a --- /dev/null +++ b/recipes/mpfr/all/patches/4.2.0-0002-windows-header-dll.patch @@ -0,0 +1,27 @@ +--- src/mpfr.h ++++ src/mpfr.h +@@ -319,16 +319,15 @@ + # endif + #endif + +-/* Support for WINDOWS Dll: +- Check if we are inside a MPFR build, and if so export the functions. +- Otherwise does the same thing as GMP */ +-#if defined(__MPFR_WITHIN_MPFR) && __GMP_LIBGMP_DLL +-# define __MPFR_DECLSPEC __GMP_DECLSPEC_EXPORT +-#else +-# ifndef __GMP_DECLSPEC +-# define __GMP_DECLSPEC ++/* Support for WINDOWS Dll */ ++#if defined(MPFR_DLL) ++# if defined(__MPFR_WITHIN_MPFR) ++# define __MPFR_DECLSPEC __GMP_DECLSPEC_EXPORT ++# else ++# define __MPFR_DECLSPEC __GMP_DECLSPEC_IMPORT + # endif +-# define __MPFR_DECLSPEC __GMP_DECLSPEC ++#else ++# define __MPFR_DECLSPEC + #endif + + /* Use MPFR_DEPRECATED to mark MPFR functions, types or variables as diff --git a/recipes/mpfr/config.yml b/recipes/mpfr/config.yml index 72132855c0cf86..217c84a76cc940 100644 --- a/recipes/mpfr/config.yml +++ b/recipes/mpfr/config.yml @@ -1,4 +1,6 @@ versions: + "4.2.0": + folder: all "4.1.0": folder: all "4.0.2": From 37c9c3a258c4eea9e8a11cd1707a5513e6be76fc Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 6 Aug 2023 10:05:39 +0300 Subject: [PATCH 0100/1140] (#18701) jungle: migrate to Conan v2 * jungle: migrate to Conan v2 * Apply suggestions from code review * jungle: restore VirtualRunEnv in test_package --------- Co-authored-by: Carlos Zoido --- recipes/jungle/all/CMakeLists.txt | 7 -- recipes/jungle/all/conandata.yml | 12 ---- recipes/jungle/all/conanfile.py | 72 ++++++++++--------- .../jungle/all/test_package/CMakeLists.txt | 10 ++- recipes/jungle/all/test_package/conanfile.py | 24 ++++--- .../jungle/all/test_v1_package/CMakeLists.txt | 8 +++ .../jungle/all/test_v1_package/conanfile.py | 18 +++++ 7 files changed, 85 insertions(+), 66 deletions(-) delete mode 100644 recipes/jungle/all/CMakeLists.txt create mode 100644 recipes/jungle/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/jungle/all/test_v1_package/conanfile.py diff --git a/recipes/jungle/all/CMakeLists.txt b/recipes/jungle/all/CMakeLists.txt deleted file mode 100644 index d2b01e47d9d637..00000000000000 --- a/recipes/jungle/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.11) -project(jungle) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory("source_subfolder") diff --git a/recipes/jungle/all/conandata.yml b/recipes/jungle/all/conandata.yml index bd27aef1a8932e..804a4efea38b21 100644 --- a/recipes/jungle/all/conandata.yml +++ b/recipes/jungle/all/conandata.yml @@ -10,31 +10,19 @@ patches: - patch_file: "patches/0001-cmake-alterations.patch" patch_description: "CMake dependency discovery outside subtree." patch_type: "conan" - base_path: "source_subfolder" - sha256: "a7111a290e145717ae0cbdace9866db69c70782731c8568a806f8579e30759eb" - patch_file: "patches/0002-forestdb-path.patch" patch_description: "Update include macros for ForestDB headers." patch_type: "conan" - base_path: "source_subfolder" - sha256: "84ec45a312c52e2fa8cb7ab615aaa11088f24dcb4e4b880340b46c2763900d6b" - patch_file: "patches/0003-stdatomic.patch" patch_description: "Include std::atomic from all compilers." patch_type: "portability" - base_path: "source_subfolder" - sha256: "3ca66676f89e2425255eeb15bf18a77ae21c4f383124013bd6d1cb660cbc1544" "cci.20221201": - patch_file: "patches/0004-cmake-alterations-cci.20221201.patch" patch_description: "CMake dependency discovery outside subtree." patch_type: "conan" - base_path: "source_subfolder" - sha256: "a7111a290e145717ae0cbdace9866db69c70782731c8568a806f8579e30759eb" - patch_file: "patches/0002-forestdb-path.patch" patch_description: "Update include macros for ForestDB headers." patch_type: "conan" - base_path: "source_subfolder" - sha256: "84ec45a312c52e2fa8cb7ab615aaa11088f24dcb4e4b880340b46c2763900d6b" - patch_file: "patches/0003-stdatomic.patch" patch_description: "Include std::atomic from all compilers." patch_type: "portability" - base_path: "source_subfolder" - sha256: "3ca66676f89e2425255eeb15bf18a77ae21c4f383124013bd6d1cb660cbc1544" diff --git a/recipes/jungle/all/conanfile.py b/recipes/jungle/all/conanfile.py index 5350d8f70668d4..dba32eb6f0f01a 100644 --- a/recipes/jungle/all/conanfile.py +++ b/recipes/jungle/all/conanfile.py @@ -1,21 +1,23 @@ -from os.path import join +import os + from conan import ConanFile -from conan.tools.files import apply_conandata_patches, copy, get from conan.tools.build import check_min_cppstd -from conans import CMake +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get + +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.50.0" class JungleConan(ConanFile): name = "jungle" - homepage = "https://github.com/eBay/Jungle" description = "Key-value storage library, based on a combined index of LSM-tree and copy-on-write B+tree" - topics = ("kv-store", "cow") - url = "https://github.com/conan-io/conan-center-index" license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/eBay/Jungle" + topics = ("kv-store", "cow") + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = { "shared": [True, False], "fPIC": [True, False], @@ -25,16 +27,19 @@ class JungleConan(ConanFile): "fPIC": True, } - generators = "cmake", "cmake_find_package" + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC - @property - def _source_subfolder(self): - return "source_subfolder" + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") - def export_sources(self): - self.copy("CMakeLists.txt") - for patch_file in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch_file["patch_file"]) + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): self.requires("forestdb/cci.20220727") @@ -43,12 +48,14 @@ def validate(self): if self.settings.compiler.cppstd: check_min_cppstd(self, 11) - def configure(self): - if self.options.shared: - del self.options.fPIC - def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): apply_conandata_patches(self) @@ -57,18 +64,17 @@ def build(self): cmake.build() def package(self): - src_dir = join(self.source_folder, self._source_subfolder) - copy(self, "LICENSE*", src_dir, join(self.package_folder, "licenses")) - - hdr_src = join(src_dir, "include") - copy(self, "*.h", hdr_src, join(self.package_folder, "include"), keep_path=True) - - lib_dir = join(self.package_folder, "lib") - copy(self, "*.a", self.build_folder, lib_dir, keep_path=False) - copy(self, "*.lib", self.build_folder, lib_dir, keep_path=False) - copy(self, "*.so*", self.build_folder, lib_dir, keep_path=False) - copy(self, "*.dylib*", self.build_folder, lib_dir, keep_path=False) - copy(self, "*.dll*", self.build_folder, join(self.package_folder, "bin"), keep_path=False) + copy(self, "LICENSE*", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*.h", + src=os.path.join(self.source_folder, "include"), + dst=os.path.join(self.package_folder, "include")) + for pattern in ["*.a", "*.lib", "*.so*", "*.dylib*", "*.dll*"]: + copy(self, pattern, + src=self.build_folder, + dst=os.path.join(self.package_folder, "lib"), + keep_path=False) def package_info(self): self.cpp_info.libs = ["jungle"] diff --git a/recipes/jungle/all/test_package/CMakeLists.txt b/recipes/jungle/all/test_package/CMakeLists.txt index 354670d11c755c..fdc2bc33ffe24c 100644 --- a/recipes/jungle/all/test_package/CMakeLists.txt +++ b/recipes/jungle/all/test_package/CMakeLists.txt @@ -1,11 +1,9 @@ -cmake_minimum_required(VERSION 3.11) -set(CMAKE_CXX_STANDARD 11) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +set(CMAKE_CXX_STANDARD 11) -find_package(jungle CONFIG REQUIRED) +find_package(jungle REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} jungle::jungle) diff --git a/recipes/jungle/all/test_package/conanfile.py b/recipes/jungle/all/test_package/conanfile.py index 9ebf26743f34b4..ef5d7042163ecc 100644 --- a/recipes/jungle/all/test_package/conanfile.py +++ b/recipes/jungle/all/test_package/conanfile.py @@ -1,11 +1,19 @@ -from conans import ConanFile -from conan.tools.build import cross_building -from conans import CMake +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/jungle/all/test_v1_package/CMakeLists.txt b/recipes/jungle/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/jungle/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/jungle/all/test_v1_package/conanfile.py b/recipes/jungle/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..9ebf26743f34b4 --- /dev/null +++ b/recipes/jungle/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile +from conan.tools.build import cross_building +from conans import CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From c53c2c0ad52c1d76d6fa94c83c1af2021985190f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 6 Aug 2023 10:25:56 +0300 Subject: [PATCH 0101/1140] (#18741) openfx: migrate to Conan v2 * openfx: migrate to Conan v2 * openfx: add OpenGL dep to CMakeLists.txt * openfx: restore VirtualRunEnv in test_package --------- Co-authored-by: Carlos Zoido --- recipes/openfx/all/CMakeLists.txt | 20 ++-- recipes/openfx/all/conanfile.py | 106 +++++++++++------- .../openfx/all/test_package/CMakeLists.txt | 7 +- recipes/openfx/all/test_package/conanfile.py | 19 +++- .../openfx/all/test_v1_package/CMakeLists.txt | 8 ++ .../openfx/all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 116 insertions(+), 61 deletions(-) create mode 100644 recipes/openfx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/openfx/all/test_v1_package/conanfile.py diff --git a/recipes/openfx/all/CMakeLists.txt b/recipes/openfx/all/CMakeLists.txt index 5232e354a73eef..1a7641b6f3019b 100644 --- a/recipes/openfx/all/CMakeLists.txt +++ b/recipes/openfx/all/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.12) project(openfx VERSION 1.4.0 LANGUAGES CXX) set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) @@ -6,18 +6,18 @@ add_definitions(-D_HAS_AUTO_PTR_ETC) # Flags if(MSVC) - set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DWINDOWS -DNOMINMAX") + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DWINDOWS -DNOMINMAX -D_WIN32") else() set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wno-deprecated -Wno-deprecated-declarations") + add_definitions(-Dlinux) endif() # Conan -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) -find_package(EXPAT REQUIRED) +find_package(expat REQUIRED) +find_package(OpenGL REQUIRED) # Macros -set(SOURCE_SUBFOLDER ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder) +set(SOURCE_SUBFOLDER ${CMAKE_CURRENT_LIST_DIR}/src) # Sources set(OFX_HEADER_DIR "${SOURCE_SUBFOLDER}/include") @@ -50,7 +50,7 @@ add_library(OfxHost ${OFX_HOSTSUPPORT_HEADER_FILES} ${OFX_HOSTSUPPORT_LIBRARY_FILES}) -target_link_libraries(OfxHost PUBLIC EXPAT::EXPAT) +target_link_libraries(OfxHost PUBLIC expat::expat OpenGL::GL) target_include_directories(OfxHost PUBLIC ${OFX_HEADER_DIR} @@ -68,7 +68,5 @@ install(FILES ${OFX_HOSTSUPPORT_HEADER_FILES} DESTINATION "include") -install(TARGETS OfxSupport OfxHost - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib) +include(GNUInstallDirs) +install(TARGETS OfxSupport OfxHost) diff --git a/recipes/openfx/all/conanfile.py b/recipes/openfx/all/conanfile.py index 6f5bee8600958e..935c3113a9393d 100644 --- a/recipes/openfx/all/conanfile.py +++ b/recipes/openfx/all/conanfile.py @@ -1,54 +1,73 @@ -from conans import ConanFile, CMake, tools import os +from conan import ConanFile +from conan.tools.apple import is_apple_os +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir + +required_conan_version = ">=1.53.0" + class openfx(ConanFile): name = "openfx" + description = "OpenFX image processing plug-in standard." license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "http://openeffects.org" - description = "OpenFX image processing plug-in standard." topics = ("image-processing", "standard") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { - "fPIC": [True, False], "shared": [True, False], + "fPIC": [True, False], } default_options = { - "fPIC": True, "shared": False, + "fPIC": True, } - requires = ("opengl/system", "expat/2.4.8") - exports_sources = "CMakeLists.txt", "cmake/*", "symbols/*" - generators = "cmake", "cmake_find_package" - _cmake = None + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) + copy(self, "*", + src=os.path.join(self.recipe_folder, "cmake"), + dst=os.path.join(self.export_sources_folder, "cmake")) + copy(self, "*", + src=os.path.join(self.recipe_folder, "symbols"), + dst=os.path.join(self.export_sources_folder, "symbols")) - def source(self): - tools.get( - **self.conan_data["sources"][self.version], - destination="source_subfolder", - strip_root=True - ) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("opengl/system") + self.requires("expat/2.5.0") - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.source_path.parent) cmake.build() @property @@ -56,26 +75,25 @@ def _build_modules(self): return [os.path.join("lib", "cmake", "OpenFX.cmake")] def package(self): - cmake = self._configure_cmake() - - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - + cmake = CMake(self) cmake.install() - - self.copy("*.symbols", src="symbols", dst="lib/symbols") - self.copy("*.cmake", src="cmake", dst="lib/cmake") - self.copy("LICENSE", src="source_subfolder/Support", dst="licenses") - self.copy("readme.md") + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + copy(self, "*.symbols", + src=os.path.join(self.export_sources_folder, "symbols"), + dst=os.path.join(self.package_folder, "lib", "symbols")) + copy(self, "*.cmake", + src=os.path.join(self.export_sources_folder, "cmake"), + dst=os.path.join(self.package_folder, "lib", "cmake")) + copy(self, "LICENSE", + src=os.path.join(self.source_folder, "Support"), + dst=os.path.join(self.package_folder, "licenses")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "openfx" - self.cpp_info.names["cmake_find_package_multi"] = "openfx" - + self.cpp_info.set_property("cmake_file_name", "openfx") + self.cpp_info.set_property("cmake_target_name", "openfx::openfx") self.cpp_info.set_property("cmake_build_modules", self._build_modules) self.cpp_info.builddirs.append(os.path.join("lib", "cmake")) - self.cpp_info.build_modules["cmake_find_package"] = self._build_modules - self.cpp_info.build_modules["cmake_find_package_multi"] = self._build_modules if self.options.shared: self.cpp_info.libs = ["OfxSupport"] @@ -84,5 +102,11 @@ def package_info(self): if self.settings.os in ("Linux", "FreeBSD"): self.cpp_info.system_libs.extend(["GL"]) - if self.settings.os == "Macos": + if is_apple_os(self): self.cpp_info.frameworks = ["CoreFoundation", "OpenGL"] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "openfx" + self.cpp_info.names["cmake_find_package_multi"] = "openfx" + self.cpp_info.build_modules["cmake_find_package"] = self._build_modules + self.cpp_info.build_modules["cmake_find_package_multi"] = self._build_modules diff --git a/recipes/openfx/all/test_package/CMakeLists.txt b/recipes/openfx/all/test_package/CMakeLists.txt index c80f526f36b854..130ac63e132fe5 100644 --- a/recipes/openfx/all/test_package/CMakeLists.txt +++ b/recipes/openfx/all/test_package/CMakeLists.txt @@ -1,12 +1,11 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) add_definitions(-D_HAS_AUTO_PTR_ETC) # Conan -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) find_package(openfx REQUIRED CONFIG) # Flags diff --git a/recipes/openfx/all/test_package/conanfile.py b/recipes/openfx/all/test_package/conanfile.py index 884a3017a3bd60..93275299d1c47d 100644 --- a/recipes/openfx/all/test_package/conanfile.py +++ b/recipes/openfx/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run("%s --help" % bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(f"{bin_path} --help", env="conanrun") diff --git a/recipes/openfx/all/test_v1_package/CMakeLists.txt b/recipes/openfx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/openfx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/openfx/all/test_v1_package/conanfile.py b/recipes/openfx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..884a3017a3bd60 --- /dev/null +++ b/recipes/openfx/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run("%s --help" % bin_path, run_environment=True) From 5a8849ff935198d6e1a0dcf3dee59a2a10050c2e Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 6 Aug 2023 09:47:40 +0200 Subject: [PATCH 0102/1140] (#18778) qt6: add new components * qt6: add new components TextToSpeech, HttpServer, Protobuf and Grpc * disable failing macos configuration --- recipes/qt/6.x.x/conanfile.py | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/recipes/qt/6.x.x/conanfile.py b/recipes/qt/6.x.x/conanfile.py index eefa33f1dae931..70ddeb3bf605a4 100644 --- a/recipes/qt/6.x.x/conanfile.py +++ b/recipes/qt/6.x.x/conanfile.py @@ -245,6 +245,9 @@ def validate(self): if self.settings.compiler == "clang" and "libstdc++" in str(self.settings.compiler.libcxx): raise ConanInvalidConfiguration("Qt needs recent libstdc++, with charconv. please switch to gcc, or to libc++") + if self.settings.os == "Macos" and self.dependencies["double-conversion"].options.shared: + raise ConanInvalidConfiguration("Test recipe fails because of Macos' SIP. Contributions are welcome.") + if self.options.get_safe("qtwebengine"): if not self.options.shared: raise ConanInvalidConfiguration("Static builds of Qt WebEngine are not supported") @@ -291,6 +294,9 @@ def validate(self): if self.options.with_sqlite3 and not self.dependencies["sqlite3"].options.enable_column_metadata: raise ConanInvalidConfiguration("sqlite3 option enable_column_metadata must be enabled for qt") + if self.options.get_safe("qtspeech") and not self.options.qtdeclarative: + raise ConanInvalidConfiguration("qtspeech requires qtdeclarative, cf QTBUG-108381") + def layout(self): cmake_layout(self, src_folder="src") @@ -1270,6 +1276,19 @@ def _create_plugin(pluginname, libname, plugintype, requires): if self.options.get_safe("qtwebview"): _create_module("WebView", ["Core", "Gui"]) + if self.options.get_safe("qtspeech"): + _create_module("TextToSpeech", []) + + if self.options.get_safe("qthttpserver"): + http_server_deps = ["Core", "Network"] + if self.options.get_safe("qtwebsockets"): + http_server_deps.append("WebSockets") + _create_module("HttpServer", http_server_deps) + + if self.options.get_safe("qtgrpc"): + _create_module("Protobuf", []) + _create_module("Grpc", ["Core", "Protobuf", "Network"]) + if self.settings.os in ["Windows", "iOS"]: if self.settings.os == "Windows": self.cpp_info.components["qtEntryPointImplementation"].set_property("cmake_target_name", "Qt6::EntryPointImplementation") From 96802b34bac5421da024c09a5a21b830c31796d1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 6 Aug 2023 11:27:29 +0300 Subject: [PATCH 0103/1140] (#18799) aws-kvs-pic: migrate to Conan v2 * aws-kvs-pic: migrate to Conan v2 * aws-kvs-pic: improve os detection --------- Co-authored-by: Carlos Zoido --- recipes/aws-kvs-pic/all/CMakeLists.txt | 7 -- recipes/aws-kvs-pic/all/conandata.yml | 3 +- recipes/aws-kvs-pic/all/conanfile.py | 85 ++++++++++--------- .../all/test_package/CMakeLists.txt | 5 +- .../aws-kvs-pic/all/test_package/conanfile.py | 27 ++++-- .../all/test_package/test_package.c | 3 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 19 +++++ 8 files changed, 97 insertions(+), 60 deletions(-) delete mode 100644 recipes/aws-kvs-pic/all/CMakeLists.txt create mode 100644 recipes/aws-kvs-pic/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/aws-kvs-pic/all/test_v1_package/conanfile.py diff --git a/recipes/aws-kvs-pic/all/CMakeLists.txt b/recipes/aws-kvs-pic/all/CMakeLists.txt deleted file mode 100644 index 6abb33ac667b00..00000000000000 --- a/recipes/aws-kvs-pic/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper LANGUAGES C) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/aws-kvs-pic/all/conandata.yml b/recipes/aws-kvs-pic/all/conandata.yml index 3e715c54770317..9d7d13929fbbc4 100644 --- a/recipes/aws-kvs-pic/all/conandata.yml +++ b/recipes/aws-kvs-pic/all/conandata.yml @@ -4,5 +4,4 @@ sources: sha256: "5a6d8da62af766ec86423ead2a45d9ff00cd80ddea679ce228ff9696a490fae5" patches: "cci.20210812": - - base_path: "source_subfolder" - patch_file: "patches/0001-do-not-enforce-fpic.patch" + - patch_file: "patches/0001-do-not-enforce-fpic.patch" diff --git a/recipes/aws-kvs-pic/all/conanfile.py b/recipes/aws-kvs-pic/all/conanfile.py index 3cdebbedda8639..f9858a924f3048 100644 --- a/recipes/aws-kvs-pic/all/conanfile.py +++ b/recipes/aws-kvs-pic/all/conanfile.py @@ -1,37 +1,34 @@ import os -from conans import ConanFile, tools, CMake -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir + +required_conan_version = ">=1.53.0" + class awskvspicConan(ConanFile): name = "aws-kvs-pic" + description = "Platform Independent Code for Amazon Kinesis Video Streams" license = "Apache-2.0" - homepage = "https://github.com/awslabs/amazon-kinesis-video-streams-pic" url = "https://github.com/conan-io/conan-center-index" - description = ("Platform Independent Code for Amazon Kinesis Video Streams") - settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {'shared': False, "fPIC": True} - generators = "cmake" + homepage = "https://github.com/awslabs/amazon-kinesis-video-streams-pic" topics = ("aws", "kvs", "kinesis", "video", "stream") - exports_sources = ["CMakeLists.txt", "patches/*"] - _cmake = None - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - def _configure_cmake(self): - if not self._cmake: - self._cmake = CMake(self) - self._cmake.definitions["BUILD_DEPENDENCIES"] = False - self._cmake.configure() - return self._cmake - - def validate(self): - if (self.settings.os != "Linux" and self.options.shared): - raise ConanInvalidConfiguration("This library can only be built shared on Linux") + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -39,38 +36,50 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.os not in ["Linux", "FreeBSD"] and self.options.shared: + raise ConanInvalidConfiguration("This library can only be built shared on Linux") def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_DEPENDENCIES"] = False + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.components["kvspic"].libs = ["kvspic"] - self.cpp_info.components["kvspic"].names["pkg_config"] = "libkvspic" + self.cpp_info.components["kvspic"].set_property("pkg_config_name", "libkvspic") if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["kvspic"].system_libs = ["dl", "rt", "pthread"] self.cpp_info.components["kvspicClient"].libs = ["kvspicClient"] - self.cpp_info.components["kvspicClient"].names["pkg_config"] = "libkvspicClient" + self.cpp_info.components["kvspicClient"].set_property("pkg_config_name", "libkvspicClient") self.cpp_info.components["kvspicState"].libs = ["kvspicState"] - self.cpp_info.components["kvspicState"].names["pkg_config"] = "libkvspicState" + self.cpp_info.components["kvspicState"].set_property("pkg_config_name", "libkvspicState") self.cpp_info.components["kvspicUtils"].libs = ["kvspicUtils"] - self.cpp_info.components["kvspicUtils"].names["pkg_config"] = "libkvspicUtils" + self.cpp_info.components["kvspicUtils"].set_property("pkg_config_name", "libkvspicUtils") if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["kvspicUtils"].system_libs = ["dl", "rt", "pthread"] diff --git a/recipes/aws-kvs-pic/all/test_package/CMakeLists.txt b/recipes/aws-kvs-pic/all/test_package/CMakeLists.txt index dbfb3fd9c78618..33561c82ed591a 100644 --- a/recipes/aws-kvs-pic/all/test_package/CMakeLists.txt +++ b/recipes/aws-kvs-pic/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(PkgConfig REQUIRED) pkg_check_modules(LIBKVSPIC REQUIRED IMPORTED_TARGET libkvspic) diff --git a/recipes/aws-kvs-pic/all/test_package/conanfile.py b/recipes/aws-kvs-pic/all/test_package/conanfile.py index 6fdab74d20c228..062f65da30ce60 100644 --- a/recipes/aws-kvs-pic/all/test_package/conanfile.py +++ b/recipes/aws-kvs-pic/all/test_package/conanfile.py @@ -1,12 +1,23 @@ import os -from conans import ConanFile, CMake, tools -class TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "pkg_config" +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "PkgConfigDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) def build_requirements(self): - self.build_requires("pkgconf/1.7.4") + self.tool_requires("pkgconf/1.9.3") + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -14,6 +25,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/aws-kvs-pic/all/test_package/test_package.c b/recipes/aws-kvs-pic/all/test_package/test_package.c index fe898105977799..08c9a0b45013e4 100644 --- a/recipes/aws-kvs-pic/all/test_package/test_package.c +++ b/recipes/aws-kvs-pic/all/test_package/test_package.c @@ -1,6 +1,7 @@ -#include #include "com/amazonaws/kinesis/video/client/Include.h" +#include + int main(int argc, char *argv[]) { diff --git a/recipes/aws-kvs-pic/all/test_v1_package/CMakeLists.txt b/recipes/aws-kvs-pic/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/aws-kvs-pic/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/aws-kvs-pic/all/test_v1_package/conanfile.py b/recipes/aws-kvs-pic/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..c890c831be1237 --- /dev/null +++ b/recipes/aws-kvs-pic/all/test_v1_package/conanfile.py @@ -0,0 +1,19 @@ +import os +from conans import ConanFile, CMake, tools + +class TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "pkg_config" + + def build_requirements(self): + self.build_requires("pkgconf/1.9.3") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 08572f515fc56ccc1d61c09ec6d63032b6f522a9 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Sun, 6 Aug 2023 10:46:29 +0200 Subject: [PATCH 0104/1140] (#18821) add nmea library * init * Update recipes/nmea/all/conanfile.py Co-authored-by: Martin Valgur * Update recipes/nmea/all/conanfile.py --------- Co-authored-by: Martin Valgur Co-authored-by: Carlos Zoido --- recipes/nmea/all/CMakeLists.txt | 67 ++++++++++++++++++++ recipes/nmea/all/conandata.yml | 4 ++ recipes/nmea/all/conanfile.py | 67 ++++++++++++++++++++ recipes/nmea/all/test_package/CMakeLists.txt | 8 +++ recipes/nmea/all/test_package/conanfile.py | 26 ++++++++ recipes/nmea/all/test_package/test_package.c | 9 +++ recipes/nmea/config.yml | 3 + 7 files changed, 184 insertions(+) create mode 100644 recipes/nmea/all/CMakeLists.txt create mode 100644 recipes/nmea/all/conandata.yml create mode 100644 recipes/nmea/all/conanfile.py create mode 100644 recipes/nmea/all/test_package/CMakeLists.txt create mode 100644 recipes/nmea/all/test_package/conanfile.py create mode 100644 recipes/nmea/all/test_package/test_package.c create mode 100644 recipes/nmea/config.yml diff --git a/recipes/nmea/all/CMakeLists.txt b/recipes/nmea/all/CMakeLists.txt new file mode 100644 index 00000000000000..75b13231e08aef --- /dev/null +++ b/recipes/nmea/all/CMakeLists.txt @@ -0,0 +1,67 @@ +cmake_minimum_required(VERSION 3.15) + +project(nmea LANGUAGES C) + +set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) + +add_library(${PROJECT_NAME}) + +set(NMEA_INCLUDE_DIR ${NMEA_ROOT_DIR}/include) +set(NMEA_SRC_DIR ${NMEA_ROOT_DIR}/src) + +target_sources( + ${PROJECT_NAME} + PRIVATE + ${NMEA_SRC_DIR}/context.c + ${NMEA_SRC_DIR}/generate.c + ${NMEA_SRC_DIR}/generator.c + ${NMEA_SRC_DIR}/gmath.c + ${NMEA_SRC_DIR}/info.c + ${NMEA_SRC_DIR}/parse.c + ${NMEA_SRC_DIR}/parser.c + ${NMEA_SRC_DIR}/sentence.c + ${NMEA_SRC_DIR}/time.c + ${NMEA_SRC_DIR}/tok.c +) + +target_include_directories( + ${PROJECT_NAME} + PUBLIC + ${NMEA_INCLUDE_DIR} +) + +set( + NMEA_HEADERS + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/config.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/context.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/generate.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/generator.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/gmath.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/info.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/nmea.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/parse.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/parser.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/sentence.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/time.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/tok.h + ${NMEA_INCLUDE_DIR}/${PROJECT_NAME}/units.h +) + +set_target_properties( + ${PROJECT_NAME} + PROPERTIES + PUBLIC_HEADER "${NMEA_HEADERS}" + C_EXTENSIONS OFF +) + +find_library(LIBM m) +target_link_libraries(${PROJECT_NAME} PRIVATE $<$:${LIBM}>) + +include(GNUInstallDirs) +install( + TARGETS ${PROJECT_NAME} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME} +) diff --git a/recipes/nmea/all/conandata.yml b/recipes/nmea/all/conandata.yml new file mode 100644 index 00000000000000..11255f314caf53 --- /dev/null +++ b/recipes/nmea/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.5.3": + url: "http://downloads.sourceforge.net/nmea/nmealib-0.5.3.zip" + sha256: "41e9fbb8fd5cb1836ff727355b3debe98662b39beb7493af9b78bc4bd4a2ad7d" diff --git a/recipes/nmea/all/conanfile.py b/recipes/nmea/all/conanfile.py new file mode 100644 index 00000000000000..17706f598b4563 --- /dev/null +++ b/recipes/nmea/all/conanfile.py @@ -0,0 +1,67 @@ +from conan import ConanFile +from conan.tools.files import get, copy +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +import os + + +required_conan_version = ">=1.53.0" + + +class NmeaConan(ConanFile): + name = "nmea" + description = "Library to work with NMEA protocol" + license = "LGPL-2.1-only" + url = "https://github.com/conan-io/conan-center-index" + homepage = "http://nmea.sourceforge.net/" + topics = ("nmea", "geospatial", "gnss", "gps", "navigation") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def export_sources(self): + copy(self, "CMakeLists.txt", self.recipe_folder, self.export_sources_folder) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["NMEA_ROOT_DIR"] = self.source_folder.replace("\\", "/") + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) + cmake.build() + + def package(self): + copy(self, pattern="LICENSE.TXT", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs.append(self.name) + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") diff --git a/recipes/nmea/all/test_package/CMakeLists.txt b/recipes/nmea/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..0fc5503253f05c --- /dev/null +++ b/recipes/nmea/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) + +project(test_package C) + +find_package(nmea REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE nmea::nmea) diff --git a/recipes/nmea/all/test_package/conanfile.py b/recipes/nmea/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/nmea/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/nmea/all/test_package/test_package.c b/recipes/nmea/all/test_package/test_package.c new file mode 100644 index 00000000000000..2c83a9e9a35fb8 --- /dev/null +++ b/recipes/nmea/all/test_package/test_package.c @@ -0,0 +1,9 @@ +#include + +#include + +int main() +{ + printf("%f", nmea_degree2radian(180.0)); + return 0; +} diff --git a/recipes/nmea/config.yml b/recipes/nmea/config.yml new file mode 100644 index 00000000000000..2a0554e18df806 --- /dev/null +++ b/recipes/nmea/config.yml @@ -0,0 +1,3 @@ +versions: + "0.5.3": + folder: all From f16a2f87e34da77c0ce7ed78147dbc8f0c1be5e6 Mon Sep 17 00:00:00 2001 From: David Ledger <68693576+seppeon@users.noreply.github.com> Date: Sun, 6 Aug 2023 20:44:50 +1000 Subject: [PATCH 0105/1140] (#18284) BugFix: Update assimp's Draco version from 1.5.5 to 1.5.6 to resolve build error --- recipes/assimp/5.x/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/assimp/5.x/conanfile.py b/recipes/assimp/5.x/conanfile.py index 6f021e008adb44..e821ffefdeea3e 100644 --- a/recipes/assimp/5.x/conanfile.py +++ b/recipes/assimp/5.x/conanfile.py @@ -181,7 +181,7 @@ def requirements(self): if self._depends_on_zlib: self.requires("zlib/1.2.13") if self._depends_on_draco: - self.requires("draco/1.5.5") + self.requires("draco/1.5.6") if self._depends_on_clipper: self.requires("clipper/4.10.0") # Only 4.x supported if self._depends_on_stb: From b794cf5d83e5e59028e515a36f60c17399f20bb1 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 6 Aug 2023 23:28:40 +0900 Subject: [PATCH 0106/1140] (#19068) zpp_bits: add version 4.4.18 --- recipes/zpp_bits/all/conandata.yml | 3 +++ recipes/zpp_bits/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/zpp_bits/all/conandata.yml b/recipes/zpp_bits/all/conandata.yml index 5c61aeec321eeb..aa294b864983dd 100644 --- a/recipes/zpp_bits/all/conandata.yml +++ b/recipes/zpp_bits/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.4.18": + url: "https://github.com/eyalz800/zpp_bits/archive/v4.4.18.tar.gz" + sha256: "c81a221a3d857218d990aa39f420f4cb5cdbe906672d22286b871355068bc14b" "4.4.17": url: "https://github.com/eyalz800/zpp_bits/archive/v4.4.17.tar.gz" sha256: "e6aacf3fbea7ee16a9b55a8622665d37b157efad321750876aa5c15ed8ac65e6" diff --git a/recipes/zpp_bits/config.yml b/recipes/zpp_bits/config.yml index f68457e0898523..e6e42fa0160a36 100644 --- a/recipes/zpp_bits/config.yml +++ b/recipes/zpp_bits/config.yml @@ -1,4 +1,6 @@ versions: + "4.4.18": + folder: all "4.4.17": folder: all "4.4.13": From c0f58a3008333da64df130057c671244a9006a86 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 7 Aug 2023 02:30:34 +0900 Subject: [PATCH 0107/1140] (#19072) libuvc: update libjpeg-turbo/3.0.0 --- recipes/libuvc/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libuvc/all/conanfile.py b/recipes/libuvc/all/conanfile.py index c10470d935e60c..798d7b5db60638 100644 --- a/recipes/libuvc/all/conanfile.py +++ b/recipes/libuvc/all/conanfile.py @@ -60,7 +60,7 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") From c8f78a23637eea6b174995ea601a645875f6c9cc Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 6 Aug 2023 20:48:26 +0200 Subject: [PATCH 0108/1140] (#18932) nss 3.92 --- recipes/nss/all/conandata.yml | 3 +++ recipes/nss/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/nss/all/conandata.yml b/recipes/nss/all/conandata.yml index 254439032f6472..a7c913155a8245 100644 --- a/recipes/nss/all/conandata.yml +++ b/recipes/nss/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.92": + url: "https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_92_RTM/src/nss-3.92.tar.gz" + sha256: "3db192d6e882039af02ae7eaf3217ed114bb7ad83414c646772ab8021e24a254" "3.91": url: "https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_91_RTM/src/nss-3.91.tar.gz" sha256: "84bd46376df17118c55f6d73d30fd93a0af21296c66e7690471547e5898fc4b3" diff --git a/recipes/nss/config.yml b/recipes/nss/config.yml index 741d3aab48e70f..467e717cc1ff4a 100644 --- a/recipes/nss/config.yml +++ b/recipes/nss/config.yml @@ -1,4 +1,6 @@ versions: + "3.92": + folder: all "3.91": folder: all "3.89": From f72a5ba2241a809f4e68e365242a0078778c3594 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 7 Aug 2023 10:30:26 +0900 Subject: [PATCH 0109/1140] (#19079) libtiff: update libjpeg-turbo --- recipes/libtiff/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libtiff/all/conanfile.py b/recipes/libtiff/all/conanfile.py index 6305fc3fa4a6f1..9d1f6de079291e 100644 --- a/recipes/libtiff/all/conanfile.py +++ b/recipes/libtiff/all/conanfile.py @@ -71,7 +71,7 @@ def requirements(self): if self.options.jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") if self.options.jbig: From 81bccad50b0b5be644ae8d4daac1a96b51bd8436 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 7 Aug 2023 11:47:43 +0900 Subject: [PATCH 0110/1140] (#18909) wt: add version 4.10.0 --- recipes/wt/all/conandata.yml | 7 +++++++ recipes/wt/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/wt/all/conandata.yml b/recipes/wt/all/conandata.yml index c26a610e865f77..2b98a42d759a59 100644 --- a/recipes/wt/all/conandata.yml +++ b/recipes/wt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.10.0": + url: "https://github.com/emweb/wt/archive/4.10.0.tar.gz" + sha256: "7090023d4fc4b6594bf4cb11072d9d3d775269327aece9a8993c7bbe46decb9d" "4.9.1": url: "https://github.com/emweb/wt/archive/4.9.1.tar.gz" sha256: "253c61779623ed125bdd604a7b7fe48e64bd991548d17180f040bfa88ccafd98" @@ -15,6 +18,10 @@ sources: url: "https://github.com/emweb/wt/archive/4.6.0.tar.gz" sha256: "7f709e132d32c4925e6db0a590c7ccc5613344e8b9052676ef891a25ccb550e6" patches: + "4.10.0": + - patch_file: "patches/4.8.0-0001-use-cci-package.patch" + patch_description: "use cci package" + patch_type: "conan" "4.9.1": - patch_file: "patches/4.8.0-0001-use-cci-package.patch" patch_description: "use cci package" diff --git a/recipes/wt/config.yml b/recipes/wt/config.yml index d129fd323175f9..6ef848d4e13366 100644 --- a/recipes/wt/config.yml +++ b/recipes/wt/config.yml @@ -1,4 +1,6 @@ versions: + "4.10.0": + folder: all "4.9.1": folder: all "4.8.0": From 8305ea0ec1be297f700d10531682332339e8d14e Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 7 Aug 2023 12:48:59 +0900 Subject: [PATCH 0111/1140] (#19080) jasper: update libjpeg-turbo --- recipes/jasper/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/jasper/all/conanfile.py b/recipes/jasper/all/conanfile.py index 6bc3bfb690d58a..9a1c9b8badf364 100644 --- a/recipes/jasper/all/conanfile.py +++ b/recipes/jasper/all/conanfile.py @@ -49,7 +49,7 @@ def requirements(self): if self.options.with_libjpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_libjpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_libjpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") From cc3da478dac3bccbb41bb59e95e3b34bfef29f8e Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 7 Aug 2023 11:43:35 +0200 Subject: [PATCH 0112/1140] (#19078) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 188 +++++++++++++++++++++++++++++ 1 file changed, 188 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 1a5d515961ed7d..d74f708376b9e5 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -50,6 +50,7 @@ required_for_references: - autoconf - autoconf-archive - automake +- avahi - avir - aws-c-auth - aws-c-cal @@ -61,6 +62,7 @@ required_for_references: - aws-c-mqtt - aws-c-sdkutils - aws-checksums +- aws-kvs-pic - aws-libfabric - b2 - b64 @@ -75,6 +77,7 @@ required_for_references: - benchmark - bertrand - bigint +- bimg - binutils - bison - bit-lite @@ -99,6 +102,7 @@ required_for_references: - bullet3 - butteraugli - bvdberg-ctest +- bx - byte-lite - bzip2 - bzip3 @@ -161,6 +165,7 @@ required_for_references: - console_bridge - continuable - cpp-httplib +- cpp-ipc - cpp-jwt - cpp-lazy - cpp-optparse @@ -180,6 +185,7 @@ required_for_references: - cpputest - cppzmq - cpr +- cprocessing - cpu_features - cpuinfo - cqrlib @@ -307,6 +313,7 @@ required_for_references: - fruit - ftxui - function2 +- functionalplus - fxdiv - g3log - gainput @@ -346,12 +353,14 @@ required_for_references: - gmp - gnu-config - gnutls +- godot_headers - googleapis - gperf - gperftools - graphene - graphthewy - greatest +- greg7mdp-gtl - grpc - grpc-proto - gsl @@ -361,13 +370,22 @@ required_for_references: - gtest - gtk - gtk-doc-stub +- gtsam +- gumbo-parser - gurkenlaeufer +- gzip-hpp - h3 - h5pp +- half - happly - harfbuzz +- hash-library +- hazelcast-cpp-client - hdf5 - hdrhistogram-c +- heatshrink +- hedley +- hffix - hidapi - highfive - highs @@ -375,8 +393,10 @@ required_for_references: - hipony-enumerate - hippomocks - hiredis +- hlslpp - homog2d - http_parser +- hwloc - icecream-cpp - icu - id3v2lib @@ -386,6 +406,7 @@ required_for_references: - imath - imgui - imguizmo +- implot - incbin - indicators - indirect_value @@ -393,9 +414,13 @@ required_for_references: - inih - inja - intel-neon2sse +- intx - inversify-cpp - iqa +- irrxml +- iso8601lib - itlib +- ittapi - jasper - jbig - jinja2cpp @@ -407,44 +432,64 @@ required_for_references: - jsoncons - jsoncpp - jsonnet +- jthread-lite +- jungle +- jwasm - jwt-cpp - jxrlib - kainjow-mustache +- kaitai_struct_cpp_stl_runtime - kangaru - keychain - khrplatform +- kickcat +- kissfft - kmod - ktx - kuba-zip +- laszip - lcms - ldns - lefticus-tools +- lely-core - lemon - leptonica - lerc - lest +- leveldb - lexbor +- libaio - libalsa +- libaom-av1 - libarchive - libassert - libatomic_ops - libattr +- libavif - libbacktrace - libbigwig - libbsd - libcap - libcbor +- libccd - libcds +- libconfig - libconfuse - libcoro +- libcorrect - libcuckoo - libcurl +- libdaemon +- libdc1394 - libde265 - libdeflate - libdisasm - libdivide +- libdmtx - libdrawille - libdwarf +- libdxfrw +- libe57format - libelf - libepoxy - libev @@ -455,13 +500,17 @@ required_for_references: - libfreenect - libfuse - libgcrypt +- libgd - libgeotiff - libgettext - libgpg-error - libgphoto2 - libgpiod - libgta +- libhal - libharu +- libheif +- libhydrogen - libiberty - libiconv - libinterpolate @@ -473,9 +522,12 @@ required_for_references: - libltc - liblzf - libmad +- libmaxminddb - libmbus - libmediainfo - libmemcached +- libmetalink +- libmicrohttpd - libmikmod - libmnl - libmodbus @@ -485,9 +537,12 @@ required_for_references: - libmp3lame - libmysqlclient - libnabo +- libnet +- libnfnetlink - libnfs - libnghttp2 - libnl +- libnoise - libnop - libnova - libnuma @@ -505,18 +560,23 @@ required_for_references: - libressl - librttopo - libsamplerate +- libschrift - libsecret - libselinux - libserial - libsgp4 +- libsigcpp - libslz - libsmacker - libsndfile - libsodium - libspatialindex +- libspatialite - libspng +- libsquish - libsrtp - libssh2 +- libsvm - libsvtav1 - libsystemd - libtar @@ -525,12 +585,15 @@ required_for_references: - libtins - libtool - libtorrent +- libucl - libudev +- libunistring - libunwind - libusb - libuuid - libuv - libuvc +- libvault - libverto - libvips - libvpx @@ -540,30 +603,45 @@ required_for_references: - libx264 - libx265 - libxls +- libxlsxwriter - libxml2 - libxslt +- libyaml - libyuv - libzen - libzip - libzippp - lief +- linmath.h - linux-headers-generic - linux-syscall-support +- litehtml - llhttp +- lmdb - lodepng +- log.c +- log4cplus - logr - loguru +- ls-qpack - lua +- luajit - luau - lunasvg - luple +- lurlparser +- lyra - lz4 +- lzfse +- lzham - lzma_sdk - lzo - m4 - magic_enum - mailio - make +- mapbox-geometry +- mapbox-variant - mariadb-connector-c - marisa - matchit @@ -574,46 +652,68 @@ required_for_references: - mawk - mbedtls - mbits-args +- mbits-diags +- mbits-lngs - mbits-mstch - mbits-semver - mbits-utfconv +- mcap - md4c - md4qt - mdnsresponder - mdspan +- meshoptimizer - meson +- metall - metis - mgs - microservice-essentials +- microtar - mikelankamp-fpm +- mikktspace - mimalloc - mingw-builds - miniaudio - minimp3 - minisat +- miniscript +- minitrace +- miniupnpc - miniz - minizip - minizip-ng +- mio +- modern-cpp-kafka +- moltenvk - mongo-c-driver - mongo-cxx-driver +- morton-nd - mozilla-build - mozjpeg - mp-units +- mpark-variant +- mpc - mpg123 +- mpmcqueue - mppp - ms-gsl - msdf-atlas-gen - msgpack-c - msgpack-cxx - msys2 +- mujs +- muparser +- muparserx - naive-tsearch - namedtype - nameof +- nanobench - nanodbc - nanoflann - nanomsg - nanorange - nanort +- nanosvg - nas - nasm - netcdf @@ -621,22 +721,33 @@ required_for_references: - nextsilicon-cpp-subprocess - ninja - nlohmann_json +- nlopt +- nmea - nng - nodejs - norm - nsync +- ntv2 - nudb +- nuklear - numcpp - nuraft - nv-codec-headers +- nvtx +- oatpp +- objectbox +- observer-ptr-lite - octomap - odbc +- ode - ogdf - ogg - ois - onetbb +- oniguruma - onnx - onnxruntime +- open-dis-cpp - openal - openal-soft - openapi-generator @@ -646,27 +757,36 @@ required_for_references: - opencl-icd-loader - opencolorio - opencore-amr +- openddl-parser - openexr +- openfbx +- openfx - opengl +- opengl-registry - opengv - openh264 - openjdk - openjpeg - openmesh +- openmvg - openssl - opensubdiv - opentelemetry-cpp - opentelemetry-proto +- openxlsx - optional-lite - opus - opusfile - orcania - osqp - out_ptr +- outcome - p-ranav-glob - paho-mqtt-c - paho-mqtt-cpp +- parallel-hashmap - parg +- parson - patchelf - pbtools - pcapplusplus @@ -674,16 +794,38 @@ required_for_references: - pcre - pcre2 - pdfgen +- pdqsort +- perf +- perfetto +- perlinnoise +- pffft - pfr +- pgm-index +- physfs - physx - picobench - picojson +- picosha2 - pixman - pkgconf - platform.delegates - platform.hashing +- platform.interfaces +- plf_colony +- plf_indiesort +- plf_list +- plf_nanotimer +- plf_queue +- plf_stack +- plog - plutovg +- pngpp - poco +- poly2tri +- polylabel +- polylineencoder +- polymorphic_value +- poppler-data - popt - portable-file-dialogs - pprint @@ -694,7 +836,11 @@ required_for_references: - proposal - protobuf - protobuf-c +- protopuf +- protozero - psimd +- psyinf-gmtl +- ptex - pthreadpool - pthreads4w - pugixml @@ -702,11 +848,15 @@ required_for_references: - pybind11 - pybind11_json - pystring +- qcbor - qhull - qpdf +- qpoases +- qr-code-generator - qt - quantlib - quaternions +- quickjs - quill - quirc - r8brain-free-src @@ -722,11 +872,16 @@ required_for_references: - rapidyaml - raylib - re2 +- reactiveplusplus +- read-excel - readerwriterqueue - readline - readosm +- recastnavigation +- reckless - rectpack2d - redis-plus-plus +- refl-cpp - replxx - restbed - restinio @@ -735,23 +890,32 @@ required_for_references: - rmm - roaring - robin-hood-hashing +- rply - rtm +- rtmidi - rttr - ruy +- rxcpp - s2n +- safeint +- sail - samurai - sbepp - sbp - scip - scnlib - scons +- scope-lite - screen_capture_lite - sdbus-cpp +- sdf - sdl - sdl_image - sdl_ttf - seadex-essentials +- seasocks - semimap +- semver.c - sentry-breakpad - sentry-crashpad - sentry-native @@ -759,21 +923,27 @@ required_for_references: - serd - serdepp - sfml +- shapelib - shield - sigslot - simde - simdjson - simdutf - simple-websocket-server +- simple-yaml - sjson-cpp - skyr-url - sml - snappy - snowhouse - soci +- sofa +- sokol +- sol2 - sonic-cpp - sophus - soplex +- soundtouch - source_location - soxr - span-lite @@ -781,27 +951,42 @@ required_for_references: - spirv-cross - spirv-headers - spirv-tools +- spscqueue +- spy - sqlite3 - sqlite_orm - sqlitecpp - sqlpp11 +- squirrel - ssht - st_tree +- statslib - status-code +- status-value-lite - stb +- stc +- stduuid - stlab - strawberryperl - string-view-lite - stringtoolbox - strong_type - structopt +- sundials +- svector +- svgpp - svgwrite - symengine - szip - tabulate +- taglib - taocpp-json +- taocpp-operators - taocpp-pegtl +- taocpp-sequences +- taocpp-tuple - taskflow +- taywee-args - tcb-span - tcl - tclap @@ -809,6 +994,8 @@ required_for_references: - tensorpipe - termcap - termcolor +- tesseract +- tgc - thelink2012-any - threadpool - thrift @@ -842,6 +1029,7 @@ required_for_references: - univalue - unordered_dense - unqlite +- upx - uriparser - usockets - utf8proc From eece843f51176004ce5e51f91f0df3d0e603d40b Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Mon, 7 Aug 2023 17:41:44 +0400 Subject: [PATCH 0113/1140] (#19024) onetbb: use AnyNewerVersion cmake version policy --- recipes/onetbb/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index 57b1bd6404c1ee..09962736783658 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -109,6 +109,7 @@ def package(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "TBB") self.cpp_info.set_property("pkg_config_name", "tbb") + self.cpp_info.set_property("cmake_config_version_compat", "AnyNewerVersion") def lib_name(name): if self.settings.build_type == "Debug": From 301d8d811f27906cd902465b152a615cff598f18 Mon Sep 17 00:00:00 2001 From: Gregor Jasny Date: Mon, 7 Aug 2023 18:50:11 +0200 Subject: [PATCH 0114/1140] (#19086) function2: add version 4.2.3 --- recipes/function2/all/conandata.yml | 3 +++ recipes/function2/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/function2/all/conandata.yml b/recipes/function2/all/conandata.yml index 4a8c1d45eb5f55..ef31d20ffc3552 100644 --- a/recipes/function2/all/conandata.yml +++ b/recipes/function2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.2.3": + url: "https://github.com/Naios/function2/archive/refs/tags/4.2.3.tar.gz" + sha256: "097333b05e596280d3bc7a4769f1262931716cd8cc31ca7337b7af714085f3fc" "4.2.2": url: "https://github.com/Naios/function2/archive/refs/tags/4.2.2.tar.gz" sha256: "f755cb79712dfb9ceefcf7f7ff3225f7c99d22a164dae109044dbfad55d7111e" diff --git a/recipes/function2/config.yml b/recipes/function2/config.yml index 955cd0773fc58e..0be889b562c58c 100644 --- a/recipes/function2/config.yml +++ b/recipes/function2/config.yml @@ -1,4 +1,6 @@ versions: + "4.2.3": + folder: all "4.2.2": folder: all "4.2.1": From 5c1dc0e189988d4fd6dabe93822ffb5233eb370b Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 8 Aug 2023 13:08:06 +0900 Subject: [PATCH 0115/1140] (#19087) mongo-c-driver: add version 1.24.3 --- recipes/mongo-c-driver/all/conandata.yml | 13 +++++++++++++ recipes/mongo-c-driver/config.yml | 2 ++ 2 files changed, 15 insertions(+) diff --git a/recipes/mongo-c-driver/all/conandata.yml b/recipes/mongo-c-driver/all/conandata.yml index eefdc63f632606..5e5abc368ffced 100644 --- a/recipes/mongo-c-driver/all/conandata.yml +++ b/recipes/mongo-c-driver/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.24.3": + url: "https://github.com/mongodb/mongo-c-driver/releases/download/1.24.3/mongo-c-driver-1.24.3.tar.gz" + sha256: "cc0ad1006447ded21bbefecf57d6fef61afe6f0d56a4e28da73805d50fdb81b5" "1.24.1": url: "https://github.com/mongodb/mongo-c-driver/releases/download/1.24.1/mongo-c-driver-1.24.1.tar.gz" sha256: "f9bdf71f24c6621c12535bad07f4654a218d84f16b85a68aca3abf6cd36d1859" @@ -21,6 +24,16 @@ sources: url: "https://github.com/mongodb/mongo-c-driver/releases/download/1.17.6/mongo-c-driver-1.17.6.tar.gz" sha256: "8644deec7ae585e8d12566978f2017181e883f303a028b5b3ccb83c91248b150" patches: + "1.24.3": + - patch_file: "patches/1.24.1-0001-disable-shared-when-static.patch" + patch_description: "separate static and shared builds" + patch_type: "conan" + - patch_file: "patches/1.24.1-0002-fix-uninitialized-warning.patch" + patch_description: "fix uninitialized variable warning" + patch_type: "portability" + - patch_file: "patches/1.22.0-0003-disable-warning-errors.patch" + patch_description: "disable compiler flags to make warnings into errors" + patch_type: "conan" "1.24.1": - patch_file: "patches/1.24.1-0001-disable-shared-when-static.patch" patch_description: "separate static and shared builds" diff --git a/recipes/mongo-c-driver/config.yml b/recipes/mongo-c-driver/config.yml index 20b511f9ecd13c..c20e8c0d078475 100644 --- a/recipes/mongo-c-driver/config.yml +++ b/recipes/mongo-c-driver/config.yml @@ -1,4 +1,6 @@ versions: + "1.24.3": + folder: all "1.24.1": folder: all "1.23.5": From 0cde8936f6b5f8a1021d8bcaaa3759961eea0c52 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 8 Aug 2023 13:49:07 +0900 Subject: [PATCH 0116/1140] (#19088) libyuv: update libjpeg-turbo/3.0.0 --- recipes/libyuv/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libyuv/all/conanfile.py b/recipes/libyuv/all/conanfile.py index 5e5b8c258b2f3f..4fea1b63b21f11 100644 --- a/recipes/libyuv/all/conanfile.py +++ b/recipes/libyuv/all/conanfile.py @@ -46,7 +46,7 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") From 0931599cfa2b9261dac03db36321b53e37d5934e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 8 Aug 2023 11:45:29 +0300 Subject: [PATCH 0117/1140] (#18238) mdns: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * mdns: migrate to Conan v2 * mdns: restore test_v1_package * mdns: add cmake_find_package_multi generator to test_v1_package * mdns: simplify test_package.c Do not open a socket during the test. * mdns: remove old versions, add v1.4.3 * mdns: restore VirtualRunEnv in test_package --------- Co-authored-by: Rubén Rincón Blanco --- recipes/mdns/all/conandata.yml | 27 +++++-------- recipes/mdns/all/conanfile.py | 39 +++++++++++-------- recipes/mdns/all/test_package/CMakeLists.txt | 7 ++-- recipes/mdns/all/test_package/conanfile.py | 23 +++++++---- recipes/mdns/all/test_package/test_package.c | 12 ++++-- .../mdns/all/test_v1_package/CMakeLists.txt | 8 ++++ recipes/mdns/all/test_v1_package/conanfile.py | 17 ++++++++ recipes/mdns/config.yml | 12 ++---- 8 files changed, 87 insertions(+), 58 deletions(-) create mode 100644 recipes/mdns/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/mdns/all/test_v1_package/conanfile.py diff --git a/recipes/mdns/all/conandata.yml b/recipes/mdns/all/conandata.yml index ef0896308dfb2b..67326bafe7dd96 100644 --- a/recipes/mdns/all/conandata.yml +++ b/recipes/mdns/all/conandata.yml @@ -1,22 +1,13 @@ sources: - "1.0": - sha256: e06ed954b4705f0e48f3e6bd44b75c115ee03f745c62394ee615f466e44e9373 - url: https://github.com/mjansson/mdns/archive/1.0.tar.gz - "1.1": - sha256: a0d170bc88151235b9f2dea10a9ffd1d538e4ce3b098426893fd45890efcbffb - url: https://github.com/mjansson/mdns/archive/1.1.tar.gz - "1.2": - sha256: 1919f8fd01b2b7e1128e51d51e4bd9e48fd4f2ef4ade88c152970a35d2084bae - url: https://github.com/mjansson/mdns/archive/1.2.tar.gz - "1.3": - url: "https://github.com/mjansson/mdns/archive/1.3.tar.gz" - sha256: "d3bfd684ef07beadca71c426586be88a10a92026fe6fe5355609d9e805ff5f85" - "1.4": - url: "https://github.com/mjansson/mdns/archive/1.4.tar.gz" - sha256: "413af72a6ce655dc96d35584dd0134f4ba87534ff78471b5b578e175b9f58dd5" - "1.4.1": - url: "https://github.com/mjansson/mdns/archive/1.4.1.tar.gz" - sha256: "decaf007376c62389712dda67c0eaa8ffb682e7be32ece816b1646119f061be3" + "1.4.3": + url: "https://github.com/mjansson/mdns/archive/1.4.3.tar.gz" + sha256: "be1fd8e35599cb7de179decbd0633c121d11a2dcb9cc193ff5c590bd0d480483" "1.4.2": url: "https://github.com/mjansson/mdns/archive/1.4.2.tar.gz" sha256: "c69cfdebe28a489c85f33744f7811c40572a9769a81cd57ecc09ef95802347f2" + "1.3": + url: "https://github.com/mjansson/mdns/archive/1.3.tar.gz" + sha256: "d3bfd684ef07beadca71c426586be88a10a92026fe6fe5355609d9e805ff5f85" + "1.2": + url: "https://github.com/mjansson/mdns/archive/1.2.tar.gz" + sha256: "1919f8fd01b2b7e1128e51d51e4bd9e48fd4f2ef4ade88c152970a35d2084bae" diff --git a/recipes/mdns/all/conanfile.py b/recipes/mdns/all/conanfile.py index aa012f43092fcf..6842da5a578476 100644 --- a/recipes/mdns/all/conanfile.py +++ b/recipes/mdns/all/conanfile.py @@ -1,38 +1,45 @@ import os -from conans import CMake, ConanFile, tools -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + class MdnsConan(ConanFile): name = "mdns" + description = "Public domain mDNS/DNS-SD library in C" license = "Unlicense" - homepage = "https://github.com/mjansson/mdns" url = "https://github.com/conan-io/conan-center-index" - description = "Public domain mDNS/DNS-SD library in C" - topics = ("mdns", "dns", "dns-sd", "multicast discovery", "discovery") - settings = "os", "compiler", "build_type", "arch" + homepage = "https://github.com/mjansson/mdns" + topics = ("dns", "dns-sd", "multicast discovery", "discovery", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() + self.info.clear() def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*.h", dst="include", src=self._source_subfolder) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, "*.h", dst=os.path.join(self.package_folder, "include"), src=self.source_folder) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + if self.settings.os == "Windows": self.cpp_info.system_libs = ["iphlpapi", "ws2_32"] - if str(self.settings.os) in ["Linux", "Android"]: - self.cpp_info.system_libs.append('pthread') + if str(self.settings.os) in ["Linux", "FreeBSD", "Android"]: + self.cpp_info.system_libs.append("pthread") self.cpp_info.set_property("cmake_file_name", "mdns") self.cpp_info.set_property("cmake_target_name", "mdns::mdns") diff --git a/recipes/mdns/all/test_package/CMakeLists.txt b/recipes/mdns/all/test_package/CMakeLists.txt index c7366be61abf1d..351413082436ff 100644 --- a/recipes/mdns/all/test_package/CMakeLists.txt +++ b/recipes/mdns/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(mdns REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE mdns::mdns) set_target_properties(${PROJECT_NAME} PROPERTIES C_STANDARD 99) diff --git a/recipes/mdns/all/test_package/conanfile.py b/recipes/mdns/all/test_package/conanfile.py index 6c0a50e0f76789..ef5d7042163ecc 100644 --- a/recipes/mdns/all/test_package/conanfile.py +++ b/recipes/mdns/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - bin_path = self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/mdns/all/test_package/test_package.c b/recipes/mdns/all/test_package/test_package.c index b27d9acd4f04bb..57ae843c7e0c01 100644 --- a/recipes/mdns/all/test_package/test_package.c +++ b/recipes/mdns/all/test_package/test_package.c @@ -15,8 +15,7 @@ # include #endif -int -main(int argc, const char* const* argv) { +int test() { #ifdef _WIN32 WORD versionWanted = MAKEWORD(1, 1); WSADATA wsaData; @@ -26,8 +25,7 @@ main(int argc, const char* const* argv) { } #endif - int port = 0; - int sock = mdns_socket_open_ipv4(port); + int sock = mdns_socket_open_ipv4(NULL); if (sock < 0) { printf("Failed to open socket: %s\n", strerror(errno)); return -1; @@ -35,9 +33,15 @@ main(int argc, const char* const* argv) { printf("socket cleanup\n"); mdns_socket_close(sock); + #ifdef _WIN32 WSACleanup(); #endif +} + +int main() { + // Do not run test() to not open a socket unnecessarily. + // Verifying that the function compiles is sufficient. return 0; } diff --git a/recipes/mdns/all/test_v1_package/CMakeLists.txt b/recipes/mdns/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/mdns/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/mdns/all/test_v1_package/conanfile.py b/recipes/mdns/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6dffe66394a26e --- /dev/null +++ b/recipes/mdns/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + bin_path = self.run(bin_path, run_environment=True) diff --git a/recipes/mdns/config.yml b/recipes/mdns/config.yml index cdb4b7bded43e5..59538424539ead 100644 --- a/recipes/mdns/config.yml +++ b/recipes/mdns/config.yml @@ -1,15 +1,9 @@ versions: - "1.0": + "1.4.3": folder: "all" - "1.1": - folder: "all" - "1.2": + "1.4.2": folder: "all" "1.3": folder: "all" - "1.4": - folder: "all" - "1.4.1": - folder: "all" - "1.4.2": + "1.2": folder: "all" From 0d0e9aea2d0a95fdc7d71185a65a03729101a9a4 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 8 Aug 2023 11:03:30 +0200 Subject: [PATCH 0118/1140] (#19089) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index d74f708376b9e5..2b71385973697f 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -421,12 +421,18 @@ required_for_references: - iso8601lib - itlib - ittapi +- ixwebsocket +- jansson - jasper - jbig +- jeaiii-itoa +- jfalcou-eve - jinja2cpp - joltphysics - jom - jpcre2 +- jpeg-compressor +- jsmn - json-c - json-schema-validator - jsoncons @@ -554,6 +560,7 @@ required_for_references: - libpqxx - libpsl - libqrencode +- librasterlite - libraw - librdkafka - librealsense @@ -602,6 +609,7 @@ required_for_references: - libwebsockets - libx264 - libx265 +- libxcrypt - libxls - libxlsxwriter - libxml2 From 5b2024b2ae1468c31c19d2b485e5fead82a20fac Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 8 Aug 2023 12:26:29 +0300 Subject: [PATCH 0119/1140] (#18350) di: migrate to Conan v2 * di: migrate to Conan v2 * di: restore test_v1_package * di: add cmake_find_package_multi generator to test_v1_package * di: fix license not being packaged * di: restore VirtualRunEnv in test_package * Added license extraction --------- Co-authored-by: Francisco Ramirez de Anton --- recipes/di/all/BSL-1.0.txt | 23 ---- recipes/di/all/conanfile.py | 112 ++++++++++++------ recipes/di/all/test_package/CMakeLists.txt | 7 +- recipes/di/all/test_package/conanfile.py | 22 +++- recipes/di/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/di/all/test_v1_package/conanfile.py | 16 +++ 6 files changed, 119 insertions(+), 69 deletions(-) delete mode 100644 recipes/di/all/BSL-1.0.txt create mode 100644 recipes/di/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/di/all/test_v1_package/conanfile.py diff --git a/recipes/di/all/BSL-1.0.txt b/recipes/di/all/BSL-1.0.txt deleted file mode 100644 index 36b7cd93cdfbac..00000000000000 --- a/recipes/di/all/BSL-1.0.txt +++ /dev/null @@ -1,23 +0,0 @@ -Boost Software License - Version 1.0 - August 17th, 2003 - -Permission is hereby granted, free of charge, to any person or organization -obtaining a copy of the software and accompanying documentation covered by -this license (the "Software") to use, reproduce, display, distribute, -execute, and transmit the Software, and to prepare derivative works of the -Software, and to permit third-parties to whom the Software is furnished to -do so, all subject to the following: - -The copyright notices in the Software and this entire statement, including -the above license grant, this restriction and the following disclaimer, -must be included in all copies of the Software, in whole or in part, and -all derivative works of the Software, unless such copies or derivative -works are solely in the form of machine-executable object code generated by -a source language processor. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT -SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE -FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, -ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER -DEALINGS IN THE SOFTWARE. diff --git a/recipes/di/all/conanfile.py b/recipes/di/all/conanfile.py index 5ccda35c324e5a..25630735095f55 100644 --- a/recipes/di/all/conanfile.py +++ b/recipes/di/all/conanfile.py @@ -1,61 +1,101 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, save, load +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class DiConan(ConanFile): name = "di" + description = "DI: C++14 Dependency Injection Library." license = "BSL-1.0" - homepage = "https://github.com/boost-ext/di" url = "https://github.com/conan-io/conan-center-index" - description = "DI: C++14 Dependency Injection Library." - topics = ("dependency-injection", "metaprogramming", "design-patterns") - exports_sources = ["BSL-1.0.txt"] - settings = "compiler" - options = {"with_extensions": [True, False], "diagnostics_level": [0, 1, 2]} - default_options = {"with_extensions": False, "diagnostics_level": 1} + homepage = "https://github.com/boost-ext/di" + topics = ("dependency-injection", "metaprogramming", "design-patterns", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + options = { + "with_extensions": [True, False], + "diagnostics_level": [0, 1, 2] + } + default_options = { + "with_extensions": False, + "diagnostics_level": 1 + } no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 14 - def configure(self): - minimal_cpp_standard = "14" - if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, minimal_cpp_standard) - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "gcc": "5", "clang": "3.4", "apple-clang": "10", - "Visual Studio": "15" + "Visual Studio": "15", + "msvc": "191" } + + def configure(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) compiler = str(self.settings.compiler) - if compiler not in minimal_version: - self.output.warn( - "%s recipe lacks information about the %s compiler standard version support" % (self.name, compiler)) - self.output.warn( - "%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) + if compiler not in self._compilers_minimum_version: + self.output.warning( + f"{self.name} recipe lacks information about the {compiler} compiler standard version support") + self.output.warning( + f"{self.name} requires a compiler that supports at least C++{self._min_cppstd}") return - version = tools.Version(self.settings.compiler.version) - if version < minimal_version[compiler]: - raise ConanInvalidConfiguration("%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) + version = Version(self.settings.compiler.version) + if version < self._compilers_minimum_version[compiler]: + raise ConanInvalidConfiguration( + f"{self.name} requires a compiler that supports at least C++{self._min_cppstd}") - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "di-" + self.version - os.rename(extracted_dir, self._source_subfolder) - - def package(self): - self.copy("BSL-1.0.txt", src="", dst="licenses") - if self.options.with_extensions: - self.copy("*.hpp", src=os.path.join(self._source_subfolder, "extension", "include", "boost", "di", "extension"), dst=os.path.join("include", "boost", "di", "extension"), keep_path=True) - self.copy("di.hpp", src=os.path.join(self._source_subfolder, "include", "boost"), dst=os.path.join("include", "boost")) + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): self.info.requires.clear() self.info.settings.clear() del self.info.options.diagnostics_level + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def _extract_license(self): + file = os.path.join(self.source_folder, "CMakeLists.txt") + file_content = load(self, file) + + license_start = file_content.find("# Copyright") + sub_end = "LICENSE_1_0.txt)" + license_end = file_content.find(sub_end) + license_contents = file_content[license_start:(license_end + len(sub_end))] + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_contents) + + + def package(self): + self._extract_license() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + if self.options.with_extensions: + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include", "boost", "di", "extension"), + src=os.path.join(self.source_folder, "extension", "include", "boost", "di", "extension"), + keep_path=True) + copy(self, "di.hpp", + dst=os.path.join(self.package_folder, "include", "boost"), + src=os.path.join(self.source_folder, "include", "boost")) + def package_info(self): - self.cpp_info.defines.append("BOOST_DI_CFG_DIAGNOSTICS_LEVEL={}".format(self.options.diagnostics_level)) + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + self.cpp_info.defines.append( + f"BOOST_DI_CFG_DIAGNOSTICS_LEVEL={self.options.diagnostics_level}") diff --git a/recipes/di/all/test_package/CMakeLists.txt b/recipes/di/all/test_package/CMakeLists.txt index 44d785353d02dd..4ead030531af2f 100644 --- a/recipes/di/all/test_package/CMakeLists.txt +++ b/recipes/di/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1.3) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(di REQUIRED CONFIG) add_executable(example example.cpp) +target_link_libraries(example di::di) set_target_properties(example PROPERTIES CXX_STANDARD 14) -target_link_libraries(example CONAN_PKG::di) diff --git a/recipes/di/all/test_package/conanfile.py b/recipes/di/all/test_package/conanfile.py index 8d63f059b4cdca..8d52b7021efe14 100644 --- a/recipes/di/all/test_package/conanfile.py +++ b/recipes/di/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class DiConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - self.run(os.path.join("bin", "example"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/di/all/test_v1_package/CMakeLists.txt b/recipes/di/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/di/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/di/all/test_v1_package/conanfile.py b/recipes/di/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..da134b42a75e31 --- /dev/null +++ b/recipes/di/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + + +class DiConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + self.run(os.path.join("bin", "example"), run_environment=True) From 1eaf77a85f94918f67be390dfb43b35898ee2171 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 8 Aug 2023 12:46:46 +0300 Subject: [PATCH 0120/1140] (#18352) si: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * si: migrate to Conan v2 * si: restore test_v1_package * si: drop older versions * si: restore VirtualRunEnv in test_package --------- Co-authored-by: Rubén Rincón Blanco --- recipes/si/all/CMakeLists.txt | 7 -- recipes/si/all/conandata.yml | 40 ++++----- recipes/si/all/conanfile.py | 81 +++++++++++-------- recipes/si/all/test_package/CMakeLists.txt | 7 +- recipes/si/all/test_package/conanfile.py | 22 +++-- recipes/si/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/si/all/test_v1_package/conanfile.py | 18 +++++ recipes/si/config.yml | 16 +--- 8 files changed, 107 insertions(+), 92 deletions(-) delete mode 100644 recipes/si/all/CMakeLists.txt create mode 100644 recipes/si/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/si/all/test_v1_package/conanfile.py diff --git a/recipes/si/all/CMakeLists.txt b/recipes/si/all/CMakeLists.txt deleted file mode 100644 index 6c3ae2de9686da..00000000000000 --- a/recipes/si/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(${CMAKE_BINARY_DIR}/../conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/si/all/conandata.yml b/recipes/si/all/conandata.yml index 5576f1491e1a59..a84644449fec85 100644 --- a/recipes/si/all/conandata.yml +++ b/recipes/si/all/conandata.yml @@ -1,28 +1,16 @@ sources: - 1.7.6: - url: https://github.com/bernedom/SI/archive/1.7.6.tar.gz - sha256: 88041156890c34f7ca92f3ae385b19189583aa5c59ac470bfe2db6df5d5c954b - 2.0.4: - url: https://github.com/bernedom/SI/archive/2.0.4.tar.gz - sha256: 459936b913e887325e6ad69e9d64389b80f49e700aa8e5308df2bd77b8c74a0e - 2.1.3: - url: https://github.com/bernedom/SI/archive/2.1.3.tar.gz - sha256: c4728155bd8878fecc5c71c006e01cb193e6084d1604f79edc71ee723027534b - 2.2.0: - url: https://github.com/bernedom/SI/archive/2.2.0.tar.gz - sha256: 4b42dbe878995e19991487b60e235699b02858a5036a1729890d7adc865794bf - 2.3.0: - url: https://github.com/bernedom/SI/archive/2.3.0.tar.gz - sha256: b714162a933ddf1be66c8f2f2d31b52626189d6e4b292770bbb899106e8f6ac1 - 2.4.0: - url: https://github.com/bernedom/SI/archive/2.4.0.tar.gz - sha256: 84e13b52520808d9a55a073b1bb98376be03dc3b09ddee862a1418ef543e9f2d - 2.4.1: - url: https://github.com/bernedom/SI/archive/2.4.1.tar.gz - sha256: 6bfdbebb549da1b2db93b55c1c7f8228a0cdc6144a815319918237ca8601ad3a - 2.5.0: - url: https://github.com/bernedom/SI/archive/2.5.0.tar.gz - sha256: dc00eb8cfaa32e19c83595b238726188d2b857f8999dae08fe3001d0107ba276 2.5.1: - url: https://github.com/bernedom/SI/archive/2.5.1.tar.gz - sha256: b7b977c04c220a47a2bd3b8e2b6acfd640d286dfe1ae609f20e184cfec998798 + url: "https://github.com/bernedom/SI/archive/2.5.1.tar.gz" + sha256: "b7b977c04c220a47a2bd3b8e2b6acfd640d286dfe1ae609f20e184cfec998798" + 2.5.0: + url: "https://github.com/bernedom/SI/archive/2.5.0.tar.gz" + sha256: "dc00eb8cfaa32e19c83595b238726188d2b857f8999dae08fe3001d0107ba276" + 2.4.1: + url: "https://github.com/bernedom/SI/archive/2.4.1.tar.gz" + sha256: "6bfdbebb549da1b2db93b55c1c7f8228a0cdc6144a815319918237ca8601ad3a" + 2.3.0: + url: "https://github.com/bernedom/SI/archive/2.3.0.tar.gz" + sha256: "b714162a933ddf1be66c8f2f2d31b52626189d6e4b292770bbb899106e8f6ac1" + 1.7.6: + url: "https://github.com/bernedom/SI/archive/1.7.6.tar.gz" + sha256: "88041156890c34f7ca92f3ae385b19189583aa5c59ac470bfe2db6df5d5c954b" diff --git a/recipes/si/all/conanfile.py b/recipes/si/all/conanfile.py index 38915243d0beff..592ef3c7ad9101 100644 --- a/recipes/si/all/conanfile.py +++ b/recipes/si/all/conanfile.py @@ -1,31 +1,33 @@ -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration - import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class SiConan(ConanFile): name = "si" + description = ( + "A header only c++ library that provides type safety and user defined literals " + "for handling physical values defined in the International System of Units." + ) license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/bernedom/SI" - description = "A header only c++ library that provides type safety and user defined literals \ - for handling pyhsical values defined in the International System of Units." - topics = ("physical units", "SI-unit-conversion", - "cplusplus-library", "cplusplus-17") - exports_sources = "CMakeLists.txt" + topics = ("physical units", "SI-unit-conversion", "cplusplus-library", "cplusplus-17", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True - generators = "cmake" @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def _min_cppstd(self): + return 17 @property def _compilers_minimum_version(self): @@ -36,38 +38,47 @@ def _compilers_minimum_version(self): "apple-clang": "10", } + def layout(self): + cmake_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, "17") + check_min_cppstd(self, self._min_cppstd) - minimum_version = self._compilers_minimum_version.get( - str(self.settings.compiler), False) + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("'si' requires C++17, which your compiler ({} {}) does not support.".format( - self.settings.compiler, self.settings.compiler.version)) + if Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + "'si' requires C++17, which your compiler " + f"({self.settings.compiler} {self.settings.compiler.version}) does not support.") else: - self.output.warn( - "'si' requires C++17. Your compiler is unknown. Assuming it supports C++17.") - - def package_id(self): - self.info.header_only() + self.output.warning("'si' requires C++17. Your compiler is unknown. Assuming it supports C++17.") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["SI_BUILD_TESTING"] = False + tc.variables["SI_BUILD_DOC"] = False + tc.variables["SI_INSTALL_LIBRARY"] = True + tc.generate() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) cmake = CMake(self) - cmake.definitions["SI_BUILD_TESTING"] = False - cmake.definitions["SI_BUILD_DOC"] = False - cmake.definitions["SI_INSTALL_LIBRARY"] = True - cmake.configure(build_folder=self._build_subfolder) + cmake.configure() cmake.install() - tools.rmdir(os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + self.cpp_info.set_property("cmake_file_name", "SI") self.cpp_info.set_property("cmake_target_name", "SI::SI") self.cpp_info.names["cmake_find_package"] = "SI" diff --git a/recipes/si/all/test_package/CMakeLists.txt b/recipes/si/all/test_package/CMakeLists.txt index 14c1322818a6b8..b7052eb3cd9b33 100644 --- a/recipes/si/all/test_package/CMakeLists.txt +++ b/recipes/si/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(SI REQUIRED CONFIG) diff --git a/recipes/si/all/test_package/conanfile.py b/recipes/si/all/test_package/conanfile.py index 8ae9b638e62feb..ef5d7042163ecc 100644 --- a/recipes/si/all/test_package/conanfile.py +++ b/recipes/si/all/test_package/conanfile.py @@ -1,11 +1,19 @@ - -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/si/all/test_v1_package/CMakeLists.txt b/recipes/si/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/si/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/si/all/test_v1_package/conanfile.py b/recipes/si/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..8ae9b638e62feb --- /dev/null +++ b/recipes/si/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ + +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/si/config.yml b/recipes/si/config.yml index 8530898d2c4b51..7296df14f7ecee 100644 --- a/recipes/si/config.yml +++ b/recipes/si/config.yml @@ -1,19 +1,11 @@ versions: - 1.7.6: - folder: all - 2.0.4: - folder: all - 2.1.3: - folder: all - 2.2.0: - folder: all - 2.3.0: + 2.5.1: folder: all - 2.4.0: + 2.5.0: folder: all 2.4.1: folder: all - 2.5.0: + 2.3.0: folder: all - 2.5.1: + 1.7.6: folder: all From bd9b51234dfbcf81a9b03455de7a0a32e002984e Mon Sep 17 00:00:00 2001 From: Alexander Bigerl Date: Tue, 8 Aug 2023 12:09:22 +0200 Subject: [PATCH 0121/1140] (#19015) Fix: sha256 sum of data for dice-template-library v1.0.0 --- recipes/dice-template-library/all/conandata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/dice-template-library/all/conandata.yml b/recipes/dice-template-library/all/conandata.yml index 8bfdcb315eb922..3dcfa182d3a53a 100644 --- a/recipes/dice-template-library/all/conandata.yml +++ b/recipes/dice-template-library/all/conandata.yml @@ -4,7 +4,7 @@ sources: sha256: "a00ee401379eaf6c8af013fb39d6732fa68c3852e14b50789edde6f054647ca2" "1.0.0": url: "https://github.com/dice-group/dice-template-library/archive/refs/tags/v1.0.0.tar.gz" - sha256: "485505ad3f9fb033083e2952bd8b4e68f6b4f123746b20f4ec3af46f4ce66cfe" + sha256: "d0c75ec4861e2480dc7d6533125f9c2dfb3574fc2cffd15c66665b1cdfa66561" "0.3.0": url: "https://github.com/dice-group/dice-template-library/archive/refs/tags/v0.3.0.tar.gz" sha256: "2c02278f86c7b5fe1c684f5126f30529952a03784fa7c883cc4fd44965b3c33e" From 4a0d5f020920532d720f962d4ab9d8437c799273 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Tue, 8 Aug 2023 20:15:37 +0930 Subject: [PATCH 0122/1140] (#18559) [util-linux-libuuid] Change CMake target from LibUUID::LibUUID to libuuid::libuuid * [util-linux-libuuid] Change CMake target from LibUUID::LibUUID to libuuid::libuuid * This is in line with what conan recipes seem to expect, which will minimise the number of patches required. LibUUID was chosen as the target name given this is what's used internally within cmake, but this isn't a public interface and so there is no common usage to take guidance from. Closes #18554 * add alias for LibUUID::LibUUID --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/util-linux-libuuid/all/conanfile.py | 7 +++++-- recipes/util-linux-libuuid/all/test_package/CMakeLists.txt | 4 ++-- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/recipes/util-linux-libuuid/all/conanfile.py b/recipes/util-linux-libuuid/all/conanfile.py index 736f1aadf03694..71265d08f5124f 100644 --- a/recipes/util-linux-libuuid/all/conanfile.py +++ b/recipes/util-linux-libuuid/all/conanfile.py @@ -109,7 +109,10 @@ def package(self): def package_info(self): self.cpp_info.set_property("pkg_config_name", "uuid") - self.cpp_info.set_property("cmake_target_name", "LibUUID::LibUUID") - self.cpp_info.set_property("cmake_file_name", "LibUUID") + self.cpp_info.set_property("cmake_target_name", "libuuid::libuuid") + self.cpp_info.set_property("cmake_file_name", "libuuid") + # Maintain alias to `LibUUID::LibUUID` for previous version of the recipe + self.cpp_info.set_property("cmake_target_aliases", ["LibUUID::LibUUID"]) + self.cpp_info.libs = ["uuid"] self.cpp_info.includedirs.append(os.path.join("include", "uuid")) diff --git a/recipes/util-linux-libuuid/all/test_package/CMakeLists.txt b/recipes/util-linux-libuuid/all/test_package/CMakeLists.txt index 02a93367160a0a..75c717f7699008 100644 --- a/recipes/util-linux-libuuid/all/test_package/CMakeLists.txt +++ b/recipes/util-linux-libuuid/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.8) project(test_package LANGUAGES C) -find_package(LibUUID REQUIRED CONFIG) +find_package(libuuid REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE LibUUID::LibUUID) +target_link_libraries(${PROJECT_NAME} PRIVATE libuuid::libuuid) target_compile_features(${PROJECT_NAME} PRIVATE c_std_99) From ff2b8d99c65e4b346ce7b289164815952734573a Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 8 Aug 2023 20:09:21 +0900 Subject: [PATCH 0123/1140] (#19050) freexl: add version 2.0.0, add package_type * freexl: add version 2.0.0, add package_type * fix typo in patch file --- recipes/freexl/all/conandata.yml | 5 +++ recipes/freexl/all/conanfile.py | 10 +++-- .../freexl/all/patches/fix-nmake-2.0.0.patch | 42 +++++++++++++++++++ recipes/freexl/config.yml | 2 + 4 files changed, 56 insertions(+), 3 deletions(-) create mode 100644 recipes/freexl/all/patches/fix-nmake-2.0.0.patch diff --git a/recipes/freexl/all/conandata.yml b/recipes/freexl/all/conandata.yml index 1ded763735f94d..9d309ba6c3c0d0 100644 --- a/recipes/freexl/all/conandata.yml +++ b/recipes/freexl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.0": + url: "http://www.gaia-gis.it/gaia-sins/freexl-sources/freexl-2.0.0.tar.gz" + sha256: "176705f1de58ab7c1eebbf5c6de46ab76fcd8b856508dbd28f5648f7c6e1a7f0" "1.0.6": url: "http://www.gaia-gis.it/gaia-sins/freexl-sources/freexl-1.0.6.tar.gz" sha256: "3de8b57a3d130cb2881ea52d3aa9ce1feedb1b57b7daa4eb37f751404f90fc22" @@ -6,6 +9,8 @@ sources: url: "http://www.gaia-gis.it/gaia-sins/freexl-sources/freexl-1.0.5.tar.gz" sha256: "3dc9b150d218b0e280a3d6a41d93c1e45f4d7155829d75f1e5bf3e0b0de6750d" patches: + "2.0.0": + - patch_file: "patches/fix-nmake-2.0.0.patch" "1.0.6": - patch_file: "patches/fix-nmake-1.0.6.patch" "1.0.5": diff --git a/recipes/freexl/all/conanfile.py b/recipes/freexl/all/conanfile.py index 794b52fdc98a55..6f97355b38f7c3 100644 --- a/recipes/freexl/all/conanfile.py +++ b/recipes/freexl/all/conanfile.py @@ -6,6 +6,7 @@ from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain from conan.tools.layout import basic_layout from conan.tools.microsoft import is_msvc, NMakeDeps, NMakeToolchain +from conan.tools.scm import Version import os required_conan_version = ">=1.55.0" @@ -16,10 +17,10 @@ class FreexlConan(ConanFile): description = "FreeXL is an open source library to extract valid data " \ "from within an Excel (.xls) spreadsheet." license = ["MPL-1.0", "GPL-2.0-only", "LGPL-2.1-only"] - topics = ("excel", "xls") - homepage = "https://www.gaia-gis.it/fossil/freexl/index" url = "https://github.com/conan-io/conan-center-index" - + homepage = "https://www.gaia-gis.it/fossil/freexl/index" + topics = ("excel", "xls") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -52,6 +53,9 @@ def layout(self): def requirements(self): self.requires("libiconv/1.17") + if Version(self.version) >= "2.0.0": + self.requires("expat/2.5.0") + self.requires("minizip/1.2.13") def build_requirements(self): if not is_msvc(self): diff --git a/recipes/freexl/all/patches/fix-nmake-2.0.0.patch b/recipes/freexl/all/patches/fix-nmake-2.0.0.patch new file mode 100644 index 00000000000000..80cf36670487d4 --- /dev/null +++ b/recipes/freexl/all/patches/fix-nmake-2.0.0.patch @@ -0,0 +1,42 @@ +diff --git a/a/makefile.vc b/b/makefile.vc +index 5cd5d05..f7505ea 100644 +--- a/a/makefile.vc ++++ b/b/makefile.vc +@@ -11,7 +11,7 @@ ODS = freexl_ods.obj + LIBOBJ = $(CORE) $(XLSX) $(ODS) + FREEXL_DLL = freexl$(VERSION).dll + +-CFLAGS = /nologo -I. -Iheaders -IC:\OSGeo4W\include $(OPTFLAGS) ++CFLAGS = /nologo -I. -Iheaders $(OPTFLAGS) + + default: all + +@@ -33,12 +33,8 @@ freexl.lib: $(LIBOBJ) + $(FREEXL_DLL): freexl_i.lib + + freexl_i.lib: $(LIBOBJ) +- link /debug /dll /out:$(FREEXL_DLL) \ +- /implib:freexl_i.lib $(LIBOBJ) \ +- C:\OSGeo4W\lib\iconv.lib \ +- C:\OSGeo4W\lib\libexpat.lib \ +- C:\OSGeo4W\lib\libminizip.lib \ +- C:\OSGeo4w\lib\zlib.lib ++ link /dll /out:$(FREEXL_DLL) \ ++ /implib:freexl_i.lib $(LIBOBJ) + if exist $(FREEXL_DLL).manifest mt -manifest \ + $(FREEXL_DLL).manifest -outputresource:$(FREEXL_DLL);2 + +diff --git a/a/nmake.opt b/b/nmake.opt +index 35f9242..15abafe 100644 +--- a/a/nmake.opt ++++ b/b/nmake.opt +@@ -2,8 +2,7 @@ + INSTDIR=C:\OSGeo4W + + # Uncomment the first for an optimized build, or the second for debug. +-OPTFLAGS= /nologo /Ox /fp:precise /W3 /MD /D_CRT_SECURE_NO_WARNINGS \ +- /DDLL_EXPORT ++OPTFLAGS= /nologo /fp:precise /W3 /D_CRT_SECURE_NO_WARNINGS $(FREEXL_EXPORT) + #OPTFLAGS= /nologo /Zi /MD /Fdfreexl.pdb /DDLL_EXPORT + + # Set the version number for the DLL. Normally we leave this blank since diff --git a/recipes/freexl/config.yml b/recipes/freexl/config.yml index 06269eb399e913..e78a14da43e749 100644 --- a/recipes/freexl/config.yml +++ b/recipes/freexl/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.0": + folder: all "1.0.6": folder: all "1.0.5": From 7008564c91237b7767521d87b18200bd3c0ec3b4 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 8 Aug 2023 16:51:11 +0200 Subject: [PATCH 0124/1140] (#19097) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 2b71385973697f..fdcbe4b81dbb26 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -765,6 +765,7 @@ required_for_references: - opencl-icd-loader - opencolorio - opencore-amr +- opencv - openddl-parser - openexr - openfbx From 52263aadbcc9777247c2ec8d4d8f99fc3d287476 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 00:12:10 +0900 Subject: [PATCH 0125/1140] (#19071) minizip-ng: add version 4.0.1, remove older versions --- recipes/minizip-ng/all/conandata.yml | 36 ++----------------- recipes/minizip-ng/all/conanfile.py | 2 +- .../3.0.1-0001-fix-cmake-project.patch | 22 ------------ .../3.0.2-0001-fix-cmake-project.patch | 22 ------------ .../3.0.3-0001-fix-cmake-project.patch | 22 ------------ recipes/minizip-ng/config.yml | 8 ++--- 6 files changed, 6 insertions(+), 106 deletions(-) delete mode 100644 recipes/minizip-ng/all/patches/3.0.1-0001-fix-cmake-project.patch delete mode 100644 recipes/minizip-ng/all/patches/3.0.2-0001-fix-cmake-project.patch delete mode 100644 recipes/minizip-ng/all/patches/3.0.3-0001-fix-cmake-project.patch diff --git a/recipes/minizip-ng/all/conandata.yml b/recipes/minizip-ng/all/conandata.yml index 352a0f4b634fe5..cad464b51193b9 100644 --- a/recipes/minizip-ng/all/conandata.yml +++ b/recipes/minizip-ng/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.0.1": + url: "https://github.com/zlib-ng/minizip-ng/archive/4.0.1.tar.gz" + sha256: "63e47a2b4dbac0da501f43f4da74f118dfb3ef0dee0ffbbe89428271002260f8" "4.0.0": url: "https://github.com/zlib-ng/minizip-ng/archive/4.0.0.tar.gz" sha256: "f9062e576de026fd5026d65597de3b05263cd4d91400cacdbbe36dfa8a642fff" @@ -20,15 +23,6 @@ sources: "3.0.4": url: "https://github.com/zlib-ng/minizip-ng/archive/3.0.4.tar.gz" sha256: "2ab219f651901a337a7d3c268128711b80330a99ea36bdc528c76b591a624c3c" - "3.0.3": - url: "https://github.com/zlib-ng/minizip-ng/archive/3.0.3.tar.gz" - sha256: "5f1dd0d38adbe9785cb9c4e6e47738c109d73a0afa86e58c4025ce3e2cc504ed" - "3.0.2": - url: "https://github.com/zlib-ng/minizip-ng/archive/3.0.2.tar.gz" - sha256: "6ba4b6629c107c27ab526e517bdb105612232f0965a6747f60150e5a04c2fe5a" - "3.0.1": - url: "https://github.com/zlib-ng/minizip-ng/archive/3.0.1.tar.gz" - sha256: "96c95b274dd535984ce0e87691691388f2b976106e8cf8d527b15da552ac94e4" patches: "3.0.9": - patch_file: "patches/3.0.9-0001-fix-cmake-project.patch" @@ -70,27 +64,3 @@ patches: patch_description: "CMake: inject libdir of lzma" patch_type: "conan" patch_source: "https://github.com/zlib-ng/minizip-ng/pull/658" - "3.0.3": - - patch_file: "patches/3.0.3-0001-fix-cmake-project.patch" - patch_description: "CMake: declare project() sooner" - patch_type: "conan" - - patch_file: "patches/3.0.1-0002-fix-lzma-libdir.patch" - patch_description: "CMake: inject libdir of lzma" - patch_type: "conan" - patch_source: "https://github.com/zlib-ng/minizip-ng/pull/658" - "3.0.2": - - patch_file: "patches/3.0.2-0001-fix-cmake-project.patch" - patch_description: "CMake: declare project() sooner" - patch_type: "conan" - - patch_file: "patches/3.0.1-0002-fix-lzma-libdir.patch" - patch_description: "CMake: inject libdir of lzma" - patch_type: "conan" - patch_source: "https://github.com/zlib-ng/minizip-ng/pull/658" - "3.0.1": - - patch_file: "patches/3.0.1-0001-fix-cmake-project.patch" - patch_description: "CMake: declare project() sooner" - patch_type: "conan" - - patch_file: "patches/3.0.1-0002-fix-lzma-libdir.patch" - patch_description: "CMake: inject libdir of lzma" - patch_type: "conan" - patch_source: "https://github.com/zlib-ng/minizip-ng/pull/658" diff --git a/recipes/minizip-ng/all/conanfile.py b/recipes/minizip-ng/all/conanfile.py index 01bda6f608ccb9..9dec1a6119509d 100644 --- a/recipes/minizip-ng/all/conanfile.py +++ b/recipes/minizip-ng/all/conanfile.py @@ -140,7 +140,7 @@ def _patch_sources(self): replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "set_target_properties(${PROJECT_NAME} PROPERTIES POSITION_INDEPENDENT_CODE 1)", "") - else: + elif Version(self.version) == "4.0.0": replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "set_target_properties(${MINIZIP_TARGET} PROPERTIES POSITION_INDEPENDENT_CODE 1)", "") diff --git a/recipes/minizip-ng/all/patches/3.0.1-0001-fix-cmake-project.patch b/recipes/minizip-ng/all/patches/3.0.1-0001-fix-cmake-project.patch deleted file mode 100644 index c44b1784ce620d..00000000000000 --- a/recipes/minizip-ng/all/patches/3.0.1-0001-fix-cmake-project.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -63,10 +63,10 @@ endif() - # BZIP2_ROOT - Parent directory of BZip2 installation - # OPENSSL_ROOT - Parent directory of OpenSSL installation - --enable_language(C) - - # Library version - set(VERSION "3.0.1") -+project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION} LANGUAGES C) - - # API version - set(SOVERSION "3.0") -@@ -677,7 +677,6 @@ endif() - list(APPEND MINIZIP_INC ${CMAKE_CURRENT_SOURCE_DIR}) - - # Create minizip library --project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION}) - - if(NOT ${MZ_PROJECT_SUFFIX} STREQUAL "") - message(STATUS "Project configured as ${PROJECT_NAME}") diff --git a/recipes/minizip-ng/all/patches/3.0.2-0001-fix-cmake-project.patch b/recipes/minizip-ng/all/patches/3.0.2-0001-fix-cmake-project.patch deleted file mode 100644 index 8cfa267f8cff7e..00000000000000 --- a/recipes/minizip-ng/all/patches/3.0.2-0001-fix-cmake-project.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -63,10 +63,10 @@ endif() - # BZIP2_ROOT - Parent directory of BZip2 installation - # OPENSSL_ROOT - Parent directory of OpenSSL installation - --enable_language(C) - - # Library version - set(VERSION "3.0.2") -+project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION} LANGUAGES C) - - # API version - set(SOVERSION "3.0") -@@ -681,7 +681,6 @@ endif() - list(APPEND MINIZIP_INC ${CMAKE_CURRENT_SOURCE_DIR}) - - # Create minizip library --project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION}) - - if(NOT ${MZ_PROJECT_SUFFIX} STREQUAL "") - message(STATUS "Project configured as ${PROJECT_NAME}") diff --git a/recipes/minizip-ng/all/patches/3.0.3-0001-fix-cmake-project.patch b/recipes/minizip-ng/all/patches/3.0.3-0001-fix-cmake-project.patch deleted file mode 100644 index 484eb23a916710..00000000000000 --- a/recipes/minizip-ng/all/patches/3.0.3-0001-fix-cmake-project.patch +++ /dev/null @@ -1,22 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -63,10 +63,10 @@ endif() - # BZIP2_ROOT - Parent directory of BZip2 installation - # OPENSSL_ROOT - Parent directory of OpenSSL installation - --enable_language(C) - - # Library version - set(VERSION "3.0.3") -+project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION} LANGUAGES C) - - # API version - set(SOVERSION "3") -@@ -681,7 +681,6 @@ endif() - list(APPEND MINIZIP_INC ${CMAKE_CURRENT_SOURCE_DIR}) - - # Create minizip library --project(minizip${MZ_PROJECT_SUFFIX} VERSION ${VERSION}) - - if(NOT ${MZ_PROJECT_SUFFIX} STREQUAL "") - message(STATUS "Project configured as ${PROJECT_NAME}") diff --git a/recipes/minizip-ng/config.yml b/recipes/minizip-ng/config.yml index 85231c75362684..b2948c58fb8806 100644 --- a/recipes/minizip-ng/config.yml +++ b/recipes/minizip-ng/config.yml @@ -1,4 +1,6 @@ versions: + "4.0.1": + folder: all "4.0.0": folder: all "3.0.9": @@ -13,9 +15,3 @@ versions: folder: all "3.0.4": folder: all - "3.0.3": - folder: all - "3.0.2": - folder: all - "3.0.1": - folder: all From c110531128f32a5fd72eb40fc134e3ebfba4232b Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 01:43:03 +0900 Subject: [PATCH 0126/1140] (#19020) quill: add version 3.3.1 --- recipes/quill/all/conandata.yml | 3 +++ recipes/quill/all/test_package/CMakeLists.txt | 4 ++++ recipes/quill/all/test_package/test_package.cpp | 8 ++++++++ recipes/quill/config.yml | 2 ++ 4 files changed, 17 insertions(+) diff --git a/recipes/quill/all/conandata.yml b/recipes/quill/all/conandata.yml index d0c356569441c7..bb2b9571b97fbe 100644 --- a/recipes/quill/all/conandata.yml +++ b/recipes/quill/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.3.1": + url: "https://github.com/odygrd/quill/archive/v3.3.1.tar.gz" + sha256: "f929d54a115b45c32dd2acd1a9810336d35c31fde9f5581c51ad2b80f980d0d1" "3.2.0": url: "https://github.com/odygrd/quill/archive/v3.2.0.tar.gz" sha256: "9745ad83b285bbd0481bd14c1b866b7e6121a981dd211b914f5d55955040fd00" diff --git a/recipes/quill/all/test_package/CMakeLists.txt b/recipes/quill/all/test_package/CMakeLists.txt index d53c2b924044a5..b6b657d776df51 100644 --- a/recipes/quill/all/test_package/CMakeLists.txt +++ b/recipes/quill/all/test_package/CMakeLists.txt @@ -10,3 +10,7 @@ if(quill_VERSION VERSION_GREATER_EQUAL "2.0.0") else() target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) endif() + +if(quill_VERSION VERSION_GREATER_EQUAL "3.3.0") + target_compile_definitions(${PROJECT_NAME} PRIVATE QUILL_FILE_HANDLERS_API_V3_3) +endif() diff --git a/recipes/quill/all/test_package/test_package.cpp b/recipes/quill/all/test_package/test_package.cpp index ab2f3ef6f2de87..b02a6dd344b064 100644 --- a/recipes/quill/all/test_package/test_package.cpp +++ b/recipes/quill/all/test_package/test_package.cpp @@ -3,7 +3,15 @@ int main() { quill::start(); +#ifdef QUILL_FILE_HANDLERS_API_V3_3 + auto file_handler = quill::file_handler("logfile.log", []() { + quill::FileHandlerConfig cfg; + cfg.set_open_mode('w'); + return cfg; + }()); +#else auto file_handler = quill::file_handler("logfile.log", "w"); +#endif auto my_logger = quill::create_logger("my_logger", std::move(file_handler)); LOG_INFO(my_logger, "Hello from {}", "Quill"); diff --git a/recipes/quill/config.yml b/recipes/quill/config.yml index d8522cb2854c60..6c3cb17b456370 100644 --- a/recipes/quill/config.yml +++ b/recipes/quill/config.yml @@ -1,4 +1,6 @@ versions: + "3.3.1": + folder: "all" "3.2.0": folder: "all" "3.1.0": From 4e10ea1897c7bd98cad8e12bf8f5cbb5e25988a1 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 04:21:32 +0900 Subject: [PATCH 0127/1140] (#19069) asio-grpc: add version 2.6.0 --- recipes/asio-grpc/all/conandata.yml | 3 +++ recipes/asio-grpc/all/conanfile.py | 2 +- recipes/asio-grpc/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/asio-grpc/all/conandata.yml b/recipes/asio-grpc/all/conandata.yml index 2e070194bef3fd..93b16454d2a6d4 100644 --- a/recipes/asio-grpc/all/conandata.yml +++ b/recipes/asio-grpc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.0": + url: "https://github.com/Tradias/asio-grpc/archive/refs/tags/v2.6.0.tar.gz" + sha256: "9f17f1dfe390667c71d8e0645937afa36f1a0e146f60f6036c7b4e12b09ed14e" "2.5.1": url: "https://github.com/Tradias/asio-grpc/archive/refs/tags/v2.5.1.tar.gz" sha256: "571779a25be6eed77a345088e3ded2cccf880c16800ee0075ece57116f14fc35" diff --git a/recipes/asio-grpc/all/conanfile.py b/recipes/asio-grpc/all/conanfile.py index a0e6d608281c48..b49ad78283c25d 100644 --- a/recipes/asio-grpc/all/conanfile.py +++ b/recipes/asio-grpc/all/conanfile.py @@ -60,7 +60,7 @@ def requirements(self): if self._local_allocator_option == "boost_container" or self.options.backend == "boost": self.requires("boost/1.82.0") if self.options.backend == "asio": - self.requires("asio/1.28.0") + self.requires("asio/1.28.1") if self.options.backend == "unifex": self.requires("libunifex/cci.20220430") diff --git a/recipes/asio-grpc/config.yml b/recipes/asio-grpc/config.yml index 9952741d8464da..5c9bbc56f454e4 100644 --- a/recipes/asio-grpc/config.yml +++ b/recipes/asio-grpc/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.0": + folder: all "2.5.1": folder: all "2.4.0": From 4a565cec2909255fea330c92b33858ed25e2dbf0 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Tue, 8 Aug 2023 22:33:12 +0200 Subject: [PATCH 0128/1140] (#19093) [proj] Bump libcurl version Signed-off-by: Uilian Ries --- recipes/proj/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/proj/all/conanfile.py b/recipes/proj/all/conanfile.py index e5322b9f644f00..9afbca02d3ff6b 100644 --- a/recipes/proj/all/conanfile.py +++ b/recipes/proj/all/conanfile.py @@ -61,7 +61,7 @@ def requirements(self): if self.options.get_safe("with_tiff"): self.requires("libtiff/4.5.1") if self.options.get_safe("with_curl"): - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.2.0") def build_requirements(self): if not can_run(self): From 9f96ee436d2af9ee5c15fbf2af10796eaaa92c80 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 8 Aug 2023 23:49:21 +0200 Subject: [PATCH 0129/1140] (#19064) cmake: add 3.27.1 --- recipes/cmake/binary/conandata.yml | 19 +++++++++++++++++++ recipes/cmake/config.yml | 18 ++++++++++-------- 2 files changed, 29 insertions(+), 8 deletions(-) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index c9e3ccde2563d7..a778631e96cbaf 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.1": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.1-linux-aarch64.tar.gz" + sha256: "812e32b569bcfb61f5ededdec244c4fddcd18d2c352a902ef88ed7d02005b2bd" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.1-linux-x86_64.tar.gz" + sha256: "9fef63e1cf87cab1153f9433045df2e43c336e462518b0f5e52d2cc91d762cff" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.1-macos10.10-universal.tar.gz" + sha256: "3f9b1b6c29369d2b4e71991420966599a378b01f84e6420d5e881946a04debed" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.1-windows-arm64.zip" + sha256: "588576bd73f20a851de053571a3ccb9bfe28446b5952ea62918dd273da608183" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.1-windows-x86_64.zip" + sha256: "664fe1655999f0b693d1e64ddb430191c727ab0a03dc1da7278f291172e1e04e" "3.27.0": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 0ed8eb6281e813..4a1e12b81255fd 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -1,19 +1,21 @@ versions: - "3.19.8": + "3.27.1": folder: "binary" - "3.20.6": + "3.27.0": folder: "binary" - "3.21.7": + "3.26.4": folder: "binary" - "3.22.6": + "3.25.3": + folder: "binary" + "3.24.4": folder: "binary" "3.23.5": folder: "binary" - "3.24.4": + "3.22.6": folder: "binary" - "3.25.3": + "3.21.7": folder: "binary" - "3.26.4": + "3.20.6": folder: "binary" - "3.27.0": + "3.19.8": folder: "binary" From 0238c2b1dfb76814b4ea0c602846df05862ad228 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Wed, 9 Aug 2023 00:32:01 +0200 Subject: [PATCH 0130/1140] (#19091) [sentry-breakpad] bump libcurl to 8.2.0 --- recipes/sentry-crashpad/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/sentry-crashpad/all/conanfile.py b/recipes/sentry-crashpad/all/conanfile.py index 645ba8aaf554d6..af63a7ade4f9dc 100644 --- a/recipes/sentry-crashpad/all/conanfile.py +++ b/recipes/sentry-crashpad/all/conanfile.py @@ -62,7 +62,7 @@ def build_requirements(self): def requirements(self): self.requires("zlib/1.2.13") if self.settings.os in ("Linux", "FreeBSD"): - self.requires("libcurl/8.1.2") + self.requires("libcurl/8.2.0") if self.options.get_safe("with_tls"): self.requires("openssl/[>=1.1 <4]") From 61ec603a9f2122621fec76bc9288080d0d200d04 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 9 Aug 2023 03:05:59 +0300 Subject: [PATCH 0131/1140] (#18081) systemc: migrate to Conan v2 * systemc: migrate to Conan v2 * systemc: restore test_v1_package * systemc: add exception for GCC v5 * systemc: don not set cxx_std_11 --------- Co-authored-by: James --- recipes/systemc/all/CMakeLists.txt | 7 -- recipes/systemc/all/conandata.yml | 6 - recipes/systemc/all/conanfile.py | 119 +++++++++--------- recipes/systemc/all/patches/0001-cmake.patch | 8 +- recipes/systemc/all/patches/0004-cmake.patch | 8 +- .../systemc/all/test_package/CMakeLists.txt | 5 +- recipes/systemc/all/test_package/conanfile.py | 21 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../systemc/all/test_v1_package/conanfile.py | 17 +++ 9 files changed, 103 insertions(+), 96 deletions(-) delete mode 100644 recipes/systemc/all/CMakeLists.txt create mode 100644 recipes/systemc/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/systemc/all/test_v1_package/conanfile.py diff --git a/recipes/systemc/all/CMakeLists.txt b/recipes/systemc/all/CMakeLists.txt deleted file mode 100644 index bd3083b512cb93..00000000000000 --- a/recipes/systemc/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/systemc/all/conandata.yml b/recipes/systemc/all/conandata.yml index db213ca0aa8346..234032a9f92d2d 100644 --- a/recipes/systemc/all/conandata.yml +++ b/recipes/systemc/all/conandata.yml @@ -8,15 +8,9 @@ sources: patches: "2.3.3": - patch_file: "patches/0001-cmake.patch" - base_path: "source_subfolder" - patch_file: "patches/0002-sc_string_view.patch" - base_path: "source_subfolder" - patch_file: "patches/0003-mingw.patch" - base_path: "source_subfolder" "2.3.4": - patch_file: "patches/0002-sc_string_view.patch" - base_path: "source_subfolder" - patch_file: "patches/0003-mingw.patch" - base_path: "source_subfolder" - patch_file: "patches/0004-cmake.patch" - base_path: "source_subfolder" diff --git a/recipes/systemc/all/conanfile.py b/recipes/systemc/all/conanfile.py index e65862f8bd94bc..60fb8e631adf24 100644 --- a/recipes/systemc/all/conanfile.py +++ b/recipes/systemc/all/conanfile.py @@ -1,20 +1,25 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -import functools +from conan import ConanFile, conan_version +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version import os -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class SystemcConan(ConanFile): name = "systemc" - description = """SystemC is a set of C++ classes and macros which provide - an event-driven simulation interface.""" - homepage = "https://www.accellera.org/" - url = "https://github.com/conan-io/conan-center-index" + description = ("SystemC is a set of C++ classes and macros which provide " + "an event-driven simulation interface.") license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.accellera.org/" topics = ("simulation", "modeling", "esl", "tlm") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -33,7 +38,7 @@ class SystemcConan(ConanFile): "fPIC": True, "disable_async_updates": False, "disable_copyright_msg": False, - "disable_virtual_bind": False, + "disable_virtual_bind": False, "enable_assertions": True, "enable_immediate_self_notifications": False, "enable_pthreads": False, @@ -41,85 +46,81 @@ class SystemcConan(ConanFile): "enable_phase_callbacks_tracing": False, } - generators = "cmake" - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _is_msvc(self): - return str(self.settings.compiler) in ["Visual Studio", "msvc"] - def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - del self.options.enable_pthreads + self.options.rm_safe("enable_pthreads") def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): - if self.settings.os == "Macos": + if is_apple_os(self): raise ConanInvalidConfiguration("Macos build not supported") if self.settings.os == "Windows" and self.options.shared: - raise ConanInvalidConfiguration("Building SystemC as a shared library on Windows is currently not supported") + raise ConanInvalidConfiguration( + "Building SystemC as a shared library on Windows is currently not supported" + ) + + if ( + conan_version.major == 1 + and self.settings.compiler == "gcc" + and Version(self.settings.compiler.version) <= "5" + ): + raise ConanInvalidConfiguration( + f"GCC {self.settings.compiler.version} is not supported by SystemC on Conan v1" + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["DISABLE_ASYNC_UPDATES"] = self.options.disable_async_updates + tc.variables["DISABLE_COPYRIGHT_MESSAGE"] = self.options.disable_copyright_msg + tc.variables["DISABLE_VIRTUAL_BIND"] = self.options.disable_virtual_bind + tc.variables["ENABLE_ASSERTIONS"] = self.options.enable_assertions + tc.variables["ENABLE_IMMEDIATE_SELF_NOTIFICATIONS"] = self.options.enable_immediate_self_notifications + tc.variables["ENABLE_PTHREADS"] = self.options.get_safe("enable_pthreads", False) + tc.variables["ENABLE_PHASE_CALLBACKS"] = self.options.get_safe("enable_phase_callbacks", False) + tc.variables["ENABLE_PHASE_CALLBACKS_TRACING"] = self.options.get_safe("enable_phase_callbacks_tracing", False) + tc.generate() - @functools.lru_cache(1) - def _configure_cmake(self): + def build(self): + apply_conandata_patches(self) cmake = CMake(self) - cmake.definitions["DISABLE_ASYNC_UPDATES"] = \ - self.options.disable_async_updates - cmake.definitions["DISABLE_COPYRIGHT_MESSAGE"] = \ - self.options.disable_copyright_msg - cmake.definitions["DISABLE_VIRTUAL_BIND"] = \ - self.options.disable_virtual_bind - cmake.definitions["ENABLE_ASSERTIONS"] = \ - self.options.enable_assertions - cmake.definitions["ENABLE_IMMEDIATE_SELF_NOTIFICATIONS"] = \ - self.options.enable_immediate_self_notifications - cmake.definitions["ENABLE_PTHREADS"] = \ - self.options.get_safe("enable_pthreads", False) - cmake.definitions["ENABLE_PHASE_CALLBACKS"] = \ - self.options.get_safe("enable_phase_callbacks", False) - cmake.definitions["ENABLE_PHASE_CALLBACKS_TRACING"] = \ - self.options.get_safe("enable_phase_callbacks_tracing", False) cmake.configure() - return cmake - - def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("NOTICE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "NOTICE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "SystemCLanguage") self.cpp_info.set_property("cmake_target_name", "SystemC::systemc") + # TODO: back to global scope in conan v2 once cmake_find_package* generators removed self.cpp_info.components["_systemc"].libs = ["systemc"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["_systemc"].system_libs = ["pthread"] - if self._is_msvc: + self.cpp_info.components["_systemc"].system_libs = ["pthread", "m"] + if is_msvc(self): self.cpp_info.components["_systemc"].cxxflags.append("/vmg") # TODO: to remove in conan v2 once cmake_find_package* generators removed diff --git a/recipes/systemc/all/patches/0001-cmake.patch b/recipes/systemc/all/patches/0001-cmake.patch index 46f27b30da9245..3598e00cb51a59 100644 --- a/recipes/systemc/all/patches/0001-cmake.patch +++ b/recipes/systemc/all/patches/0001-cmake.patch @@ -1,6 +1,6 @@ --- CMakeLists.txt +++ CMakeLists.txt -@@ -273,12 +273,12 @@ +@@ -273,12 +273,6 @@ FORCE) endif (NOT CMAKE_BUILD_TYPE) @@ -10,12 +10,6 @@ - "The with CMAKE_CXX_STANDARD selected C++ standard is a requirement.") -mark_as_advanced (CMAKE_CXX_STANDARD_REQUIRED) - -+#set (CMAKE_CXX_STANDARD 98 CACHE STRING -+# "C++ standard to build all targets. Supported values are 98, 11, and 14.") -+#set (CMAKE_CXX_STANDARD_REQUIRED ON CACHE BOOL -+# "The with CMAKE_CXX_STANDARD selected C++ standard is a requirement.") -+#mark_as_advanced (CMAKE_CXX_STANDARD_REQUIRED) -+# if (NOT (WIN32 OR CYGWIN)) option (BUILD_SHARED_LIBS "Build shared libraries." ON) else (NOT (WIN32 OR CYGWIN)) diff --git a/recipes/systemc/all/patches/0004-cmake.patch b/recipes/systemc/all/patches/0004-cmake.patch index 83eead38732bc8..5c4004ed81fc29 100644 --- a/recipes/systemc/all/patches/0004-cmake.patch +++ b/recipes/systemc/all/patches/0004-cmake.patch @@ -1,6 +1,6 @@ --- CMakeLists.txt +++ CMakeLists.txt -@@ -277,12 +277,12 @@ +@@ -277,12 +277,6 @@ FORCE) endif (NOT CMAKE_BUILD_TYPE) @@ -10,12 +10,6 @@ - "The with CMAKE_CXX_STANDARD selected C++ standard is a requirement.") -mark_as_advanced (CMAKE_CXX_STANDARD_REQUIRED) - -+#set (CMAKE_CXX_STANDARD 98 CACHE STRING -+# "C++ standard to build all targets. Supported values are 98, 11, 14, and 17.") -+#set (CMAKE_CXX_STANDARD_REQUIRED ON CACHE BOOL -+# "The with CMAKE_CXX_STANDARD selected C++ standard is a requirement.") -+#mark_as_advanced (CMAKE_CXX_STANDARD_REQUIRED) -+# if (NOT (WIN32 OR CYGWIN)) option (BUILD_SHARED_LIBS "Build shared libraries." ON) else (NOT (WIN32 OR CYGWIN)) diff --git a/recipes/systemc/all/test_package/CMakeLists.txt b/recipes/systemc/all/test_package/CMakeLists.txt index 5d31301bc9ee25..86a595ce48e9a2 100644 --- a/recipes/systemc/all/test_package/CMakeLists.txt +++ b/recipes/systemc/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(SystemCLanguage REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/systemc/all/test_package/conanfile.py b/recipes/systemc/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/systemc/all/test_package/conanfile.py +++ b/recipes/systemc/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/systemc/all/test_v1_package/CMakeLists.txt b/recipes/systemc/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/systemc/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/systemc/all/test_v1_package/conanfile.py b/recipes/systemc/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/systemc/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 88c385576f6c0a4cad20a56c6c14d2769bf33cb1 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 9 Aug 2023 02:39:56 +0200 Subject: [PATCH 0132/1140] (#19099) zookeeper-client-c: use stable url for tarball of source code --- recipes/zookeeper-client-c/all/conandata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/zookeeper-client-c/all/conandata.yml b/recipes/zookeeper-client-c/all/conandata.yml index 5a209ac187af0d..f81d1f4e6d34ff 100644 --- a/recipes/zookeeper-client-c/all/conandata.yml +++ b/recipes/zookeeper-client-c/all/conandata.yml @@ -1,6 +1,6 @@ sources: "3.8.1": - url: "https://dlcdn.apache.org/zookeeper/zookeeper-3.8.1/apache-zookeeper-3.8.1.tar.gz" + url: "https://archive.apache.org/dist/zookeeper/zookeeper-3.8.1/apache-zookeeper-3.8.1.tar.gz" sha256: "ccc16850c8ab2553583583234d11c813061b5ea5f3b8ff1d740cde6c1fd1e219" patches: "3.8.1": From d6e70e93f154cf014117e2903b54dede76266411 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 9 Aug 2023 02:50:00 +0200 Subject: [PATCH 0133/1140] (#19105) meson: add version 1.2.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/meson/all/conandata.yml | 3 +++ recipes/meson/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/meson/all/conandata.yml b/recipes/meson/all/conandata.yml index df69b3c1b2cb9e..17f050a5732927 100644 --- a/recipes/meson/all/conandata.yml +++ b/recipes/meson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.1": + url: "https://github.com/mesonbuild/meson/releases/download/1.2.1/meson-1.2.1.tar.gz" + sha256: "b1db3a153087549497ee52b1c938d2134e0338214fe14f7efd16fecd57b639f5" "1.2.0": url: "https://github.com/mesonbuild/meson/archive/1.2.0.tar.gz" sha256: "603489f0aaa6305f806c6cc4a4455a965f22290fc74f65871f589b002110c790" diff --git a/recipes/meson/config.yml b/recipes/meson/config.yml index b926152e71ae8f..785517ff377e80 100644 --- a/recipes/meson/config.yml +++ b/recipes/meson/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.1": + folder: all "1.2.0": folder: all "1.1.1": From 1023c443c01ebb21b6f20417a06fab9ab0a1c2ad Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 9 Aug 2023 03:30:59 +0200 Subject: [PATCH 0134/1140] (#19106) libgeotiff: bump deps --- recipes/libgeotiff/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libgeotiff/all/conanfile.py b/recipes/libgeotiff/all/conanfile.py index 4125b818ee21da..74323fd2d39a07 100644 --- a/recipes/libgeotiff/all/conanfile.py +++ b/recipes/libgeotiff/all/conanfile.py @@ -45,7 +45,7 @@ def layout(self): def requirements(self): # libgeotiff/include/xtiffio.h includes libtiff/include/tiffio.h self.requires("libtiff/4.5.1", transitive_headers=True, transitive_libs=True) - self.requires("proj/9.1.1") + self.requires("proj/9.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From b6bf78a15124bcf90591baa19ed89793bbe746c0 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Wed, 9 Aug 2023 08:12:27 +0200 Subject: [PATCH 0135/1140] (#19102) Add libsvtav1/1.6.0 --- recipes/libsvtav1/all/conandata.yml | 3 +++ recipes/libsvtav1/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libsvtav1/all/conandata.yml b/recipes/libsvtav1/all/conandata.yml index 74d595eb1046fb..116460d8d2500b 100644 --- a/recipes/libsvtav1/all/conandata.yml +++ b/recipes/libsvtav1/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.6.0": + url: https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v1.6.0/SVT-AV1-v1.6.0.tar.bz2 + sha256: c6b49111a2d4c5113f1ada0c2f716d94bd4a8db704623d453066826401ecdab5 "1.4.1": url: https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v1.4.1/SVT-AV1-v1.4.1.tar.bz2 sha256: 0e988582f315fe76c909accf5e7f81b975c5bd2b850ee760d8e9fac297f70b5d diff --git a/recipes/libsvtav1/config.yml b/recipes/libsvtav1/config.yml index 37cfc8825c04fd..e7e07862417048 100644 --- a/recipes/libsvtav1/config.yml +++ b/recipes/libsvtav1/config.yml @@ -1,4 +1,6 @@ versions: + "1.6.0": + folder: all "1.4.1": folder: all "1.3.0": From c4ca097e9ef0e863b04f9107b00bf767f6be6cde Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 16:09:24 +0900 Subject: [PATCH 0136/1140] (#18910) libmysqlclient: add version 8.0.34 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libmysqlclient: add version 8.0.34 * update openssl --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libmysqlclient/all/conandata.yml | 7 +++++++ recipes/libmysqlclient/all/conanfile.py | 25 +++++++++++++----------- recipes/libmysqlclient/config.yml | 2 ++ 3 files changed, 23 insertions(+), 11 deletions(-) diff --git a/recipes/libmysqlclient/all/conandata.yml b/recipes/libmysqlclient/all/conandata.yml index 7533ad1b401d84..6ace30de169748 100644 --- a/recipes/libmysqlclient/all/conandata.yml +++ b/recipes/libmysqlclient/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.0.34": + url: "https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.34.tar.gz" + sha256: "e65d03a3c42618b5fbf99042aed33209402e9b27aa62c7c8743ffd4788d8db1d" "8.0.31": url: "https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.31.tar.gz" sha256: "67bb8cba75b28e95c7f7948563f01fb84528fcbb1a35dba839d4ce44fe019baa" @@ -9,6 +12,10 @@ sources: url: "https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.25.tar.gz" sha256: "c16aa9cf621bc028efba2bb11f3c36a323b125fa0d108ff92fab60e46309206e" patches: + "8.0.34": + - patch_file: "patches/0006-fix-cpp20-build-8.0.29.patch" + patch_description: "Fix C++20 compilation" + patch_type: "portability" "8.0.31": - patch_file: "patches/0006-fix-cpp20-build-8.0.29.patch" patch_description: "Fix C++20 compilation" diff --git a/recipes/libmysqlclient/all/conanfile.py b/recipes/libmysqlclient/all/conanfile.py index 46f8df1537d5e8..ba135f46de785c 100644 --- a/recipes/libmysqlclient/all/conanfile.py +++ b/recipes/libmysqlclient/all/conanfile.py @@ -63,7 +63,7 @@ def layout(self): def requirements(self): if Version(self.version) < "8.0.30": - self.requires("openssl/1.1.1t") + self.requires("openssl/1.1.1u") else: self.requires("openssl/[>=1.1 <4]") self.requires("zlib/1.2.13") @@ -127,14 +127,14 @@ def _patch_sources(self): f"# WARN_MISSING_SYSTEM_{lib.upper()}({lib.upper()}_WARN_GIVEN)", strict=False) - replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), - f"SET({lib.upper()}_WARN_GIVEN)", - f"# SET({lib.upper()}_WARN_GIVEN)", - strict=False) + if lib != "libevent" or Version(self.version) < "8.0.34": + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + f"SET({lib.upper()}_WARN_GIVEN)", + f"# SET({lib.upper()}_WARN_GIVEN)", + strict=False) rmdir(self, os.path.join(self.source_folder, "extra")) for folder in ["client", "man", "mysql-test", "libbinlogstandalone"]: - rmdir(self, os.path.join(self.source_folder, folder)) replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), f"ADD_SUBDIRECTORY({folder})\n", "", @@ -147,9 +147,10 @@ def _patch_sources(self): strict=False) # Upstream does not actually load lz4 directories for system, force it to - replace_in_file(self, os.path.join(self.source_folder, "libbinlogevents", "CMakeLists.txt"), - "INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/libbinlogevents/include)", - "MY_INCLUDE_SYSTEM_DIRECTORIES(LZ4)\nINCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/libbinlogevents/include)") + if Version(self.version) < "8.0.34": + replace_in_file(self, os.path.join(self.source_folder, "libbinlogevents", "CMakeLists.txt"), + "INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/libbinlogevents/include)", + "MY_INCLUDE_SYSTEM_DIRECTORIES(LZ4)\nINCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/libbinlogevents/include)") replace_in_file(self, os.path.join(self.source_folder, "cmake", "zstd.cmake"), "NAMES zstd", @@ -180,7 +181,9 @@ def _patch_sources(self): "if(0)") # Do not copy shared libs of dependencies to package folder - deps_shared = ["SSL", "KERBEROS", "SASL", "LDAP", "PROTOBUF", "CURL"] + deps_shared = ["SSL", "KERBEROS", "SASL", "LDAP", "PROTOBUF"] + if Version(self.version) < "8.0.34": + deps_shared.append("CURL") for dep in deps_shared: replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), f"MYSQL_CHECK_{dep}_DLLS()", @@ -211,7 +214,7 @@ def generate(self): tc.cache_variables["ENABLED_PROFILING"] = False tc.cache_variables["MYSQL_MAINTAINER_MODE"] = False tc.cache_variables["WIX_DIR"] = False - # Disable additional Linux distro-specific compiler checks. + # Disable additional Linux distro-specific compiler checks. # The recipe already checks for minimum versions of supported # compilers. tc.cache_variables["FORCE_UNSUPPORTED_COMPILER"] = True diff --git a/recipes/libmysqlclient/config.yml b/recipes/libmysqlclient/config.yml index d2183e51a5f3cd..7df89d243f4953 100644 --- a/recipes/libmysqlclient/config.yml +++ b/recipes/libmysqlclient/config.yml @@ -1,4 +1,6 @@ versions: + "8.0.34": + folder: all "8.0.31": folder: all "8.0.30": From 3d75d65d19ee7e406f669a51ff40e8ffac208efe Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 9 Aug 2023 09:48:30 +0200 Subject: [PATCH 0137/1140] (#18697) qt 6.5.2 * qt 6.5.2 generated with: conan config install https://github.com/conan-io/conan-extensions.git conan cci:upgrade-qt-recipe 6.5.2 * remove qt 6.4.1 --- recipes/qt/6.x.x/conandata.yml | 39 +-- recipes/qt/6.x.x/patches/3801bba82.patch | 27 -- recipes/qt/6.x.x/qtmodules6.5.2.conf | 331 +++++++++++++++++++++++ recipes/qt/config.yml | 4 +- 4 files changed, 347 insertions(+), 54 deletions(-) delete mode 100644 recipes/qt/6.x.x/patches/3801bba82.patch create mode 100644 recipes/qt/6.x.x/qtmodules6.5.2.conf diff --git a/recipes/qt/6.x.x/conandata.yml b/recipes/qt/6.x.x/conandata.yml index fc7a158ca95177..ed9afdd80458b9 100644 --- a/recipes/qt/6.x.x/conandata.yml +++ b/recipes/qt/6.x.x/conandata.yml @@ -1,4 +1,14 @@ sources: + "6.5.2": + url: + - "https://download.qt.io/official_releases/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://download.qt.io/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://mirrors.ukfast.co.uk/sites/qt.io/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://qt-mirror.dannhauer.de/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://master.qt.io/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://www.nic.funet.fi/pub/mirrors/download.qt-project.org/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + - "https://mirrors.sjtug.sjtu.edu.cn/qt/archive/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" + sha256: "cde57be663d0f875759797298bdc37a936d517c39f2013e4e6ece5e12edeed12" "6.5.1": url: - "https://download.qt.io/official_releases/qt/6.5/6.5.1/single/qt-everywhere-src-6.5.1.tar.xz" @@ -45,14 +55,6 @@ sources: - "https://ftp.fau.de/qtproject/archive/qt/6.4/6.4.2/single/qt-everywhere-src-6.4.2.tar.xz" - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/6.4/6.4.2/single/qt-everywhere-src-6.4.2.tar.xz" sha256: "689f53e6652da82fccf7c2ab58066787487339f28d1ec66a8765ad357f4976be" - "6.4.1": - url: - - "https://download.qt.io/archive/qt/6.4/6.4.1/single/qt-everywhere-src-6.4.1.tar.xz" - - "https://qt-mirror.dannhauer.de/archive/qt/6.4/6.4.1/single/qt-everywhere-src-6.4.1.tar.xz" - - "https://www.funet.fi/pub/mirrors/download.qt-project.org/archive/qt/6.4/6.4.1/single/qt-everywhere-src-6.4.1.tar.xz" - - "https://ftp.fau.de/qtproject/archive/qt/6.4/6.4.1/single/qt-everywhere-src-6.4.1.tar.xz" - - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/6.4/6.4.1/single/qt-everywhere-src-6.4.1.tar.xz" - sha256: "e20b850b6134098a7f2e7701cfddfb213c6cf394b9e848e6fbc5b0e89dcfcc09" "6.3.2": url: - "https://download.qt.io/archive/qt/6.3/6.3.2/single/qt-everywhere-src-6.3.2.tar.xz" @@ -62,6 +64,10 @@ sources: - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/6.3/6.3.2/single/qt-everywhere-src-6.3.2.tar.xz" sha256: "b90524f686224a0e5a945c1d65307e16a375348dbe275c9ac11de171fe31374a" patches: + "6.5.2": + - "base_path": "qtwebengine" + "patch_description": "Workaround for too long .rps file name" + "patch_file": "patches/c72097e.diff" "6.5.1": - base_path: "qtwebengine" patch_description: "Workaround for too long .rps file name" @@ -88,23 +94,6 @@ patches: patch_description: "Fix PCRE2 detection" patch_type: "bugfix" patch_source: "https://codereview.qt-project.org/c/qt/qtbase/+/445885" - "6.4.1": - - base_path: "qtbase/cmake" - patch_description: "Fix pri helpers" - patch_file: "patches/qt6-pri-helpers-fix.diff" - - patch_file: "patches/c72097e.diff" - base_path: "qtwebengine" - patch_description: "Workaround for too long .rps file name" - - patch_file: "patches/d13958d.diff" - base_path: "qtbase" - patch_description: "Fix PCRE2 detection" - patch_type: "bugfix" - patch_source: "https://codereview.qt-project.org/c/qt/qtbase/+/445885" - - patch_file: "patches/3801bba82.patch" - base_path: "qtwebengine/src/3rdparty" - patch_description: "fix qtwebengine with MSVC2022" - patch_type: "portability" - patch_source: "https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/444132" "6.3.2": - base_path: "qtbase/cmake" patch_description: "Fix pri helpers" diff --git a/recipes/qt/6.x.x/patches/3801bba82.patch b/recipes/qt/6.x.x/patches/3801bba82.patch deleted file mode 100644 index 79b347ce90a23b..00000000000000 --- a/recipes/qt/6.x.x/patches/3801bba82.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 3801bba822bf88c202a348d3e01dd493c0ca0551 Mon Sep 17 00:00:00 2001 -From: Nadim Asaduzzaman -Date: Fri, 18 Nov 2022 04:34:38 -0700 -Subject: [PATCH] skia: fix compilation with MSVC2022 - -compilation with MSVC2022 failed due to missing string definition within std namespace - -Fixes: QTBUG-108532 -Change-Id: I2119952d5809895e2511ce1c2c262022af3ba191 -Reviewed-on: https://codereview.qt-project.org/c/qt/qtwebengine-chromium/+/444132 -Reviewed-by: Allan Sandfeld Jensen ---- - chromium/third_party/skia/src/core/SkShaderCodeDictionary.h | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/chromium/third_party/skia/src/core/SkShaderCodeDictionary.h b/chromium/third_party/skia/src/core/SkShaderCodeDictionary.h -index 3a54bbe22e7..8612a469862 100644 ---- a/chromium/third_party/skia/src/core/SkShaderCodeDictionary.h -+++ b/chromium/third_party/skia/src/core/SkShaderCodeDictionary.h -@@ -9,6 +9,7 @@ - #define SkShaderCodeDictionary_DEFINED - - #include -+#include - #include - #include - #include "include/core/SkSpan.h" diff --git a/recipes/qt/6.x.x/qtmodules6.5.2.conf b/recipes/qt/6.x.x/qtmodules6.5.2.conf new file mode 100644 index 00000000000000..b8053b7bdfcc3c --- /dev/null +++ b/recipes/qt/6.x.x/qtmodules6.5.2.conf @@ -0,0 +1,331 @@ +[submodule "qtbase"] + path = qtbase + url = ../qtbase.git + branch = 6.5.2 + status = essential +[submodule "qtsvg"] + depends = qtbase + path = qtsvg + url = ../qtsvg.git + branch = 6.5.2 + status = addon +[submodule "qtdeclarative"] + depends = qtbase + recommends = qtimageformats qtshadertools qtsvg qtlanguageserver + path = qtdeclarative + url = ../qtdeclarative.git + branch = 6.5.2 + status = essential +[submodule "qtactiveqt"] + depends = qtbase + path = qtactiveqt + url = ../qtactiveqt.git + branch = 6.5.2 + status = addon +[submodule "qtmultimedia"] + depends = qtbase qtshadertools + recommends = qtdeclarative qtquick3d + path = qtmultimedia + url = ../qtmultimedia.git + branch = 6.5.2 + status = addon +[submodule "qttools"] + depends = qtbase + recommends = qtdeclarative qtactiveqt + path = qttools + url = ../qttools.git + branch = 6.5.2 + status = essential +[submodule "qtxmlpatterns"] + depends = qtbase + recommends = qtdeclarative + path = qtxmlpatterns + url = ../qtxmlpatterns.git + branch = dev + status = ignore +[submodule "qttranslations"] + depends = qttools + path = qttranslations + url = ../qttranslations.git + branch = 6.5.2 + status = essential + priority = 30 +[submodule "qtdoc"] + depends = qtdeclarative qttools + recommends = qtmultimedia qtshadertools qtwebengine + path = qtdoc + url = ../qtdoc.git + branch = 6.5.2 + status = essential + priority = 40 +[submodule "qtrepotools"] + path = qtrepotools + url = ../qtrepotools.git + branch = master + status = essential + project = - +[submodule "qtqa"] + depends = qtbase + path = qtqa + url = ../qtqa.git + branch = dev + status = essential + priority = 50 +[submodule "qtlocation"] + depends = qtbase qtpositioning + recommends = qtdeclarative + path = qtlocation + url = ../qtlocation.git + branch = 6.5.2 + status = preview +[submodule "qtpositioning"] + depends = qtbase + recommends = qtdeclarative qtserialport + path = qtpositioning + url = ../qtpositioning.git + branch = 6.5.2 + status = addon +[submodule "qtsensors"] + depends = qtbase + recommends = qtdeclarative + path = qtsensors + url = ../qtsensors.git + branch = 6.5.2 + status = addon +[submodule "qtsystems"] + depends = qtbase + recommends = qtdeclarative + path = qtsystems + url = ../qtsystems.git + branch = dev + status = ignore +[submodule "qtfeedback"] + depends = qtdeclarative + recommends = qtmultimedia + path = qtfeedback + url = ../qtfeedback.git + branch = master + status = ignore +[submodule "qtpim"] + depends = qtdeclarative + path = qtpim + url = ../qtpim.git + branch = dev + status = ignore +[submodule "qtconnectivity"] + depends = qtbase + recommends = qtdeclarative + path = qtconnectivity + url = ../qtconnectivity.git + branch = 6.5.2 + status = addon +[submodule "qtwayland"] + depends = qtbase + recommends = qtdeclarative + path = qtwayland + url = ../qtwayland.git + branch = 6.5.2 + status = addon +[submodule "qt3d"] + depends = qtbase + recommends = qtdeclarative qtshadertools + path = qt3d + url = ../qt3d.git + branch = 6.5.2 + status = addon +[submodule "qtimageformats"] + depends = qtbase + path = qtimageformats + url = ../qtimageformats.git + branch = 6.5.2 + status = addon +[submodule "qtserialbus"] + depends = qtbase + recommends = qtserialport + path = qtserialbus + url = ../qtserialbus.git + branch = 6.5.2 + status = addon +[submodule "qtserialport"] + depends = qtbase + path = qtserialport + url = ../qtserialport.git + branch = 6.5.2 + status = addon +[submodule "qtwebsockets"] + depends = qtbase + recommends = qtdeclarative + path = qtwebsockets + url = ../qtwebsockets.git + branch = 6.5.2 + status = addon +[submodule "qtwebchannel"] + depends = qtbase + recommends = qtdeclarative qtwebsockets + path = qtwebchannel + url = ../qtwebchannel.git + branch = 6.5.2 + status = addon +[submodule "qtwebengine"] + depends = qtdeclarative + recommends = qtwebchannel qttools qtpositioning + path = qtwebengine + url = ../qtwebengine.git + branch = 6.5.2 + status = addon + priority = 10 +[submodule "qtcanvas3d"] + depends = qtdeclarative + path = qtcanvas3d + url = ../qtcanvas3d.git + branch = dev + status = ignore +[submodule "qtwebview"] + depends = qtdeclarative + recommends = qtwebengine + path = qtwebview + url = ../qtwebview.git + branch = 6.5.2 + status = addon +[submodule "qtcharts"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtcharts + url = ../qtcharts.git + branch = 6.5.2 + status = addon +[submodule "qtdatavis3d"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtdatavis3d + url = ../qtdatavis3d.git + branch = 6.5.2 + status = addon +[submodule "qtvirtualkeyboard"] + depends = qtbase qtdeclarative qtsvg + recommends = qtmultimedia + path = qtvirtualkeyboard + url = ../qtvirtualkeyboard.git + branch = 6.5.2 + status = addon +[submodule "qtgamepad"] + depends = qtbase + recommends = qtdeclarative + path = qtgamepad + url = ../qtgamepad.git + branch = dev + status = ignore +[submodule "qtscxml"] + depends = qtbase qtdeclarative + path = qtscxml + url = ../qtscxml.git + branch = 6.5.2 + status = addon +[submodule "qtspeech"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtspeech + url = ../qtspeech.git + branch = 6.5.2 + status = addon +[submodule "qtnetworkauth"] + depends = qtbase + path = qtnetworkauth + url = ../qtnetworkauth.git + branch = 6.5.2 + status = addon +[submodule "qtremoteobjects"] + depends = qtbase + recommends = qtdeclarative + path = qtremoteobjects + url = ../qtremoteobjects.git + branch = 6.5.2 + status = addon +[submodule "qtwebglplugin"] + depends = qtbase qtwebsockets + recommends = qtdeclarative + path = qtwebglplugin + url = ../qtwebglplugin.git + branch = dev + status = ignore +[submodule "qtlottie"] + depends = qtbase qtdeclarative + path = qtlottie + url = ../qtlottie.git + branch = 6.5.2 + status = addon +[submodule "qtquicktimeline"] + depends = qtbase qtdeclarative + path = qtquicktimeline + url = ../qtquicktimeline + branch = 6.5.2 + status = addon +[submodule "qtquick3d"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquicktimeline + path = qtquick3d + url = ../qtquick3d.git + branch = 6.5.2 + status = addon +[submodule "qtshadertools"] + depends = qtbase + path = qtshadertools + url = ../qtshadertools.git + branch = 6.5.2 + status = addon +[submodule "qt5compat"] + depends = qtbase qtdeclarative + path = qt5compat + url = ../qt5compat.git + branch = 6.5.2 + status = deprecated +[submodule "qtcoap"] + depends = qtbase + path = qtcoap + url = ../qtcoap.git + branch = 6.5.2 + status = addon +[submodule "qtmqtt"] + depends = qtbase qtdeclarative + path = qtmqtt + url = ../qtmqtt.git + branch = 6.5.2 + status = addon +[submodule "qtopcua"] + depends = qtbase qtdeclarative + path = qtopcua + url = ../qtopcua.git + branch = 6.5.2 + status = addon +[submodule "qtlanguageserver"] + depends = qtbase + path = qtlanguageserver + url = ../qtlanguageserver.git + branch = 6.5.2 + status = preview +[submodule "qthttpserver"] + depends = qtbase + recommends = qtwebsockets + path = qthttpserver + url = ../qthttpserver.git + branch = 6.5.2 + status = preview +[submodule "qtquick3dphysics"] + depends = qtbase qtdeclarative qtquick3d qtshadertools + path = qtquick3dphysics + url = ../qtquick3dphysics.git + branch = 6.5.2 + status = addon +[submodule "qtgrpc"] + depends = qtbase + path = qtgrpc + url = ../qtgrpc.git + branch = 6.5.2 + status = preview +[submodule "qtquickeffectmaker"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquick3d + path = qtquickeffectmaker + url = ../qtquickeffectmaker.git + branch = 6.5.2 + status = addon diff --git a/recipes/qt/config.yml b/recipes/qt/config.yml index 84b51c6e98dab4..6d034f7e112276 100644 --- a/recipes/qt/config.yml +++ b/recipes/qt/config.yml @@ -1,12 +1,12 @@ versions: + "6.5.2": + folder: 6.x.x "6.5.1": folder: 6.x.x "6.5.0": folder: 6.x.x "6.4.2": folder: 6.x.x - "6.4.1": - folder: 6.x.x "6.3.2": folder: 6.x.x "5.15.10": From afaedf634cf90bd11e9a52c60e4198d88cbe6630 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 17:39:28 +0930 Subject: [PATCH 0138/1140] [aaf] Use util-linux-libuuid instead of deprecated libuuid (#18556) Use `util-linux-libuuid` instead of deprecated `libuuid`. --- recipes/aaf/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/aaf/all/conanfile.py b/recipes/aaf/all/conanfile.py index 080c644424a04b..ee7906ff059366 100644 --- a/recipes/aaf/all/conanfile.py +++ b/recipes/aaf/all/conanfile.py @@ -38,7 +38,7 @@ def requirements(self): self.requires("expat/2.5.0") self.requires("libjpeg/9e") if self.settings.os in ("FreeBSD", "Linux"): - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From ab7f4e22e80b47c346c9f4b855dbc09de43889cc Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 17:51:32 +0930 Subject: [PATCH 0139/1140] [azure-storage-cpp] Use util-linux-libuuid instead of deprecated libuuid (#18557) Use util-linux-libuuid instead of deprecated libuuid (#18557), see issue #19084 --- recipes/azure-storage-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/azure-storage-cpp/all/conanfile.py b/recipes/azure-storage-cpp/all/conanfile.py index 692bc2ab703fed..92f05a255ac83f 100644 --- a/recipes/azure-storage-cpp/all/conanfile.py +++ b/recipes/azure-storage-cpp/all/conanfile.py @@ -51,7 +51,7 @@ def requirements(self): if self.settings.os != "Windows": self.requires("boost/1.76.0") self.requires("libxml2/2.9.10") - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") if self.settings.os == "Macos": self.requires("libgettext/0.20.1") From 32e7f51732d62e0fee383f3417a20a64a065cf07 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 17:58:32 +0930 Subject: [PATCH 0140/1140] [cppcommon] Use util-linux-libuuid instead of deprecated libuuid (#18553) Use util-linux-libuuid instead of deprecated libuuid (#18553), see issue #19084 --- recipes/cppcommon/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cppcommon/all/conanfile.py b/recipes/cppcommon/all/conanfile.py index c289f88e777b01..31e78b570dc50a 100644 --- a/recipes/cppcommon/all/conanfile.py +++ b/recipes/cppcommon/all/conanfile.py @@ -64,7 +64,7 @@ def requirements(self): else: self.requires("fmt/10.0.0") if self.settings.os == "Linux": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") def validate(self): if self.settings.compiler.cppstd: From e3c7fb70d7ebd2582bf1034dbf1e9c729dba376f Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 18:21:05 +0930 Subject: [PATCH 0141/1140] [czmq] Use util-linux-libuuid instead of deprecated libuuid (#18552) * [czmq] Use util-linux-libuuid instead of deprecated libuuid * czmq: add transitive headers for zeromq --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/czmq/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/czmq/all/conanfile.py b/recipes/czmq/all/conanfile.py index 88618f4797ed7c..1ea4a28e1852a5 100644 --- a/recipes/czmq/all/conanfile.py +++ b/recipes/czmq/all/conanfile.py @@ -62,7 +62,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zeromq/4.3.4") + self.requires("zeromq/4.3.4", transitive_headers=True) if self.options.get_safe("with_libmicrohttpd"): self.requires("libmicrohttpd/0.9.75") if self.options.get_safe("with_libcurl"): @@ -70,7 +70,7 @@ def requirements(self): if self.options.with_lz4: self.requires("lz4/1.9.4") if self.options.get_safe("with_libuuid"): - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") if self.options.get_safe("with_systemd"): self.requires("libsystemd/252.4") From 4aa57795d3fde534ab1f3d45ebe36ecbbf0ea74a Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 18:39:23 +0930 Subject: [PATCH 0142/1140] [drogon] Use util-linux-libuuid instead of deprecated libuuid (#18555) --- recipes/drogon/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index 80dc0d02645002..0b84047ab4ed5f 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -113,7 +113,7 @@ def requirements(self): self.requires("openssl/[>=1.1 <4]") self.requires("zlib/1.2.13") if self.settings.os == "Linux": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") if self.options.with_profile: self.requires("coz/cci.20210322") if self.options.with_boost: From 201d8e3ee0d1dca10c89450ae5a72da2dbbdace6 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 19:04:39 +0930 Subject: [PATCH 0143/1140] [fontconfig] Use util-linux-libuuid instead of deprecated libuuid (#18550) --- recipes/fontconfig/all/conanfile.py | 2 +- recipes/fontconfig/meson/conanfile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/fontconfig/all/conanfile.py b/recipes/fontconfig/all/conanfile.py index c44276116659f5..1a6adb5ab1e225 100644 --- a/recipes/fontconfig/all/conanfile.py +++ b/recipes/fontconfig/all/conanfile.py @@ -50,7 +50,7 @@ def requirements(self): self.requires("freetype/2.13.0") self.requires("expat/2.5.0") if self.settings.os == "Linux": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") def validate(self): if is_msvc(self): diff --git a/recipes/fontconfig/meson/conanfile.py b/recipes/fontconfig/meson/conanfile.py index dc1462585f4ec2..54997946cfcf63 100644 --- a/recipes/fontconfig/meson/conanfile.py +++ b/recipes/fontconfig/meson/conanfile.py @@ -52,7 +52,7 @@ def requirements(self): self.requires("freetype/2.13.0") self.requires("expat/2.5.0") if self.settings.os == "Linux": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") def build_requirements(self): self.tool_requires("gperf/3.1") From f0239e2af1f3a809b2d4722a633e491009624d57 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 19:18:26 +0930 Subject: [PATCH 0144/1140] [stduuid] Use util-linux-libuuid instead of deprecated libuuid (#18549) --- recipes/stduuid/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/stduuid/all/conanfile.py b/recipes/stduuid/all/conanfile.py index f5148b86a236f4..0ca3e6b2dcb08d 100644 --- a/recipes/stduuid/all/conanfile.py +++ b/recipes/stduuid/all/conanfile.py @@ -46,7 +46,7 @@ def requirements(self): if not self.options.with_cxx20_span: self.requires("ms-gsl/3.1.0", transitive_headers=True) if self.settings.os == "Linux" and Version(self.version) <= "1.0": - self.requires("libuuid/1.0.3", transitive_headers=True, transitive_libs=True) + self.requires("util-linux-libuuid/2.39", transitive_headers=True, transitive_libs=True) def package_id(self): self.info.clear() From c189ba416c4a028329ccf26b07c3653a174ce62e Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Wed, 9 Aug 2023 19:30:13 +0930 Subject: [PATCH 0145/1140] [xapian-core] Use util-linux-libuuid instead of deprecated libuuid (#18551) --- recipes/xapian-core/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/xapian-core/all/conanfile.py b/recipes/xapian-core/all/conanfile.py index f2cc68f3f1bd4e..f4278ec4f019a0 100644 --- a/recipes/xapian-core/all/conanfile.py +++ b/recipes/xapian-core/all/conanfile.py @@ -56,7 +56,7 @@ def layout(self): def requirements(self): self.requires("zlib/1.2.13") if self.settings.os != "Windows": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") def validate(self): if self.options.shared and self.settings.os == "Windows": From 48de38e7fef219370afc1a712a8e74a618599401 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 19:17:09 +0900 Subject: [PATCH 0146/1140] libcurl: add version 8.2.1 (#18923) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/libcurl/all/conandata.yml | 3 +++ recipes/libcurl/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libcurl/all/conandata.yml b/recipes/libcurl/all/conandata.yml index fa48006c6d92ff..e0c9dcbbb24845 100644 --- a/recipes/libcurl/all/conandata.yml +++ b/recipes/libcurl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.2.1": + url: "https://curl.se/download/curl-8.2.1.tar.gz" + sha256: "f98bdb06c0f52bdd19e63c4a77b5eb19b243bcbbd0f5b002b9f3cba7295a3a42" "8.2.0": url: "https://curl.se/download/curl-8.2.0.tar.gz" sha256: "c67849462d171a3fee08b605cdd837d18ee22ecc3ee2c6a0393c9cec5d1a137e" diff --git a/recipes/libcurl/config.yml b/recipes/libcurl/config.yml index 29dfe667599fa6..91b7536f966b4b 100644 --- a/recipes/libcurl/config.yml +++ b/recipes/libcurl/config.yml @@ -1,4 +1,6 @@ versions: + "8.2.1": + folder: all "8.2.0": folder: all "8.1.2": From 78a9ff7d0feb0035cf9905337769ce6b2acea0d7 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 9 Aug 2023 12:39:47 +0200 Subject: [PATCH 0147/1140] Update list of references (prod-v2/ListPackages) (#19109) --- .c3i/conan_v2_ready_references.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index fdcbe4b81dbb26..0b338c3849bddf 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -224,6 +224,7 @@ required_for_references: - dbus - debug_assert - decimal_for_cpp +- di - dice-template-library - dirent - discount @@ -668,6 +669,7 @@ required_for_references: - mcap - md4c - md4qt +- mdns - mdnsresponder - mdspan - meshoptimizer @@ -934,6 +936,7 @@ required_for_references: - sfml - shapelib - shield +- si - sigslot - simde - simdjson From 3fe4c9fa39d87e5ef9604938aa1590eeda49e1fe Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 19:42:47 +0900 Subject: [PATCH 0148/1140] leptonica: add version 1.83.1, update libjpeg-turbo (#19101) --- recipes/leptonica/all/conandata.yml | 3 +++ recipes/leptonica/all/conanfile.py | 4 ++-- recipes/leptonica/config.yml | 2 ++ 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/recipes/leptonica/all/conandata.yml b/recipes/leptonica/all/conandata.yml index 2902df5b0c405c..49782e81d8fcd3 100644 --- a/recipes/leptonica/all/conandata.yml +++ b/recipes/leptonica/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.83.1": + url: "https://github.com/DanBloomberg/leptonica/archive/1.83.1.tar.gz" + sha256: "4289d0a4224b614010072253531c0455a33a4d7c7a0017fe7825ed382290c0da" "1.83.0": url: "https://github.com/DanBloomberg/leptonica/archive/1.83.0.tar.gz" sha256: "14cf531c2219a1414e8e3c51a3caa5cf021a52e782c4a6561bf64d0ef2119282" diff --git a/recipes/leptonica/all/conanfile.py b/recipes/leptonica/all/conanfile.py index 405081e59b3848..d072baae99b619 100644 --- a/recipes/leptonica/all/conanfile.py +++ b/recipes/leptonica/all/conanfile.py @@ -72,7 +72,7 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") if self.options.with_png: @@ -87,7 +87,7 @@ def requirements(self): def build_requirements(self): if self.options.with_webp or self.options.with_openjpeg: if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/leptonica/config.yml b/recipes/leptonica/config.yml index 36297367918ece..7de53a77a39165 100644 --- a/recipes/leptonica/config.yml +++ b/recipes/leptonica/config.yml @@ -1,4 +1,6 @@ versions: + "1.83.1": + folder: all "1.83.0": folder: all "1.82.0": From e05300c58b46b5dd6b929315b9d371243e776789 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Wed, 9 Aug 2023 15:36:37 +0400 Subject: [PATCH 0149/1140] [onetbb] added hwloc / tbbbind support (#17939) --- recipes/onetbb/all/conandata.yml | 6 ++ recipes/onetbb/all/conanfile.py | 45 +++++++++ ...pkg-search-module-use-imported-target.diff | 97 +++++++++++++++++++ 3 files changed, 148 insertions(+) create mode 100644 recipes/onetbb/all/patches/pkg-search-module-use-imported-target.diff diff --git a/recipes/onetbb/all/conandata.yml b/recipes/onetbb/all/conandata.yml index 9ccf39c2f9dca4..880145b4a46b00 100644 --- a/recipes/onetbb/all/conandata.yml +++ b/recipes/onetbb/all/conandata.yml @@ -35,3 +35,9 @@ patches: patch_type: "portability" patch_source: "https://github.com/oneapi-src/oneTBB/pull/716.diff" patch_file: "patches/fix-overeager-stripping-of-compile-flag.diff" + - patch_description: "Use pkg_search_module with IMPORTED_TARGET" + patch_type: "portability" + patch_source: + - "https://github.com/oneapi-src/oneTBB/pull/448.diff" + - "https://github.com/oneapi-src/oneTBB/commit/df3096075a00942acbdd3ce9347f5298cc153fd6.diff" + patch_file: "patches/pkg-search-module-use-imported-target.diff" diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index 09962736783658..165436b84b383b 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -1,7 +1,9 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration +from conan.tools.build import cross_building from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, load, rmdir +from conan.tools.gnu import PkgConfigDeps from conan.tools.scm import Version import os import re @@ -26,6 +28,7 @@ class OneTBBConan(ConanFile): "fPIC": [True, False], "tbbmalloc": [True, False], "tbbproxy": [True, False], + "tbbbind": [True, False], "interprocedural_optimization": [True, False], } default_options = { @@ -33,15 +36,37 @@ class OneTBBConan(ConanFile): "fPIC": True, "tbbmalloc": True, "tbbproxy": True, + "tbbbind": True, "interprocedural_optimization": True, } + @property + def _tbbbind_hwloc_version(self): + # TBB expects different variables depending on the version + return "2_5" if Version(self.version) >= "2021.4.0" else "2_4" + + @property + def _tbbbind_supported(self): + return Version(self.version) >= "2021.1.1" and not self.settings.os == "Macos" + + @property + def _tbbbind_build(self): + return self.options.get_safe("tbbbind", False) and self._tbbbind_supported + + @property + def _tbbbind_explicit_hwloc(self): + # during cross-compilation, oneTBB does not search for HWLOC and we need to specify it explicitly + # but then oneTBB creates an imported SHARED target from provided paths, so we have to set shared=True + return self._tbbbind_build and cross_building(self) + def export_sources(self): export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if not self._tbbbind_supported: + del self.options.tbbbind if Version(self.version) < "2021.6.0" or self.settings.os == "Android": del self.options.interprocedural_optimization if Version(self.version) < "2021.2.0": @@ -53,8 +78,15 @@ def configure(self): self.options.rm_safe("fPIC") else: del self.options.tbbproxy + self.options.rm_safe("tbbbind") if not self.options.tbbmalloc: self.options.rm_safe("tbbproxy") + if self._tbbbind_explicit_hwloc: + self.options["hwloc"].shared = True + + def requirements(self): + if self._tbbbind_build: + self.requires("hwloc/2.9.1") def layout(self): cmake_layout(self, src_folder="src") @@ -76,6 +108,8 @@ def validate_build(self): "Please consider fixing at least the aforementioned issue in upstream." ) self.output.warning("oneTBB strongly discourages usage of static linkage") + if self._tbbbind_explicit_hwloc and not self.dependencies["hwloc"].options.shared: + raise ConanInvalidConfiguration(f"{self.ref} requires hwloc:shared=True to be built.") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -90,6 +124,17 @@ def generate(self): toolchain.variables["TBB_ENABLE_IPO"] = self.options.interprocedural_optimization if Version(self.version) >= "2021.6.0" and self.options.get_safe("tbbproxy"): toolchain.variables["TBBMALLOC_PROXY_BUILD"] = self.options.tbbproxy + toolchain.variables["TBB_DISABLE_HWLOC_AUTOMATIC_SEARCH"] = not self._tbbbind_build + if self._tbbbind_build: + deps = PkgConfigDeps(self) + deps.generate() + if self._tbbbind_explicit_hwloc: + hwloc_package_folder = self.dependencies["hwloc"].package_folder.replace("\\", "/") + hwloc_lib_name = "hwloc.lib" if self.settings.os == "Windows" else "libhwloc.so" + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_LIBRARY_PATH"] = os.path.join(hwloc_package_folder, "lib", hwloc_lib_name) + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_INCLUDE_PATH"] = os.path.join(hwloc_package_folder, "include") + if self.settings.os == "Windows": + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_DLL_PATH"] = os.path.join(hwloc_package_folder, "bin", "hwloc.dll") toolchain.generate() def build(self): diff --git a/recipes/onetbb/all/patches/pkg-search-module-use-imported-target.diff b/recipes/onetbb/all/patches/pkg-search-module-use-imported-target.diff new file mode 100644 index 00000000000000..e1a3505708cbad --- /dev/null +++ b/recipes/onetbb/all/patches/pkg-search-module-use-imported-target.diff @@ -0,0 +1,97 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 34a23d40..d569d57e 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -100,6 +100,8 @@ option(TBB_NO_APPCONTAINER "Apply /APPCONTAINER:NO (for testing binaries for Win + option(TBB4PY_BUILD "Enable tbb4py build" OFF) + option(TBB_CPF "Enable preview features of the library" OFF) + option(TBB_FIND_PACKAGE "Enable search for external oneTBB using find_package instead of build from sources" OFF) ++option(TBB_DISABLE_HWLOC_AUTOMATIC_SEARCH "Disable HWLOC automatic search by pkg-config tool" OFF) ++ + + if (NOT DEFINED BUILD_SHARED_LIBS) + set(BUILD_SHARED_LIBS ON) +@@ -194,7 +196,7 @@ else() + if (NOT "${CMAKE_SYSTEM_PROCESSOR}" MATCHES "mips") + add_subdirectory(src/tbbmalloc) + add_subdirectory(src/tbbmalloc_proxy) +- if (APPLE) ++ if (APPLE OR NOT BUILD_SHARED_LIBS) + message(STATUS "TBBBind build target is disabled due to unsupported environment") + else() + add_subdirectory(src/tbbbind) +diff --git a/cmake/hwloc_detection.cmake b/cmake/hwloc_detection.cmake +index f1740662..e1806a0f 100644 +--- a/cmake/hwloc_detection.cmake ++++ b/cmake/hwloc_detection.cmake +@@ -45,11 +45,15 @@ endforeach() + + unset(HWLOC_TARGET_NAME) + +-if (NOT HWLOC_TARGET_EXPLICITLY_DEFINED) ++if (NOT HWLOC_TARGET_EXPLICITLY_DEFINED AND ++ # No hwloc auto detection for cross compilation ++ NOT CMAKE_CROSSCOMPILING AND ++ NOT TBB_DISABLE_HWLOC_AUTOMATIC_SEARCH ++) + find_package(PkgConfig QUIET) +- if (PKG_CONFIG_FOUND) +- pkg_search_module(HWLOC hwloc) +- if (HWLOC_FOUND) ++ if (PKG_CONFIG_FOUND AND NOT CMAKE_VERSION VERSION_LESS 3.6) ++ pkg_search_module(HWLOC hwloc IMPORTED_TARGET) ++ if (TARGET PkgConfig::HWLOC) + if (HWLOC_VERSION VERSION_LESS 2) + set(TBBBIND_LIBRARY_NAME tbbbind) + elseif(HWLOC_VERSION VERSION_LESS 2.4) +@@ -60,4 +64,3 @@ if (NOT HWLOC_TARGET_EXPLICITLY_DEFINED) + endif() + endif() + endif() +- +diff --git a/src/tbbbind/CMakeLists.txt b/src/tbbbind/CMakeLists.txt +index da9dabfe..1a4c6ca0 100644 +--- a/src/tbbbind/CMakeLists.txt ++++ b/src/tbbbind/CMakeLists.txt +@@ -18,12 +18,13 @@ endif() + set(CMAKE_SKIP_BUILD_RPATH TRUE) + + function(tbbbind_build TBBBIND_NAME REQUIRED_HWLOC_TARGET) +- if (NOT TARGET ${REQUIRED_HWLOC_TARGET} AND NOT DEFINED HWLOC_LIBRARIES) ++ if (NOT TARGET ${REQUIRED_HWLOC_TARGET}) + message(STATUS "HWLOC target ${REQUIRED_HWLOC_TARGET} doesn't exist." + " The ${TBBBIND_NAME} target cannot be created") + return() + endif() + add_library(${TBBBIND_NAME} tbb_bind.cpp) ++ + add_library(TBB::${TBBBIND_NAME} ALIAS ${TBBBIND_NAME}) + + target_compile_definitions(${TBBBIND_NAME} +@@ -64,14 +65,12 @@ function(tbbbind_build TBBBIND_NAME REQUIRED_HWLOC_TARGET) + PRIVATE + ${TBB_LIB_LINK_FLAGS} + ${TBB_COMMON_LINK_FLAGS} +- ${HWLOC_LIBRARY_DIRS} # pkg-config defined + ) + else() + target_link_libraries(${TBBBIND_NAME} + PRIVATE + ${TBB_LIB_LINK_FLAGS} + ${TBB_COMMON_LINK_FLAGS} +- ${HWLOC_LIBRARY_DIRS} # pkg-config defined + ) + endif() + +@@ -90,9 +89,9 @@ function(tbbbind_build TBBBIND_NAME REQUIRED_HWLOC_TARGET) + endif() + endfunction() + +-if (NOT DEFINED HWLOC_TARGET_EXPLICITLY_DEFINED AND DEFINED HWLOC_LIBRARIES) ++if (NOT DEFINED HWLOC_TARGET_EXPLICITLY_DEFINED AND TARGET PkgConfig::HWLOC) + message(STATUS "The ${TBBBIND_LIBRARY_NAME} target will be configured using the HWLOC ${HWLOC_VERSION}") +- tbbbind_build(${TBBBIND_LIBRARY_NAME} ${HWLOC_LIBRARIES}) ++ tbbbind_build(${TBBBIND_LIBRARY_NAME} PkgConfig::HWLOC) + else() + tbbbind_build(tbbbind HWLOC::hwloc_1_11) + tbbbind_build(tbbbind_2_0 HWLOC::hwloc_2 ) From 00ebe43c1551751bffbc19a2463f4f1913e51821 Mon Sep 17 00:00:00 2001 From: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> Date: Wed, 9 Aug 2023 15:02:22 +0100 Subject: [PATCH 0150/1140] fontconfig: minimal change to ensure most recent rrev (#19114) --- recipes/fontconfig/meson/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/fontconfig/meson/conanfile.py b/recipes/fontconfig/meson/conanfile.py index 54997946cfcf63..f037cbc5601ca2 100644 --- a/recipes/fontconfig/meson/conanfile.py +++ b/recipes/fontconfig/meson/conanfile.py @@ -95,7 +95,7 @@ def package(self): copy(self, "COPYING", self.source_folder, os.path.join(self.package_folder, "licenses")) meson = Meson(self) meson.install() - rm(self, "*.pdb", os.path.join(self.package_folder, "bin")) + rm(self, "*.pdb", self.package_folder, recursive=True) rm(self, "*.conf", os.path.join(self.package_folder, "bin", "etc", "fonts", "conf.d")) rm(self, "*.def", os.path.join(self.package_folder, "lib")) rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) From 823512b432652a73a37b85cbd097adf25ce170a1 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 9 Aug 2023 23:33:48 +0900 Subject: [PATCH 0151/1140] uwebsockets: add version 20.45.0 (#19047) --- recipes/uwebsockets/all/conandata.yml | 3 +++ recipes/uwebsockets/all/conanfile.py | 2 +- recipes/uwebsockets/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/uwebsockets/all/conandata.yml b/recipes/uwebsockets/all/conandata.yml index d0d6f814547b2a..02893378e4419e 100644 --- a/recipes/uwebsockets/all/conandata.yml +++ b/recipes/uwebsockets/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20.45.0": + url: "https://github.com/uNetworking/uWebSockets/archive/v20.45.0.tar.gz" + sha256: "db7599e9eac0c18b76740e7c391663652e0d7188b992a1a5a8dc28f347f483ec" "20.36.0": url: "https://github.com/uNetworking/uWebSockets/archive/v20.36.0.tar.gz" sha256: "cda266f7ed6abe67ef3cae6e223a580fe5091db9156c1f4123ee328ae21511c9" diff --git a/recipes/uwebsockets/all/conanfile.py b/recipes/uwebsockets/all/conanfile.py index a7539cf95209b7..1ef8ede49e7675 100644 --- a/recipes/uwebsockets/all/conanfile.py +++ b/recipes/uwebsockets/all/conanfile.py @@ -56,7 +56,7 @@ def requirements(self): self.requires("libdeflate/1.14") if Version(self.version) > "20.17.0": - self.requires("usockets/0.8.5") + self.requires("usockets/0.8.6") elif Version(self.version) >= "20.15.0": self.requires("usockets/0.8.2") elif Version(self.version) >= "19.0.0": diff --git a/recipes/uwebsockets/config.yml b/recipes/uwebsockets/config.yml index be1e8815a9c32c..06958fe4bce177 100644 --- a/recipes/uwebsockets/config.yml +++ b/recipes/uwebsockets/config.yml @@ -1,4 +1,6 @@ versions: + "20.45.0": + folder: all "20.36.0": folder: all "20.17.0": From 542429318a13c65a309773ab92e7fc57d35d22e2 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 9 Aug 2023 17:59:17 +0300 Subject: [PATCH 0152/1140] cargs: migrate to Conan v2 (#18704) * cargs: migrate to Conan v2 * cargs: restore VirtualRunEnv in test_package * cargs: fix packaging of DLLs --- recipes/cargs/all/CMakeLists.txt | 7 -- recipes/cargs/all/conanfile.py | 94 +++++++++++-------- recipes/cargs/all/test_package/CMakeLists.txt | 9 +- recipes/cargs/all/test_package/conanfile.py | 22 +++-- .../cargs/all/test_v1_package/CMakeLists.txt | 8 ++ .../cargs/all/test_v1_package/conanfile.py | 16 ++++ 6 files changed, 100 insertions(+), 56 deletions(-) delete mode 100644 recipes/cargs/all/CMakeLists.txt create mode 100644 recipes/cargs/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cargs/all/test_v1_package/conanfile.py diff --git a/recipes/cargs/all/CMakeLists.txt b/recipes/cargs/all/CMakeLists.txt deleted file mode 100644 index 42d6e7408fb330..00000000000000 --- a/recipes/cargs/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.9.2) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/cargs/all/conanfile.py b/recipes/cargs/all/conanfile.py index 6aeeae1d3b488d..6de6ac89acce0d 100644 --- a/recipes/cargs/all/conanfile.py +++ b/recipes/cargs/all/conanfile.py @@ -1,34 +1,37 @@ import os -from conans import ConanFile, CMake, tools -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class CargsConan(ConanFile): name = "cargs" - description = "A lightweight getopt replacement that works on Linux, " \ - "Windows and macOS. Command line argument parser library" \ - " for C/C++. Can be used to parse argv and argc parameters." - url = "https://github.com/conan-io/conan-center-index" + description = ( + "A lightweight getopt replacement that works on Linux, " + "Windows and macOS. Command line argument parser library" + " for C/C++. Can be used to parse argv and argc parameters." + ) license = "MIT" + url = "https://github.com/conan-io/conan-center-index" homepage = "https://likle.github.io/cargs/" topics = ("cargs", "cross-platform", "windows", "macos", "osx", "linux", "getopt", "getopt-long", "command-line-parser", "command-line", "arguments", "argument-parser") - exports_sources = ["CMakeLists.txt"] - generators = "cmake" + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {'shared': False, 'fPIC': True} - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def config_options(self): if self.settings.os == "Windows": @@ -36,33 +39,48 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): cmake = CMake(self) - cmake.definitions["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared and self.settings.os == "Windows" - cmake.configure(build_folder=self._build_subfolder) + cmake.configure() cmake.build(target="cargs") def package(self): - include_dir = os.path.join(self._source_subfolder, 'include') - lib_dir = os.path.join(self._build_subfolder, "lib") - bin_dir = os.path.join(self._build_subfolder, "bin") - - self.copy("LICENSE.md", dst="licenses", src=self._source_subfolder) - self.copy("cargs.h", dst="include", src=include_dir) - self.copy(pattern="*.a", dst="lib", src=lib_dir, keep_path=False) - self.copy(pattern="*.lib", dst="lib", src=lib_dir, keep_path=False) - self.copy(pattern="*.dylib", dst="lib", src=lib_dir, keep_path=False) - self.copy(pattern="*.so*", dst="lib", src=lib_dir, keep_path=False, - symlinks=True) - self.copy(pattern="*.dll", dst="bin", src=bin_dir, keep_path=False) + copy(self, "LICENSE.md", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "cargs.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) + for pattern in ["*.a", "*.so*", "*.dylib", "*.lib"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder, + keep_path=False) + copy(self, "*.dll", + dst=os.path.join(self.package_folder, "bin"), + src=self.build_folder, + keep_path=False) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = ["cargs"] diff --git a/recipes/cargs/all/test_package/CMakeLists.txt b/recipes/cargs/all/test_package/CMakeLists.txt index f6bb6f79f518f1..2d259c06a7d890 100644 --- a/recipes/cargs/all/test_package/CMakeLists.txt +++ b/recipes/cargs/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(cargs REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE cargs::cargs) set_property(TARGET ${PROJECT_NAME} PROPERTY C_STANDARD 11) diff --git a/recipes/cargs/all/test_package/conanfile.py b/recipes/cargs/all/test_package/conanfile.py index 4903f1a7e8fa0f..ef5d7042163ecc 100644 --- a/recipes/cargs/all/test_package/conanfile.py +++ b/recipes/cargs/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cargs/all/test_v1_package/CMakeLists.txt b/recipes/cargs/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cargs/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cargs/all/test_v1_package/conanfile.py b/recipes/cargs/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/cargs/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From bbe0e7dac732b9a4fc3a8a114a6bce07dbfe3693 Mon Sep 17 00:00:00 2001 From: Daniel <140124999+liquiddaniel@users.noreply.github.com> Date: Thu, 10 Aug 2023 02:08:33 +1000 Subject: [PATCH 0153/1140] (#18769) Add capnproto/0.10.4 --- recipes/capnproto/all/conandata.yml | 5 +++++ recipes/capnproto/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/capnproto/all/conandata.yml b/recipes/capnproto/all/conandata.yml index 8a6eeaab5a8d19..9becf4a51dc853 100644 --- a/recipes/capnproto/all/conandata.yml +++ b/recipes/capnproto/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.10.4": + url: "https://github.com/capnproto/capnproto/archive/v0.10.4.tar.gz" + sha256: "c6f25940688c87ddb24e0c4e475c3213d9b044aad2ba305439cc8c224f559da6" "0.10.3": url: "https://github.com/capnproto/capnproto/archive/v0.10.3.tar.gz" sha256: "e07446f56043c983e009038e69d18ff86a2924909f0b518ccf47eccf5ac03919" @@ -18,6 +21,8 @@ sources: url: "https://github.com/capnproto/capnproto/archive/v0.7.0.tar.gz" sha256: 76c7114a3d142ad08b7208b3964a26e72a6320ee81331d3f0b87569fc9c47a28 patches: + "0.10.4": + - patch_file: patches/0014-disable-tests-for-0.10.1.patch "0.10.3": - patch_file: patches/0014-disable-tests-for-0.10.1.patch "0.10.1": diff --git a/recipes/capnproto/config.yml b/recipes/capnproto/config.yml index 89d97bce3d8502..884c84c332e24d 100644 --- a/recipes/capnproto/config.yml +++ b/recipes/capnproto/config.yml @@ -1,4 +1,6 @@ versions: + "0.10.4": + folder: all "0.10.3": folder: all "0.10.1": From 6a5d58eaca59aa19d457535890a2736c76c8b851 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 10 Aug 2023 01:32:13 +0900 Subject: [PATCH 0154/1140] (#19054) simdutf: add version 3.2.15, remove older versions, remove unused patch --- recipes/simdutf/all/conandata.yml | 24 ++++------- .../2.0.6-0002-add-workaround-gcc9.patch | 42 ------------------- recipes/simdutf/config.yml | 6 +-- 3 files changed, 9 insertions(+), 63 deletions(-) delete mode 100644 recipes/simdutf/all/patches/2.0.6-0002-add-workaround-gcc9.patch diff --git a/recipes/simdutf/all/conandata.yml b/recipes/simdutf/all/conandata.yml index b0cd66f4e34df9..a0fbb535961972 100644 --- a/recipes/simdutf/all/conandata.yml +++ b/recipes/simdutf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.15": + url: "https://github.com/simdutf/simdutf/archive/v3.2.15.tar.gz" + sha256: "c26d2e2e9124e1c20335d3880d74c8b0d74a5e247ba82ef82d15df4ccc413bcd" "3.2.14": url: "https://github.com/simdutf/simdutf/archive/v3.2.14.tar.gz" sha256: "6bd6cd41e0e588312c3ae24adb297454bd9bd9622ed7443f41300d7201f233a1" @@ -23,16 +26,14 @@ sources: "2.0.9": url: "https://github.com/simdutf/simdutf/archive/v2.0.9.tar.gz" sha256: "ff6a19de4c23671e7f1077cf6c0f60bc01197f29c6e4f56fa485c9cd732576ac" - "2.0.8": - url: "https://github.com/simdutf/simdutf/archive/v2.0.8.tar.gz" - sha256: "bd7aa550a8d9a1aba2c0b4eb2088f90c964375b13394f9076f7ba49f51dc40b5" - "2.0.6": - url: "https://github.com/simdutf/simdutf/archive/v2.0.6.tar.gz" - sha256: "40f1f9a4403f81c2c3d736ef9c73662835b2241871caa262fcd654e0898f9e4e" "1.0.1": url: "https://github.com/simdutf/simdutf/archive/v1.0.1.tar.gz" sha256: "e7832ba58fb95fe00de76dbbb2f17d844a7ad02a6f5e3e9e5ce9520e820049a0" patches: + "3.2.15": + - patch_file: "patches/3.2.14-0001-fix-cmake.patch" + patch_description: "remove static build, enable rpath on macOS" + patch_type: "conan" "3.2.14": - patch_file: "patches/3.2.14-0001-fix-cmake.patch" patch_description: "remove static build, enable rpath on macOS" @@ -65,17 +66,6 @@ patches: - patch_file: "patches/2.0.3-0001-fix-cmake.patch" patch_description: "remove static build, enable rpath on macOS" patch_type: "conan" - "2.0.8": - - patch_file: "patches/2.0.3-0001-fix-cmake.patch" - patch_description: "remove static build, enable rpath on macOS" - patch_type: "conan" - "2.0.6": - - patch_file: "patches/2.0.3-0001-fix-cmake.patch" - patch_description: "remove static build, enable rpath on macOS" - patch_type: "conan" - - patch_file: "patches/2.0.6-0002-add-workaround-gcc9.patch" - patch_description: "apply gcc8 workaround to gcc9" - patch_type: "portability" "1.0.1": - patch_file: "patches/1.0.1-0001-fix-cmake.patch" patch_description: "disable test and benchmark build and enable rpath on macOS" diff --git a/recipes/simdutf/all/patches/2.0.6-0002-add-workaround-gcc9.patch b/recipes/simdutf/all/patches/2.0.6-0002-add-workaround-gcc9.patch deleted file mode 100644 index 957a9759ee2fac..00000000000000 --- a/recipes/simdutf/all/patches/2.0.6-0002-add-workaround-gcc9.patch +++ /dev/null @@ -1,42 +0,0 @@ -diff --git a/src/icelake/icelake_utf8_common.inl.cpp b/src/icelake/icelake_utf8_common.inl.cpp -index 962700b..a192a18 100644 ---- a/src/icelake/icelake_utf8_common.inl.cpp -+++ b/src/icelake/icelake_utf8_common.inl.cpp -@@ -448,12 +448,12 @@ __m512i prev(__m512i input, __m512i previous) { - static_assert(N<=32, "N must be no larger than 32"); - const __m512i movemask = _mm512_setr_epi32(28,29,30,31,0,1,2,3,4,5,6,7,8,9,10,11); - const __m512i rotated = _mm512_permutex2var_epi32(input, movemask, previous); --#if SIMDUTF_GCC8 -- constexpr int shift = 16-N; // workaround for GCC8 -+#if SIMDUTF_GCC8 || SIMDUTF_GCC9 -+ constexpr int shift = 16-N; // workaround for GCC8,9 - return _mm512_alignr_epi8(input, rotated, shift); - #else - return _mm512_alignr_epi8(input, rotated, 16-N); --#endif // SIMDUTF_GCC8 -+#endif // SIMDUTF_GCC8 || SIMDUTF_GCC9 - } - - template -diff --git a/src/simdutf/icelake/intrinsics.h b/src/simdutf/icelake/intrinsics.h -index c71a085..edcd289 100644 ---- a/src/simdutf/icelake/intrinsics.h -+++ b/src/simdutf/icelake/intrinsics.h -@@ -64,7 +64,9 @@ - #if defined(__GNUC__) && !defined(__clang__) - #if __GNUC__ == 8 - #define SIMDUTF_GCC8 1 --#endif // __GNUC__ == 8 -+#elif __GNUC__ == 9 -+#define SIMDUTF_GCC9 1 -+#endif // __GNUC__ == 8 || __GNUC__ == 9 - #endif // defined(__GNUC__) && !defined(__clang__) - - #if SIMDUTF_GCC8 -@@ -83,4 +85,4 @@ inline __m512i _mm512_set_epi8(uint8_t a0, uint8_t a1, uint8_t a2, uint8_t a3, u - } - #endif // SIMDUTF_GCC8 - --#endif // SIMDUTF_HASWELL_INTRINSICS_H -\ No newline at end of file -+#endif // SIMDUTF_HASWELL_INTRINSICS_H diff --git a/recipes/simdutf/config.yml b/recipes/simdutf/config.yml index ec7185837f86c2..997781983cc10b 100644 --- a/recipes/simdutf/config.yml +++ b/recipes/simdutf/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.15": + folder: all "3.2.14": folder: all "3.2.2": @@ -15,9 +17,5 @@ versions: folder: all "2.0.9": folder: all - "2.0.8": - folder: all - "2.0.6": - folder: all "1.0.1": folder: all From ece3a9e3e94f7de261a685dca49d553298e3ad82 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Wed, 9 Aug 2023 19:25:12 +0200 Subject: [PATCH 0155/1140] (#19092) [sentry-breakpad] Replace _patch_sources by patches * [sentry-breakpad] Convert to patches * Remove second patch * Fix breakpad patch * Remove base_path in other versions * Fix patches for all versions --- recipes/sentry-breakpad/all/conandata.yml | 46 ++++ recipes/sentry-breakpad/all/conanfile.py | 83 +------ .../0.4.18-0001-remove-third-pary-lss.patch | 227 ++++++++++++++++++ .../0.4.18-0002-install-breakpad-header.patch | 54 +++++ .../0.5.4-0001-remove-third-pary-lss.patch | 227 ++++++++++++++++++ .../0.5.4-0002-install-breakpad-header.patch | 54 +++++ .../0.6.x-0001-remove-third-pary-lss.patch | 227 ++++++++++++++++++ .../0.6.x-0002-install-breakpad-header.patch | 54 +++++ 8 files changed, 893 insertions(+), 79 deletions(-) create mode 100644 recipes/sentry-breakpad/all/patches/0.4.18-0001-remove-third-pary-lss.patch create mode 100644 recipes/sentry-breakpad/all/patches/0.4.18-0002-install-breakpad-header.patch create mode 100644 recipes/sentry-breakpad/all/patches/0.5.4-0001-remove-third-pary-lss.patch create mode 100644 recipes/sentry-breakpad/all/patches/0.5.4-0002-install-breakpad-header.patch create mode 100644 recipes/sentry-breakpad/all/patches/0.6.x-0001-remove-third-pary-lss.patch create mode 100644 recipes/sentry-breakpad/all/patches/0.6.x-0002-install-breakpad-header.patch diff --git a/recipes/sentry-breakpad/all/conandata.yml b/recipes/sentry-breakpad/all/conandata.yml index ced5e36dba275c..2687fcfc48fd41 100644 --- a/recipes/sentry-breakpad/all/conandata.yml +++ b/recipes/sentry-breakpad/all/conandata.yml @@ -14,3 +14,49 @@ sources: "0.4.18": url: "https://github.com/getsentry/sentry-native/releases/download/0.4.18/sentry-native.zip" sha256: "41fdf6499cd8576142beb03104badcc9e0b80b8ef27080ca71cd4408cc1d7ece" +patches: + "0.6.5": + - patch_file: "patches/0.6.x-0001-remove-third-pary-lss.patch" + patch_description: "Remove third party lss from include" + patch_type: "conan" + patch_source: "https://github.com/getsentry/breakpad/pull/37" + - patch_file: "patches/0.6.x-0002-install-breakpad-header.patch" + patch_description: "Install breakpad header" + patch_type: "conan" + patch_source: "https://github.com/getsentry/sentry-native/pull/872" + "0.6.4": + - patch_file: "patches/0.6.x-0001-remove-third-pary-lss.patch" + patch_description: "Remove third party lss from include" + patch_type: "conan" + patch_source: "https://github.com/getsentry/breakpad/pull/37" + - patch_file: "patches/0.6.x-0002-install-breakpad-header.patch" + patch_description: "Install breakpad header" + patch_type: "conan" + patch_source: "https://github.com/getsentry/sentry-native/pull/872" + "0.6.3": + - patch_file: "patches/0.6.x-0001-remove-third-pary-lss.patch" + patch_description: "Remove third party lss from include" + patch_type: "conan" + patch_source: "https://github.com/getsentry/breakpad/pull/37" + - patch_file: "patches/0.6.x-0002-install-breakpad-header.patch" + patch_description: "Install breakpad header" + patch_type: "conan" + patch_source: "https://github.com/getsentry/sentry-native/pull/872" + "0.5.4": + - patch_file: "patches/0.5.4-0001-remove-third-pary-lss.patch" + patch_description: "Remove third party lss from include" + patch_type: "conan" + patch_source: "https://github.com/getsentry/breakpad/pull/37" + - patch_file: "patches/0.5.4-0002-install-breakpad-header.patch" + patch_description: "Install breakpad header" + patch_type: "conan" + patch_source: "https://github.com/getsentry/sentry-native/pull/872" + "0.4.18": + - patch_file: "patches/0.4.18-0001-remove-third-pary-lss.patch" + patch_description: "Remove third party lss from include" + patch_type: "conan" + patch_source: "https://github.com/getsentry/breakpad/pull/37" + - patch_file: "patches/0.4.18-0002-install-breakpad-header.patch" + patch_description: "Install breakpad header" + patch_type: "conan" + patch_source: "https://github.com/getsentry/sentry-native/pull/872" diff --git a/recipes/sentry-breakpad/all/conanfile.py b/recipes/sentry-breakpad/all/conanfile.py index a7d5646c8989e6..8e95117df3a32f 100644 --- a/recipes/sentry-breakpad/all/conanfile.py +++ b/recipes/sentry-breakpad/all/conanfile.py @@ -3,7 +3,7 @@ from conan.tools.apple import is_apple_os from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, replace_in_file, save +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.scm import Version import os @@ -43,6 +43,7 @@ def _compilers_minimum_version(self): def export_sources(self): copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -54,7 +55,7 @@ def layout(self): def requirements(self): if self.settings.os in ("FreeBSD", "Linux"): # linux-syscal-support is a public dependency - # see https://github.com/conan-io/conan-center-index/pull/16752#issuecomment-1487241864 + # see https://github.com/conan-io/conan-center-index/pull/16752#issuecomment-1487241864 self.requires("linux-syscall-support/cci.20200813", transitive_headers=True) def validate(self): @@ -75,84 +76,8 @@ def generate(self): tc.variables["LINUX"] = True tc.generate() - def _patch_sources(self): - # FIXME: convert to patches - import textwrap - - files_to_patch = [ - # "src/tools/linux/md2core/minidump-2-core.cc", - # "src/processor/testdata/linux_test_app.cc", - "src/common/memory_allocator.h", - "src/common/linux/memory_mapped_file.cc", - "src/common/linux/file_id.cc", - "src/common/linux/safe_readlink.cc", - "src/client/minidump_file_writer.cc", - "src/client/linux/handler/exception_handler.cc", - "src/client/linux/handler/exception_handler_unittest.cc", - "src/client/linux/log/log.cc", - "src/client/linux/crash_generation/crash_generation_client.cc", - "src/client/linux/minidump_writer/linux_dumper.cc", - "src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc", - "src/client/linux/minidump_writer/proc_cpuinfo_reader.h", - "src/client/linux/minidump_writer/minidump_writer.cc", - "src/client/linux/minidump_writer/linux_ptrace_dumper.cc", - "src/client/linux/minidump_writer/cpu_set.h", - "src/client/linux/minidump_writer/directory_reader.h", - "src/client/linux/minidump_writer/line_reader.h" - ] - - for file in files_to_patch: - replace_in_file(self, - os.path.join(self.source_folder, "external", "breakpad", file), - "#include \"third_party/lss/linux_syscall_support.h\"", - "#include " - ) - - save(self, os.path.join(self.source_folder, "external", "CMakeLists.txt"), - textwrap.dedent("""\ - target_compile_features(breakpad_client PUBLIC cxx_std_11) - if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") - find_path(LINUX_SYSCALL_INCLUDE_DIR NAMES linux_syscall_support.h) - target_include_directories(breakpad_client PRIVATE ${LINUX_SYSCALL_INCLUDE_DIR}) - endif() - install(TARGETS breakpad_client - ARCHIVE DESTINATION lib - LIBRARY DESTINATION lib - RUNTIME DESTINATION bin - ) - file(GLOB COMMON_FILES breakpad/src/common/*.h) - install(FILES ${COMMON_FILES} - DESTINATION include/breakpad/common - ) - set(PLATFORM_FOLDER) - if(IOS) - set(PLATFORM_FOLDER ios) - elseif(APPLE) - set(PLATFORM_FOLDER mac) - elseif(UNIX) - set(PLATFORM_FOLDER linux) - endif() - if(WIN32) - set(PLATFORM_FOLDER windows) - endif() - if(NOT PLATFORM_FOLDER) - message(FATAL_ERROR "Unknown os -> don't know how to install headers") - endif() - file(GLOB COMMON_PLATFORM_HEADERS breakpad/src/common/${PLATFORM_FOLDER}/*.h) - install(FILES ${COMMON_PLATFORM_HEADERS} - DESTINATION include/breakpad/common/${PLATFORM_FOLDER}) - install(DIRECTORY breakpad/src/client/${PLATFORM_FOLDER} - DESTINATION include/breakpad/client - FILES_MATCHING PATTERN *.h - ) - install(DIRECTORY breakpad/src/google_breakpad/common - DESTINATION include/breakpad/google_breakpad - FILES_MATCHING PATTERN *.h - ) - """), append=True) - def build(self): - self._patch_sources() + apply_conandata_patches(self) cmake = CMake(self) cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) cmake.build() diff --git a/recipes/sentry-breakpad/all/patches/0.4.18-0001-remove-third-pary-lss.patch b/recipes/sentry-breakpad/all/patches/0.4.18-0001-remove-third-pary-lss.patch new file mode 100644 index 00000000000000..a573e142644bba --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.4.18-0001-remove-third-pary-lss.patch @@ -0,0 +1,227 @@ +commit a9d52d999e0450a2f6b7ca24b245e718ab537cec +Author: Martin Delille +Date: Tue Aug 8 11:59:04 2023 +0200 + + Remove third_party/lss + +diff --git a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +index d8bfbbad..b7b43cff 100644 +--- a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc ++++ b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +@@ -37,7 +37,7 @@ + + #include "common/linux/eintr_wrapper.h" + #include "common/linux/ignore_ret.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/handler/exception_handler.cc b/external/breakpad/src/client/linux/handler/exception_handler.cc +index 499be0a9..d6c3ba71 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler.cc +@@ -95,7 +95,7 @@ + #include "client/linux/minidump_writer/linux_dumper.h" + #include "client/linux/minidump_writer/minidump_writer.h" + #include "common/linux/eintr_wrapper.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ANDROID__) + #include "linux/sched.h" +diff --git a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +index 35dcbfd4..21647998 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +@@ -50,7 +50,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/tests/auto_tempdir.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #include "google_breakpad/processor/minidump.h" + + using namespace google_breakpad; +diff --git a/external/breakpad/src/client/linux/log/log.cc b/external/breakpad/src/client/linux/log/log.cc +index 31879409..072377ed 100644 +--- a/external/breakpad/src/client/linux/log/log.cc ++++ b/external/breakpad/src/client/linux/log/log.cc +@@ -33,7 +33,7 @@ + #include + #include + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace logger { +diff --git a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +index 1cca9aa5..50f83d8c 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h ++++ b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +@@ -35,7 +35,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +index a4bde180..e1c69a23 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +@@ -38,7 +38,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/line_reader.h b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +index 9fc4b7cc..cf75dfe0 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/line_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +@@ -35,7 +35,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +index 44430c4e..a702ee68 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +@@ -51,7 +51,7 @@ + #include "common/linux/memory_mapped_file.h" + #include "common/linux/safe_readlink.h" + #include "google_breakpad/common/minidump_exception_linux.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + using google_breakpad::elf::FileID; + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +index 331f4bb3..c4c5bd42 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +@@ -39,7 +39,7 @@ + #include + + #include "common/scoped_ptr.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ARM_EABI__) + #define TID_PTR_REGISTER "r3" +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +index e3ddb81a..6712af94 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +@@ -57,7 +57,7 @@ + #include "client/linux/minidump_writer/directory_reader.h" + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + // Suspends a thread by attaching to it. + static bool SuspendThread(pid_t pid) { +diff --git a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +index 7ce9ac57..4d9f1e21 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +@@ -79,7 +79,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/minidump_type_helper.h" + #include "google_breakpad/common/minidump_format.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +index d9461bf3..a915a88b 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +@@ -36,7 +36,7 @@ + + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/minidump_file_writer.cc b/external/breakpad/src/client/minidump_file_writer.cc +index 5c3c5cbb..6b0e2dd0 100644 +--- a/external/breakpad/src/client/minidump_file_writer.cc ++++ b/external/breakpad/src/client/minidump_file_writer.cc +@@ -41,7 +41,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/string_conversion.h" + #if defined(__linux__) && __linux__ +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + #if defined(__ANDROID__) +diff --git a/external/breakpad/src/common/linux/file_id.cc b/external/breakpad/src/common/linux/file_id.cc +index b483eb5c..eff1e8ce 100644 +--- a/external/breakpad/src/common/linux/file_id.cc ++++ b/external/breakpad/src/common/linux/file_id.cc +@@ -46,7 +46,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/linux/memory_mapped_file.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + namespace elf { +diff --git a/external/breakpad/src/common/linux/memory_mapped_file.cc b/external/breakpad/src/common/linux/memory_mapped_file.cc +index 99362945..efaae8ec 100644 +--- a/external/breakpad/src/common/linux/memory_mapped_file.cc ++++ b/external/breakpad/src/common/linux/memory_mapped_file.cc +@@ -40,7 +40,7 @@ + #include + + #include "common/memory_range.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/linux/safe_readlink.cc b/external/breakpad/src/common/linux/safe_readlink.cc +index 870c28af..37872b5b 100644 +--- a/external/breakpad/src/common/linux/safe_readlink.cc ++++ b/external/breakpad/src/common/linux/safe_readlink.cc +@@ -32,7 +32,7 @@ + + #include + +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/memory_allocator.h b/external/breakpad/src/common/memory_allocator.h +index d28fbfc3..fbf8c977 100644 +--- a/external/breakpad/src/common/memory_allocator.h ++++ b/external/breakpad/src/common/memory_allocator.h +@@ -47,7 +47,7 @@ + #define sys_munmap munmap + #define MAP_ANONYMOUS MAP_ANON + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace google_breakpad { diff --git a/recipes/sentry-breakpad/all/patches/0.4.18-0002-install-breakpad-header.patch b/recipes/sentry-breakpad/all/patches/0.4.18-0002-install-breakpad-header.patch new file mode 100644 index 00000000000000..2956814e8f096e --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.4.18-0002-install-breakpad-header.patch @@ -0,0 +1,54 @@ +commit 6f1543b58c2ae4dbe129aec0123e45461da24c3c +Author: Martin Delille +Date: Tue Aug 8 12:45:23 2023 +0200 + + Update external/CMakeLists.txt to install breakpad headers + +diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt +index ca807f7..41d7cd4 100644 +--- a/external/CMakeLists.txt ++++ b/external/CMakeLists.txt +@@ -177,3 +177,43 @@ target_include_directories(breakpad_client + PUBLIC + "$" + ) ++ ++target_compile_features(breakpad_client PUBLIC cxx_std_11) ++if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") ++ find_path(LINUX_SYSCALL_INCLUDE_DIR NAMES linux_syscall_support.h) ++ target_include_directories(breakpad_client PRIVATE ${LINUX_SYSCALL_INCLUDE_DIR}) ++endif() ++install(TARGETS breakpad_client ++ ARCHIVE DESTINATION lib ++ LIBRARY DESTINATION lib ++ RUNTIME DESTINATION bin ++) ++file(GLOB COMMON_FILES breakpad/src/common/*.h) ++install(FILES ${COMMON_FILES} ++ DESTINATION include/breakpad/common ++) ++set(PLATFORM_FOLDER) ++if(IOS) ++ set(PLATFORM_FOLDER ios) ++elseif(APPLE) ++ set(PLATFORM_FOLDER mac) ++elseif(UNIX) ++ set(PLATFORM_FOLDER linux) ++endif() ++if(WIN32) ++ set(PLATFORM_FOLDER windows) ++endif() ++if(NOT PLATFORM_FOLDER) ++ message(FATAL_ERROR "Unknown os -> don't know how to install headers") ++endif() ++file(GLOB COMMON_PLATFORM_HEADERS breakpad/src/common/${PLATFORM_FOLDER}/*.h) ++install(FILES ${COMMON_PLATFORM_HEADERS} ++ DESTINATION include/breakpad/common/${PLATFORM_FOLDER}) ++install(DIRECTORY breakpad/src/client/${PLATFORM_FOLDER} ++ DESTINATION include/breakpad/client ++ FILES_MATCHING PATTERN *.h ++) ++install(DIRECTORY breakpad/src/google_breakpad/common ++ DESTINATION include/breakpad/google_breakpad ++ FILES_MATCHING PATTERN *.h ++) diff --git a/recipes/sentry-breakpad/all/patches/0.5.4-0001-remove-third-pary-lss.patch b/recipes/sentry-breakpad/all/patches/0.5.4-0001-remove-third-pary-lss.patch new file mode 100644 index 00000000000000..f97256dfd7ea1a --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.5.4-0001-remove-third-pary-lss.patch @@ -0,0 +1,227 @@ +commit d4424474455a06293d64571b58bef889a8956c34 +Author: Martin Delille +Date: Tue Aug 8 11:59:04 2023 +0200 + + Remove third_party/lss + +diff --git a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +index 5a8c6b4c..ea502283 100644 +--- a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc ++++ b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +@@ -36,7 +36,7 @@ + + #include "common/linux/eintr_wrapper.h" + #include "common/linux/ignore_ret.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/handler/exception_handler.cc b/external/breakpad/src/client/linux/handler/exception_handler.cc +index bbdb798b..cc8e451b 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler.cc +@@ -94,7 +94,7 @@ + #include "client/linux/minidump_writer/linux_dumper.h" + #include "client/linux/minidump_writer/minidump_writer.h" + #include "common/linux/eintr_wrapper.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ANDROID__) + #include "linux/sched.h" +diff --git a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +index 691ea133..93ae3cae 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +@@ -49,7 +49,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/tests/auto_tempdir.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #include "google_breakpad/processor/minidump.h" + + using namespace google_breakpad; +diff --git a/external/breakpad/src/client/linux/log/log.cc b/external/breakpad/src/client/linux/log/log.cc +index c45de64b..69b8832a 100644 +--- a/external/breakpad/src/client/linux/log/log.cc ++++ b/external/breakpad/src/client/linux/log/log.cc +@@ -32,7 +32,7 @@ + #include + #include + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace logger { +diff --git a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +index 70c1c758..92f7cdec 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h ++++ b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +@@ -34,7 +34,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +index 62bba877..568278ff 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +@@ -37,7 +37,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/line_reader.h b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +index d54a67d0..9ba8cd4c 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/line_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +@@ -34,7 +34,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +index 01b06fac..d967034d 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +@@ -50,7 +50,7 @@ + #include "common/linux/memory_mapped_file.h" + #include "common/linux/safe_readlink.h" + #include "google_breakpad/common/minidump_exception_linux.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + using google_breakpad::elf::FileID; + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +index bc1e4fbe..01fa6bd4 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +@@ -38,7 +38,7 @@ + #include + + #include "common/scoped_ptr.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ARM_EABI__) + #define TID_PTR_REGISTER "r3" +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +index 718fab7c..51be53ea 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +@@ -56,7 +56,7 @@ + #include "client/linux/minidump_writer/directory_reader.h" + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + // Suspends a thread by attaching to it. + static bool SuspendThread(pid_t pid) { +diff --git a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +index a5f9b841..6b9241a8 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +@@ -78,7 +78,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/minidump_type_helper.h" + #include "google_breakpad/common/minidump_format.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +index 5ae16dfb..dcbb2e63 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +@@ -35,7 +35,7 @@ + + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/minidump_file_writer.cc b/external/breakpad/src/client/minidump_file_writer.cc +index d5193e2c..e9d0b3bd 100644 +--- a/external/breakpad/src/client/minidump_file_writer.cc ++++ b/external/breakpad/src/client/minidump_file_writer.cc +@@ -40,7 +40,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/string_conversion.h" + #if defined(__linux__) && __linux__ +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + #if defined(__ANDROID__) +diff --git a/external/breakpad/src/common/linux/file_id.cc b/external/breakpad/src/common/linux/file_id.cc +index 0bd2a759..a330f9c1 100644 +--- a/external/breakpad/src/common/linux/file_id.cc ++++ b/external/breakpad/src/common/linux/file_id.cc +@@ -45,7 +45,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/linux/memory_mapped_file.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + namespace elf { +diff --git a/external/breakpad/src/common/linux/memory_mapped_file.cc b/external/breakpad/src/common/linux/memory_mapped_file.cc +index 7e444607..f193163b 100644 +--- a/external/breakpad/src/common/linux/memory_mapped_file.cc ++++ b/external/breakpad/src/common/linux/memory_mapped_file.cc +@@ -39,7 +39,7 @@ + #include + + #include "common/memory_range.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/linux/safe_readlink.cc b/external/breakpad/src/common/linux/safe_readlink.cc +index 97ea62c0..27f39326 100644 +--- a/external/breakpad/src/common/linux/safe_readlink.cc ++++ b/external/breakpad/src/common/linux/safe_readlink.cc +@@ -31,7 +31,7 @@ + + #include + +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/memory_allocator.h b/external/breakpad/src/common/memory_allocator.h +index 1c99913a..5fa3c337 100644 +--- a/external/breakpad/src/common/memory_allocator.h ++++ b/external/breakpad/src/common/memory_allocator.h +@@ -46,7 +46,7 @@ + #define sys_munmap munmap + #define MAP_ANONYMOUS MAP_ANON + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace google_breakpad { diff --git a/recipes/sentry-breakpad/all/patches/0.5.4-0002-install-breakpad-header.patch b/recipes/sentry-breakpad/all/patches/0.5.4-0002-install-breakpad-header.patch new file mode 100644 index 00000000000000..4af6201d0565f4 --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.5.4-0002-install-breakpad-header.patch @@ -0,0 +1,54 @@ +commit 32bf5d991a43151e149a88ee77d600170713ad69 +Author: Martin Delille +Date: Tue Aug 8 12:45:23 2023 +0200 + + Update external/CMakeLists.txt to install breakpad headers + +diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt +index ca807f7..41d7cd4 100644 +--- a/external/CMakeLists.txt ++++ b/external/CMakeLists.txt +@@ -177,3 +177,43 @@ target_include_directories(breakpad_client + PUBLIC + "$" + ) ++ ++target_compile_features(breakpad_client PUBLIC cxx_std_11) ++if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") ++ find_path(LINUX_SYSCALL_INCLUDE_DIR NAMES linux_syscall_support.h) ++ target_include_directories(breakpad_client PRIVATE ${LINUX_SYSCALL_INCLUDE_DIR}) ++endif() ++install(TARGETS breakpad_client ++ ARCHIVE DESTINATION lib ++ LIBRARY DESTINATION lib ++ RUNTIME DESTINATION bin ++) ++file(GLOB COMMON_FILES breakpad/src/common/*.h) ++install(FILES ${COMMON_FILES} ++ DESTINATION include/breakpad/common ++) ++set(PLATFORM_FOLDER) ++if(IOS) ++ set(PLATFORM_FOLDER ios) ++elseif(APPLE) ++ set(PLATFORM_FOLDER mac) ++elseif(UNIX) ++ set(PLATFORM_FOLDER linux) ++endif() ++if(WIN32) ++ set(PLATFORM_FOLDER windows) ++endif() ++if(NOT PLATFORM_FOLDER) ++ message(FATAL_ERROR "Unknown os -> don't know how to install headers") ++endif() ++file(GLOB COMMON_PLATFORM_HEADERS breakpad/src/common/${PLATFORM_FOLDER}/*.h) ++install(FILES ${COMMON_PLATFORM_HEADERS} ++ DESTINATION include/breakpad/common/${PLATFORM_FOLDER}) ++install(DIRECTORY breakpad/src/client/${PLATFORM_FOLDER} ++ DESTINATION include/breakpad/client ++ FILES_MATCHING PATTERN *.h ++) ++install(DIRECTORY breakpad/src/google_breakpad/common ++ DESTINATION include/breakpad/google_breakpad ++ FILES_MATCHING PATTERN *.h ++) diff --git a/recipes/sentry-breakpad/all/patches/0.6.x-0001-remove-third-pary-lss.patch b/recipes/sentry-breakpad/all/patches/0.6.x-0001-remove-third-pary-lss.patch new file mode 100644 index 00000000000000..5134a67b8fcd0f --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.6.x-0001-remove-third-pary-lss.patch @@ -0,0 +1,227 @@ +commit 2f63423367c2624a26e60b3867dd2462530d9334 +Author: Martin Delille +Date: Tue Aug 8 11:59:04 2023 +0200 + + Remove third_party/lss + +diff --git a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +index f06273d5..45599971 100644 +--- a/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc ++++ b/external/breakpad/src/client/linux/crash_generation/crash_generation_client.cc +@@ -40,7 +40,7 @@ + + #include "common/linux/eintr_wrapper.h" + #include "common/linux/ignore_ret.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/handler/exception_handler.cc b/external/breakpad/src/client/linux/handler/exception_handler.cc +index 9e23c119..4edd781c 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler.cc +@@ -98,7 +98,7 @@ + #include "client/linux/minidump_writer/linux_dumper.h" + #include "client/linux/minidump_writer/minidump_writer.h" + #include "common/linux/eintr_wrapper.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ANDROID__) + #include "linux/sched.h" +diff --git a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +index b2d8d468..a9199e2d 100644 +--- a/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc ++++ b/external/breakpad/src/client/linux/handler/exception_handler_unittest.cc +@@ -53,7 +53,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/tests/auto_tempdir.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #include "google_breakpad/processor/minidump.h" + + using namespace google_breakpad; +diff --git a/external/breakpad/src/client/linux/log/log.cc b/external/breakpad/src/client/linux/log/log.cc +index 2a48d7fe..0e3329a4 100644 +--- a/external/breakpad/src/client/linux/log/log.cc ++++ b/external/breakpad/src/client/linux/log/log.cc +@@ -36,7 +36,7 @@ + #include + #include + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace logger { +diff --git a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +index 70c1c758..92f7cdec 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/cpu_set.h ++++ b/external/breakpad/src/client/linux/minidump_writer/cpu_set.h +@@ -34,7 +34,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +index 62bba877..568278ff 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/directory_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/directory_reader.h +@@ -37,7 +37,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/line_reader.h b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +index d54a67d0..9ba8cd4c 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/line_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/line_reader.h +@@ -34,7 +34,7 @@ + #include + + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +index 85922a9c..3df94a6b 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper.cc +@@ -54,7 +54,7 @@ + #include "common/linux/memory_mapped_file.h" + #include "common/linux/safe_readlink.h" + #include "google_breakpad/common/minidump_exception_linux.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + using google_breakpad::elf::FileID; + +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +index 5a135fda..9f27f8d9 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_dumper_unittest_helper.cc +@@ -42,7 +42,7 @@ + #include + + #include "common/scoped_ptr.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + #if defined(__ARM_EABI__) + #define TID_PTR_REGISTER "r3" +diff --git a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +index 0e58236b..d8613cd3 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/linux_ptrace_dumper.cc +@@ -60,7 +60,7 @@ + #include "client/linux/minidump_writer/directory_reader.h" + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + // Suspends a thread by attaching to it. + static bool SuspendThread(pid_t pid) { +diff --git a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +index a95dd254..a0ed1e1d 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc ++++ b/external/breakpad/src/client/linux/minidump_writer/minidump_writer.cc +@@ -82,7 +82,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/minidump_type_helper.h" + #include "google_breakpad/common/minidump_format.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace { + +diff --git a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +index 5ae16dfb..dcbb2e63 100644 +--- a/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h ++++ b/external/breakpad/src/client/linux/minidump_writer/proc_cpuinfo_reader.h +@@ -35,7 +35,7 @@ + + #include "client/linux/minidump_writer/line_reader.h" + #include "common/linux/linux_libc_support.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/client/minidump_file_writer.cc b/external/breakpad/src/client/minidump_file_writer.cc +index c00af36c..acf5a520 100644 +--- a/external/breakpad/src/client/minidump_file_writer.cc ++++ b/external/breakpad/src/client/minidump_file_writer.cc +@@ -44,7 +44,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/string_conversion.h" + #if defined(__linux__) && __linux__ +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + #if defined(__ANDROID__) +diff --git a/external/breakpad/src/common/linux/file_id.cc b/external/breakpad/src/common/linux/file_id.cc +index d8fcbd8d..c81e43bc 100644 +--- a/external/breakpad/src/common/linux/file_id.cc ++++ b/external/breakpad/src/common/linux/file_id.cc +@@ -49,7 +49,7 @@ + #include "common/linux/linux_libc_support.h" + #include "common/linux/memory_mapped_file.h" + #include "common/using_std_string.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + namespace elf { +diff --git a/external/breakpad/src/common/linux/memory_mapped_file.cc b/external/breakpad/src/common/linux/memory_mapped_file.cc +index a7b96eb5..b89a3c95 100644 +--- a/external/breakpad/src/common/linux/memory_mapped_file.cc ++++ b/external/breakpad/src/common/linux/memory_mapped_file.cc +@@ -43,7 +43,7 @@ + #include + + #include "common/memory_range.h" +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/linux/safe_readlink.cc b/external/breakpad/src/common/linux/safe_readlink.cc +index a42b01a5..939e5309 100644 +--- a/external/breakpad/src/common/linux/safe_readlink.cc ++++ b/external/breakpad/src/common/linux/safe_readlink.cc +@@ -35,7 +35,7 @@ + + #include + +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + + namespace google_breakpad { + +diff --git a/external/breakpad/src/common/memory_allocator.h b/external/breakpad/src/common/memory_allocator.h +index 1c99913a..5fa3c337 100644 +--- a/external/breakpad/src/common/memory_allocator.h ++++ b/external/breakpad/src/common/memory_allocator.h +@@ -46,7 +46,7 @@ + #define sys_munmap munmap + #define MAP_ANONYMOUS MAP_ANON + #else +-#include "third_party/lss/linux_syscall_support.h" ++#include "linux_syscall_support.h" + #endif + + namespace google_breakpad { diff --git a/recipes/sentry-breakpad/all/patches/0.6.x-0002-install-breakpad-header.patch b/recipes/sentry-breakpad/all/patches/0.6.x-0002-install-breakpad-header.patch new file mode 100644 index 00000000000000..e71cb09fcd1877 --- /dev/null +++ b/recipes/sentry-breakpad/all/patches/0.6.x-0002-install-breakpad-header.patch @@ -0,0 +1,54 @@ +commit 78914ad6c0099d1ca4d891435c85ba0a6289814d +Author: Martin Delille +Date: Tue Aug 8 12:45:23 2023 +0200 + + Update external/CMakeLists.txt to install breakpad headers + +diff --git a/external/CMakeLists.txt b/external/CMakeLists.txt +index 9f3a298..31ac3f8 100644 +--- a/external/CMakeLists.txt ++++ b/external/CMakeLists.txt +@@ -185,3 +185,43 @@ target_include_directories(breakpad_client + PUBLIC + "$" + ) ++ ++target_compile_features(breakpad_client PUBLIC cxx_std_11) ++if(CMAKE_SYSTEM_NAME STREQUAL "Linux" OR CMAKE_SYSTEM_NAME STREQUAL "FreeBSD") ++ find_path(LINUX_SYSCALL_INCLUDE_DIR NAMES linux_syscall_support.h) ++ target_include_directories(breakpad_client PRIVATE ${LINUX_SYSCALL_INCLUDE_DIR}) ++endif() ++install(TARGETS breakpad_client ++ ARCHIVE DESTINATION lib ++ LIBRARY DESTINATION lib ++ RUNTIME DESTINATION bin ++) ++file(GLOB COMMON_FILES breakpad/src/common/*.h) ++install(FILES ${COMMON_FILES} ++ DESTINATION include/breakpad/common ++) ++set(PLATFORM_FOLDER) ++if(IOS) ++ set(PLATFORM_FOLDER ios) ++elseif(APPLE) ++ set(PLATFORM_FOLDER mac) ++elseif(UNIX) ++ set(PLATFORM_FOLDER linux) ++endif() ++if(WIN32) ++ set(PLATFORM_FOLDER windows) ++endif() ++if(NOT PLATFORM_FOLDER) ++ message(FATAL_ERROR "Unknown os -> don't know how to install headers") ++endif() ++file(GLOB COMMON_PLATFORM_HEADERS breakpad/src/common/${PLATFORM_FOLDER}/*.h) ++install(FILES ${COMMON_PLATFORM_HEADERS} ++ DESTINATION include/breakpad/common/${PLATFORM_FOLDER}) ++install(DIRECTORY breakpad/src/client/${PLATFORM_FOLDER} ++ DESTINATION include/breakpad/client ++ FILES_MATCHING PATTERN *.h ++) ++install(DIRECTORY breakpad/src/google_breakpad/common ++ DESTINATION include/breakpad/google_breakpad ++ FILES_MATCHING PATTERN *.h ++) From 2b9fdef89fdb389275df584b615cb3029bf3223c Mon Sep 17 00:00:00 2001 From: Thomas Steiner <47025493+steinerthomas@users.noreply.github.com> Date: Wed, 9 Aug 2023 20:08:17 +0200 Subject: [PATCH 0156/1140] (#19019) sqlitecpp: bump sqlite3 3.42.0 --- recipes/sqlitecpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/sqlitecpp/all/conanfile.py b/recipes/sqlitecpp/all/conanfile.py index 70dd5900f9a1ac..3cb33ddd1e3dd8 100644 --- a/recipes/sqlitecpp/all/conanfile.py +++ b/recipes/sqlitecpp/all/conanfile.py @@ -43,7 +43,7 @@ def configure(self): self.options.rm_safe("fPIC") def requirements(self): - self.requires("sqlite3/3.40.0") + self.requires("sqlite3/3.42.0") def validate(self): if Version(self.version) >= "3.0.0" and self.info.settings.compiler.get_safe("cppstd"): From b9727130b965a5eb00a45ef71264e52d62c9d329 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 9 Aug 2023 20:19:05 +0200 Subject: [PATCH 0157/1140] (#19117) librttopo: bump geos --- recipes/librttopo/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/librttopo/all/conanfile.py b/recipes/librttopo/all/conanfile.py index ceb7c7bc70c186..aeef7fdcae4069 100644 --- a/recipes/librttopo/all/conanfile.py +++ b/recipes/librttopo/all/conanfile.py @@ -45,7 +45,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("geos/3.11.1", transitive_headers=True, transitive_libs=True) + self.requires("geos/3.11.2", transitive_headers=True, transitive_libs=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 981a12748abe6a0875ef18625b0ac9e378b314dd Mon Sep 17 00:00:00 2001 From: Thomas Steiner <47025493+steinerthomas@users.noreply.github.com> Date: Wed, 9 Aug 2023 23:09:05 +0200 Subject: [PATCH 0158/1140] (#18937) poco: sqlite3 bump 3.42.0 * poco sqlite3 3.42.0 * sqlitecpp sqlite3 3.42.0 * Revert sqlitecpp --------- Co-authored-by: Uilian Ries --- recipes/poco/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/poco/all/conanfile.py b/recipes/poco/all/conanfile.py index 330da5a01ce349..a9fe39975ab8a2 100644 --- a/recipes/poco/all/conanfile.py +++ b/recipes/poco/all/conanfile.py @@ -116,7 +116,7 @@ def requirements(self): if self.options.enable_xml: self.requires("expat/2.5.0") if self.options.enable_data_sqlite: - self.requires("sqlite3/3.41.2") + self.requires("sqlite3/3.42.0") if self.options.enable_apacheconnector: self.requires("apr/1.7.0") self.requires("apr-util/1.6.1") From cb446e5070838ef568d6a4438cf8a6cab617e3b4 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 10 Aug 2023 11:36:14 +0900 Subject: [PATCH 0159/1140] (#19132) etl: add version 20.37.3 --- recipes/etl/all/conandata.yml | 3 +++ recipes/etl/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/etl/all/conandata.yml b/recipes/etl/all/conandata.yml index 716bd8799f7d5f..048eb0ba5716e3 100644 --- a/recipes/etl/all/conandata.yml +++ b/recipes/etl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20.37.3": + url: "https://github.com/ETLCPP/etl/archive/20.37.3.tar.gz" + sha256: "fbdf60c770772cd96d1eb25bdf56e4f45f23bf4029e18ef1f2af1f2056b9ea41" "20.37.2": url: "https://github.com/ETLCPP/etl/archive/20.37.2.tar.gz" sha256: "13bd5d9d1bfbc887e3182895ca0291df0008a1c5770ddd12ef6cd2215c2bc6af" diff --git a/recipes/etl/config.yml b/recipes/etl/config.yml index b1fd5bf4caa620..aa2b1c54bb8bdb 100644 --- a/recipes/etl/config.yml +++ b/recipes/etl/config.yml @@ -1,4 +1,6 @@ versions: + "20.37.3": + folder: all "20.37.2": folder: all "20.37.1": From 6ae5af76a1535994cff26adb4cc7da1da0ac932d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Thu, 10 Aug 2023 10:24:31 +0200 Subject: [PATCH 0160/1140] (#19134) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 0b338c3849bddf..00fca464901176 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -211,6 +211,7 @@ required_for_references: - cxxopts - cyclonedds - cyrus-sasl +- czmq - dacap-clip - darknet - dataframe @@ -703,6 +704,7 @@ required_for_references: - mp-units - mpark-variant - mpc +- mpfr - mpg123 - mpmcqueue - mppp @@ -989,6 +991,7 @@ required_for_references: - svgpp - svgwrite - symengine +- systemc - szip - tabulate - taglib @@ -1048,6 +1051,7 @@ required_for_references: - utfcpp - util-linux-libuuid - uvw +- uwebsockets - vaapi - variant-lite - vdpau From ea3af1333d855ce9d028d046ace13e153b5763cc Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 10 Aug 2023 17:49:45 +0900 Subject: [PATCH 0161/1140] (#19130) drogon: fix compilation error on gcc13 * drogon: fix compilation error on gcc13 * support 1.8.2 --- recipes/drogon/all/conandata.yml | 12 ++++++++++++ .../all/patches/1.8.2-0004-support-gcc13.patch | 12 ++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 recipes/drogon/all/patches/1.8.2-0004-support-gcc13.patch diff --git a/recipes/drogon/all/conandata.yml b/recipes/drogon/all/conandata.yml index 3ee3725bb502de..dd03c6b133f928 100644 --- a/recipes/drogon/all/conandata.yml +++ b/recipes/drogon/all/conandata.yml @@ -28,6 +28,10 @@ patches: - patch_file: "patches/1.8.4-0004-find-package-yaml-cpp.patch" patch_description: "Fix yaml-cpp cmake target name" patch_type: "conan" + - patch_file: "patches/1.8.2-0004-support-gcc13.patch" + patch_description: "Fix compilation error on gcc13 with C++17" + patch_type: "portability" + patch_source: "https://github.com/drogonframework/drogon/pull/1563/" "1.8.3": - patch_file: "patches/1.8.0-0001-disable-unused-data.patch" patch_description: "Consume Trantor package from Conan instead of using the\ @@ -39,6 +43,10 @@ patches: - patch_file: "patches/1.8.3-0003-find-package-sqlite.patch" patch_description: "Fix sqlite cmake target name" patch_type: "conan" + - patch_file: "patches/1.8.2-0004-support-gcc13.patch" + patch_description: "Fix compilation error on gcc13 with C++17" + patch_type: "portability" + patch_source: "https://github.com/drogonframework/drogon/pull/1563/" "1.8.2": - patch_file: "patches/1.8.0-0001-disable-unused-data.patch" patch_description: "Consume Trantor package from Conan instead of using the\ @@ -50,6 +58,10 @@ patches: - patch_file: "patches/1.8.2-0003-find-package-sqlite.patch" patch_description: "Fix sqlite cmake target name" patch_type: "conan" + - patch_file: "patches/1.8.2-0004-support-gcc13.patch" + patch_description: "Fix compilation error on gcc13 with C++17" + patch_type: "portability" + patch_source: "https://github.com/drogonframework/drogon/pull/1563/" "1.8.0": - patch_file: "patches/1.8.0-0001-disable-unused-data.patch" patch_description: "Consume Trantor package from Conan instead of using the subproject" diff --git a/recipes/drogon/all/patches/1.8.2-0004-support-gcc13.patch b/recipes/drogon/all/patches/1.8.2-0004-support-gcc13.patch new file mode 100644 index 00000000000000..477d23fb1fd63f --- /dev/null +++ b/recipes/drogon/all/patches/1.8.2-0004-support-gcc13.patch @@ -0,0 +1,12 @@ +diff --git a/lib/inc/drogon/RateLimiter.h b/lib/inc/drogon/RateLimiter.h +index 3b8706b..dece795 100644 +--- a/lib/inc/drogon/RateLimiter.h ++++ b/lib/inc/drogon/RateLimiter.h +@@ -3,6 +3,7 @@ + #include + #include + #include ++#include + + namespace drogon + { From 216654c1aefde6294eefeb67fceab9307a209bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 10 Aug 2023 10:57:35 +0200 Subject: [PATCH 0162/1140] Add backup sources config (#18082) --- .c3i/config_v2.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index b5ee3148ca00b6..1f13510578fc9d 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -4,6 +4,14 @@ id: 'conan-io/conan-center-index' conan: version: 2.0.9 + backup_sources: + upload_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/" + download_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/" + + globalconf: + - 'core.sources:download_cache={{ CONFIG_HOME }}/backup_sources_cache' + - 'core.sources:download_urls=["{{ ARTI_DOWNLOAD_URL }}", "origin"]' + - 'core.sources:upload_url={{ ARTI_UPLOAD_URL }}' artifactory: url: "https://c3i.jfrog.io/c3i" From f3a66013c215e28bed06746407ccc09c4e4f50d7 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 11 Aug 2023 00:29:28 +0900 Subject: [PATCH 0163/1140] (#18958) fpzip: add recipe * fpzip: add recipe * add FPZIP_SHARED_LIBS --- recipes/fpzip/all/conandata.yml | 4 + recipes/fpzip/all/conanfile.py | 80 ++++++++++ recipes/fpzip/all/test_package/CMakeLists.txt | 7 + recipes/fpzip/all/test_package/conanfile.py | 26 ++++ recipes/fpzip/all/test_package/test_package.c | 142 ++++++++++++++++++ recipes/fpzip/config.yml | 3 + 6 files changed, 262 insertions(+) create mode 100644 recipes/fpzip/all/conandata.yml create mode 100644 recipes/fpzip/all/conanfile.py create mode 100644 recipes/fpzip/all/test_package/CMakeLists.txt create mode 100644 recipes/fpzip/all/test_package/conanfile.py create mode 100644 recipes/fpzip/all/test_package/test_package.c create mode 100644 recipes/fpzip/config.yml diff --git a/recipes/fpzip/all/conandata.yml b/recipes/fpzip/all/conandata.yml new file mode 100644 index 00000000000000..ef306da4b06498 --- /dev/null +++ b/recipes/fpzip/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.3.0": + url: "https://github.com/LLNL/fpzip/releases/download/1.3.0/fpzip-1.3.0.tar.gz" + sha256: "248df7d84259e3feaa4c4797956b2a77c3fcd734e8f8fdc51ce171dcf4f0136c" diff --git a/recipes/fpzip/all/conanfile.py b/recipes/fpzip/all/conanfile.py new file mode 100644 index 00000000000000..2369b2e58e6b6a --- /dev/null +++ b/recipes/fpzip/all/conanfile.py @@ -0,0 +1,80 @@ +from conan import ConanFile +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +import os + + +required_conan_version = ">=1.53.0" + +class FpzipConan(ConanFile): + name = "fpzip" + description = "Lossless compressor of multidimensional floating-point arrays" + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "http://fpzip.llnl.gov/" + topics = ("compression", "lossless", "floating-point") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_fp": ["fast", "safe", "emul", "int"], + } + default_options = { + "shared": False, + "fPIC": True, + "with_fp": "fast", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + @property + def _fp_name_table(self): + return { + "fast": "FPZIP_FP_FAST", + "safe": "FPZIP_FP_SAFE", + "emul": "FPZIP_FP_EMUL", + "int": "FPZIP_FP_INT", + } + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["FPZIP_FP"] = self._fp_name_table.get(str(self.options.with_fp), "FP_ZIP_FAST") + tc.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + self.cpp_info.libs = ["fpzip"] + self.cpp_info.defines.append("FPZIP_FP={}".format(self._fp_name_table.get(str(self.options.with_fp), "FP_ZIP_FAST"))) + if self.options.shared: + self.cpp_info.defines.append("FPZIP_SHARED_LIBS") + if self.settings.compiler in ["gcc", "clang", "apple-clang"]: + self.cpp_info.system_libs += ["stdc++"] diff --git a/recipes/fpzip/all/test_package/CMakeLists.txt b/recipes/fpzip/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..1476da8811ce63 --- /dev/null +++ b/recipes/fpzip/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) + +find_package(fpzip REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE fpzip::fpzip) diff --git a/recipes/fpzip/all/test_package/conanfile.py b/recipes/fpzip/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/fpzip/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fpzip/all/test_package/test_package.c b/recipes/fpzip/all/test_package/test_package.c new file mode 100644 index 00000000000000..8e359fe8da3194 --- /dev/null +++ b/recipes/fpzip/all/test_package/test_package.c @@ -0,0 +1,142 @@ +#include +#include +#include +#include +#include + +#include "fpzip.h" + +static size_t +compress(FPZ* fpz, const void* data) +{ + size_t size; + /* write header */ + if (!fpzip_write_header(fpz)) { + fprintf(stderr, "cannot write header: %s\n", fpzip_errstr[fpzip_errno]); + return 0; + } + /* perform actual compression */ + size = fpzip_write(fpz, data); + if (!size) { + fprintf(stderr, "compression failed: %s\n", fpzip_errstr[fpzip_errno]); + return 0; + } + return size; +} + +static int +decompress(FPZ* fpz, void* data, size_t inbytes) +{ + /* read header */ + if (!fpzip_read_header(fpz)) { + fprintf(stderr, "cannot read header: %s\n", fpzip_errstr[fpzip_errno]); + return 0; + } + /* make sure array size stored in header matches expectations */ + if ((fpz->type == FPZIP_TYPE_FLOAT ? sizeof(float) : sizeof(double)) * fpz->nx * fpz->ny * fpz->nz * fpz->nf != inbytes) { + fprintf(stderr, "array size does not match dimensions from header\n"); + return 0; + } + /* perform actual decompression */ + if (!fpzip_read(fpz, data)) { + fprintf(stderr, "decompression failed: %s\n", fpzip_errstr[fpzip_errno]); + return 0; + } + return 1; +} + +static float +float_rand() +{ + static unsigned int seed = 1; + double val; + seed = 1103515245 * seed + 12345; + seed &= 0x7fffffffu; + val = ldexp((double)seed, -31); + val = 2 * val - 1; + val *= val * val; + val *= val * val; + return val; +} + +/* generate a trilinear field perturbed by random noise */ +float* +float_field(int nx, int ny, int nz, float offset) +{ + int n = nx * ny * nz; + float* field = malloc(n * sizeof(float)); + int i, x, y, z; + /* generate random field */ + *field = offset; + for (i = 1; i < n; i++) + field[i] = float_rand(); + /* integrate along x */ + for (z = 0; z < nz; z++) + for (y = 0; y < ny; y++) + for (x = 1; x < nx; x++) + field[x + nx * (y + ny * z)] += field[(x - 1) + nx * (y + ny * z)]; + /* integrate along y */ + for (z = 0; z < nz; z++) + for (y = 1; y < ny; y++) + for (x = 0; x < nx; x++) + field[x + nx * (y + ny * z)] += field[x + nx * ((y - 1) + ny * z)]; + /* integrate along z */ + for (z = 1; z < nz; z++) + for (y = 0; y < ny; y++) + for (x = 0; x < nx; x++) + field[x + nx * (y + ny * z)] += field[x + nx * (y + ny * (z - 1))]; + return field; +} + +static void +test_float_array(const float* field, int nx, int ny, int nz, int prec) +{ + int status; + unsigned int actual_checksum; + int dims = (nz == 1 ? ny == 1 ? 1 : 2 : 3); + size_t inbytes = nx * ny * nz * sizeof(float); + size_t bufbytes = 1024 + inbytes; + size_t outbytes = 0; + void* buffer = malloc(bufbytes); + float* copy = malloc(inbytes); + char name[0x100]; + + /* compress to memory */ + FPZ* fpz = fpzip_write_to_buffer(buffer, bufbytes); + fpz->type = FPZIP_TYPE_FLOAT; + fpz->prec = prec; + fpz->nx = nx; + fpz->ny = ny; + fpz->nz = nz; + fpz->nf = 1; + outbytes = compress(fpz, field); + status = (0 < outbytes && outbytes <= bufbytes); + fpzip_write_close(fpz); + sprintf(name, "test.float.%dd.prec%d.compress", dims, prec); + + /* decompress */ + fpz = fpzip_read_from_buffer(buffer); + status = decompress(fpz, copy, inbytes); + fpzip_read_close(fpz); + sprintf(name, "test.float.%dd.prec%d.decompress", dims, prec); + + free(copy); + free(buffer); +} + +static int +test_float(int nx, int ny, int nz) +{ + float* field = float_field(nx, ny, nz, 0); + int prec = 8; + test_float_array(field, nx * ny * nz, 1, 1, prec); + test_float_array(field, nx, ny * nz, 1, prec); + test_float_array(field, nx, ny, nz, prec); + free(field); +} + +int main(void) { + test_float(65, 64, 63); + + return 0; +} diff --git a/recipes/fpzip/config.yml b/recipes/fpzip/config.yml new file mode 100644 index 00000000000000..426a0e4c79e9b1 --- /dev/null +++ b/recipes/fpzip/config.yml @@ -0,0 +1,3 @@ +versions: + "1.3.0": + folder: all From ebfaa8b83cd995e56dcbcd388038768a310e9cb5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 10 Aug 2023 18:04:17 +0200 Subject: [PATCH 0164/1140] (#19136) Fix documentation typo --- docs/adding_packages/folders_and_files.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/adding_packages/folders_and_files.md b/docs/adding_packages/folders_and_files.md index 0136f36792b5b2..b5a51c8d603097 100644 --- a/docs/adding_packages/folders_and_files.md +++ b/docs/adding_packages/folders_and_files.md @@ -140,7 +140,7 @@ When a package needs other packages those can be include with the `requirements( ```python def requirements(self): - self.require("fmt/9.0.0") + self.requires("fmt/9.0.0") ``` For more information see the [Dependencies](dependencies.md) documentation. From d2ce190148958e5c954def44d60e6d7bdb7e583e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 10 Aug 2023 19:28:08 +0300 Subject: [PATCH 0165/1140] (#18893) openfst: migrate to Conan v2 * openfst: migrate to Conan v2 * openfst: restore VirtualRunEnv in test_package * openfst: use -pthread instead of -lpthread --- recipes/openfst/all/conandata.yml | 1 - recipes/openfst/all/conanfile.py | 123 ++++++++++-------- .../openfst/all/test_package/CMakeLists.txt | 5 +- recipes/openfst/all/test_package/conanfile.py | 21 ++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../openfst/all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 110 insertions(+), 65 deletions(-) create mode 100644 recipes/openfst/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/openfst/all/test_v1_package/conanfile.py diff --git a/recipes/openfst/all/conandata.yml b/recipes/openfst/all/conandata.yml index ef54f290e00776..aed678082ff26c 100644 --- a/recipes/openfst/all/conandata.yml +++ b/recipes/openfst/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "1.8.2": - patch_file: "patches/1.8.2-allocate-hint.patch" - base_path: "source_subfolder" diff --git a/recipes/openfst/all/conanfile.py b/recipes/openfst/all/conanfile.py index ef0a6f1a558d2a..350f5171a2fd11 100644 --- a/recipes/openfst/all/conanfile.py +++ b/recipes/openfst/all/conanfile.py @@ -1,20 +1,26 @@ -from conans import ConanFile, AutoToolsBuildEnvironment, tools -from conans.errors import ConanInvalidConfiguration -import functools -from itertools import product import os +from itertools import product + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rename, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.scm import Version -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" class OpenFstConan(ConanFile): name = "openfst" description = "A library for constructing, combining, optimizing and searching weighted finite-state-transducers (FSTs)." - topics = ("asr", "fst", "wfst", "openfst") + license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.openfst.org/twiki/bin/view/FST/WebHome" - license = "Apache-2.0" + topics = ("asr", "fst", "wfst", "openfst") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -49,26 +55,27 @@ class OpenFstConan(ConanFile): "enable_special": False, } - @property - def _source_subfolder(self): - return "source_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.os != "Linux": - raise ConanInvalidConfiguration( - "OpenFst is only supported on linux") + if self.settings.os not in ["Linux", "FreeBSD"]: + raise ConanInvalidConfiguration("OpenFst is only supported on linux") compilers = { "gcc": "8", @@ -76,33 +83,36 @@ def validate(self): } if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 17) + check_min_cppstd(self, 17) minimum_compiler = compilers.get(str(self.settings.compiler)) if minimum_compiler: - if tools.Version(self.settings.compiler.version) < minimum_compiler: - raise ConanInvalidConfiguration(f"{self.name} requires c++17, which your compiler does not support.") + if Version(self.settings.compiler.version) < minimum_compiler: + raise ConanInvalidConfiguration( + f"{self.name} requires c++17, which your compiler does not support." + ) else: - self.output.warn(f"{self.name} requires c++17, but this compiler is unknown to this recipe. Assuming your compiler supports c++17.") + self.output.warning( + f"{self.name} requires c++17, but this compiler is unknown to this recipe." + f" Assuming your compiler supports c++17." + ) # Check stdlib ABI compatibility if self.settings.compiler == "gcc" and self.settings.compiler.libcxx != "libstdc++11": - raise ConanInvalidConfiguration('Using %s with GCC requires "compiler.libcxx=libstdc++11"' % self.name) + raise ConanInvalidConfiguration( + f'Using {self.name} with GCC requires "compiler.libcxx=libstdc++11"' + ) elif self.settings.compiler == "clang" and self.settings.compiler.libcxx not in ["libstdc++11", "libc++"]: - raise ConanInvalidConfiguration('Using %s with Clang requires either "compiler.libcxx=libstdc++11"' - ' or "compiler.libcxx=libc++"' % self.name) + raise ConanInvalidConfiguration( + f'Using {self.name} with Clang requires either "compiler.libcxx=libstdc++11" or "compiler.libcxx=libc++"' + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_autotools(self): - autotools = AutoToolsBuildEnvironment(self) + def generate(self): + tc = AutotoolsToolchain(self) yes_no = lambda v: "yes" if v else "no" - args = [ - "--with-pic={}".format(yes_no(self.options.get_safe("fPIC", True))), - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-static={}".format(yes_no(not self.options.shared)), + tc.configure_args += [ "--enable-bin={}".format(yes_no(self.options.enable_bin)), "--enable-compact-fsts={}".format(yes_no(self.options.enable_compact_fsts)), "--enable-compress={}".format(yes_no(self.options.enable_compress)), @@ -115,47 +125,51 @@ def _configure_autotools(self): "--enable-ngram-fsts={}".format(yes_no(self.options.enable_ngram_fsts)), "--enable-pdt={}".format(yes_no(self.options.enable_pdt)), "--enable-special={}".format(yes_no(self.options.enable_special)), - "LIBS=-lpthread", ] - autotools.configure(args=args, configure_dir=self._source_subfolder) - return autotools - - def export_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + tc.extra_cflags.append("-pthread") + tc.extra_cxxflags.append("-pthread") + tc.generate() def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) + apply_conandata_patches(self) def build(self): self._patch_sources() - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + + autotools = Autotools(self) autotools.install() lib_dir = os.path.join(self.package_folder, "lib") lib_subdir = os.path.join(self.package_folder, "lib", "fst") if os.path.exists(lib_subdir): for fn in os.listdir(lib_subdir): - tools.rename(os.path.join(lib_subdir, fn), os.path.join(lib_dir, "lib{}".format(fn))) - tools.rmdir(lib_subdir) + rename(self, + os.path.join(lib_subdir, fn), + os.path.join(lib_dir, f"lib{fn}")) + rmdir(self, lib_subdir) - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.remove_files_by_mask(lib_dir, "*.la") + rmdir(self, os.path.join(self.package_folder, "share")) + rm(self, "*.la", lib_dir, recursive=True) @property def _get_const_fsts_libs(self): - return ["const{}-fst".format(n) for n in [8, 16, 64]] + return [f"const{n}-fst" for n in [8, 16, 64]] @property def _get_compact_fsts_libs(self): - return ["compact{}_{}-fst".format(n, fst) - for n, fst in product([8, 16, 64], ["acceptor", "string", "unweighted_acceptor", "unweighted", "weighted_string"])] + return [f"compact{n}_{fst}-fst" + for n, fst in product( + [8, 16, 64], + ["acceptor", "string", "unweighted_acceptor", "unweighted", "weighted_string"] + )] def package_info(self): self.cpp_info.set_property("cmake_file_name", "OpenFst") @@ -196,8 +210,9 @@ def package_info(self): if self.options.enable_pdt or self.options.enable_grm: self.cpp_info.libs.append("fstpdtscript") - bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment var: {}".format(bindir)) - self.env_info.PATH.append(bindir) - self.cpp_info.system_libs = ["pthread", "dl", "m"] + + # TODO: Legacy, to be removed on Conan 2.0 + bindir = os.path.join(self.package_folder, "bin") + self.output.info(f"Appending PATH environment var: {bindir}") + self.env_info.PATH.append(bindir) diff --git a/recipes/openfst/all/test_package/CMakeLists.txt b/recipes/openfst/all/test_package/CMakeLists.txt index cdd919fc9ae03e..71588be2b8f7ec 100644 --- a/recipes/openfst/all/test_package/CMakeLists.txt +++ b/recipes/openfst/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) set(CMAKE_CXX_STANDARD 17) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(OpenFst REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/openfst/all/test_package/conanfile.py b/recipes/openfst/all/test_package/conanfile.py index 90eb89e3f2f46b..ef5d7042163ecc 100644 --- a/recipes/openfst/all/test_package/conanfile.py +++ b/recipes/openfst/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/openfst/all/test_v1_package/CMakeLists.txt b/recipes/openfst/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/openfst/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/openfst/all/test_v1_package/conanfile.py b/recipes/openfst/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..90eb89e3f2f46b --- /dev/null +++ b/recipes/openfst/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 39a944e865c161cbad60c158c2d6c8fe37a4f646 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 10 Aug 2023 19:52:09 +0300 Subject: [PATCH 0166/1140] (#18939) djinni-generator: migrate to Conan v2 --- recipes/djinni-generator/all/conanfile.py | 47 ++++++++++++++----- .../all/test_package/conanfile.py | 22 +++++---- .../all/test_v1_package/conanfile.py | 21 +++++++++ 3 files changed, 69 insertions(+), 21 deletions(-) create mode 100644 recipes/djinni-generator/all/test_v1_package/conanfile.py diff --git a/recipes/djinni-generator/all/conanfile.py b/recipes/djinni-generator/all/conanfile.py index ae2c62ed78bb57..f6319f3914356b 100644 --- a/recipes/djinni-generator/all/conanfile.py +++ b/recipes/djinni-generator/all/conanfile.py @@ -1,37 +1,60 @@ import os -from conans import ConanFile, tools +from conan import ConanFile +from conan.tools.files import copy, download +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.47.0" class Djinni(ConanFile): name = "djinni-generator" + description = "Djinni is a tool for generating cross-language type declarations and interface bindings." + license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://djinni.xlcpp.dev" - description = "Djinni is a tool for generating cross-language type declarations and interface bindings." topics = ("java", "Objective-C", "ios", "Android") - license = "Apache-2.0" - settings = "os", "arch" + package_type = "application" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + del self.info.settings.compiler + del self.info.settings.build_type def source(self): filename = os.path.basename(self.conan_data["sources"][self.version]["url"]) - tools.download(filename=filename, **self.conan_data["sources"][self.version]) - tools.download(filename="LICENSE", url="https://raw.githubusercontent.com/cross-language-cpp/djinni-generator/main/LICENSE") + download(self, filename=filename, **self.conan_data["sources"][self.version]) + download(self, filename="LICENSE", url="https://raw.githubusercontent.com/cross-language-cpp/djinni-generator/main/LICENSE") def build(self): pass # avoid warning for missing build steps def package(self): - if tools.detected_os() == "Windows": - os.rename('djinni','djinni.bat') - self.copy("djinni.bat", dst="bin", keep_path=False) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder, + keep_path=False) + copy(self, "djinni", + dst=os.path.join(self.package_folder, "bin"), + src=self.source_folder, + keep_path=False) + if self.settings.os == "Windows": + os.rename(os.path.join(self.package_folder, "bin", "djinni"), + os.path.join(self.package_folder, "bin", "djinni.bat")) else: - self.copy("djinni", dst="bin", keep_path=False) executable = os.path.join(self.package_folder, "bin", "djinni") os.chmod(executable, os.stat(executable).st_mode | 0o111) - self.copy("LICENSE", dst="licenses", keep_path=False) def package_info(self): + self.cpp_info.frameworkdirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = [] self.cpp_info.includedirs = [] - self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) + # TODO: Legacy, to be removed on Conan 2.0 + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) diff --git a/recipes/djinni-generator/all/test_package/conanfile.py b/recipes/djinni-generator/all/test_package/conanfile.py index 456428a9a86702..7d899a138c0dd2 100644 --- a/recipes/djinni-generator/all/test_package/conanfile.py +++ b/recipes/djinni-generator/all/test_package/conanfile.py @@ -1,21 +1,25 @@ - from io import StringIO -from conans import ConanFile, tools + +from conan import ConanFile +from conan.tools.build import can_run + class TestPackageConan(ConanFile): - settings = "os", "arch" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" - def build(self): - pass # please no warning that we build nothing + def build_requirements(self): + self.tool_requires(self.tested_reference_str) def test(self): - if not tools.cross_building(self.settings): + if can_run(self): output = StringIO() - self.run("djinni --help", output=output, run_environment=True) - output.seek(0, 0) + self.run("djinni --help", output) + output.seek(0) found_usage = False for line in output: if "Usage: djinni [options]" in line: found_usage = True break - assert(found_usage) + assert found_usage diff --git a/recipes/djinni-generator/all/test_v1_package/conanfile.py b/recipes/djinni-generator/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..456428a9a86702 --- /dev/null +++ b/recipes/djinni-generator/all/test_v1_package/conanfile.py @@ -0,0 +1,21 @@ + +from io import StringIO +from conans import ConanFile, tools + +class TestPackageConan(ConanFile): + settings = "os", "arch" + + def build(self): + pass # please no warning that we build nothing + + def test(self): + if not tools.cross_building(self.settings): + output = StringIO() + self.run("djinni --help", output=output, run_environment=True) + output.seek(0, 0) + found_usage = False + for line in output: + if "Usage: djinni [options]" in line: + found_usage = True + break + assert(found_usage) From e69902cb0473c637073ebbc993a961f228440436 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 10 Aug 2023 20:29:25 +0300 Subject: [PATCH 0167/1140] (#18984) pupnp: migrate to Conan v2 --- recipes/pupnp/all/conanfile.py | 121 ++++++++---------- recipes/pupnp/all/test_package/CMakeLists.txt | 7 +- recipes/pupnp/all/test_package/conanfile.py | 21 ++- .../pupnp/all/test_v1_package/CMakeLists.txt | 8 ++ .../pupnp/all/test_v1_package/conanfile.py | 17 +++ 5 files changed, 96 insertions(+), 78 deletions(-) create mode 100644 recipes/pupnp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/pupnp/all/test_v1_package/conanfile.py diff --git a/recipes/pupnp/all/conanfile.py b/recipes/pupnp/all/conanfile.py index be3c8ca6dae343..b3ee88419c46cf 100644 --- a/recipes/pupnp/all/conanfile.py +++ b/recipes/pupnp/all/conanfile.py @@ -1,8 +1,14 @@ -from conans import AutoToolsBuildEnvironment, ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" class PupnpConan(ConanFile): @@ -15,8 +21,10 @@ class PupnpConan(ConanFile): license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/pupnp/pupnp" - topics = ("conan", "upnp", "networking") - settings = "os", "compiler", "build_type", "arch" + topics = ("upnp", "networking") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -28,7 +36,7 @@ class PupnpConan(ConanFile): "largefile": [True, False], "tools": [True, False], "blocking-tcp": [True, False], - "debug": [True, False] + "debug": [True, False], } default_options = { "shared": False, @@ -41,95 +49,74 @@ class PupnpConan(ConanFile): "largefile": True, "tools": True, "blocking-tcp": False, - "debug": True # Actually enables logging routines... + "debug": True, } - _autotools = None - @property - def _source_subfolder(self): - return "source_subfolder" + def _settings_build(self): + return getattr(self, "settings_build", self.settings) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.compiler == "Visual Studio": + if is_msvc(self): # Note, pupnp has build instructions for Visual Studio but they # include VC 6 and require pthreads-w32 library. # Someone who needs it and has possibility to build it could step in. raise ConanInvalidConfiguration("Visual Studio not supported yet in this recipe") - @property - def _settings_build(self): - return getattr(self, "settings_build", self.settings) - def build_requirements(self): - self.build_requires("libtool/2.4.6") - self.build_requires("pkgconf/1.7.4") - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): - self.build_requires("msys2/cci.latest") + self.tool_requires("libtool/2.4.7") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _configure_autotools(self): - if not self._autotools: - args = [ - "--enable-static=%s" % ("no" if self.options.shared else "yes"), - "--enable-shared=%s" % ("yes" if self.options.shared else "no"), - "--disable-samples", - ] - - def enable_disable(opt): - what = "enable" if getattr(self.options, opt) else "disable" - return "--{}-{}".format(what, opt) - - args.extend( - map( - enable_disable, - ( - "ipv6", - "reuseaddr", - "webserver", - "client", - "device", - "largefile", - "tools", - "debug" - ), - ) - ) - - args.append("--%s-blocking_tcp_connections" % ("enable" if getattr(self.options, "blocking-tcp") else "disable")) - - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) - self._autotools.configure(configure_dir=self._source_subfolder, args=args) - return self._autotools + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + tc = AutotoolsToolchain(self) + features = {} + features["samples"] = False + features["blocking_tcp_connections"] = self.options["blocking-tcp"] + for opt in ("ipv6", "reuseaddr", "webserver", "client", "device", "largefile", "tools", "debug"): + features[opt] = self.options[opt] + for feature, enabled in features.items(): + what = "enable" if enabled else "disable" + tc.configure_args.append(f"--{what}-{feature}") + tc.generate() def build(self): - with tools.chdir(self._source_subfolder): - self.run("{} -fiv".format(tools.get_env("AUTORECONF")), win_bash=tools.os_info.is_windows) - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.autoreconf() + autotools.configure() autotools.make() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + autotools = Autotools(self) autotools.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) def package_info(self): - self.cpp_info.names["pkg_config"] = "libupnp" + self.cpp_info.set_property("pkg_config_name", "libupnp") self.cpp_info.libs = ["upnp", "ixml"] self.cpp_info.includedirs.append(os.path.join("include", "upnp")) if self.settings.os in ["Linux", "FreeBSD"]: diff --git a/recipes/pupnp/all/test_package/CMakeLists.txt b/recipes/pupnp/all/test_package/CMakeLists.txt index 4715fd995b522f..d453ce024a9683 100644 --- a/recipes/pupnp/all/test_package/CMakeLists.txt +++ b/recipes/pupnp/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(pupnp REQUIRED) +find_package(pupnp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} pupnp::pupnp) diff --git a/recipes/pupnp/all/test_package/conanfile.py b/recipes/pupnp/all/test_package/conanfile.py index 91263ae215697e..ef5d7042163ecc 100644 --- a/recipes/pupnp/all/test_package/conanfile.py +++ b/recipes/pupnp/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import CMake, ConanFile, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class PupnpTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self, skip_x64_x86=True): - self.run(os.path.join("bin", "test_package"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pupnp/all/test_v1_package/CMakeLists.txt b/recipes/pupnp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/pupnp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/pupnp/all/test_v1_package/conanfile.py b/recipes/pupnp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..b1255b47b830e3 --- /dev/null +++ b/recipes/pupnp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os + +from conans import CMake, ConanFile, tools + + +class PupnpTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self, skip_x64_x86=True): + self.run(os.path.join("bin", "test_package"), run_environment=True) From 29994e05d35b6756254b90a88204d69ff7a6314a Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 11 Aug 2023 02:52:46 +0900 Subject: [PATCH 0168/1140] (#19133) libmysqlclient: add version 8.1.0 --- recipes/libmysqlclient/all/conandata.yml | 7 +++++++ .../patches/0006-fix-cpp20-build-8.1.0.patch | 17 +++++++++++++++++ recipes/libmysqlclient/config.yml | 2 ++ 3 files changed, 26 insertions(+) create mode 100644 recipes/libmysqlclient/all/patches/0006-fix-cpp20-build-8.1.0.patch diff --git a/recipes/libmysqlclient/all/conandata.yml b/recipes/libmysqlclient/all/conandata.yml index 6ace30de169748..78b5ed97e3e15f 100644 --- a/recipes/libmysqlclient/all/conandata.yml +++ b/recipes/libmysqlclient/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.1.0": + url: "https://dev.mysql.com/get/Downloads/MySQL-8.1/mysql-8.1.0.tar.gz" + sha256: "3dd017a940734aa90796a4c65e125e6712f64bbbbe3388d36469deaa87b599eb" "8.0.34": url: "https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.34.tar.gz" sha256: "e65d03a3c42618b5fbf99042aed33209402e9b27aa62c7c8743ffd4788d8db1d" @@ -12,6 +15,10 @@ sources: url: "https://dev.mysql.com/get/Downloads/MySQL-8.0/mysql-8.0.25.tar.gz" sha256: "c16aa9cf621bc028efba2bb11f3c36a323b125fa0d108ff92fab60e46309206e" patches: + "8.1.0": + - patch_file: "patches/0006-fix-cpp20-build-8.1.0.patch" + patch_description: "Fix C++20 compilation" + patch_type: "portability" "8.0.34": - patch_file: "patches/0006-fix-cpp20-build-8.0.29.patch" patch_description: "Fix C++20 compilation" diff --git a/recipes/libmysqlclient/all/patches/0006-fix-cpp20-build-8.1.0.patch b/recipes/libmysqlclient/all/patches/0006-fix-cpp20-build-8.1.0.patch new file mode 100644 index 00000000000000..ebaba58ec7fab0 --- /dev/null +++ b/recipes/libmysqlclient/all/patches/0006-fix-cpp20-build-8.1.0.patch @@ -0,0 +1,17 @@ +diff --git a/sql/sql_bitmap.h b/sql/sql_bitmap.h +index 0f4a540..bd81a40 100644 +--- a/sql/sql_bitmap.h ++++ b/sql/sql_bitmap.h +@@ -145,10 +145,10 @@ class Bitmap<64> { + ulonglong map; + + public: +- Bitmap<64>() { init(); } ++ Bitmap() { init(); } + enum { ALL_BITS = 64 }; + +- explicit Bitmap<64>(uint prefix_to_set) { set_prefix(prefix_to_set); } ++ explicit Bitmap(uint prefix_to_set) { set_prefix(prefix_to_set); } + void init() { clear_all(); } + void init(uint prefix_to_set) { set_prefix(prefix_to_set); } + uint length() const { return 64; } diff --git a/recipes/libmysqlclient/config.yml b/recipes/libmysqlclient/config.yml index 7df89d243f4953..1b617851b7de68 100644 --- a/recipes/libmysqlclient/config.yml +++ b/recipes/libmysqlclient/config.yml @@ -1,4 +1,6 @@ versions: + "8.1.0": + folder: all "8.0.34": folder: all "8.0.31": From d8efa063851f272049a78807deae4a957db68068 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Thu, 10 Aug 2023 20:35:27 +0200 Subject: [PATCH 0169/1140] (#19143) [freetype] Bump requirements for libpng and zlib --- recipes/freetype/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/freetype/all/conanfile.py b/recipes/freetype/all/conanfile.py index 2d1c5c126ce107..5073e3cf9b655b 100644 --- a/recipes/freetype/all/conanfile.py +++ b/recipes/freetype/all/conanfile.py @@ -64,9 +64,9 @@ def layout(self): def requirements(self): if self.options.with_png: - self.requires("libpng/1.6.40") + self.requires("libpng/[>=1.6 <1.7]") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2 <1.3]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.get_safe("with_brotli"): From c23527885c7fa4df0c1c1c9d0d69602b1fc43dbf Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 11 Aug 2023 16:30:16 +0900 Subject: [PATCH 0170/1140] (#19149) zookeeper-client-c: add version 3.9.0 --- recipes/zookeeper-client-c/all/conandata.yml | 7 +++++++ recipes/zookeeper-client-c/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/zookeeper-client-c/all/conandata.yml b/recipes/zookeeper-client-c/all/conandata.yml index f81d1f4e6d34ff..0487be945d8c94 100644 --- a/recipes/zookeeper-client-c/all/conandata.yml +++ b/recipes/zookeeper-client-c/all/conandata.yml @@ -1,8 +1,15 @@ sources: + "3.9.0": + url: "https://archive.apache.org/dist/zookeeper/zookeeper-3.9.0/apache-zookeeper-3.9.0.tar.gz" + sha256: "c7af07e7411c798398bb8cd50f47780d8e014831666c41df6ec6540c143c0da2" "3.8.1": url: "https://archive.apache.org/dist/zookeeper/zookeeper-3.8.1/apache-zookeeper-3.8.1.tar.gz" sha256: "ccc16850c8ab2553583583234d11c813061b5ea5f3b8ff1d740cde6c1fd1e219" patches: + "3.9.0": + - patch_file: "patches/3.8.1-0001-add-install.patch" + patch_description: "add installer, disable cli program" + patch_type: "conan" "3.8.1": - patch_file: "patches/3.8.1-0001-add-install.patch" patch_description: "add installer, disable cli program" diff --git a/recipes/zookeeper-client-c/config.yml b/recipes/zookeeper-client-c/config.yml index f3cf585c380d6d..31b8685d6b74af 100644 --- a/recipes/zookeeper-client-c/config.yml +++ b/recipes/zookeeper-client-c/config.yml @@ -1,3 +1,5 @@ versions: + "3.9.0": + folder: all "3.8.1": folder: all From b47f2ebfbf29742e5c1c7ceba26f674d784c0524 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 11 Aug 2023 10:44:49 +0200 Subject: [PATCH 0171/1140] (#19139) [bot] Update authorized users list (2023-08-10) --- .c3i/authorized_users.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 902e3fd4b97b9c..29f7167d2ab9c5 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1209,3 +1209,6 @@ authorized_users: - aliaksei135 - ibosnic00 - Xav83 +- matthewT53 +- sjlamerton +- marxin From 6ee3c95cb77ed11b7dfeda27d93895fb9052a102 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 11 Aug 2023 11:03:11 +0200 Subject: [PATCH 0172/1140] (#19142) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 00fca464901176..2158d3f771f43f 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -119,6 +119,7 @@ required_for_references: - canvas_ity - capnproto - capstone +- cargs - catch2 - ccache - cccl From bd75b4178d25de88a5a3215216e008e3330d88ab Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 11 Aug 2023 11:28:21 +0200 Subject: [PATCH 0173/1140] (#19128) wil: add 1.0.230629.1 --- recipes/wil/all/conandata.yml | 3 +++ recipes/wil/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/wil/all/conandata.yml b/recipes/wil/all/conandata.yml index a123bb6fadf863..9253a5b752cf37 100644 --- a/recipes/wil/all/conandata.yml +++ b/recipes/wil/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.230629.1": + url: "https://github.com/microsoft/wil/archive/refs/tags/v1.0.230629.1.tar.gz" + sha256: "c0d9ad1f295e181aa28d7c9b219e7d530e6bc4b7533317be50e7eae760c8d63f" "1.0.230411.1": url: "https://github.com/microsoft/wil/archive/refs/tags/v1.0.230411.1.tar.gz" sha256: "03742849f5cb458fcfe8d30ff7afb6ff4bd67fe3aee3768cd6fb1140c59fcfd3" diff --git a/recipes/wil/config.yml b/recipes/wil/config.yml index 4e26f7b007f298..00c073f03a7a2b 100644 --- a/recipes/wil/config.yml +++ b/recipes/wil/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.230629.1": + folder: "all" "1.0.230411.1": folder: "all" "1.0.230202.1": From 02ab9f1d8a79fa9e1937acde59d946df13dc095f Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Fri, 11 Aug 2023 12:07:39 +0200 Subject: [PATCH 0174/1140] (#18438) [sentry-native/0.6.5] Add version * [sentry-native/0.6.4] Add version * [sentry-native/0.6.5] Add version --- recipes/sentry-native/all/conandata.yml | 6 +++--- recipes/sentry-native/config.yml | 4 ++-- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/sentry-native/all/conandata.yml b/recipes/sentry-native/all/conandata.yml index 17d89711effcc9..ced5e36dba275c 100644 --- a/recipes/sentry-native/all/conandata.yml +++ b/recipes/sentry-native/all/conandata.yml @@ -1,13 +1,13 @@ sources: + "0.6.5": + url: "https://github.com/getsentry/sentry-native/releases/download/0.6.5/sentry-native.zip" + sha256: "5f74a5c5c3abc6e1e7825d3306be9e3b3fd4e0f586f3cf7e86607d6f56a71995" "0.6.4": url: "https://github.com/getsentry/sentry-native/releases/download/0.6.4/sentry-native.zip" sha256: "e00278bf9a4821bb4008985a5a552a84aba6ebb06d3f9e828082fcbf06b04a38" "0.6.3": url: "https://github.com/getsentry/sentry-native/releases/download/0.6.3/sentry-native.zip" sha256: "6b515c17a9b860ea47c6a5fd7abdfdc89b4b8cbc654c23a8bb42a39bfcb87ad9" - "0.6.2": - url: "https://github.com/getsentry/sentry-native/releases/download/0.6.2/sentry-native.zip" - sha256: "9b9f4b2cec961ca132039c7887fb876b3dd6f4795b31ca01d188187f69758efa" "0.5.4": url: "https://github.com/getsentry/sentry-native/releases/download/0.5.4/sentry-native.zip" sha256: "e151bdc76894eb964ba4637361b2a96b7447fb04212053cf695fd7f72b636e4d" diff --git a/recipes/sentry-native/config.yml b/recipes/sentry-native/config.yml index fb99bc2eb64b89..3450228c14b096 100644 --- a/recipes/sentry-native/config.yml +++ b/recipes/sentry-native/config.yml @@ -1,10 +1,10 @@ versions: + "0.6.5": + folder: all "0.6.4": folder: all "0.6.3": folder: all - "0.6.2": - folder: all "0.5.4": folder: all "0.4.18": From 62f912380c62db5add03821791a9fc6d3f688e30 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 11 Aug 2023 12:30:06 +0200 Subject: [PATCH 0175/1140] (#19003) dbus: enable static build MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * dbus: enable static build * fix windows static library name * Update recipes/dbus/1.x.x/conanfile.py Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries Co-authored-by: Rubén Rincón Blanco --- recipes/dbus/1.x.x/conandata.yml | 12 -- recipes/dbus/1.x.x/conanfile.py | 134 ++++++------------ .../1.x.x/patches/0001-cmake-project.patch | 23 --- ...make_configure_checks_list_separator.patch | 22 --- recipes/dbus/config.yml | 4 - 5 files changed, 47 insertions(+), 148 deletions(-) delete mode 100644 recipes/dbus/1.x.x/patches/0001-cmake-project.patch delete mode 100644 recipes/dbus/1.x.x/patches/0002-cmake_configure_checks_list_separator.patch diff --git a/recipes/dbus/1.x.x/conandata.yml b/recipes/dbus/1.x.x/conandata.yml index c3b193cfa06c5e..3dc58977ca2ea4 100644 --- a/recipes/dbus/1.x.x/conandata.yml +++ b/recipes/dbus/1.x.x/conandata.yml @@ -8,12 +8,6 @@ sources: "1.15.0": url: "https://dbus.freedesktop.org/releases/dbus/dbus-1.15.0.tar.xz" sha256: "5073c8cb9ad20226647bb38f4965182b762a6e1f595ccdc8e59411014bfd640a" - "1.14.0": - url: "https://dbus.freedesktop.org/releases/dbus/dbus-1.14.0.tar.xz" - sha256: "ccd7cce37596e0a19558fd6648d1272ab43f011d80c8635aea8fd0bad58aebd4" - "1.12.20": - url: "https://dbus.freedesktop.org/releases/dbus/dbus-1.12.20.tar.gz" - sha256: "f77620140ecb4cdc67f37fb444f8a6bea70b5b6461f12f1cbe2cec60fa7de5fe" patches: "1.15.2": - patch_file: "patches/0003-meson-monotonic-clock-check.patch" @@ -25,9 +19,3 @@ patches: patch_type: "portability" patch_description: "Fix detection of necessary monotonic clock functions in pthread" patch_source: "https://gitlab.freedesktop.org/dbus/dbus/-/merge_requests/352" - "1.12.20": - - patch_file: "patches/0001-cmake-project.patch" - - patch_file: "patches/0002-cmake_configure_checks_list_separator.patch" - patch_type: "portability" - url: "https://gitlab.freedesktop.org/dbus/dbus/-/commit/8cd1c2155252938ed38d2612e4d054c7fc0244c3.patch" - patch_source: "https://gitlab.freedesktop.org/dbus/dbus/-/issues/324" diff --git a/recipes/dbus/1.x.x/conanfile.py b/recipes/dbus/1.x.x/conanfile.py index 7be295c8d86058..c20fd3f03b189c 100644 --- a/recipes/dbus/1.x.x/conanfile.py +++ b/recipes/dbus/1.x.x/conanfile.py @@ -1,7 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.apple import fix_apple_shared_install_name, is_apple_os -from conan.tools.cmake import CMake, cmake_layout, CMakeDeps, CMakeToolchain from conan.tools.env import VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, mkdir, rename, replace_in_file, rm, rmdir, save from conan.tools.gnu import PkgConfigDeps @@ -21,10 +20,12 @@ class DbusConan(ConanFile): homepage = "https://www.freedesktop.org/wiki/Software/dbus" description = "D-Bus is a simple system for interprocess communication and coordination." topics = "bus", "interprocess", "message" - package_type = "shared-library" + package_type = "library" settings = "os", "arch", "compiler", "build_type" short_paths = True options = { + "shared": [True, False], + "fPIC": [True, False], "system_socket": [None, "ANY"], "system_pid_file": [None, "ANY"], "with_x11": [True, False], @@ -34,6 +35,8 @@ class DbusConan(ConanFile): "session_socket_dir": ["ANY"], } default_options = { + "shared": False, + "fPIC": True, "system_socket": None, "system_pid_file": None, "with_x11": False, @@ -43,28 +46,25 @@ class DbusConan(ConanFile): "session_socket_dir": "/tmp", } - @property - def _meson_available(self): - return Version(self.version) >= "1.15.0" - def export_sources(self): export_conandata_patches(self) def config_options(self): - if self.settings.os not in ("Linux", "FreeBSD") or Version(self.version) < "1.14.0": + if self.settings.os not in ("Linux", "FreeBSD"): del self.options.with_systemd if self.settings.os not in ("Linux", "FreeBSD"): del self.options.with_x11 + if self.settings.os == "Windows": + del self.options.fPIC def configure(self): self.settings.rm_safe("compiler.cppstd") self.settings.rm_safe("compiler.libcxx") + if self.options.shared: + self.options.rm_safe("fPIC") def layout(self): - if self._meson_available: - basic_layout(self, src_folder="src") - else: - cmake_layout(self, src_folder="src") + basic_layout(self, src_folder="src") def requirements(self): self.requires("expat/2.5.0") @@ -78,19 +78,13 @@ def requirements(self): self.requires("xorg/system") def validate(self): - if Version(self.version) >= "1.14.0": - if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < 7: - raise ConanInvalidConfiguration(f"{self.ref} requires at least gcc 7.") - - if not self._meson_available and self.settings.os == "Windows": - raise ConanInvalidConfiguration(f"{self.ref} does not support Windows. Contributions welcome.") + if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < 7: + raise ConanInvalidConfiguration(f"{self.ref} requires at least gcc 7.") def build_requirements(self): - if self._meson_available: - self.tool_requires("meson/1.2.0") - if self._meson_available or self.options.get_safe("with_systemd"): - if not self.conf.get("tools.gnu:pkg_config",check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("meson/1.2.0") + if not self.conf.get("tools.gnu:pkg_config",check_type=str): + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -98,77 +92,38 @@ def source(self): def generate(self): env = VirtualBuildEnv(self) env.generate() - if self._meson_available: - tc = MesonToolchain(self) - tc.project_options["asserts"] = not is_apple_os(self) - tc.project_options["checks"] = False - tc.project_options["doxygen_docs"] = "disabled" - tc.project_options["modular_tests"] = "disabled" - tc.project_options["system_socket"] = str(self.options.get_safe("system_socket", "")) - tc.project_options["system_pid_file"] = str(self.options.get_safe("system_pid_file", "")) - tc.project_options["session_socket_dir"] = str(self.options.get_safe("session_socket_dir", "")) - tc.project_options["selinux"] = "enabled" if self.options.get_safe("with_selinux", False) else "disabled" - tc.project_options["systemd"] = "enabled" if self.options.get_safe("with_systemd", False) else "disabled" - if self.options.get_safe("with_systemd", False): - tc.project_options["systemd_system_unitdir"] = os.path.join(self.package_folder, "lib", "systemd", "system") - tc.project_options["systemd_user_unitdir"] = os.path.join(self.package_folder, "lib", "systemd", "user") - if is_apple_os(self): - tc.project_options["launchd_agent_dir"] = os.path.join(self.package_folder, "res", "LaunchAgents") - tc.project_options["x11_autolaunch"] = "enabled" if self.options.get_safe("with_x11", False) else "disabled" - tc.project_options["xml_docs"] = "disabled" - tc.generate() - deps = PkgConfigDeps(self) - deps.generate() - else: - tc = CMakeToolchain(self) - tc.variables["DBUS_BUILD_TESTS"] = False - tc.variables["DBUS_ENABLE_DOXYGEN_DOCS"] = False - tc.variables["DBUS_ENABLE_XML_DOCS"] = False - tc.variables["DBUS_BUILD_X11"] = bool(self.options.get_safe("with_x11", False)) - tc.variables["ENABLE_SYSTEMD"] = "ON" if self.options.get_safe("with_systemd", False) else "OFF" - tc.variables["DBUS_WITH_GLIB"] = bool(self.options.get_safe("with_glib", False)) - tc.variables["DBUS_DISABLE_ASSERT"] = is_apple_os(self) - tc.variables["DBUS_DISABLE_CHECKS"] = False - tc.variables["DBUS_SYSTEM_BUS_DEFAULT_ADDRESS"] = str(self.options.get_safe("system_socket", "")) - - # Conan does not provide an EXPAT_LIBRARIES CMake variable for the Expat library. - # Define EXPAT_LIBRARIES to be the expat::expat target provided by Conan to fix linking. - tc.variables["EXPAT_LIBRARIES"] = "expat::expat" - - # https://github.com/freedesktop/dbus/commit/e827309976cab94c806fda20013915f1db2d4f5a - tc.variables["DBUS_SESSION_SOCKET_DIR"] = str(self.options.get_safe("session_socket_dir", "")) - - tc.cache_variables["CMAKE_FIND_PACKAGE_PREFER_CONFIG"] = False - tc.generate() - cmake_deps = CMakeDeps(self) - cmake_deps.generate() - if self.options.get_safe("with_systemd"): - deps = PkgConfigDeps(self) - deps.generate() + tc = MesonToolchain(self) + tc.project_options["asserts"] = not is_apple_os(self) + tc.project_options["checks"] = False + tc.project_options["doxygen_docs"] = "disabled" + tc.project_options["modular_tests"] = "disabled" + tc.project_options["system_socket"] = str(self.options.get_safe("system_socket", "")) + tc.project_options["system_pid_file"] = str(self.options.get_safe("system_pid_file", "")) + tc.project_options["session_socket_dir"] = str(self.options.get_safe("session_socket_dir", "")) + tc.project_options["selinux"] = "enabled" if self.options.get_safe("with_selinux", False) else "disabled" + tc.project_options["systemd"] = "enabled" if self.options.get_safe("with_systemd", False) else "disabled" + if self.options.get_safe("with_systemd", False): + tc.project_options["systemd_system_unitdir"] = os.path.join(self.package_folder, "lib", "systemd", "system") + tc.project_options["systemd_user_unitdir"] = os.path.join(self.package_folder, "lib", "systemd", "user") + if is_apple_os(self): + tc.project_options["launchd_agent_dir"] = os.path.join(self.package_folder, "res", "LaunchAgents") + tc.project_options["x11_autolaunch"] = "enabled" if self.options.get_safe("with_x11", False) else "disabled" + tc.project_options["xml_docs"] = "disabled" + tc.generate() + deps = PkgConfigDeps(self) + deps.generate() def build(self): apply_conandata_patches(self) - if self._meson_available: - replace_in_file(self, os.path.join(self.source_folder, "meson.build"), "subdir('test')", "# subdir('test')") - meson = Meson(self) - meson.configure() - meson.build() - else: - cmake = CMake(self) - build_script_folder = None - if Version(self.version) < "1.14.0": - build_script_folder = "cmake" - cmake.configure(build_script_folder=build_script_folder) - cmake.build() + replace_in_file(self, os.path.join(self.source_folder, "meson.build"), "subdir('test')", "# subdir('test')") + meson = Meson(self) + meson.configure() + meson.build() def package(self): copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) - if self._meson_available: - meson = Meson(self) - meson.install() - else: - cmake = CMake(self) - cmake.install() + meson = Meson(self) + meson.install() rm(self, "*.pdb", os.path.join(self.package_folder, "bin")) rmdir(self, os.path.join(self.package_folder, "share", "doc")) @@ -180,6 +135,8 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "lib", "systemd")) fix_apple_shared_install_name(self) + if self.settings.os == "Windows" and not self.options.shared: + rename(self, os.path.join(self.package_folder, "lib", "libdbus-1.a"), os.path.join(self.package_folder, "lib", "dbus-1.lib")) # TODO: to remove in conan v2 once cmake_find_package_* generators removed self._create_cmake_module_alias_targets( @@ -219,6 +176,9 @@ def package_info(self): else: self.cpp_info.system_libs.append("pthread") + if not self.options.shared: + self.cpp_info.defines.append("DBUS_STATIC_BUILD") + # TODO: to remove in conan v2 once cmake_find_package_* & pkg_config generators removed self.cpp_info.filenames["cmake_find_package"] = "DBus1" self.cpp_info.filenames["cmake_find_package_multi"] = "DBus1" diff --git a/recipes/dbus/1.x.x/patches/0001-cmake-project.patch b/recipes/dbus/1.x.x/patches/0001-cmake-project.patch deleted file mode 100644 index 2d00f57d33527d..00000000000000 --- a/recipes/dbus/1.x.x/patches/0001-cmake-project.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- a/cmake/CMakeLists.txt -+++ b/cmake/CMakeLists.txt -@@ -1,10 +1,3 @@ --# where to look first for cmake modules, before ${CMAKE_ROOT}/Modules/ is checked --list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/modules") -- --# we do not need to have WIN32 defined --set(CMAKE_LEGACY_CYGWIN_WIN32 0) -- --project(dbus) - - # we need to be up to date - CMAKE_MINIMUM_REQUIRED(VERSION 3.0.2 FATAL_ERROR) -@@ -19,6 +12,9 @@ if(CMAKE_MAJOR_VERSION GREATER 2) - cmake_policy(SET CMP0054 NEW) - endif() - endif() -+set(CMAKE_LEGACY_CYGWIN_WIN32 0) -+project(dbus) -+list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/modules") - - # detect version - include(MacrosAutotools) diff --git a/recipes/dbus/1.x.x/patches/0002-cmake_configure_checks_list_separator.patch b/recipes/dbus/1.x.x/patches/0002-cmake_configure_checks_list_separator.patch deleted file mode 100644 index 7c60bf52d5ec22..00000000000000 --- a/recipes/dbus/1.x.x/patches/0002-cmake_configure_checks_list_separator.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff --git a/cmake/ConfigureChecks.cmake b/cmake/ConfigureChecks.cmake -index a9a5fc90..1a59461a 100644 ---- a/cmake/ConfigureChecks.cmake -+++ b/cmake/ConfigureChecks.cmake -@@ -43,7 +43,7 @@ check_symbol_exists(backtrace "execinfo.h" HAVE_BACKTRACE) # - check_symbol_exists(getgrouplist "grp.h" HAVE_GETGROUPLIST) # dbus-sysdeps.c - check_symbol_exists(getpeerucred "ucred.h" HAVE_GETPEERUCRED) # dbus-sysdeps.c, dbus-sysdeps-win.c - check_symbol_exists(nanosleep "time.h" HAVE_NANOSLEEP) # dbus-sysdeps.c --check_symbol_exists(getpwnam_r "errno.h pwd.h" HAVE_POSIX_GETPWNAM_R) # dbus-sysdeps-util-unix.c -+check_symbol_exists(getpwnam_r "errno.h;pwd.h" HAVE_POSIX_GETPWNAM_R) # dbus-sysdeps-util-unix.c - check_symbol_exists(setenv "stdlib.h" HAVE_SETENV) # dbus-sysdeps.c - check_symbol_exists(unsetenv "stdlib.h" HAVE_UNSETENV) # dbus-sysdeps.c - check_symbol_exists(clearenv "stdlib.h" HAVE_CLEARENV) # dbus-sysdeps.c -@@ -66,7 +66,7 @@ check_symbol_exists(getrlimit "sys/resource.h;sys/time.h" HAVE_GETRLIMIT) - check_symbol_exists(prlimit "sys/resource.h;sys/time.h" HAVE_PRLIMIT) - check_symbol_exists(setrlimit "sys/resource.h;sys/time.h" HAVE_SETRLIMIT) - --check_struct_member(cmsgcred cmcred_pid "sys/types.h sys/socket.h" HAVE_CMSGCRED) # dbus-sysdeps.c -+check_struct_member(cmsgcred cmcred_pid "sys/types.h;sys/socket.h" HAVE_CMSGCRED) # dbus-sysdeps.c - - # missing: - # DBUS_HAVE_GCC33_GCOV diff --git a/recipes/dbus/config.yml b/recipes/dbus/config.yml index b9caba7b443496..53bb57eb6cadcd 100644 --- a/recipes/dbus/config.yml +++ b/recipes/dbus/config.yml @@ -5,7 +5,3 @@ versions: folder: 1.x.x "1.15.0": folder: 1.x.x - "1.14.0": - folder: 1.x.x - "1.12.20": - folder: 1.x.x From b65900a5b8d1b1c96b1e99ebc2b8dc8f293fc9bb Mon Sep 17 00:00:00 2001 From: Jason Sobotka Date: Fri, 11 Aug 2023 06:07:06 -0500 Subject: [PATCH 0176/1140] (#18027) [gdal] add version 3.7.0 --- recipes/gdal/config.yml | 2 + recipes/gdal/post_3.5.0/conandata.yml | 6 + .../3.7.0/0-replace-find-package.patch | 282 ++++++++++++++++++ 3 files changed, 290 insertions(+) create mode 100644 recipes/gdal/post_3.5.0/patches/3.7.0/0-replace-find-package.patch diff --git a/recipes/gdal/config.yml b/recipes/gdal/config.yml index 3a324b7465d342..da2f4dc3a9cabb 100644 --- a/recipes/gdal/config.yml +++ b/recipes/gdal/config.yml @@ -1,4 +1,6 @@ versions: + "3.7.0": + folder: "post_3.5.0" "3.5.2": folder: "post_3.5.0" "3.5.1": diff --git a/recipes/gdal/post_3.5.0/conandata.yml b/recipes/gdal/post_3.5.0/conandata.yml index 2dbc2d17b374fa..6ac086393ccfdc 100644 --- a/recipes/gdal/post_3.5.0/conandata.yml +++ b/recipes/gdal/post_3.5.0/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.7.0": + url: "https://github.com/OSGeo/gdal/releases/download/v3.7.0/gdal-3.7.0.tar.gz" + sha256: "5a806d759f403a15bbbf8a14ecc6947071afc5ab91e5abaef0d11d1d2d16bf94" "3.5.2": url: "https://github.com/OSGeo/gdal/releases/download/v3.5.2/gdal-3.5.2.tar.gz" sha256: "fbd696e1b2a858fbd2eb3718db16b14ed9ba82521d3578770d480c74fe1146d2" @@ -6,6 +9,9 @@ sources: url: "https://github.com/OSGeo/gdal/releases/download/v3.5.1/gdal-3.5.1.tar.gz" sha256: "7c4406ca010dc8632703a0a326f39e9db25d9f1f6ebaaeca64a963e3fac123d1" patches: + "3.7.0": + - patch_file: "patches/3.7.0/0-replace-find-package.patch" + base_path: "source_subfolder" "3.5.2": - patch_file: "patches/3.5.2/0-replace-find-package.patch" base_path: "source_subfolder" diff --git a/recipes/gdal/post_3.5.0/patches/3.7.0/0-replace-find-package.patch b/recipes/gdal/post_3.5.0/patches/3.7.0/0-replace-find-package.patch new file mode 100644 index 00000000000000..34401a53eae6d4 --- /dev/null +++ b/recipes/gdal/post_3.5.0/patches/3.7.0/0-replace-find-package.patch @@ -0,0 +1,282 @@ +diff -urN ./a/alg/CMakeLists.txt ./b/alg/CMakeLists.txt +--- ./a/alg/CMakeLists.txt 2023-05-02 08:47:11.000000000 -0500 ++++ ./b/alg/CMakeLists.txt 2023-06-06 16:47:02.784509800 -0500 +@@ -73,7 +73,7 @@ + target_sources(alg PRIVATE gdalwarpkernel_opencl.h gdalwarpkernel_opencl.cpp) + endif () + +-gdal_target_link_libraries(alg PRIVATE PROJ::proj) ++target_link_libraries(alg PUBLIC PROJ::proj) + + if (GDAL_USE_QHULL_INTERNAL) + target_compile_definitions(alg PRIVATE -DINTERNAL_QHULL) +diff -urN ./a/apps/CMakeLists.txt ./b/apps/CMakeLists.txt +--- ./a/apps/CMakeLists.txt 2023-05-02 08:47:11.000000000 -0500 ++++ ./b/apps/CMakeLists.txt 2023-06-06 16:46:55.380690700 -0500 +@@ -26,7 +26,7 @@ + appslib PRIVATE $ $ + $ $) + +-gdal_target_link_libraries(appslib PRIVATE PROJ::proj) ++target_link_libraries(appslib PUBLIC PROJ::proj) + + set_property(TARGET appslib PROPERTY POSITION_INDEPENDENT_CODE ${GDAL_OBJECT_LIBRARIES_POSITION_INDEPENDENT_CODE}) + if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.16) +diff -urN ./a/cmake/helpers/CheckDependentLibraries.cmake ./b/cmake/helpers/CheckDependentLibraries.cmake +--- ./a/cmake/helpers/CheckDependentLibraries.cmake 2023-06-07 09:33:06.599777700 -0500 ++++ ./b/cmake/helpers/CheckDependentLibraries.cmake 2023-06-07 13:38:51.722872200 -0500 +@@ -11,7 +11,8 @@ + include(CheckFunctionExists) + include(CMakeDependentOption) + include(FeatureSummary) +-include(DefineFindPackage2) ++#include(DefineFindPackage2) ++include(ConanFindPackage) + include(CheckSymbolExists) + + option( +@@ -109,51 +110,8 @@ + string(TOUPPER ${name} key) + set(_find_dependency "") + set(_find_dependency_args "") +- if(FIND_PACKAGE2_${name}_ENABLED) +- find_package2(${name} QUIET OUT_DEPENDENCY _find_dependency) +- else() +- set(_find_package_args) +- if (_GCP_VERSION) +- list(APPEND _find_package_args ${_GCP_VERSION}) +- endif () +- if (_GCP_CONFIG) +- list(APPEND _find_package_args CONFIG) +- endif () +- if (_GCP_COMPONENTS) +- list(APPEND _find_package_args COMPONENTS ${_GCP_COMPONENTS}) +- endif () +- if (_GCP_PATHS) +- list(APPEND _find_package_args PATHS ${_GCP_PATHS}) +- endif () +- if (_GCP_NAMES) +- set(GDAL_CHECK_PACKAGE_${name}_NAMES "${_GCP_NAMES}" CACHE STRING "Config file name for ${name}") +- mark_as_advanced(GDAL_CHECK_PACKAGE_${name}_NAMES) +- endif () +- if (_GCP_TARGETS) +- set(GDAL_CHECK_PACKAGE_${name}_TARGETS "${_GCP_TARGETS}" CACHE STRING "Target name candidates for ${name}") +- mark_as_advanced(GDAL_CHECK_PACKAGE_${name}_TARGETS) +- endif () +- if (GDAL_CHECK_PACKAGE_${name}_NAMES) +- find_package(${name} NAMES ${GDAL_CHECK_PACKAGE_${name}_NAMES} ${_find_package_args}) +- gdal_check_package_target(${name} ${GDAL_CHECK_PACKAGE_${name}_TARGETS} REQUIRED) +- if (${name}_FOUND) +- get_filename_component(_find_dependency_args "${${name}_CONFIG}" NAME) +- string(REPLACE ";" " " _find_dependency_args "${name} NAMES ${GDAL_CHECK_PACKAGE_${name}_NAMES} CONFIGS ${_find_dependency_args} ${_find_package_args}") +- endif () +- endif () +- if (NOT ${name}_FOUND) +- find_package(${name} ${_find_package_args}) +- if (${name}_FOUND) +- gdal_check_package_target(${name} ${GDAL_CHECK_PACKAGE_${name}_TARGETS}) +- elseif (${key}_FOUND) # Some find modules do not set _FOUND +- gdal_check_package_target(${key} ${GDAL_CHECK_PACKAGE_${name}_TARGETS}) +- set(${name}_FOUND "${key}_FOUND") +- endif () +- if (${name}_FOUND) +- string(REPLACE ";" " " _find_dependency_args "${name} ${_find_package_args}") +- endif() +- endif () +- endif () ++ ++ find_package2(${name} QUIET OUT_DEPENDENCY _find_dependency) + if (${key}_FOUND OR ${name}_FOUND) + if(_GCP_MINIMUM_VERSION) + +@@ -368,14 +326,12 @@ + endif () + + # First check with CMake config files (starting at version 8, due to issues with earlier ones), and then fallback to the FindPROJ module. +-find_package(PROJ 9 CONFIG QUIET) +-if (NOT PROJ_FOUND) +- find_package(PROJ 8 CONFIG QUIET) +-endif() ++find_package2(PROJ) ++target_include_directories(PROJ::proj INTERFACE ${PROJ_INCLUDE_DIRS}) + if (PROJ_FOUND) + string(APPEND GDAL_IMPORT_DEPENDENCIES "find_dependency(PROJ ${PROJ_VERSION_MAJOR} CONFIG)\n") + else() +- find_package(PROJ 6.0 REQUIRED) ++ find_package(proj 6.0 REQUIRED) + string(APPEND GDAL_IMPORT_DEPENDENCIES "find_dependency(PROJ 6.0)\n") + endif () + +@@ -458,15 +414,10 @@ + TARGETS json-c::json-c JSONC::JSONC + ) + gdal_internal_library(JSONC REQUIRED) +-if(TARGET json-c::json-c) +- get_target_property(include_dirs json-c::json-c INTERFACE_INCLUDE_DIRECTORIES) +- find_path(GDAL_JSON_INCLUDE_DIR NAMES json.h PATHS ${include_dirs} PATH_SUFFIXES json-c NO_DEFAULT_PATH) +- list(APPEND include_dirs "${GDAL_JSON_INCLUDE_DIR}") +- list(REMOVE_DUPLICATES include_dirs) +- set_target_properties(json-c::json-c PROPERTIES +- INTERFACE_INCLUDE_DIRECTORIES "${GDAL_JSON_INCLUDE_DIR}" +- ) +-endif() ++get_target_property(include_dirs json-c::json-c INTERFACE_INCLUDE_DIRECTORIES) ++list(APPEND include_dirs "${JSONC_INCLUDE_DIRS}/json-c") ++set_target_properties(json-c::json-c PROPERTIES INTERFACE_INCLUDE_DIRECTORIES "${include_dirs}") ++message("Setting include for json-c: ${include_dirs}") + + gdal_check_package(OpenCAD "libopencad (external, used by OpenCAD driver)" CAN_DISABLE) + gdal_internal_library(OPENCAD) +@@ -527,6 +478,24 @@ + gdal_check_package(SQLite3 "Enable SQLite3 support (used by SQLite/Spatialite, GPKG, Rasterlite, MBTiles, etc.)" + CAN_DISABLE RECOMMENDED) + if (SQLite3_FOUND) ++ set(CMAKE_REQUIRED_INCLUDES ${SQLite3_INCLUDE_DIRS}) ++ check_symbol_exists(sqlite3_mutex_alloc sqlite3ext.h SQLite3_HAS_MUTEX_ALLOC) ++ check_symbol_exists(sqlite3_column_table_name sqlite3ext.h SQLite3_HAS_COLUMN_METADATA) ++ check_symbol_exists(sqlite3_rtree_query_callback sqlite3.h SQLite3_HAS_RTREE) ++ check_symbol_exists(sqlite3_load_extension sqlite3ext.h SQLite3_HAS_LOAD_EXTENSION) ++ # https://www.sqlite.org/compile.html recommends to build with -DSQLITE_OMIT_PROGRESS_CALLBACK ++ # "for applications that are able to use them"... This is sometimes wrongly ++ # understood as recommended in all situations. ++ check_symbol_exists(sqlite3_progress_handler sqlite3.h SQLite3_HAS_PROGRESS_HANDLER) ++ ++ #if(NOT TARGET SQLite::SQLite3) ++ # add_library(SQLite::SQLite3 UNKNOWN IMPORTED) ++ # set_target_properties(SQLite::SQLite3 PROPERTIES ++ # INTERFACE_INCLUDE_DIRECTORIES "${SQLite3_INCLUDE_DIRS}" ++ # IMPORTED_LINK_INTERFACE_LANGUAGES "C" ++ # IMPORTED_LOCATION "${SQLite3_LIBRARY}") ++ #endif() ++ + if (NOT DEFINED SQLite3_HAS_COLUMN_METADATA) + message(FATAL_ERROR "missing SQLite3_HAS_COLUMN_METADATA") + endif () +@@ -566,7 +535,7 @@ + gdal_check_package(SPATIALITE "Enable spatialite support for sqlite3" VERSION 4.1.2 CAN_DISABLE) + gdal_check_package(RASTERLITE2 "Enable RasterLite2 support for sqlite3" VERSION 1.1.0 CAN_DISABLE) + +-find_package(LibKML COMPONENTS DOM ENGINE) ++find_package(LibKML COMPONENTS kmlengine kmldom kmlbase) + if (GDAL_USE_LIBKML) + if (NOT LibKML_FOUND) + message(FATAL_ERROR "Configured to use GDAL_USE_LIBKML, but not found") +diff -urN ./a/cmake/helpers/ConanFindPackage.cmake ./b/cmake/helpers/ConanFindPackage.cmake +--- ./a/cmake/helpers/ConanFindPackage.cmake 1969-12-31 18:00:00.000000000 -0600 ++++ ./b/cmake/helpers/ConanFindPackage.cmake 2023-06-06 16:26:55.800008000 -0500 +@@ -0,0 +1,43 @@ ++ ++function(define_find_package2 pkgname include_file library_name) ++endfunction() ++ ++function(find_package2 pkgname) ++ set(_options QUIET REQUIRED) ++ set(_oneValueArgs OUT_DEPENDENCY) ++ set(_multiValueArgs) ++ cmake_parse_arguments(arg "${_options}" "${_oneValueArgs}" "${_multiValueArgs}" ${ARGN}) ++ if(arg_QUIET) ++ set(${pkgname}_FIND_QUIETLY TRUE) ++ endif() ++ if(arg_REQUIRED) ++ set(${pkgname}_FIND_REQUIRED TRUE) ++ endif() ++ ++ string(TOUPPER ${pkgname} key) ++ ++ set(docstring "Configured for conan package ${GDAL_CONAN_PACKAGE_FOR_${key}}") ++ if (DEFINED GDAL_CONAN_PACKAGE_FOR_${key}) ++ message("Using conan package ${GDAL_CONAN_PACKAGE_FOR_${key}} for dependency ${pkgname}") ++ set(conan_package ${GDAL_CONAN_PACKAGE_FOR_${key}}) ++ string(TOUPPER ${conan_package} conan_package_upper) ++ ++ set(${key}_INCLUDE_DIRS "${CONAN_INCLUDE_DIRS_${conan_package_upper}}" CACHE STRING ${docstring}) ++ if (NOT TARGET_FOR_${key}) ++ set(TARGET_FOR_${key} "${conan_package}::${conan_package}") ++ endif() ++ set(${key}_LIBRARIES "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${key}_LIBRARY "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${key}_TARGET "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${pkgname}_INCLUDE_DIRS "CONAN_INCLUDE_DIRS_${conan_package_upper}" CACHE STRING ${docstring}) ++ set(${pkgname}_LIBRARIES "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${pkgname}_LIBRARY "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${pkgname}_TARGET "${TARGET_FOR_${key}}" CACHE STRING ${docstring}) ++ set(${key}_FOUND TRUE CACHE BOOL ${docstring}) ++ ++ else () ++ message("dependency ${pkgname} has no conan package") ++ set(${key}_FOUND FALSE CACHE BOOL ${docstring}) ++ endif() ++ ++endfunction() +diff -urN ./a/frmts/hfa/CMakeLists.txt ./b/frmts/hfa/CMakeLists.txt +--- ./a/frmts/hfa/CMakeLists.txt 2023-05-02 08:47:11.000000000 -0500 ++++ ./b/frmts/hfa/CMakeLists.txt 2023-06-06 16:54:31.162043900 -0500 +@@ -15,7 +15,8 @@ + hfa_overviews.cpp + BUILTIN) + gdal_standard_includes(gdal_HFA) +-target_include_directories(gdal_HFA PRIVATE $) ++target_link_libraries(gdal_HFA INTERFACE PROJ::proj) ++target_include_directories(gdal_HFA PRIVATE ${PROJ_INCLUDE_DIRS}) + target_compile_definitions(gdal_HFA PRIVATE $) + + if (CMAKE_VERSION VERSION_GREATER_EQUAL 3.12) +diff -urN ./a/gdal.cmake ./b/gdal.cmake +--- ./a/gdal.cmake 2023-05-02 08:47:12.000000000 -0500 ++++ ./b/gdal.cmake 2023-06-06 16:55:34.252830900 -0500 +@@ -859,25 +859,6 @@ + ${CMAKE_CURRENT_BINARY_DIR}/GDALConfig.cmake @ONLY) + install(FILES ${CMAKE_CURRENT_BINARY_DIR}/GDALConfig.cmake DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/gdal/) + +- # Generate gdal-config utility command and pkg-config module gdal.pc +- include(GdalGenerateConfig) +- gdal_generate_config( +- TARGET +- "${GDAL_LIB_TARGET_NAME}" +- GLOBAL_PROPERTY +- "gdal_private_link_libraries" +- GDAL_CONFIG +- "${PROJECT_BINARY_DIR}/apps/gdal-config" +- PKG_CONFIG +- "${CMAKE_CURRENT_BINARY_DIR}/gdal.pc") +- install( +- PROGRAMS ${PROJECT_BINARY_DIR}/apps/gdal-config +- DESTINATION ${CMAKE_INSTALL_BINDIR} +- COMPONENT applications) +- install( +- FILES ${CMAKE_CURRENT_BINARY_DIR}/gdal.pc +- DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig +- COMPONENT libraries) + endif () + + configure_file(${GDAL_CMAKE_TEMPLATE_PATH}/uninstall.cmake.in ${PROJECT_BINARY_DIR}/cmake_uninstall.cmake @ONLY) +diff -urN ./a/ogr/CMakeLists.txt ./b/ogr/CMakeLists.txt +--- ./a/ogr/CMakeLists.txt 2023-05-02 08:47:12.000000000 -0500 ++++ ./b/ogr/CMakeLists.txt 2023-06-06 16:56:18.682151700 -0500 +@@ -89,12 +89,12 @@ + + target_compile_definitions(ogr PRIVATE HAVE_MITAB) + +-gdal_target_link_libraries(ogr PRIVATE PROJ::proj) ++target_link_libraries(ogr PUBLIC PROJ::proj) + + # External libs then + if (GDAL_USE_GEOS) + target_compile_definitions(ogr PRIVATE -DHAVE_GEOS=1) +- gdal_target_link_libraries(ogr PRIVATE ${GEOS_TARGET}) ++ target_link_libraries(ogr PUBLIC ${GEOS_TARGET}) + endif () + + if (GDAL_USE_SFCGAL) +diff -urN ./a/ogr/ogr_proj_p.h ./b/ogr/ogr_proj_p.h +--- ./a/ogr/ogr_proj_p.h 2023-05-02 08:47:12.000000000 -0500 ++++ ./b/ogr/ogr_proj_p.h 2023-06-06 16:56:30.772908800 -0500 +@@ -29,7 +29,7 @@ + #ifndef OGR_PROJ_P_H_INCLUDED + #define OGR_PROJ_P_H_INCLUDED + +-#include "proj.h" ++#include + + #include "cpl_mem_cache.h" + From 6ad6f3cf709dc5ed2420f316cea75b79fcbec5fe Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pau=20Farr=C3=A9?= Date: Fri, 11 Aug 2023 14:00:51 +0200 Subject: [PATCH 0177/1140] (#18164) [cpuinfo] Add 20230118 20220618 versions * [cpuinfo] Add 20230118 20220618 versions - Refactor package_info and expose clog as a component. Require that component from cpuinfo only in the specific versions that required it * Remove share folder from installed package * Provide CPUINFO_VERSION for test_v1_package * Fix Version handling --- recipes/cpuinfo/all/conandata.yml | 6 +++++ recipes/cpuinfo/all/conanfile.py | 23 ++++++++++++++----- .../cpuinfo/all/test_package/CMakeLists.txt | 8 ++++++- recipes/cpuinfo/all/test_package/conanfile.py | 9 ++++++-- .../cpuinfo/all/test_v1_package/conanfile.py | 1 + recipes/cpuinfo/config.yml | 4 ++++ 6 files changed, 42 insertions(+), 9 deletions(-) diff --git a/recipes/cpuinfo/all/conandata.yml b/recipes/cpuinfo/all/conandata.yml index 6231a9e8c3b977..56ce9c275f3d91 100644 --- a/recipes/cpuinfo/all/conandata.yml +++ b/recipes/cpuinfo/all/conandata.yml @@ -1,4 +1,10 @@ sources: + "cci.20230118": + url: "https://github.com/pytorch/cpuinfo/archive/3dc310302210c1891ffcfb12ae67b11a3ad3a150.tar.gz" + sha256: "f2f4df6d2b01036f36c5e372954e536881cdd59f5c2461c67aa0a92c6d755c61" + "cci.20220618": + url: "https://github.com/pytorch/cpuinfo/archive/082deffc80ce517f81dc2f3aebe6ba671fcd09c9.tar.gz" + sha256: "4379348ec3127b37e854a0a66f85ea1d3c606e5f3a6dce235dc9c69ce663c026" "cci.20220228": url: "https://github.com/pytorch/cpuinfo/archive/6288930068efc8dff4f3c0b95f062fc5ddceba04.tar.gz" sha256: "9e9e937b3569320d23d8b1c8c26ed3603affe55c3e4a3e49622e8a2c6d6e1696" diff --git a/recipes/cpuinfo/all/conanfile.py b/recipes/cpuinfo/all/conanfile.py index 3a1f62573cb435..00574928a56f75 100644 --- a/recipes/cpuinfo/all/conanfile.py +++ b/recipes/cpuinfo/all/conanfile.py @@ -65,9 +65,10 @@ def generate(self): tc.generate() def _patch_sources(self): - replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), - "SET_PROPERTY(TARGET clog PROPERTY POSITION_INDEPENDENT_CODE ON)", - "") + if self.version < "cci.20230118": + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "SET_PROPERTY(TARGET clog PROPERTY POSITION_INDEPENDENT_CODE ON)", + "") def build(self): self._patch_sources() @@ -80,9 +81,19 @@ def package(self): cmake = CMake(self) cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): self.cpp_info.set_property("pkg_config_name", "libcpuinfo") - self.cpp_info.libs = ["cpuinfo", "clog"] - if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["pthread"] + + if self.version < "cci.20230118": + self.cpp_info.components["clog"].libs = ["clog"] + cpuinfo_clog_target = "clog" if self.version < "cci.20220618" else "cpuinfo::clog" + self.cpp_info.components["clog"].set_property("cmake_target_name", cpuinfo_clog_target) + + self.cpp_info.components["cpuinfo"].set_property("cmake_target_name", "cpuinfo::cpuinfo") + self.cpp_info.components["cpuinfo"].libs = ["cpuinfo"] + if self.version < "cci.20230118": + self.cpp_info.components["cpuinfo"].requires = ["clog"] + if self.settings.os in ["Linux", "FreeBSD", "Android"]: + self.cpp_info.components["cpuinfo"].system_libs.append("pthread") diff --git a/recipes/cpuinfo/all/test_package/CMakeLists.txt b/recipes/cpuinfo/all/test_package/CMakeLists.txt index f7fd88969d977e..96ba94c8edef55 100644 --- a/recipes/cpuinfo/all/test_package/CMakeLists.txt +++ b/recipes/cpuinfo/all/test_package/CMakeLists.txt @@ -4,5 +4,11 @@ project(test_package LANGUAGES C) find_package(cpuinfo REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE cpuinfo::cpuinfo) +if ((${CPUINFO_VERSION} GREATER_EQUAL "20220618") AND (${CPUINFO_VERSION} LESS "20230118")) + # in that version range cpuinfo exposed cpuinfo::clog. Check that is available through conan recipe + target_link_libraries(${PROJECT_NAME} PRIVATE cpuinfo::cpuinfo cpuinfo::clog) +else () + target_link_libraries(${PROJECT_NAME} PRIVATE cpuinfo::cpuinfo) +endif() + target_compile_features(${PROJECT_NAME} PRIVATE c_std_99) diff --git a/recipes/cpuinfo/all/test_package/conanfile.py b/recipes/cpuinfo/all/test_package/conanfile.py index 0a6bc68712d901..2690818e475701 100644 --- a/recipes/cpuinfo/all/test_package/conanfile.py +++ b/recipes/cpuinfo/all/test_package/conanfile.py @@ -1,12 +1,12 @@ from conan import ConanFile from conan.tools.build import can_run -from conan.tools.cmake import CMake, cmake_layout +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" def layout(self): @@ -15,6 +15,11 @@ def layout(self): def requirements(self): self.requires(self.tested_reference_str) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CPUINFO_VERSION"] = str(self.dependencies["cpuinfo"].ref.version).split('.')[1] + tc.generate() + def build(self): cmake = CMake(self) cmake.configure() diff --git a/recipes/cpuinfo/all/test_v1_package/conanfile.py b/recipes/cpuinfo/all/test_v1_package/conanfile.py index 38f4483872d47f..ea57bb8b3a514c 100644 --- a/recipes/cpuinfo/all/test_v1_package/conanfile.py +++ b/recipes/cpuinfo/all/test_v1_package/conanfile.py @@ -8,6 +8,7 @@ class TestPackageConan(ConanFile): def build(self): cmake = CMake(self) + cmake.definitions["CPUINFO_VERSION"] = self.deps_cpp_info["cpuinfo"].version.split('.')[1] cmake.configure() cmake.build() diff --git a/recipes/cpuinfo/config.yml b/recipes/cpuinfo/config.yml index a6383a8ac8924b..8e98d8506c888d 100644 --- a/recipes/cpuinfo/config.yml +++ b/recipes/cpuinfo/config.yml @@ -1,4 +1,8 @@ versions: + "cci.20230118": + folder: all + "cci.20220618": + folder: all "cci.20220228": folder: all "cci.20201217": From f4635a5ab2b2d0c9f73ba41f247885c3c7d95d24 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Fri, 11 Aug 2023 14:52:00 +0200 Subject: [PATCH 0178/1140] (#18771) Add libde265/1.0.12 Since 1.0.12 release win lib has lib prefix See https://github.com/strukturag/libde265/compare/v1.0.12..v1.0.11#diff-9d651a9edfe60c8a6d63c14ddc658ecec43e23b1376257c555d4e15577e52f41 --- recipes/libde265/all/conandata.yml | 3 +++ recipes/libde265/all/conanfile.py | 3 ++- recipes/libde265/config.yml | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/recipes/libde265/all/conandata.yml b/recipes/libde265/all/conandata.yml index 1536fa75197a75..d9b1262d06c1f6 100644 --- a/recipes/libde265/all/conandata.yml +++ b/recipes/libde265/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.12": + url: "https://github.com/strukturag/libde265/releases/download/v1.0.12/libde265-1.0.12.tar.gz" + sha256: "62185ea2182e68cf68bba20cc6eb4c287407b509cf0a827d7ddb75614db77b5c" "1.0.11": url: "https://github.com/strukturag/libde265/releases/download/v1.0.11/libde265-1.0.11.tar.gz" sha256: "2f8f12cabbdb15e53532b7c1eb964d4e15d444db1be802505e6ac97a25035bab" diff --git a/recipes/libde265/all/conanfile.py b/recipes/libde265/all/conanfile.py index 286e6952e05dca..6618b97bf0692d 100644 --- a/recipes/libde265/all/conanfile.py +++ b/recipes/libde265/all/conanfile.py @@ -106,7 +106,8 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "de265") self.cpp_info.set_property("cmake_target_aliases", ["libde265"]) # official imported target before 1.0.10 self.cpp_info.set_property("pkg_config_name", "libde265") - prefix = "lib" if Version(self.version) < "1.0.10" else "" + version = Version(self.version) + prefix = "lib" if (version < "1.0.10" or (version > "1.0.11" and self.settings.os == "Windows" and not self.options.shared)) else "" self.cpp_info.libs = [f"{prefix}de265"] if not self.options.shared: self.cpp_info.defines = ["LIBDE265_STATIC_BUILD"] diff --git a/recipes/libde265/config.yml b/recipes/libde265/config.yml index d32ffee4c65d8b..2745db31bb6cde 100644 --- a/recipes/libde265/config.yml +++ b/recipes/libde265/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.12": + folder: all "1.0.11": folder: all "1.0.9": From 78976dd93818c5217b227d539800fce114be6e66 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 11 Aug 2023 15:23:51 +0200 Subject: [PATCH 0179/1140] (#19150) [mpfr] Fix when building shared library on Linux Signed-off-by: Uilian Ries --- recipes/mpfr/all/conanfile.py | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/recipes/mpfr/all/conanfile.py b/recipes/mpfr/all/conanfile.py index 03acd9af8c0815..0356da09ec7fb0 100644 --- a/recipes/mpfr/all/conanfile.py +++ b/recipes/mpfr/all/conanfile.py @@ -5,6 +5,8 @@ from conan.tools.gnu import Autotools, AutotoolsToolchain, AutotoolsDeps from conan.tools.microsoft import is_msvc, check_min_vs, unix_path from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.env import VirtualRunEnv +from conan.tools.build import cross_building from conan.errors import ConanException import os import re @@ -73,6 +75,9 @@ def source(self): destination=self.source_folder, strip_root=True) def generate(self): + if not cross_building(self): + env = VirtualRunEnv(self) + env.generate(scope="build") if self.settings.os == "Windows": if is_msvc(self) and not check_min_vs(self, 193, raise_invalid=False) and \ not self.conf.get("tools.cmake.cmaketoolchain:generator", check_type=str): @@ -126,9 +131,8 @@ def _extract_mpfr_autotools_variables(self): defs = self._extract_makefile_variable(makefile, "DEFS") return sources, headers, defs - def build(self): + def _patch_sources(self): apply_conandata_patches(self) - if self.settings.os == "Windows": # Allow mixed shared and static libs replace_in_file(self, os.path.join(self.source_folder, "configure"), 'as_fn_error $? "libgmp isn\'t provided as a DLL: use --enable-static --disable-shared" "$LINENO" 5', @@ -144,6 +148,8 @@ def build(self): "", "") save(self, "gmp.h", "#pragma once\n#include \n") + def build(self): + self._patch_sources() autotools = Autotools(self) autotools.configure() # Need to generate Makefile to extract variables for CMake below From d05b789cd0ec20451364609c5372d53399b78738 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 11 Aug 2023 16:26:45 +0200 Subject: [PATCH 0180/1140] (#18611) at-spi2-core: conan V2 compatibility MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * at-spi2-core: conan V2 compatibility * bump deps * add glib as tool requirement * Use proper conan min version check * Option * Add package_type --------- Co-authored-by: Rubén Rincón Blanco --- recipes/at-spi2-core/new/conanfile.py | 22 ++++++------- .../new/test_package/CMakeLists.txt | 9 ----- .../new/test_package/conanfile.py | 33 ++++++++++++++----- .../at-spi2-core/new/test_package/meson.build | 5 +++ 4 files changed, 39 insertions(+), 30 deletions(-) delete mode 100644 recipes/at-spi2-core/new/test_package/CMakeLists.txt create mode 100644 recipes/at-spi2-core/new/test_package/meson.build diff --git a/recipes/at-spi2-core/new/conanfile.py b/recipes/at-spi2-core/new/conanfile.py index 85d759b7547fc0..041ae5da456f18 100644 --- a/recipes/at-spi2-core/new/conanfile.py +++ b/recipes/at-spi2-core/new/conanfile.py @@ -9,7 +9,8 @@ import os -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.60.0 <2.0 || >=2.0.5" + class AtSpi2CoreConan(ConanFile): name = "at-spi2-core" description = "It provides a Service Provider Interface for the Assistive Technologies available on the GNOME platform and a library against which applications can be linked" @@ -20,17 +21,18 @@ class AtSpi2CoreConan(ConanFile): provides = "at-spi2-atk", "atk" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], "with_x11": [True, False], - } + } default_options = { "shared": False, "fPIC": True, "with_x11": False, - } + } def export_sources(self): export_conandata_patches(self) @@ -40,22 +42,21 @@ def configure(self): self.options.rm_safe("fPIC") self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") - if self.options.shared: - self.options["glib"].shared = True def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.0") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") + self.tool_requires("glib/") def requirements(self): - self.requires("glib/2.76.3") + self.requires("glib/2.77.0") if self.options.with_x11: self.requires("xorg/system") self.requires("dbus/1.15.6") def validate(self): - if self.options.shared and not self.options["glib"].shared: + if self.options.shared and not self.dependencies["glib"].options.shared: raise ConanInvalidConfiguration( "Linking a shared library against static glib can cause unexpected behaviour." ) @@ -123,6 +124,3 @@ def package_info(self): self.cpp_info.components["atk-bridge"].includedirs = [os.path.join('include', 'at-spi2-atk', '2.0')] self.cpp_info.components["atk-bridge"].requires = ["dbus::dbus", "atk", "glib::glib", "atspi"] self.cpp_info.components["atk-bridge"].set_property("pkg_config_name", 'atk-bridge-2.0') - - def package_id(self): - self.info.requires["glib"].full_package_mode() diff --git a/recipes/at-spi2-core/new/test_package/CMakeLists.txt b/recipes/at-spi2-core/new/test_package/CMakeLists.txt deleted file mode 100644 index afa24763570742..00000000000000 --- a/recipes/at-spi2-core/new/test_package/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) diff --git a/recipes/at-spi2-core/new/test_package/conanfile.py b/recipes/at-spi2-core/new/test_package/conanfile.py index d4128b04507778..74125d16c3d5f5 100644 --- a/recipes/at-spi2-core/new/test_package/conanfile.py +++ b/recipes/at-spi2-core/new/test_package/conanfile.py @@ -1,17 +1,32 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "PkgConfigDeps", "MesonToolchain", "VirtualRunEnv", "VirtualBuildEnv" + test_type = "explicit" + + def layout(self): + basic_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build_requirements(self): + self.tool_requires("meson/1.2.0") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() + meson = Meson(self) + meson.configure() + meson.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/at-spi2-core/new/test_package/meson.build b/recipes/at-spi2-core/new/test_package/meson.build new file mode 100644 index 00000000000000..a6950ebe6d4ab2 --- /dev/null +++ b/recipes/at-spi2-core/new/test_package/meson.build @@ -0,0 +1,5 @@ +project('test_package', 'c') +package_dep = dependency('atspi-2') +executable('test_package', + sources : ['test_package.c'], + dependencies : [package_dep]) From 49ccd98bb1ff5deb1fd34cad484e7393e0723a85 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Fri, 11 Aug 2023 17:08:26 +0200 Subject: [PATCH 0181/1140] (#18719) Add Alembic 1.8.5 * Add Alembic 1.8.5 * Update recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch Co-authored-by: Martin Valgur * Update 1.8.5-0001-fix-cmake.patch Co-authored-by: Martin Valgur --------- Co-authored-by: Martin Valgur Co-authored-by: Uilian Ries --- recipes/alembic/all/conandata.yml | 7 +++++ .../all/patches/1.8.5-0001-fix-cmake.patch | 26 +++++++++++++++++++ recipes/alembic/config.yml | 2 ++ 3 files changed, 35 insertions(+) create mode 100644 recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch diff --git a/recipes/alembic/all/conandata.yml b/recipes/alembic/all/conandata.yml index bf7fb209af8bcf..c09b44adc0b83b 100644 --- a/recipes/alembic/all/conandata.yml +++ b/recipes/alembic/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.5": + url: "https://github.com/alembic/alembic/archive/1.8.5.tar.gz" + sha256: "180a12f08d391cd89f021f279dbe3b5423b1db751a9898540c8059a45825c2e9" "1.8.3": url: "https://github.com/alembic/alembic/archive/1.8.3.tar.gz" sha256: "b0bc74833bff118a869e81e6acb810a58797e77ef63143954b2f8e817c7f65cb" @@ -6,6 +9,10 @@ sources: url: "https://github.com/alembic/alembic/archive/refs/tags/1.8.2.tar.gz" sha256: "3f1c466ee1600578689b32b1f2587066d3259704ec7ed1fcf80c324d01274f48" patches: + "1.8.5": + - patch_file: "patches/1.8.5-0001-fix-cmake.patch" + patch_description: "Disable a line in a CMakeLists.txt to build with shared=True" + patch_type: "portability" "1.8.3": - patch_file: "patches/1.8.2-0001-fix-cmake.patch" "1.8.2": diff --git a/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch b/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch new file mode 100644 index 00000000000000..3ebad2885a6413 --- /dev/null +++ b/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch @@ -0,0 +1,26 @@ +--- a/lib/Alembic/CMakeLists.txt ++++ b/lib/Alembic/CMakeLists.txt +@@ -68,7 +68,6 @@ IF (ALEMBIC_SHARED_LIBS) + + if (ALEMBIC_USING_IMATH_3) + if (APPLE OR UNIX) +- set_target_properties(Alembic PROPERTIES INSTALL_RPATH "$") + endif () + endif () + ENDIF() +@@ -87,9 +87,9 @@ TARGET_LINK_LIBRARIES(Alembic + SET( ALEMBIC_LIB_INSTALL_DIR lib CACHE STRING "Where to install the Alembic libs") + INSTALL(TARGETS Alembic + EXPORT AlembicTargets +- LIBRARY DESTINATION ${ALEMBIC_LIB_INSTALL_DIR} +- ARCHIVE DESTINATION ${ALEMBIC_LIB_INSTALL_DIR} +- RUNTIME DESTINATION ${ALEMBIC_LIB_INSTALL_DIR}) ++ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) + + #-****************************************************************************** + # PACKAGE EXPORTS +-- +2.41.0 + diff --git a/recipes/alembic/config.yml b/recipes/alembic/config.yml index 68197c279a4ee3..d20dd33414a44f 100644 --- a/recipes/alembic/config.yml +++ b/recipes/alembic/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.5": + folder: all "1.8.3": folder: all "1.8.2": From 1485a373e72c9017500133c8cae3b32c171e4514 Mon Sep 17 00:00:00 2001 From: PeteAudinate <99274874+PeteAudinate@users.noreply.github.com> Date: Fri, 11 Aug 2023 19:46:55 +0100 Subject: [PATCH 0182/1140] (#17882) b2: Support CXX from a VirtualBuildEnv * Use environment from VirtualBuildEnv to get CXX/CXXFLAGS * Write a project-config.jam file containing the toolset from CXX This ensures the b2 install command can find the correct compiler binary. --------- Co-authored-by: Chris Mc --- recipes/b2/portable/conanfile.py | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/recipes/b2/portable/conanfile.py b/recipes/b2/portable/conanfile.py index dad95965dea312..829c74015b1efe 100644 --- a/recipes/b2/portable/conanfile.py +++ b/recipes/b2/portable/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import cross_building +from conan.tools.env import VirtualBuildEnv from conan.tools.files import chdir, copy, get from conan.tools.layout import basic_layout @@ -107,6 +108,12 @@ def _bootstrap_env(self): os.environ.clear() os.environ.update(saved_env) + def _write_project_config(self, cxx): + with open(os.path.join(self.source_folder, "project-config.jam"), "w") as f: + f.write( + f"using {self.options.toolset} : : {cxx} ;\n" + ) + def build(self): # The order of the with:with: below is important. The first one changes # the current dir. While the second does env changes that guarantees @@ -139,10 +146,14 @@ def build(self): command += "build" if use_windows_commands else "./build.sh" if self.options.use_cxx_env: - cxx = os.environ.get("CXX") + envvars = VirtualBuildEnv(self).vars() + + cxx = envvars.get("CXX") if cxx: command += f" --cxx={cxx}" - cxxflags = os.environ.get("CXXFLAGS") + self._write_project_config(cxx) + + cxxflags = envvars.get("CXXFLAGS") if cxxflags: command += f" --cxxflags={cxxflags}" From ba719d617331f6432ae68488cc832e1953bca1ec Mon Sep 17 00:00:00 2001 From: James Date: Sun, 13 Aug 2023 12:22:25 +0200 Subject: [PATCH 0183/1140] (#18961) fix fastdds binaries --- recipes/fast-dds/all/conanfile.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/recipes/fast-dds/all/conanfile.py b/recipes/fast-dds/all/conanfile.py index d47f222eebac4d..e8ad7b42a13f0e 100644 --- a/recipes/fast-dds/all/conanfile.py +++ b/recipes/fast-dds/all/conanfile.py @@ -1,3 +1,6 @@ +import os +import textwrap + from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd @@ -15,8 +18,7 @@ ) from conan.tools.microsoft import check_min_vs, is_msvc_static_runtime, is_msvc, msvc_runtime_flag from conan.tools.scm import Version -import os -import textwrap + required_conan_version = ">=1.53.0" @@ -69,7 +71,7 @@ def layout(self): def requirements(self): self.requires("tinyxml2/9.0.0") - self.requires("asio/1.28.0") + self.requires("asio/1.28.0") # This is now a package_type = header self.requires("fast-cdr/1.0.27", transitive_headers=True, transitive_libs=True) self.requires("foonathan-memory/0.7.3") if self.options.with_ssl: From f9102fd6be2e512122b5b66d14c5589d83fc9733 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 13 Aug 2023 12:42:35 +0200 Subject: [PATCH 0184/1140] (#15193) opencv 4.x: refactor to allow fine-grained selection of each module/contrib * allow to build opencv_objdetect without dnn in 4.5.5 It has been "fixed" upstream for OpenCV 4.6.0 It fixes few things in this recipe: - avoid a bug where quirc is in requirements, but not required by any component in package_indo() when dnn is False - a regression introduced by https://github.com/conan-io/conan-center-index/pull/11009. Indeed objdetect can be built without dnn in all OpenCV version before 4.5.4, so this PR was breaking these versions when dnn was False by not exposing opencv_objdetect and few contrib components. * add missing contrib components when dnn is True components: - dnn_objdetect & opencv_text - dnn_superres since 4.1.2 - mcc since 4.5.0 - wechat_qrcode since 4.5.2 - barcode since 4.5.3 * fix photo & stitching components when cuda is enabled * add quality component in contrib only if version >= 4.1.0 * add dnn as an option dependency of video since 4.5.1 * dnn is an optional dependency of tracking * text is an optional dependency of datasets * move cuda components under contrib * fix requires of several contrib components * improve requires of main components * add an option for each contrib and deprecate contrib option * fix internal requirements of tracking module * force disable tesseract in text module for the moment * deprecate with_ade option in favor of gapi option * add option to allow to disable stitching module * remove useless comments * adapt test package to new options * add option to allow disabling highgui * add option to allow disabling videoio * add option to allow disabling ml * add option to allow disabling photo * move options related to modules first * add missing frameworks for imgcodecs * add with_tesseract option for text module * also handle cuda contribs * add option to allow disabling objdetect * add option to allow disabling video * prefer to force enable options required by modules explicitly required by consumers * improve CMakeLists of test package * add option to allow disabling imgcodecs * typo * remove with_imgcodec_* options when imgcodecs module is disabled * add option to allow disabling calib3d * add option to allow disabling features2d * classification of options by category * add option to allow disabling flann * split executables in test package per tested module * add option to allow disabling imgproc * opencv 4.x requires at least C++11 * test opencv_core * add options for gdal & gdcm support in imgcodecs * test opencv_imgcodecs * minor change * add missing mantadory dependency to tracking * minor change * add contrib_ovis option * add contrib_hdf option * fix system libs of opencv_gapi on Windows * remove with_v4l option if videoio module is disabled * control build of cudev through with_cuda option * add vulkan support in dnn module * add with_opencl option * do not build Android examples * fix discovery of zlib static if Android * fix install layout for Android * better filter to collect extra libs in opencv core * remove contrib prefix * add deprecation messages * alphamat requires eigen support * fix injection of cpu_baseline and cpu_dispatch in case of empty string * neon stuff * pass False to WITH_FFMPEG if option removed * remove deprecated options from package id * simplify * add cvv and viz options viz module can't be enabled yet, due to lack of vtk recipe in conan-center * avoid redefining cmake variables * do not force disable openexr if Android * better handling of qt * no base_path in conandata.yml * fix qt link * improve deprecated contrib option handling * factorize modules in options & default_options * declare frameworks & system_libs in _opencv_modules * typo * fix link to qt in cvv module * add a test of calib3d module * add a test of flann module * add a test of objdetect module * add a test of video module * add a test of photo module * add a test of stitching module * add a test of ml module * add a test of highgui module * parallel ctest in test package * add a test of features2d module * add a test of freetype module * parallel ctest in test v1 package * add a test of structured_light module * add a test of shape module * add a test of reg module * simplify test_imgproc.cpp * test more extra modules * more elegant workaround of get_safe in test_v1_package * small change * missing tesseract in requires of text component * add a test of text module * add test of xfeatures2d module * add test of ximgproc module * test more extra modules * add missing header in alphamat.hpp * typo * sfm module needs eigen enabled * test more extra modules * test more extra modules * test more extra modules * simplify CMakeLists of test package * simplify test package even more * test more modules * adapt dnn_superres test to work with old versions * fix build of sfm extra module in opencv < 4.5.3 * check again internal dependencies between options in validate() in conan v2 downstream options values always have precedence, so we have to check again in validate() that combination of opencv options is still valid * add world option * minor change * minor comment change * factorize a little bit * bump protobuf to 3.21.9 * compat with openexr 3.x in old opencv versions * add res to resdirs of components * bump dependencies * some conan v2 stuff * bump freetype * properly set requires of each component regarding eigen Eigen is a private dependency of: - calib3d - core - features2d - stitching - rgbd - sfm - ximgproc * fix cuda internal dependencies * use self.dependencies["ffmpeg"] * fix ffmpeg required components * improve ffmpeg handling * ffmpeg workaround for the moment * bump ffmpeg * avutil always available in ffmpeg * bump dependencies * factorize * remove patches of removed versions * fix world option * bump dependencies * fix typo in requires of cudacodec * bump several dependencies * Update recipes/opencv/4.x/conandata.yml Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/opencv/4.x/conandata.yml | 66 +- recipes/opencv/4.x/conanfile.py | 1506 ++++++++++++----- .../4.1.2-0005-tracking-no-plot-deps.patch | 7 + .../opencv/4.x/patches/4.1.2-0006-hdf.patch | 21 + .../patches/4.1.2-0008-link-qt-targets.patch | 29 + .../4.x/patches/4.1.2-0009-sfm-deps.patch | 49 + .../4.1.2-0010-compat-protobuf-ge-3.18.patch | 22 + .../patches/4.1.2-0011-compat-openexr3.patch | 10 + .../4.5.1-0001-tracking-no-plot-deps.patch | 13 + .../patches/4.5.1-0002-alphamat-header.patch | 11 + .../patches/4.5.3-0002-link-qt-targets.patch | 30 + .../4.5.5-0002-objdetect-without-dnn.patch | 97 ++ .../4.x/patches/4.5.5-0003-find-quirc.patch | 12 + .../patches/4.5.5-0004-link-qt-targets.patch | 22 + .../opencv/4.x/test_package/CMakeLists.txt | 55 +- recipes/opencv/4.x/test_package/conanfile.py | 37 +- .../opencv/4.x/test_package/test_alphamat.cpp | 10 + .../opencv/4.x/test_package/test_aruco.cpp | 9 + .../opencv/4.x/test_package/test_bgsegm.cpp | 6 + .../4.x/test_package/test_bioinspired.cpp | 6 + .../opencv/4.x/test_package/test_calib3d.cpp | 26 + .../opencv/4.x/test_package/test_ccalib.cpp | 8 + recipes/opencv/4.x/test_package/test_core.cpp | 6 + .../opencv/4.x/test_package/test_datasets.cpp | 6 + recipes/opencv/4.x/test_package/test_dnn.cpp | 6 + .../4.x/test_package/test_dnn_superres.cpp | 6 + recipes/opencv/4.x/test_package/test_face.cpp | 6 + .../4.x/test_package/test_features2d.cpp | 6 + .../opencv/4.x/test_package/test_flann.cpp | 28 + .../opencv/4.x/test_package/test_freetype.cpp | 6 + .../opencv/4.x/test_package/test_fuzzy.cpp | 9 + recipes/opencv/4.x/test_package/test_gapi.cpp | 18 + recipes/opencv/4.x/test_package/test_hdf.cpp | 6 + recipes/opencv/4.x/test_package/test_hfs.cpp | 6 + .../opencv/4.x/test_package/test_highgui.cpp | 8 + .../opencv/4.x/test_package/test_img_hash.cpp | 10 + .../4.x/test_package/test_imgcodecs.cpp | 9 + .../opencv/4.x/test_package/test_imgproc.cpp | 14 + .../test_package/test_intensity_transform.cpp | 9 + .../4.x/test_package/test_line_descriptor.cpp | 6 + recipes/opencv/4.x/test_package/test_mcc.cpp | 6 + recipes/opencv/4.x/test_package/test_ml.cpp | 6 + .../4.x/test_package/test_objdetect.cpp | 17 + .../opencv/4.x/test_package/test_optflow.cpp | 7 + .../opencv/4.x/test_package/test_package.cpp | 235 --- .../test_package/test_phase_unwrapping.cpp | 6 + .../opencv/4.x/test_package/test_photo.cpp | 10 + recipes/opencv/4.x/test_package/test_plot.cpp | 12 + .../opencv/4.x/test_package/test_quality.cpp | 8 + recipes/opencv/4.x/test_package/test_reg.cpp | 9 + recipes/opencv/4.x/test_package/test_rgbd.cpp | 7 + .../opencv/4.x/test_package/test_saliency.cpp | 6 + recipes/opencv/4.x/test_package/test_sfm.cpp | 10 + .../opencv/4.x/test_package/test_shape.cpp | 6 + .../4.x/test_package/test_stitching.cpp | 13 + .../test_package/test_structured_light.cpp | 6 + .../opencv/4.x/test_package/test_superres.cpp | 6 + .../test_package/test_surface_matching.cpp | 7 + recipes/opencv/4.x/test_package/test_text.cpp | 11 + .../opencv/4.x/test_package/test_tracking.cpp | 6 + .../opencv/4.x/test_package/test_video.cpp | 7 + .../opencv/4.x/test_package/test_videoio.cpp | 11 + .../4.x/test_package/test_wechat_qrcode.cpp | 9 + .../4.x/test_package/test_xfeatures2d.cpp | 6 + .../opencv/4.x/test_package/test_ximgproc.cpp | 6 + .../4.x/test_package/test_xobjdetect.cpp | 6 + .../opencv/4.x/test_package/test_xphoto.cpp | 6 + .../opencv/4.x/test_v1_package/CMakeLists.txt | 4 +- .../opencv/4.x/test_v1_package/conanfile.py | 40 +- 69 files changed, 2042 insertions(+), 664 deletions(-) create mode 100644 recipes/opencv/4.x/patches/4.1.2-0005-tracking-no-plot-deps.patch create mode 100644 recipes/opencv/4.x/patches/4.1.2-0006-hdf.patch create mode 100644 recipes/opencv/4.x/patches/4.1.2-0008-link-qt-targets.patch create mode 100644 recipes/opencv/4.x/patches/4.1.2-0009-sfm-deps.patch create mode 100644 recipes/opencv/4.x/patches/4.1.2-0010-compat-protobuf-ge-3.18.patch create mode 100644 recipes/opencv/4.x/patches/4.1.2-0011-compat-openexr3.patch create mode 100644 recipes/opencv/4.x/patches/4.5.1-0001-tracking-no-plot-deps.patch create mode 100644 recipes/opencv/4.x/patches/4.5.1-0002-alphamat-header.patch create mode 100644 recipes/opencv/4.x/patches/4.5.3-0002-link-qt-targets.patch create mode 100644 recipes/opencv/4.x/patches/4.5.5-0002-objdetect-without-dnn.patch create mode 100644 recipes/opencv/4.x/patches/4.5.5-0003-find-quirc.patch create mode 100644 recipes/opencv/4.x/patches/4.5.5-0004-link-qt-targets.patch create mode 100644 recipes/opencv/4.x/test_package/test_alphamat.cpp create mode 100644 recipes/opencv/4.x/test_package/test_aruco.cpp create mode 100644 recipes/opencv/4.x/test_package/test_bgsegm.cpp create mode 100644 recipes/opencv/4.x/test_package/test_bioinspired.cpp create mode 100644 recipes/opencv/4.x/test_package/test_calib3d.cpp create mode 100644 recipes/opencv/4.x/test_package/test_ccalib.cpp create mode 100644 recipes/opencv/4.x/test_package/test_core.cpp create mode 100644 recipes/opencv/4.x/test_package/test_datasets.cpp create mode 100644 recipes/opencv/4.x/test_package/test_dnn.cpp create mode 100644 recipes/opencv/4.x/test_package/test_dnn_superres.cpp create mode 100644 recipes/opencv/4.x/test_package/test_face.cpp create mode 100644 recipes/opencv/4.x/test_package/test_features2d.cpp create mode 100644 recipes/opencv/4.x/test_package/test_flann.cpp create mode 100644 recipes/opencv/4.x/test_package/test_freetype.cpp create mode 100644 recipes/opencv/4.x/test_package/test_fuzzy.cpp create mode 100644 recipes/opencv/4.x/test_package/test_gapi.cpp create mode 100644 recipes/opencv/4.x/test_package/test_hdf.cpp create mode 100644 recipes/opencv/4.x/test_package/test_hfs.cpp create mode 100644 recipes/opencv/4.x/test_package/test_highgui.cpp create mode 100644 recipes/opencv/4.x/test_package/test_img_hash.cpp create mode 100644 recipes/opencv/4.x/test_package/test_imgcodecs.cpp create mode 100644 recipes/opencv/4.x/test_package/test_imgproc.cpp create mode 100644 recipes/opencv/4.x/test_package/test_intensity_transform.cpp create mode 100644 recipes/opencv/4.x/test_package/test_line_descriptor.cpp create mode 100644 recipes/opencv/4.x/test_package/test_mcc.cpp create mode 100644 recipes/opencv/4.x/test_package/test_ml.cpp create mode 100644 recipes/opencv/4.x/test_package/test_objdetect.cpp create mode 100644 recipes/opencv/4.x/test_package/test_optflow.cpp delete mode 100644 recipes/opencv/4.x/test_package/test_package.cpp create mode 100644 recipes/opencv/4.x/test_package/test_phase_unwrapping.cpp create mode 100644 recipes/opencv/4.x/test_package/test_photo.cpp create mode 100644 recipes/opencv/4.x/test_package/test_plot.cpp create mode 100644 recipes/opencv/4.x/test_package/test_quality.cpp create mode 100644 recipes/opencv/4.x/test_package/test_reg.cpp create mode 100644 recipes/opencv/4.x/test_package/test_rgbd.cpp create mode 100644 recipes/opencv/4.x/test_package/test_saliency.cpp create mode 100644 recipes/opencv/4.x/test_package/test_sfm.cpp create mode 100644 recipes/opencv/4.x/test_package/test_shape.cpp create mode 100644 recipes/opencv/4.x/test_package/test_stitching.cpp create mode 100644 recipes/opencv/4.x/test_package/test_structured_light.cpp create mode 100644 recipes/opencv/4.x/test_package/test_superres.cpp create mode 100644 recipes/opencv/4.x/test_package/test_surface_matching.cpp create mode 100644 recipes/opencv/4.x/test_package/test_text.cpp create mode 100644 recipes/opencv/4.x/test_package/test_tracking.cpp create mode 100644 recipes/opencv/4.x/test_package/test_video.cpp create mode 100644 recipes/opencv/4.x/test_package/test_videoio.cpp create mode 100644 recipes/opencv/4.x/test_package/test_wechat_qrcode.cpp create mode 100644 recipes/opencv/4.x/test_package/test_xfeatures2d.cpp create mode 100644 recipes/opencv/4.x/test_package/test_ximgproc.cpp create mode 100644 recipes/opencv/4.x/test_package/test_xobjdetect.cpp create mode 100644 recipes/opencv/4.x/test_package/test_xphoto.cpp diff --git a/recipes/opencv/4.x/conandata.yml b/recipes/opencv/4.x/conandata.yml index 3da12bba6234f6..694b74e2be5aa8 100644 --- a/recipes/opencv/4.x/conandata.yml +++ b/recipes/opencv/4.x/conandata.yml @@ -5,25 +5,42 @@ sources: - url: "https://github.com/opencv/opencv_contrib/archive/refs/tags/4.5.5.tar.gz" sha256: "a97c2eaecf7a23c6dbd119a609c6d7fae903e5f9ff5f1fe678933e01c67a6c11" "4.5.3": - - url: "https://github.com/opencv/opencv/archive/4.5.3.tar.gz" + - url: "https://github.com/opencv/opencv/archive/refs/tags/4.5.3.tar.gz" sha256: "77f616ae4bea416674d8c373984b20c8bd55e7db887fd38c6df73463a0647bab" - - url: "https://github.com/opencv/opencv_contrib/archive/4.5.3.tar.gz" + - url: "https://github.com/opencv/opencv_contrib/archive/refs/tags/4.5.3.tar.gz" sha256: "73da052fd10e73aaba2560eaff10cc5177e2dcc58b27f8aedf7c649e24c233bc" "4.1.2": - - url: "https://github.com/opencv/opencv/archive/4.1.2.tar.gz" + - url: "https://github.com/opencv/opencv/archive/refs/tags/4.1.2.tar.gz" sha256: "385dd0a9c25e67ef0dd60e022d2a2d7b17e2f36819cf3cb46aa8cdff5c5282c9" - - url: "https://github.com/opencv/opencv_contrib/archive/4.1.2.tar.gz" + - url: "https://github.com/opencv/opencv_contrib/archive/refs/tags/4.1.2.tar.gz" sha256: "0f6c3d30baa39e3e7611afb481ee86dea45dafb182cac87d570c95dccd83eb8b" patches: "4.5.5": - patch_file: "patches/4.5.5-0001-find-openexr.patch" patch_description: "Robust discovery & injection of OpenEXR" patch_type: "conan" + - patch_file: "patches/4.5.5-0002-objdetect-without-dnn.patch" + patch_description: "Allow to build objdetect module without dnn" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv/pull/21369" + - patch_file: "patches/4.5.5-0003-find-quirc.patch" + patch_description: "Robust discovery & injection of quirc" + patch_type: "conan" + - patch_file: "patches/4.5.5-0004-link-qt-targets.patch" + patch_description: "Link to Qt through CMake targets" + patch_type: "conan" - patch_file: "patches/4.5.0-0002-find-ade.patch" patch_description: "Robust discovery & injection of ade" patch_type: "conan" - - patch_file: "patches/4.1.2-0003-find-quirc.patch" - patch_description: "Robust discovery & injection of quirc" + - patch_file: "patches/4.5.1-0001-tracking-no-plot-deps.patch" + patch_description: "Fix requirements of tracking module" + patch_type: "conan" + - patch_file: "patches/4.5.1-0002-alphamat-header.patch" + patch_description: "Add missing header in alphamat.hpp" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv_contrib/pull/3422" + - patch_file: "patches/4.1.2-0006-hdf.patch" + patch_description: "Robust discovery of hdf" patch_type: "conan" - patch_file: "patches/4.5.2-0001-fix-zlib-static-android.patch" patch_description: "Fix discovery of zlib static if Android" @@ -35,18 +52,35 @@ patches: - patch_file: "patches/4.5.3-0001-find-openexr.patch" patch_description: "Robust discovery & injection of OpenEXR" patch_type: "conan" + - patch_file: "patches/4.5.3-0002-link-qt-targets.patch" + patch_description: "Link to Qt through CMake targets" + patch_type: "conan" - patch_file: "patches/4.5.0-0002-find-ade.patch" patch_description: "Robust discovery & injection of ade" patch_type: "conan" - patch_file: "patches/4.1.2-0003-find-quirc.patch" patch_description: "Robust discovery & injection of quirc" patch_type: "conan" + - patch_file: "patches/4.5.1-0001-tracking-no-plot-deps.patch" + patch_description: "Fix requirements of tracking module" + patch_type: "conan" + - patch_file: "patches/4.5.1-0002-alphamat-header.patch" + patch_description: "Add missing header in alphamat.hpp" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv_contrib/pull/3422" + - patch_file: "patches/4.1.2-0006-hdf.patch" + patch_description: "Robust discovery of hdf" + patch_type: "conan" - patch_file: "patches/4.5.2-0001-fix-zlib-static-android.patch" patch_description: "Fix discovery of zlib static if Android" patch_type: "conan" - patch_file: "patches/4.1.2-0007-android-install-layout.patch" patch_description: "Honor install layout from conan if Android" patch_type: "conan" + - patch_file: "patches/4.1.2-0010-compat-protobuf-ge-3.18.patch" + patch_description: "Compatibility with protobuf >= 3.18" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv/pull/20386" "4.1.2": - patch_file: "patches/4.1.2-0001-find-openexr.patch" patch_description: "Robust discovery & injection of OpenEXR" @@ -60,6 +94,26 @@ patches: - patch_file: "patches/4.1.2-0004-jasper.patch" patch_description: "Compatibility with recent jasper versions" patch_type: "portability" + - patch_file: "patches/4.1.2-0005-tracking-no-plot-deps.patch" + patch_description: "Fix requirements of tracking module" + patch_type: "conan" + - patch_file: "patches/4.1.2-0006-hdf.patch" + patch_description: "Robust discovery of hdf" + patch_type: "conan" - patch_file: "patches/4.1.2-0007-android-install-layout.patch" patch_description: "Honor install layout from conan if Android" patch_type: "conan" + - patch_file: "patches/4.1.2-0008-link-qt-targets.patch" + patch_description: "Link to Qt through CMake targets" + patch_type: "conan" + - patch_file: "patches/4.1.2-0009-sfm-deps.patch" + patch_description: "Fix link to dependencies of sfm module" + patch_type: "conan" + - patch_file: "patches/4.1.2-0010-compat-protobuf-ge-3.18.patch" + patch_description: "Compatibility with protobuf >= 3.18" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv/pull/20386" + - patch_file: "patches/4.1.2-0011-compat-openexr3.patch" + patch_description: "Compatibility with OpenEXR 3.x" + patch_type: "portability" + patch_source: "https://github.com/opencv/opencv/pull/19970" diff --git a/recipes/opencv/4.x/conanfile.py b/recipes/opencv/4.x/conanfile.py index 895fee1eb01868..96c7055a75aa04 100644 --- a/recipes/opencv/4.x/conanfile.py +++ b/recipes/opencv/4.x/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile -from conan.errors import ConanInvalidConfiguration -from conan.tools.build import cross_building +from conan.errors import ConanException, ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.build import can_run, check_min_cppstd, valid_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.env import VirtualBuildEnv, VirtualRunEnv from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, rename, replace_in_file, rmdir, save @@ -13,6 +14,81 @@ required_conan_version = ">=1.54.0" +OPENCV_MAIN_MODULES_OPTIONS = ( + "calib3d", + "dnn", + "features2d", + "flann", + "gapi", + "highgui", + "imgcodecs", + "imgproc", + "ml", + "objdetect", + "photo", + "stitching", + "video", + "videoio", +) + +OPENCV_EXTRA_MODULES_OPTIONS = ( + "alphamat", + "aruco", + "barcode", + "bgsegm", + "bioinspired", + "ccalib", + "cudaarithm", + "cudabgsegm", + "cudacodec", + "cudafeatures2d", + "cudafilters", + "cudaimgproc", + "cudalegacy", + "cudaobjdetect", + "cudaoptflow", + "cudastereo", + "cudawarping", + "cvv", + "datasets", + "dnn_objdetect", + "dnn_superres", + "dpm", + "face", + "freetype", + "fuzzy", + "hdf", + "hfs", + "img_hash", + "intensity_transform", + "line_descriptor", + "mcc", + "optflow", + "ovis", + "phase_unwrapping", + "plot", + "quality", + "rapid", + "reg", + "rgbd", + "saliency", + "sfm", + "shape", + "stereo", + "structured_light", + "superres", + "surface_matching", + "text", + "tracking", + "videostab", + "viz", + "wechat_qrcode", + "xfeatures2d", + "ximgproc", + "xobjdetect", + "xphoto", +) + class OpenCVConan(ConanFile): name = "opencv" license = "Apache-2.0" @@ -21,83 +97,117 @@ class OpenCVConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" topics = ("computer-vision", "deep-learning", "image-processing") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], - "contrib": [True, False], - "contrib_freetype": [True, False], - "contrib_sfm": [True, False], + # global options "parallel": [False, "tbb", "openmp"], "with_ipp": [False, "intel-ipp", "opencv-icv"], - "with_ade": [True, False], + "with_eigen": [True, False], + "neon": [True, False], + "with_opencl": [True, False], + "with_cuda": [True, False], + "with_cublas": [True, False], + "with_cufft": [True, False], + "with_cudnn": [True, False], + "cuda_arch_bin": [None, "ANY"], + "cpu_baseline": [None, "ANY"], + "cpu_dispatch": [None, "ANY"], + "world": [True, False], + "nonfree": [True, False], + # dnn module options + "with_vulkan": [True, False], + "dnn_cuda": [True, False], + # highgui module options + "with_gtk": [True, False], + "with_qt": [True, False], + # imgcodecs module options "with_jpeg": [False, "libjpeg", "libjpeg-turbo", "mozjpeg"], "with_png": [True, False], "with_tiff": [True, False], "with_jpeg2000": [False, "jasper", "openjpeg"], "with_openexr": [True, False], - "with_eigen": [True, False], "with_webp": [True, False], - "with_gtk": [True, False], - "with_quirc": [True, False], - "with_cuda": [True, False], - "with_cublas": [True, False], - "with_cufft": [True, False], - "with_cudnn": [True, False], - "with_v4l": [True, False], - "with_ffmpeg": [True, False], + "with_gdal": [True, False], + "with_gdcm": [True, False], "with_imgcodec_hdr": [True, False], "with_imgcodec_pfm": [True, False], "with_imgcodec_pxm": [True, False], "with_imgcodec_sunraster": [True, False], "with_msmf": [True, False], "with_msmf_dxva": [True, False], - "neon": [True, False], - "dnn": [True, False], - "dnn_cuda": [True, False], - "cuda_arch_bin": [None, "ANY"], - "cpu_baseline": [None, "ANY"], - "cpu_dispatch": [None, "ANY"], - "nonfree": [True, False], + # objdetect module options + "with_quirc": [True, False], + # videoio module options + "with_ffmpeg": [True, False], + "with_v4l": [True, False], + # text module options + "with_tesseract": [True, False], + # TODO: deprecated options to remove in few months + "contrib": [True, False, "deprecated"], + "contrib_freetype": [True, False, "deprecated"], + "contrib_sfm": [True, False, "deprecated"], + "with_ade": [True, False, "deprecated"], } + options.update({_name: [True, False] for _name in OPENCV_MAIN_MODULES_OPTIONS}) + options.update({_name: [True, False] for _name in OPENCV_EXTRA_MODULES_OPTIONS}) + default_options = { "shared": False, "fPIC": True, + # global options "parallel": False, - "contrib": False, - "contrib_freetype": False, - "contrib_sfm": False, "with_ipp": False, - "with_ade": True, + "with_eigen": True, + "neon": True, + "with_opencl": False, + "with_cuda": False, + "with_cublas": False, + "with_cufft": False, + "with_cudnn": False, + "cuda_arch_bin": None, + "cpu_baseline": None, + "cpu_dispatch": None, + "world": False, + "nonfree": False, + # dnn module options + "with_vulkan": False, + "dnn_cuda": False, + # highgui module options + "with_gtk": True, + "with_qt": False, + # imgcodecs module options "with_jpeg": "libjpeg", "with_png": True, "with_tiff": True, "with_jpeg2000": "jasper", "with_openexr": True, - "with_eigen": True, "with_webp": True, - "with_gtk": True, - "with_quirc": True, - "with_cuda": False, - "with_cublas": False, - "with_cufft": False, - "with_cudnn": False, - "with_v4l": False, - "with_ffmpeg": True, + "with_gdal": False, + "with_gdcm": False, "with_imgcodec_hdr": False, "with_imgcodec_pfm": False, "with_imgcodec_pxm": False, "with_imgcodec_sunraster": False, "with_msmf": True, "with_msmf_dxva": True, - "neon": True, - "dnn": True, - "dnn_cuda": False, - "cuda_arch_bin": None, - "cpu_baseline": None, - "cpu_dispatch": None, - "nonfree": False, + # objdetect module options + "with_quirc": True, + # videoio module options + "with_ffmpeg": True, + "with_v4l": False, + # text module options + "with_tesseract": True, + # TODO: deprecated options to remove in few months + "contrib": "deprecated", + "contrib_freetype": "deprecated", + "contrib_sfm": "deprecated", + "with_ade": "deprecated", } + default_options.update({_name: True for _name in OPENCV_MAIN_MODULES_OPTIONS}) + default_options.update({_name: False for _name in OPENCV_EXTRA_MODULES_OPTIONS}) short_paths = True @@ -117,9 +227,37 @@ def _has_with_tiff_option(self): def _has_with_ffmpeg_option(self): return self.settings.os != "iOS" and self.settings.os != "WindowsStore" + @property + def _has_superres_option(self): + return self.settings.os != "iOS" + + @property + def _has_alphamat_option(self): + return Version(self.version) >= "4.3.0" + + @property + def _has_intensity_transform_option(self): + return Version(self.version) >= "4.3.0" + + @property + def _has_rapid_option(self): + return Version(self.version) >= "4.3.0" + + @property + def _has_mcc_option(self): + return Version(self.version) >= "4.5.0" + + @property + def _has_wechat_qrcode_option(self): + return Version(self.version) >= "4.5.2" + + @property + def _has_barcode_option(self): + return Version(self.version) >= "4.5.3" + @property def _protobuf_version(self): - return "3.17.1" + return "3.21.12" def export_sources(self): export_conandata_patches(self) @@ -130,6 +268,8 @@ def config_options(self): if self.settings.os != "Linux": del self.options.with_gtk del self.options.with_v4l + if self.settings.os in ["iOS", "Android"]: + del self.options.with_opencl if self.settings.os != "Windows": del self.options.with_msmf del self.options.with_msmf_dxva @@ -148,101 +288,848 @@ def config_options(self): del self.options.with_jpeg2000 if not self._has_with_tiff_option: del self.options.with_tiff + if not self._has_superres_option: + del self.options.superres + if not self._has_alphamat_option: + del self.options.alphamat + if not self._has_intensity_transform_option: + del self.options.intensity_transform + if not self._has_rapid_option: + del self.options.rapid + if not self._has_mcc_option: + del self.options.mcc + if not self._has_wechat_qrcode_option: + del self.options.wechat_qrcode + if not self._has_barcode_option: + del self.options.barcode + + @property + def _opencv_modules(self): + def imageformats_deps(): + components = [] + if self.options.get_safe("with_jpeg2000"): + components.append("{0}::{0}".format(self.options.with_jpeg2000)) + if self.options.get_safe("with_png"): + components.append("libpng::libpng") + if self.options.get_safe("with_jpeg") == "libjpeg": + components.append("libjpeg::libjpeg") + elif self.options.get_safe("with_jpeg") == "libjpeg-turbo": + components.append("libjpeg-turbo::jpeg") + elif self.options.get_safe("with_jpeg") == "mozjpeg": + components.append("mozjpeg::libjpeg") + if self.options.get_safe("with_tiff"): + components.append("libtiff::libtiff") + if self.options.get_safe("with_openexr"): + components.append("openexr::openexr") + if self.options.get_safe("with_webp"): + components.append("libwebp::libwebp") + if self.options.get_safe("with_gdal"): + components.append("gdal::gdal") + if self.options.get_safe("with_gdcm"): + components.append("gdcm::gdcm") + return components + + def eigen(): + return ["eigen::eigen"] if self.options.with_eigen else [] + + def ffmpeg(): + if self.options.get_safe("with_ffmpeg"): + return [ + "ffmpeg::avcodec", "ffmpeg::avdevice", "ffmpeg::avformat", + "ffmpeg::avutil", "ffmpeg::swscale", + ] + return [] + + def freetype(): + return ["freetype::freetype"] if self.options.freetype else [] + + def gtk(): + return ["gtk::gtk"] if self.options.get_safe("with_gtk") else [] + + def ipp(): + if self.options.with_ipp == "intel-ipp": + return ["intel-ipp::intel-ipp"] + elif self.options.with_ipp == "opencv-icv" and not self.options.shared: + return ["ippiw"] + return [] + + def parallel(): + return ["onetbb::onetbb"] if self.options.parallel == "tbb" else [] + + def qt(): + return ["qt::qt"] if self.options.get_safe("with_qt") else [] + + def quirc(): + return ["quirc::quirc"] if self.options.get_safe("with_quirc") else [] + + def tesseract(): + return ["tesseract::tesseract"] if self.options.get_safe("with_tesseract") else [] + + def vulkan(): + return ["vulkan-headers::vulkan-headers"] if self.options.get_safe("with_vulkan") else [] + + def opencv_calib3d(): + return ["opencv_calib3d"] if self.options.calib3d else [] + + def opencv_cudaarithm(): + return ["opencv_cudaarithm"] if self.options.cudaarithm else [] + + def opencv_cudacodec(): + return ["opencv_cudacodec"] if self.options.cudacodec else [] + + def opencv_cudafeatures2d(): + return ["opencv_cudafeatures2d"] if self.options.cudafeatures2d else [] + + def opencv_cudafilters(): + return ["opencv_cudafilters"] if self.options.cudafilters else [] + + def opencv_cudaimgproc(): + return ["opencv_cudaimgproc"] if self.options.cudaimgproc else [] + + def opencv_cudalegacy(): + return ["opencv_cudalegacy"] if self.options.cudalegacy else [] + + def opencv_cudaoptflow(): + return ["opencv_cudaoptflow"] if self.options.cudaoptflow else [] + + def opencv_cudawarping(): + return ["opencv_cudawarping"] if self.options.cudawarping else [] + + def opencv_dnn(): + return ["opencv_dnn"] if self.options.dnn else [] + + def opencv_flann(): + return ["opencv_flann"] if self.options.flann else [] + + def opencv_imgcodecs(): + return ["opencv_imgcodecs"] if self.options.imgcodecs else [] + + def opencv_imgproc(): + return ["opencv_imgproc"] if self.options.imgproc else [] + + def opencv_objdetect(): + return ["opencv_objdetect"] if self.options.objdetect else [] + + def opencv_video(): + return ["opencv_video"] if self.options.video else [] + + def opencv_videoio(): + return ["opencv_videoio"] if self.options.videoio else [] + + def opencv_xfeatures2d(): + return ["opencv_xfeatures2d"] if self.options.xfeatures2d else [] + + opencv_modules = { + # Main modules + "calib3d": { + "is_built": self.options.calib3d, + "mandatory_options": ["features2d", "flann", "imgproc"], + "requires": ["opencv_core", "opencv_features2d", "opencv_flann", "opencv_imgproc"] + eigen() + ipp(), + }, + "core": { + "is_built": True, + "no_option": True, + "requires": ["zlib::zlib"] + parallel() + eigen() + ipp(), + "system_libs": [ + (self.settings.os == "Android", ["dl", "m", "log"]), + (self.settings.os == "FreeBSD", ["m", "pthread"]), + (self.settings.os == "Linux", ["dl", "m", "pthread", "rt"]), + ], + "frameworks": [ + (self.settings.os == "Macos" and self.options.get_safe("with_opencl"), ["OpenCL"]), + ], + }, + "dnn": { + "is_built": self.options.dnn, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc", "protobuf::protobuf"] + vulkan() + ipp(), + }, + "features2d": { + "is_built": self.options.features2d, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc"] + opencv_flann() + eigen() + ipp(), + }, + "flann": { + "is_built": self.options.flann, + "requires": ["opencv_core"] + ipp(), + }, + "gapi": { + "is_built": self.options.gapi, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc", "ade::ade"], + "system_libs": [ + (self.settings.os == "Windows", ["ws2_32", "wsock32"]), + ], + }, + "highgui": { + "is_built": self.options.highgui, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + opencv_imgcodecs() + + opencv_videoio() + freetype() + gtk() + qt() + ipp(), + "system_libs": [ + (self.settings.os == "Windows", ["comctl32", "gdi32", "ole32", "setupapi", "ws2_32", "vfw32"]), + ], + "frameworks": [ + (self.settings.os == "Macos", ["Cocoa"]), + ], + }, + "imgcodecs": { + "is_built": self.options.imgcodecs, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc", "zlib::zlib"] + imageformats_deps() + ipp(), + "frameworks": [ + (is_apple_os(self), ["CoreFoundation", "CoreGraphics"]), + (self.settings.os == "iOS", ["UIKit"]), + (self.settings.os == "Macos", ["AppKit"]), + ], + }, + "imgproc": { + "is_built": self.options.imgproc, + "requires": ["opencv_core"] + ipp(), + }, + "ml": { + "is_built": self.options.ml, + "requires": ["opencv_core"] + ipp(), + }, + "objdetect": { + "is_built": self.options.objdetect, + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc"] + quirc() + ipp(), + }, + "photo": { + "is_built": self.options.photo, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc"] + opencv_cudaarithm() + opencv_cudaimgproc() + ipp(), + }, + "stitching": { + "is_built": self.options.stitching, + "mandatory_options": ["calib3d", "features2d", "flann", "imgproc"], + "requires": ["opencv_calib3d", "opencv_features2d", "opencv_flann", "opencv_imgproc"] + + opencv_xfeatures2d() + opencv_cudaarithm() + opencv_cudawarping() + + opencv_cudafeatures2d() + opencv_cudalegacy() + opencv_cudaimgproc() + eigen() + ipp(), + }, + "video": { + "is_built": self.options.video, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc"] + opencv_calib3d() + ipp(), + }, + "videoio": { + "is_built": self.options.videoio, + "mandatory_options": ["imgcodecs", "imgproc"], + "requires": ["opencv_imgcodecs", "opencv_imgproc"] + ffmpeg() + ipp(), + "system_libs": [ + (self.settings.os == "Android" and int(str(self.settings.os.api_level)) > 20, ["mediandk"]), + ], + "frameworks": [ + (is_apple_os(self), ["Accelerate", "AVFoundation", "CoreGraphics", "CoreMedia", "CoreVideo", "QuartzCore"]), + (self.settings.os == "iOS", ["CoreImage", "UIKit"]), + (self.settings.os == "Macos", ["Cocoa"]), + ], + }, + # Extra modules + "alphamat": { + "is_built": self.options.get_safe("alphamat"), + "mandatory_options": ["with_eigen", "imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "aruco": { + "is_built": self.options.aruco, + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc"] + ipp(), + }, + "barcode": { + "is_built": self.options.get_safe("barcode"), + "mandatory_options": ["dnn", "imgproc"], + "requires": ["opencv_core", "opencv_dnn", "opencv_imgproc"] + ipp(), + }, + "bgsegm": { + "is_built": self.options.bgsegm, + "mandatory_options": ["calib3d", "imgproc", "video"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc", "opencv_video"] + ipp(), + }, + "bioinspired": { + "is_built": self.options.bioinspired, + "requires": ["opencv_core"] + ipp(), + }, + "ccalib": { + "is_built": self.options.ccalib, + "mandatory_options": ["calib3d", "features2d", "highgui", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_features2d", "opencv_highgui", "opencv_imgproc"] + ipp(), + }, + "cudaarithm": { + "is_built": self.options.cudaarithm, + "mandatory_options": ["with_cuda"], + "requires": ["opencv_core", "opencv_cudev"] + ipp(), + }, + "cudabgsegm": { + "is_built": self.options.cudabgsegm, + "mandatory_options": ["with_cuda", "video"], + "requires": ["opencv_video"] + ipp(), + }, + "cudacodec": { + "is_built": self.options.cudacodec, + "mandatory_options": ["with_cuda", "videoio"], + "requires": ["opencv_core", "opencv_videoio", "opencv_cudev"] + ipp(), + }, + "cudafeatures2d": { + "is_built": self.options.cudafeatures2d, + "mandatory_options": ["with_cuda", "features2d", "cudafilters", "cudawarping"], + "requires": ["opencv_features2d", "opencv_cudafilters", "opencv_cudawarping"] + ipp(), + }, + "cudafilters": { + "is_built": self.options.cudafilters, + "mandatory_options": ["with_cuda", "imgproc", "cudaarithm"], + "requires": ["opencv_imgproc", "opencv_cudaarithm"] + ipp(), + }, + "cudaimgproc": { + "is_built": self.options.cudaimgproc, + "mandatory_options": ["with_cuda", "imgproc"], + "requires": ["opencv_imgproc", "opencv_cudev"] + opencv_cudaarithm() + opencv_cudafilters() + ipp(), + }, + "cudalegacy": { + "is_built": self.options.cudalegacy, + "mandatory_options": ["with_cuda", "video"], + "requires": ["opencv_core", "opencv_video"] + opencv_calib3d() + opencv_imgproc() + opencv_objdetect() + + opencv_cudaarithm() + opencv_cudafilters() + opencv_cudaimgproc() + ipp(), + }, + "cudaobjdetect": { + "is_built": self.options.cudaobjdetect, + "mandatory_options": ["with_cuda", "objdetect", "cudaarithm", "cudawarping"], + "requires": ["opencv_objdetect", "opencv_cudaarithm", "opencv_cudawarping"] + opencv_cudalegacy() + ipp(), + }, + "cudaoptflow": { + "is_built": self.options.cudaoptflow, + "mandatory_options": ["with_cuda", "video", "cudaarithm", "cudaimgproc", "cudawarping", "optflow"], + "requires": ["opencv_video", "opencv_cudaarithm", "cudaimgproc", "opencv_cudawarping", + "opencv_optflow"] + opencv_cudalegacy() + ipp(), + }, + "cudastereo": { + "is_built": self.options.cudastereo, + "mandatory_options": ["with_cuda", "calib3d"], + "requires": ["opencv_calib3d", "opencv_cudev"] + ipp(), + }, + "cudawarping": { + "is_built": self.options.cudawarping, + "mandatory_options": ["with_cuda", "imgproc"], + "requires": ["opencv_core", "opencv_imgproc", "opencv_cudev"] + ipp(), + }, + "cudev": { + "is_built": self.options.with_cuda, + "no_option": True, + "requires": ipp(), + }, + "cvv": { + "is_built": self.options.cvv, + "mandatory_options": ["with_qt", "features2d", "imgproc"], + "requires": ["opencv_core", "opencv_features2d", "opencv_imgproc", "qt::qt"] + ipp(), + }, + "datasets": { + "is_built": self.options.datasets, + "mandatory_options": ["flann", "imgcodecs", "ml"], + "requires": ["opencv_core", "opencv_flann", "opencv_imgcodecs", "opencv_ml"] + ipp(), + }, + "dnn_objdetect": { + "is_built": self.options.dnn_objdetect, + "mandatory_options": ["dnn", "imgproc"], + "requires": ["opencv_core", "opencv_dnn", "opencv_imgproc"] + ipp(), + }, + "dnn_superres": { + "is_built": self.options.dnn_superres, + "mandatory_options": ["dnn", "imgproc"], + "requires": ["opencv_core", "opencv_dnn", "opencv_imgproc"] + ipp(), + }, + "dpm": { + "is_built": self.options.dpm, + "mandatory_options": ["imgproc", "objdetect"], + "requires": ["opencv_core", "opencv_imgproc", "opencv_objdetect"] + ipp(), + }, + "face": { + "is_built": self.options.face, + "mandatory_options": ["calib3d", "imgproc", "objdetect", "photo"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc", "opencv_objdetect", "opencv_photo"] + ipp(), + }, + "freetype": { + "is_built": self.options.freetype, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc", "freetype::freetype", "harfbuzz::harfbuzz"] + ipp(), + }, + "fuzzy": { + "is_built": self.options.fuzzy, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "hdf": { + "is_built": self.options.hdf, + "requires": ["opencv_core", "hdf5::hdf5"] + ipp(), + }, + "hfs": { + "is_built": self.options.hfs, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "img_hash": { + "is_built": self.options.img_hash, + "is_part_of_world": False, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "intensity_transform": { + "is_built": self.options.get_safe("intensity_transform"), + "requires": ["opencv_core"] + ipp(), + }, + "line_descriptor": { + "is_built": self.options.line_descriptor, + "mandatory_options": ["imgproc"], + "requires": ["opencv_imgproc"] + ipp(), + }, + "mcc": { + "is_built": self.options.get_safe("mcc"), + "mandatory_options": ["calib3d", "dnn", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_dnn", "opencv_imgproc"] + ipp(), + }, + "optflow": { + "is_built": self.options.optflow, + "mandatory_options": ["calib3d", "flann", "imgcodecs", "imgproc", "video", "ximgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_flann", "opencv_imgcodecs", "opencv_imgproc", + "opencv_video", "opencv_ximgproc"] + ipp(), + }, + "ovis": { + "is_built": self.options.ovis, + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc", "ogre::ogre"] + ipp(), + }, + "phase_unwrapping": { + "is_built": self.options.phase_unwrapping, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "plot": { + "is_built": self.options.plot, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "quality": { + "is_built": self.options.quality, + "mandatory_options": ["imgproc", "ml"], + "requires": ["opencv_core", "opencv_imgproc", "opencv_ml"] + ipp(), + }, + "rapid": { + "is_built": self.options.get_safe("rapid"), + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc"] + ipp(), + }, + "reg": { + "is_built": self.options.reg, + "mandatory_options": ["imgproc"], + "requires": ["opencv_core", "opencv_imgproc"] + ipp(), + }, + "rgbd": { + "is_built": self.options.rgbd, + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc"] + eigen() + ipp(), + }, + "saliency": { + "is_built": self.options.saliency, + "mandatory_options": ["features2d", "imgproc"], + "requires": ["opencv_features2d", "opencv_imgproc"] + ipp(), + }, + "sfm": { + "is_built": self.options.sfm, + "is_part_of_world": False, + "mandatory_options": ["with_eigen", "calib3d", "features2d", "imgcodecs", "xfeatures2d"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_features2d", "opencv_imgcodecs", "opencv_xfeatures2d", + "correspondence", "multiview", "numeric", "glog::glog", "gflags::gflags"] + eigen() + ipp(), + }, + "shape": { + "is_built": self.options.shape, + "mandatory_options": ["calib3d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc"] + ipp(), + }, + "stereo": { + "is_built": self.options.stereo, + "mandatory_options": ["features2d", "imgproc", "tracking"], + "requires": ["opencv_core", "opencv_features2d", "opencv_imgproc", "opencv_tracking"] + ipp(), + }, + "structured_light": { + "is_built": self.options.structured_light, + "mandatory_options": ["calib3d", "imgproc", "phase_unwrapping"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgproc", "opencv_phase_unwrapping"] + ipp(), + }, + "superres": { + "is_built": self.options.get_safe("superres"), + "mandatory_options": ["imgproc", "video", "optflow"], + "requires": ["opencv_imgproc", "opencv_video", "opencv_optflow"] + opencv_videoio() + ipp() + + opencv_cudaarithm() + opencv_cudafilters() + opencv_cudawarping() + opencv_cudaimgproc() + + opencv_cudaoptflow() + opencv_cudacodec(), + }, + "surface_matching": { + "is_built": self.options.surface_matching, + "mandatory_options": ["flann"], + "requires": ["opencv_core", "opencv_flann"] + ipp(), + }, + "text": { + "is_built": self.options.text, + "mandatory_options": ["dnn", "features2d", "imgproc", "ml"], + "requires": ["opencv_core", "opencv_dnn", "opencv_features2d", "opencv_imgproc", "opencv_ml"] + + tesseract() + ipp(), + }, + "tracking": { + "is_built": self.options.tracking, + "mandatory_options": ["imgproc", "video"], + "requires": ["opencv_core", "opencv_imgproc", "opencv_video"] + opencv_dnn() + ipp(), + }, + "videostab": { + "is_built": self.options.videostab, + "mandatory_options": ["calib3d", "features2d", "imgproc", "photo", "video"], + "requires": ["opencv_calib3d", "opencv_features2d", "opencv_imgproc", "opencv_photo", "opencv_video"] + + opencv_videoio() + ipp() + opencv_cudawarping() + opencv_cudaoptflow(), + }, + "viz": { + "is_built": self.options.viz, + "requires": ["opencv_core", "vtk::vtk"] + ipp(), + }, + "wechat_qrcode": { + "is_built": self.options.get_safe("wechat_qrcode"), + "mandatory_options": ["dnn", "imgproc"], + "requires": ["opencv_core", "opencv_dnn", "opencv_imgproc"] + ipp(), + }, + "xfeatures2d": { + "is_built": self.options.xfeatures2d, + "mandatory_options": ["calib3d", "features2d", "imgproc"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_features2d", "opencv_imgproc"] + ipp() + opencv_cudaarithm(), + }, + "ximgproc": { + "is_built": self.options.ximgproc, + "mandatory_options": ["calib3d", "imgcodecs", "imgproc", "video"], + "requires": ["opencv_core", "opencv_calib3d", "opencv_imgcodecs", "opencv_imgproc", "opencv_video"] + + eigen() + ipp(), + }, + "xobjdetect": { + "is_built": self.options.xobjdetect, + "mandatory_options": ["imgcodecs", "imgproc", "objdetect"], + "requires": ["opencv_core", "opencv_imgcodecs", "opencv_imgproc", "opencv_objdetect"] + ipp(), + }, + "xphoto": { + "is_built": self.options.xphoto, + "mandatory_options": ["imgproc", "photo"], + "requires": ["opencv_core", "opencv_imgproc", "opencv_photo"] + ipp(), + }, + # Extra targets (without prefix in their target & lib name) + "ippiw": { + "is_built": self.options.with_ipp == "opencv-icv" and not self.options.shared, + "is_part_of_world": False, + "no_option": True, + }, + "numeric": { + "is_built": self.options.sfm, + "is_part_of_world": False, + "no_option": True, + "requires": eigen() + ipp(), + }, + "correspondence": { + "is_built": self.options.sfm, + "is_part_of_world": False, + "no_option": True, + "requires": ["opencv_imgcodecs", "multiview", "glog::glog"] + eigen() + ipp(), + }, + "multiview": { + "is_built": self.options.sfm, + "is_part_of_world": False, + "no_option": True, + "requires": ["numeric", "glog::glog"] + eigen() + ipp(), + }, + } + + if Version(self.version) >= "4.3.0": + opencv_modules["gapi"].setdefault("requires", []).extend(opencv_video()) + if Version(self.version) >= "4.5.2": + opencv_modules["gapi"].setdefault("requires", []).extend(opencv_calib3d()) + if Version(self.version) >= "4.5.4": + opencv_modules["objdetect"].setdefault("requires", []).extend(opencv_dnn()) + if Version(self.version) >= "4.5.1": + opencv_modules["video"].setdefault("requires", []).extend(opencv_dnn()) + if Version(self.version) >= "4.4.0": + opencv_modules["intensity_transform"].setdefault("mandatory_options", []).append("imgproc") + opencv_modules["intensity_transform"].setdefault("requires", []).append("opencv_imgproc") + if Version(self.version) < "4.3.0": + opencv_modules["stereo"].setdefault("mandatory_options", []).extend(["calib3d", "video"]) + opencv_modules["stereo"].setdefault("requires", []).extend(["opencv_calib3d", "opencv_video"]) + + return opencv_modules + + def _get_mandatory_disabled_options(self, opencv_modules): + direct_options_to_enable = {} + transitive_options_to_enable = {} + + # Check which direct options have to be enabled + base_options = [option for option, values in opencv_modules.items() + if not values.get("no_option") and self.options.get_safe(option)] + for base_option in base_options: + for mandatory_option in opencv_modules.get(base_option, {}).get("mandatory_options", []): + if not self.options.get_safe(mandatory_option): + direct_options_to_enable.setdefault(mandatory_option, set()).add(base_option) + + # Now traverse the graph to check which transitive options have to be enabled + def collect_transitive_options(base_option, option): + for mandatory_option in opencv_modules.get(option, {}).get("mandatory_options", []): + if not self.options.get_safe(mandatory_option): + if mandatory_option not in transitive_options_to_enable: + transitive_options_to_enable[mandatory_option] = set() + collect_transitive_options(base_option, mandatory_option) + if base_option not in direct_options_to_enable.get(mandatory_option, set()): + transitive_options_to_enable[mandatory_option].add(base_option) + + for base_option in base_options: + collect_transitive_options(base_option, base_option) + + return { + "direct": direct_options_to_enable, + "transitive": transitive_options_to_enable, + } + + def _solve_internal_dependency_graph(self, opencv_modules): + disabled_options = self._get_mandatory_disabled_options(opencv_modules) + direct_options_to_enable = disabled_options["direct"] + transitive_options_to_enable = disabled_options["transitive"] + + # Enable mandatory options + all_options_to_enable = set(direct_options_to_enable.keys()) + all_options_to_enable.update(transitive_options_to_enable.keys()) + if all_options_to_enable: + message = ("Several opencv options which were disabled will be enabled because " + "they are required by modules you have explicitly requested:\n") + + for option_to_enable in all_options_to_enable: + setattr(self.options, option_to_enable, True) + + direct_and_transitive = [] + direct = ", ".join(direct_options_to_enable.get(option_to_enable, [])) + if direct: + direct_and_transitive.append(f"direct dependency of {direct}") + transitive = ", ".join(transitive_options_to_enable.get(option_to_enable, [])) + if transitive: + direct_and_transitive.append(f"transitive dependency of {transitive}") + message += f" - {option_to_enable}: {' / '.join(direct_and_transitive)}\n" + + self.output.warning(message) def configure(self): if self.options.shared: self.options.rm_safe("fPIC") - if not self.options.contrib: - del self.options.contrib_freetype - del self.options.contrib_sfm + + # TODO: remove contrib option in few months + if self.options.contrib != "deprecated": + self.output.warning("contrib option is deprecated") + if self.options.contrib: + # During deprecation period, keep old behavior of contrib=True, which was to enable + # all available contribs. + ## Filter main module options + filtered_options = list(OPENCV_MAIN_MODULES_OPTIONS) + ## Filter extra modules not built previously with contrib=True + filtered_options.extend(["cvv", "freetype", "hdf", "ovis", "sfm", "viz"]) + ## Filter extra modules not built previously when some option was disabled + if not self.options.with_eigen: + filtered_options.append("alphamat") + if not self.options.with_cuda: + filtered_options.extend([ + "cudaarithm", "cudabgsegm", "cudacodec", "cudafeatures2d", "cudafilters", "cudaimgproc", + "cudalegacy", "cudaobjdetect", "cudaoptflow", "cudastereo", "cudawarping", + ]) + for option, values in self._opencv_modules.items(): + if option not in filtered_options and not values.get("no_option"): + try: + if hasattr(self.options, option): + setattr(self.options, option, True) + except ConanException: + continue + + # TODO: remove contrib_freetype option in few months + if self.options.contrib_freetype != "deprecated": + self.output.warning("contrib_freetype option is deprecated, use freetype option instead") + self.options.freetype = self.options.contrib_freetype + + # TODO: remove contrib_sfm option in few months + if self.options.contrib_sfm != "deprecated": + self.output.warning("contrib_sfm option is deprecated, use sfm option instead") + self.options.sfm = self.options.contrib_sfm + + # TODO: remove with_ade option in few months + if self.options.with_ade != "deprecated": + self.output.warning("with_ade option is deprecated, use gapi option instead") + self.options.gapi = self.options.with_ade + + # Call this first before any further manipulation of options based on other options + self._solve_internal_dependency_graph(self._opencv_modules) + if not self.options.dnn: - del self.options.dnn_cuda + self.options.rm_safe("dnn_cuda") + self.options.rm_safe("with_vulkan") + if not self.options.highgui: + self.options.rm_safe("with_gtk") + if not (self.options.highgui or self.options.cvv): + self.options.rm_safe("with_qt") + if not self.options.imgcodecs: + self.options.rm_safe("with_jpeg") + self.options.rm_safe("with_jpeg2000") + self.options.rm_safe("with_openexr") + self.options.rm_safe("with_png") + self.options.rm_safe("with_tiff") + self.options.rm_safe("with_webp") + self.options.rm_safe("with_gdal") + self.options.rm_safe("with_gdcm") + self.options.rm_safe("with_imgcodec_hdr") + self.options.rm_safe("with_imgcodec_pfm") + self.options.rm_safe("with_imgcodec_pxm") + self.options.rm_safe("with_imgcodec_sunraster") + self.options.rm_safe("with_msmf") + self.options.rm_safe("with_msmf_dxva") + if not self.options.objdetect: + self.options.rm_safe("with_quirc") + if not self.options.videoio: + self.options.rm_safe("with_ffmpeg") + self.options.rm_safe("with_v4l") if not self.options.with_cuda: - del self.options.with_cublas - del self.options.with_cudnn - del self.options.with_cufft - del self.options.dnn_cuda - del self.options.cuda_arch_bin - if bool(self.options.with_jpeg): + self.options.rm_safe("with_cublas") + self.options.rm_safe("with_cudnn") + self.options.rm_safe("with_cufft") + self.options.rm_safe("dnn_cuda") + self.options.rm_safe("cuda_arch_bin") + if not self.options.text: + self.options.rm_safe("with_tesseract") + + if bool(self.options.get_safe("with_jpeg", False)): if self.options.get_safe("with_jpeg2000") == "jasper": self.options["jasper"].with_libjpeg = self.options.with_jpeg if self.options.get_safe("with_tiff"): self.options["libtiff"].jpeg = self.options.with_jpeg - if self.settings.os == "Android": - self.options.with_openexr = False # disabled because this forces linkage to libc++_shared.so - def layout(self): cmake_layout(self, src_folder="src") def requirements(self): + # core module dependencies self.requires("zlib/1.2.13") - if self.options.with_jpeg == "libjpeg": + if self.options.with_eigen: + self.requires("eigen/3.4.0") + if self.options.parallel == "tbb": + self.requires("onetbb/2021.9.0") + if self.options.with_ipp == "intel-ipp": + self.requires("intel-ipp/2020") + # dnn module dependencies + if self.options.dnn: + # Symbols are exposed https://github.com/conan-io/conan-center-index/pull/16678#issuecomment-1507811867 + self.requires(f"protobuf/{self._protobuf_version}", transitive_libs=True, run=can_run(self)) + if self.options.get_safe("with_vulkan"): + self.requires("vulkan-headers/1.3.250.0") + # gapi module dependencies + if self.options.gapi: + self.requires("ade/0.1.2a") + # highgui module dependencies + if self.options.get_safe("with_gtk"): + self.requires("gtk/system") + if self.options.get_safe("with_qt"): + self.requires("qt/5.15.10") + # imgcodecs module dependencies + if self.options.get_safe("with_jpeg") == "libjpeg": self.requires("libjpeg/9e") - elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") - elif self.options.with_jpeg == "mozjpeg": + elif self.options.get_safe("with_jpeg") == "libjpeg-turbo": + self.requires("libjpeg-turbo/3.0.0") + elif self.options.get_safe("with_jpeg") == "mozjpeg": self.requires("mozjpeg/4.1.1") if self.options.get_safe("with_jpeg2000") == "jasper": self.requires("jasper/4.0.0") elif self.options.get_safe("with_jpeg2000") == "openjpeg": self.requires("openjpeg/2.5.0") - if self.options.with_png: + if self.options.get_safe("with_png"): self.requires("libpng/1.6.40") - if self.options.with_openexr: - if Version(self.version) < "4.5.3": - # opencv < 4.5.3 doesn't support openexr >= 3 - self.requires("openexr/2.5.7") - else: - self.requires("openexr/3.1.9") + if self.options.get_safe("with_openexr"): + self.requires("openexr/3.1.9") if self.options.get_safe("with_tiff"): self.requires("libtiff/4.5.1") - if self.options.with_eigen: - self.requires("eigen/3.4.0") + if self.options.get_safe("with_webp"): + self.requires("libwebp/1.3.1") + if self.options.get_safe("with_gdal"): + self.requires("gdal/3.5.2") + if self.options.get_safe("with_gdcm"): + self.requires("gdcm/3.0.21") + # objdetect module dependencies + if self.options.get_safe("with_quirc"): + self.requires("quirc/1.2") + # videoio module dependencies if self.options.get_safe("with_ffmpeg"): # opencv doesn't support ffmpeg >= 5.0.0 for the moment (until 4.5.5 at least) self.requires("ffmpeg/4.4.3") - if self.options.parallel == "tbb": - self.requires("onetbb/2021.9.0") - if self.options.with_ipp == "intel-ipp": - self.requires("intel-ipp/2020") - if self.options.with_webp: - self.requires("libwebp/1.3.1") - if self.options.get_safe("contrib_freetype"): + # freetype module dependencies + if self.options.freetype: self.requires("freetype/2.13.0") - self.requires("harfbuzz/6.0.0") - if self.options.get_safe("contrib_sfm"): + self.requires("harfbuzz/8.1.1") + # hdf module dependencies + if self.options.hdf: + self.requires("hdf5/1.14.1") + # ovis module dependencies + if self.options.ovis: + self.requires("ogre/1.10.2") + # sfm module dependencies + if self.options.sfm: self.requires("gflags/2.2.2") self.requires("glog/0.6.0") - if self.options.with_quirc: - self.requires("quirc/1.1") - if self.options.get_safe("with_gtk"): - self.requires("gtk/system") - if self.options.dnn: - # Symbols are exposed https://github.com/conan-io/conan-center-index/pull/16678#issuecomment-1507811867 - self.requires(f"protobuf/{self._protobuf_version}", transitive_libs=True) - if self.options.with_ade: - self.requires("ade/0.1.2a") + # text module dependencies + if self.options.get_safe("with_tesseract"): + self.requires("tesseract/5.3.0") + + def package_id(self): + # deprecated options + del self.info.options.contrib + del self.info.options.contrib_freetype + del self.info.options.contrib_sfm + del self.info.options.with_ade + + def _check_mandatory_options(self, opencv_modules): + disabled_options = self._get_mandatory_disabled_options(opencv_modules) + direct_disabled_mandatory_options = disabled_options["direct"] + transitive_disabled_mandatory_options = disabled_options["transitive"] + + # check mandatory options + all_disabled_mandatory_options = set(direct_disabled_mandatory_options.keys()) + all_disabled_mandatory_options.update(transitive_disabled_mandatory_options.keys()) + if all_disabled_mandatory_options: + message = ("Several opencv options are disabled but are required by modules " + "you have explicitly requested:\n") + + for disabled_option in all_disabled_mandatory_options: + direct_and_transitive = [] + direct = ", ".join(direct_disabled_mandatory_options.get(disabled_option, [])) + if direct: + direct_and_transitive.append(f"direct dependency of {direct}") + transitive = ", ".join(transitive_disabled_mandatory_options.get(disabled_option, [])) + if transitive: + direct_and_transitive.append(f"transitive dependency of {transitive}") + message += f" - {disabled_option}: {' / '.join(direct_and_transitive)}\n" + + raise ConanInvalidConfiguration(message) def validate(self): + self._check_mandatory_options(self._opencv_modules) + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) if self.options.shared and is_msvc(self) and is_msvc_static_runtime(self): raise ConanInvalidConfiguration("Visual Studio with static runtime is not supported for shared library.") if self.settings.compiler == "clang" and Version(self.settings.compiler.version) < "4": raise ConanInvalidConfiguration("Clang 3.x can't build OpenCV 4.x due to an internal bug.") - if self.options.with_cuda and not self.options.contrib: - raise ConanInvalidConfiguration("contrib must be enabled for cuda") if self.options.get_safe("dnn_cuda") and \ - (not self.options.with_cuda or not self.options.contrib or not self.options.with_cublas or not self.options.with_cudnn): - raise ConanInvalidConfiguration("with_cublas, with_cudnn and contrib must be enabled for dnn_cuda") + (not self.options.with_cuda or not self.options.with_cublas or not self.options.with_cudnn): + raise ConanInvalidConfiguration("with_cublas and with_cudnn must be enabled for dnn_cuda") if self.options.with_ipp == "opencv-icv" and \ - (not str(self.settings.arch) in ["x86", "x86_64"] or \ - not str(self.settings.os) in ["Linux", "Macos", "Windows"]): + not (self.settings.arch in ["x86", "x86_64"] and self.settings.os in ["Linux", "Macos", "Windows"]): raise ConanInvalidConfiguration(f"opencv-icv is not available for {self.settings.os}/{self.settings.arch}") + if self.options.viz: + raise ConanInvalidConfiguration( + "viz module can't be enabled yet. It requires VTK which is not available in conan-center." + ) def build_requirements(self): - if self.options.dnn: - if hasattr(self, "settings_build") and cross_building(self): - self.tool_requires(f"protobuf/{self._protobuf_version}") + if self.options.dnn and not can_run(self): + self.tool_requires(f"protobuf/{self._protobuf_version}") def source(self): get(self, **self.conan_data["sources"][self.version][0], strip_root=True) @@ -258,6 +1145,7 @@ def _patch_sources(self): replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "ANDROID OR NOT UNIX", "FALSE") replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "elseif(EMSCRIPTEN)", "elseif(QNXNTO)\nelseif(EMSCRIPTEN)") replace_in_file(self, os.path.join(self.source_folder, "modules", "imgcodecs", "CMakeLists.txt"), "JASPER_", "Jasper_") + replace_in_file(self, os.path.join(self.source_folder, "modules", "imgcodecs", "CMakeLists.txt"), "${GDAL_LIBRARY}", "GDAL::GDAL") # Fix detection of ffmpeg replace_in_file(self, os.path.join(self.source_folder, "modules", "videoio", "cmake", "detect_ffmpeg.cmake"), @@ -285,35 +1173,20 @@ def _patch_sources(self): 'if(TARGET "${Protobuf_LIBRARIES}")', 'if(FALSE) # patch: disable if(TARGET "${Protobuf_LIBRARIES}")') - if self.options.get_safe("contrib_freetype"): + if self.options.freetype: freetype_cmake = os.path.join(self._contrib_folder, "modules", "freetype", "CMakeLists.txt") replace_in_file(self, freetype_cmake, "ocv_check_modules(FREETYPE freetype2)", "find_package(Freetype REQUIRED MODULE)") replace_in_file(self, freetype_cmake, "FREETYPE_", "Freetype_") - replace_in_file(self, freetype_cmake, "ocv_check_modules(HARFBUZZ harfbuzz)", "find_package(harfbuzz REQUIRED)") + replace_in_file(self, freetype_cmake, "ocv_check_modules(HARFBUZZ harfbuzz)", "find_package(harfbuzz REQUIRED CONFIG)") replace_in_file(self, freetype_cmake, "HARFBUZZ_", "harfbuzz_") - if self.options.get_safe("contrib_sfm") and Version(self.version) <= "4.5.2": - sfm_cmake = os.path.join(self._contrib_folder, "modules", "sfm", "CMakeLists.txt") - ver = Version(self.version) - if ver <= "4.5.0": - search = " find_package(Glog QUIET)\nendif()" - else: - search = ' set(GLOG_INCLUDE_DIRS "${GLOG_INCLUDE_DIR}")\nendif()' - replace_in_file(self, sfm_cmake, search, f"""{search} - if(NOT GFLAGS_LIBRARIES AND TARGET gflags::gflags) - set(GFLAGS_LIBRARIES gflags::gflags) - endif() - if(NOT GLOG_LIBRARIES AND TARGET glog::glog) - set(GLOG_LIBRARIES glog::glog) - endif()""") - def generate(self): if self.options.dnn: - if hasattr(self, "settings_build") and cross_building(self): - VirtualBuildEnv(self).generate() - else: + if can_run(self): VirtualRunEnv(self).generate(scope="build") + else: + VirtualBuildEnv(self).generate() tc = CMakeToolchain(self) tc.variables["OPENCV_CONFIG_INSTALL_PATH"] = "cmake" @@ -323,11 +1196,13 @@ def generate(self): tc.variables["OPENCV_OTHER_INSTALL_PATH"] = "res" tc.variables["OPENCV_LICENSES_INSTALL_PATH"] = "licenses" + tc.variables["OPENCV_SKIP_CMAKE_CXX_STANDARD"] = valid_min_cppstd(self, 11) + tc.variables["BUILD_CUDA_STUBS"] = False tc.variables["BUILD_DOCS"] = False tc.variables["BUILD_EXAMPLES"] = False tc.variables["BUILD_FAT_JAVA_LIB"] = False - tc.variables["BUILD_IPP_IW"] = False + tc.variables["BUILD_IPP_IW"] = self.options.with_ipp == "opencv-icv" tc.variables["BUILD_ITT"] = False tc.variables["BUILD_JASPER"] = False tc.variables["BUILD_JAVA"] = False @@ -357,12 +1232,11 @@ def generate(self): tc.variables["BUILD_opencv_ts"] = False tc.variables["WITH_1394"] = False - tc.variables["WITH_ADE"] = False tc.variables["WITH_ARAVIS"] = False tc.variables["WITH_CLP"] = False tc.variables["WITH_NVCUVID"] = False - tc.variables["WITH_FFMPEG"] = self.options.get_safe("with_ffmpeg") + tc.variables["WITH_FFMPEG"] = self.options.get_safe("with_ffmpeg", False) if self.options.get_safe("with_ffmpeg"): tc.variables["OPENCV_FFMPEG_SKIP_BUILD_CHECK"] = True tc.variables["OPENCV_FFMPEG_SKIP_DOWNLOAD"] = True @@ -370,72 +1244,70 @@ def generate(self): # libavcodec;libavformat;libavutil;libswscale modules tc.variables["OPENCV_FFMPEG_USE_FIND_PACKAGE"] = "ffmpeg" tc.variables["OPENCV_INSTALL_FFMPEG_DOWNLOAD_SCRIPT"] = False - tc.variables["FFMPEG_LIBRARIES"] = "ffmpeg::avcodec;ffmpeg::avformat;ffmpeg::avutil;ffmpeg::swscale" - ffmpeg_cpp_info = self.dependencies["ffmpeg"].cpp_info - for component in ["avcodec", "avformat", "avutil", "swscale"]: - ffmpeg_component_version = ffmpeg_cpp_info.components[component].get_property("component_version") - tc.variables[f"FFMPEG_lib{component}_VERSION"] = ffmpeg_component_version + ffmpeg_libraries = [] + for component in ["avcodec", "avdevice", "avformat", "avutil", "swscale", "avresample"]: + if component == "avutil" or self.dependencies["ffmpeg"].options.get_safe(component): + ffmpeg_libraries.append(f"ffmpeg::{component}") + ffmpeg_component_version = self.dependencies["ffmpeg"].cpp_info.components[component].get_property("component_version") + tc.variables[f"FFMPEG_lib{component}_VERSION"] = ffmpeg_component_version + tc.variables["FFMPEG_LIBRARIES"] = ";".join(ffmpeg_libraries) tc.variables["WITH_GSTREAMER"] = False tc.variables["WITH_HALIDE"] = False tc.variables["WITH_HPX"] = False - tc.variables["WITH_IMGCODEC_HDR"] = self.options.with_imgcodec_hdr - tc.variables["WITH_IMGCODEC_PFM"] = self.options.with_imgcodec_pfm - tc.variables["WITH_IMGCODEC_PXM"] = self.options.with_imgcodec_pxm - tc.variables["WITH_IMGCODEC_SUNRASTER"] = self.options.with_imgcodec_sunraster + tc.variables["WITH_IMGCODEC_HDR"] = self.options.get_safe("with_imgcodec_hdr", False) + tc.variables["WITH_IMGCODEC_PFM"] = self.options.get_safe("with_imgcodec_pfm", False) + tc.variables["WITH_IMGCODEC_PXM"] = self.options.get_safe("with_imgcodec_pxm", False) + tc.variables["WITH_IMGCODEC_SUNRASTER"] = self.options.get_safe("with_imgcodec_sunraster", False) tc.variables["WITH_INF_ENGINE"] = False - tc.variables["WITH_IPP"] = False - if self.options.with_ipp: - tc.variables["WITH_IPP"] = True - if self.options.with_ipp == "intel-ipp": - ipp_root = self.dependencies["intel-ipp"].package_folder.replace("\\", "/") - if self.settings.os == "Windows": - ipp_root = ipp_root.replace("\\", "/") - tc.variables["IPPROOT"] = ipp_root - tc.variables["IPPIWROOT"] = ipp_root - else: - tc.variables["BUILD_IPP_IW"] = True + tc.variables["WITH_IPP"] = bool(self.options.with_ipp) + if self.options.with_ipp == "intel-ipp": + ipp_root = self.dependencies["intel-ipp"].package_folder.replace("\\", "/") + tc.variables["IPPROOT"] = ipp_root + tc.variables["IPPIWROOT"] = ipp_root tc.variables["WITH_ITT"] = False tc.variables["WITH_LIBREALSENSE"] = False tc.variables["WITH_MFX"] = False tc.variables["WITH_NGRAPH"] = False - tc.variables["WITH_OPENCL"] = False + tc.variables["WITH_OPENCL"] = self.options.get_safe("with_opencl", False) tc.variables["WITH_OPENCLAMDBLAS"] = False tc.variables["WITH_OPENCLAMDFFT"] = False tc.variables["WITH_OPENCL_SVM"] = False tc.variables["WITH_OPENGL"] = False - tc.variables["WITH_OPENMP"] = False + tc.variables["WITH_TBB"] = self.options.parallel == "tbb" + tc.variables["WITH_OPENMP"] = self.options.parallel == "openmp" tc.variables["WITH_OPENNI"] = False tc.variables["WITH_OPENNI2"] = False tc.variables["WITH_OPENVX"] = False tc.variables["WITH_PLAIDML"] = False tc.variables["WITH_PVAPI"] = False - tc.variables["WITH_QT"] = False + tc.variables["WITH_QT"] = self.options.get_safe("with_qt", False) tc.variables["WITH_QUIRC"] = False tc.variables["WITH_V4L"] = self.options.get_safe("with_v4l", False) tc.variables["WITH_VA"] = False tc.variables["WITH_VA_INTEL"] = False - tc.variables["WITH_VTK"] = False - tc.variables["WITH_VULKAN"] = False + tc.variables["WITH_VTK"] = self.options.viz + tc.variables["WITH_VULKAN"] = self.options.get_safe("with_vulkan", False) + if self.options.get_safe("with_vulkan"): + tc.variables["VULKAN_INCLUDE_DIRS"] = os.path.join(self.dependencies["vulkan-headers"].package_folder, "include").replace("\\", "/") tc.variables["WITH_XIMEA"] = False tc.variables["WITH_XINE"] = False tc.variables["WITH_LAPACK"] = False tc.variables["WITH_GTK"] = self.options.get_safe("with_gtk", False) tc.variables["WITH_GTK_2_X"] = self._is_gtk_version2 - tc.variables["WITH_WEBP"] = self.options.with_webp - tc.variables["WITH_JPEG"] = bool(self.options.with_jpeg) - tc.variables["WITH_PNG"] = self.options.with_png + tc.variables["WITH_WEBP"] = self.options.get_safe("with_webp", False) + tc.variables["WITH_JPEG"] = bool(self.options.get_safe("with_jpeg", False)) + tc.variables["WITH_PNG"] = self.options.get_safe("with_png", False) if self._has_with_tiff_option: - tc.variables["WITH_TIFF"] = self.options.with_tiff + tc.variables["WITH_TIFF"] = self.options.get_safe("with_tiff", False) if self._has_with_jpeg2000_option: - tc.variables["WITH_JASPER"] = self.options.with_jpeg2000 == "jasper" - tc.variables["WITH_OPENJPEG"] = self.options.with_jpeg2000 == "openjpeg" - tc.variables["WITH_OPENEXR"] = self.options.with_openexr - if self.options.with_openexr: - tc.variables["CMAKE_CXX_STANDARD"] = 11 + tc.variables["WITH_JASPER"] = self.options.get_safe("with_jpeg2000") == "jasper" + tc.variables["WITH_OPENJPEG"] = self.options.get_safe("with_jpeg2000") == "openjpeg" + tc.variables["WITH_OPENEXR"] = self.options.get_safe("with_openexr", False) + tc.variables["WITH_GDAL"] = self.options.get_safe("with_gdal", False) + tc.variables["WITH_GDCM"] = self.options.get_safe("with_gdcm", False) tc.variables["WITH_EIGEN"] = self.options.with_eigen - tc.variables["HAVE_QUIRC"] = self.options.with_quirc # force usage of quirc requirement tc.variables["WITH_DSHOW"] = is_msvc(self) tc.variables["WITH_MSMF"] = self.options.get_safe("with_msmf", False) tc.variables["WITH_MSMF_DXVA"] = self.options.get_safe("with_msmf_dxva", False) @@ -448,31 +1320,43 @@ def generate(self): if self.options.cpu_dispatch or self.options.cpu_dispatch == "": tc.variables["CPU_DISPATCH"] = self.options.cpu_dispatch - if self.options.get_safe("neon") is not None: - tc.variables["ENABLE_NEON"] = self.options.get_safe("neon") + tc.variables["ENABLE_NEON"] = self.options.get_safe("neon", False) + tc.variables["OPENCV_DNN_CUDA"] = self.options.get_safe("dnn_cuda", False) + + # Special world option merging all enabled modules into one big library file + tc.variables["BUILD_opencv_world"] = self.options.world + + # Main modules + tc.variables["BUILD_opencv_core"] = True + for module in OPENCV_MAIN_MODULES_OPTIONS: + tc.variables[f"BUILD_opencv_{module}"] = self.options.get_safe(module, False) tc.variables["WITH_PROTOBUF"] = self.options.dnn if self.options.dnn: tc.variables["PROTOBUF_UPDATE_FILES"] = True - tc.variables["BUILD_opencv_dnn"] = True - tc.variables["OPENCV_DNN_CUDA"] = self.options.get_safe("dnn_cuda", False) - - if self.options.contrib: - tc.variables["OPENCV_EXTRA_MODULES_PATH"] = os.path.join(self._contrib_folder, "modules").replace("\\", "/") - tc.variables["BUILD_opencv_freetype"] = self.options.get_safe("contrib_freetype", False) - tc.variables["BUILD_opencv_sfm"] = self.options.get_safe("contrib_sfm", False) + tc.variables["WITH_ADE"] = self.options.gapi + if self.options.objdetect: + tc.variables["HAVE_QUIRC"] = self.options.with_quirc # force usage of quirc requirement + + # Extra modules + tc.variables["OPENCV_EXTRA_MODULES_PATH"] = os.path.join(self._contrib_folder, "modules").replace("\\", "/") + tc.variables["BUILD_opencv_cudev"] = self.options.with_cuda + for module in OPENCV_EXTRA_MODULES_OPTIONS: + tc.variables[f"BUILD_opencv_{module}"] = self.options.get_safe(module, False) + tc.variables["BUILD_opencv_cnn_3dobj"] = False + if Version(self.version) >= "4.4.0": + tc.variables["BUILD_opencv_julia"] = False + tc.variables["BUILD_opencv_matlab"] = False + if self.options.text: + tc.variables["WITH_TESSERACT"] = self.options.with_tesseract if self.options.get_safe("with_jpeg2000") == "openjpeg": openjpeg_version = Version(self.dependencies["openjpeg"].ref.version) tc.variables["OPENJPEG_MAJOR_VERSION"] = openjpeg_version.major tc.variables["OPENJPEG_MINOR_VERSION"] = openjpeg_version.minor tc.variables["OPENJPEG_BUILD_VERSION"] = openjpeg_version.patch - if self.options.parallel: - tc.variables["WITH_TBB"] = self.options.parallel == "tbb" - tc.variables["WITH_OPENMP"] = self.options.parallel == "openmp" tc.variables["WITH_CUDA"] = self.options.with_cuda - tc.variables["WITH_ADE"] = self.options.with_ade if self.options.with_cuda: # This allows compilation on older GCC/NVCC, otherwise build errors. tc.variables["CUDA_NVCC_FLAGS"] = "--expt-relaxed-constexpr" @@ -511,9 +1395,12 @@ def package(self): os.path.join(self.package_folder, "res", "setup_vars_opencv4.cmd")) # TODO: to remove in conan v2 once cmake_find_package* generators removed + targets_mapping = {self._cmake_target(k): f"opencv::{self._cmake_target(k)}" for k in self._opencv_modules.keys()} + if self.options.world: + targets_mapping.update({"opencv_world": "opencv::opencv_world"}) self._create_cmake_module_alias_targets( os.path.join(self.package_folder, self._module_file_rel_path), - {component["target"]:"opencv::{}".format(component["target"]) for component in self._opencv_components} + targets_mapping, ) def _create_cmake_module_alias_targets(self, module_file, targets): @@ -544,245 +1431,104 @@ def _is_gtk_version2(self): else: return Version(gtk_version) < "3.0.0" - @property - def _opencv_components(self): - def imageformats_deps(): - components = [] - if self.options.get_safe("with_jpeg2000"): - components.append("{0}::{0}".format(self.options.with_jpeg2000)) - if self.options.with_png: - components.append("libpng::libpng") - if self.options.with_jpeg == "libjpeg": - components.append("libjpeg::libjpeg") - elif self.options.with_jpeg == "libjpeg-turbo": - components.append("libjpeg-turbo::jpeg") - elif self.options.with_jpeg == "mozjpeg": - components.append("mozjpeg::libjpeg") - if self.options.get_safe("with_tiff"): - components.append("libtiff::libtiff") - if self.options.with_openexr: - components.append("openexr::openexr") - if self.options.with_webp: - components.append("libwebp::libwebp") - return components - - def eigen(): - return ["eigen::eigen"] if self.options.with_eigen else [] - - def parallel(): - return ["onetbb::onetbb"] if self.options.parallel == "tbb" else [] - - def quirc(): - return ["quirc::quirc"] if self.options.with_quirc else [] - - def gtk(): - return ["gtk::gtk"] if self.options.get_safe("with_gtk") else [] - - def protobuf(): - return ["protobuf::protobuf"] if self.options.dnn else [] - - def freetype(): - return ["freetype::freetype"] if self.options.get_safe("contrib_freetype") else [] - - def xfeatures2d(): - return ["opencv_xfeatures2d"] if self.options.contrib else [] - - def ffmpeg(): - if self.options.get_safe("with_ffmpeg"): - return [ - "ffmpeg::avcodec", - "ffmpeg::avfilter", - "ffmpeg::avformat", - "ffmpeg::avutil", - "ffmpeg::swresample", - "ffmpeg::swscale" ] - else: - return [ ] - - def ipp(): - if self.options.with_ipp: - if self.options.with_ipp == "intel-ipp": - return ["intel-ipp::intel-ipp"] - elif self.options.with_ipp == "opencv-icv" and not self.options.shared: - return ["ippiw"] - else: - return [] - else: - return [] - - opencv_components = [ - {"target": "opencv_core", "lib": "core", "requires": ["zlib::zlib"] + parallel() + eigen() + ipp()}, - {"target": "opencv_flann", "lib": "flann", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_imgproc", "lib": "imgproc", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_ml", "lib": "ml", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_photo", "lib": "photo", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_features2d", "lib": "features2d", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_imgcodecs", "lib": "imgcodecs", "requires": ["opencv_core", "opencv_imgproc", "zlib::zlib"] + eigen() + imageformats_deps() + ipp()}, - {"target": "opencv_videoio", "lib": "videoio", "requires": ( - ["opencv_core", "opencv_imgproc", "opencv_imgcodecs"] - + eigen() + ffmpeg() + ipp())}, - {"target": "opencv_calib3d", "lib": "calib3d", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d"]+ eigen() + ipp()}, - {"target": "opencv_highgui", "lib": "highgui", "requires": ["opencv_core", "opencv_imgproc", "opencv_imgcodecs", "opencv_videoio"] + freetype() + eigen() + gtk() + ipp()}, - {"target": "opencv_stitching", "lib": "stitching", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + xfeatures2d() + eigen() + ipp()}, - {"target": "opencv_video", "lib": "video", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + eigen() + ipp()}, - ] - if self.options.with_ipp == "opencv-icv" and not self.options.shared: - opencv_components.extend([ - {"target": "ippiw", "lib": "ippiw", "requires": []} - ]) - - if self.options.dnn: - opencv_components.extend([ - {"target": "opencv_dnn", "lib": "dnn", "requires": ["opencv_core", "opencv_imgproc"] + protobuf() + ipp()}, - {"target": "opencv_objdetect", "lib": "objdetect", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + eigen() + quirc() + ipp()}, - - ]) - if self.options.contrib: - opencv_components.extend([ - {"target": "opencv_phase_unwrapping", "lib": "phase_unwrapping", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_plot", "lib": "plot", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_quality", "lib": "quality", "requires": ["opencv_core", "opencv_imgproc", "opencv_ml"] + eigen() + ipp()}, - {"target": "opencv_reg", "lib": "reg", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_surface_matching", "lib": "surface_matching", "requires": ["opencv_core", "opencv_flann"] + eigen() + ipp()}, - {"target": "opencv_xphoto", "lib": "xphoto", "requires": ["opencv_core", "opencv_imgproc", "opencv_photo"] + eigen() + ipp()}, - {"target": "opencv_fuzzy", "lib": "fuzzy", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_hfs", "lib": "hfs", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_img_hash", "lib": "img_hash", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_line_descriptor", "lib": "line_descriptor", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d"] + eigen() + ipp()}, - {"target": "opencv_saliency", "lib": "saliency", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d"] + eigen() + ipp()}, - {"target": "opencv_datasets", "lib": "datasets", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_ml", "opencv_imgcodecs"] + eigen() + ipp()}, - {"target": "opencv_rgbd", "lib": "rgbd", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + eigen() + ipp()}, - {"target": "opencv_shape", "lib": "shape", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + eigen() + ipp()}, - {"target": "opencv_structured_light", "lib": "structured_light", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_phase_unwrapping", "opencv_features2d", "opencv_calib3d"] + eigen() + ipp()}, - {"target": "opencv_videostab", "lib": "videostab", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_photo", "opencv_features2d", "opencv_imgcodecs", "opencv_videoio", "opencv_calib3d", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_xfeatures2d", "lib": "xfeatures2d", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_ml", "opencv_features2d", "opencv_calib3d", "opencv_shape", ] + eigen() + ipp()}, - {"target": "opencv_ximgproc", "lib": "ximgproc", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_aruco", "lib": "aruco", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d"] + eigen() + ipp()}, - {"target": "opencv_bgsegm", "lib": "bgsegm", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_bioinspired", "lib": "bioinspired", "requires": ["opencv_core", "opencv_imgproc", "opencv_imgcodecs", "opencv_videoio", "opencv_highgui"] + eigen() + ipp()}, - {"target": "opencv_ccalib", "lib": "ccalib", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_videoio", "opencv_calib3d", "opencv_highgui"] + eigen() + ipp()}, - {"target": "opencv_optflow", "lib": "optflow", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_video", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_video", "opencv_ximgproc"] + eigen() + ipp()}, - {"target": "opencv_superres", "lib": "superres", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_videoio", "opencv_calib3d", "opencv_video", "opencv_ximgproc", "opencv_optflow"] + eigen() + ipp()}, - {"target": "opencv_tracking", "lib": "tracking", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_ml", "opencv_plot", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_datasets", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_stereo", "lib": "stereo", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_ml", "opencv_plot", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_datasets", "opencv_video", "opencv_tracking"] + eigen() + ipp()}, - ]) - if self.options.dnn: - opencv_components.extend([ - {"target": "opencv_xobjdetect", "lib": "xobjdetect", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_objdetect"] + eigen() + ipp()}, - {"target": "opencv_dpm", "lib": "dpm", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_imgcodecs", "opencv_videoio", "opencv_calib3d", "opencv_highgui", "opencv_objdetect"] + eigen() + ipp()}, - {"target": "opencv_face", "lib": "face", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_photo", "opencv_features2d", "opencv_calib3d", "opencv_objdetect"] + eigen() + ipp()} - ]) - if self.version >= "4.3.0": - opencv_components.extend([ - {"target": "opencv_intensity_transform", "lib": "intensity_transform", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_alphamat", "lib": "alphamat", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_rapid", "lib": "rapid", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_features2d", "opencv_calib3d"] + eigen() + ipp()}, - ]) - - if self.options.get_safe("contrib_freetype"): - opencv_components.extend([ - {"target": "opencv_freetype", "lib": "freetype", "requires": ["opencv_core", "opencv_imgproc", "freetype::freetype", "harfbuzz::harfbuzz"] + eigen() + ipp()}, - ]) - - if self.options.get_safe("contrib_sfm"): - opencv_components.extend([ - {"target": "opencv_sfm", "lib": "sfm", "requires": ["opencv_core", "opencv_flann", "opencv_imgproc", "opencv_ml", "opencv_features2d", "opencv_imgcodecs", "opencv_calib3d", "opencv_shape", "opencv_xfeatures2d", "correspondence", "multiview", "numeric", "glog::glog", "gflags::gflags"] + eigen() + ipp()}, - {"target": "numeric", "lib": "numeric", "requires": eigen() + ipp()}, - {"target": "correspondence", "lib": "correspondence", "requires": ["multiview", "glog::glog"] + eigen() + ipp()}, - {"target": "multiview", "lib": "multiview", "requires": ["numeric", "gflags::gflags"] + eigen() + ipp()}, - ]) - - - if self.options.with_cuda: - opencv_components.extend([ - {"target": "opencv_cudaarithm", "lib": "cudaarithm", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_cudabgsegm", "lib": "cudabgsegm", "requires": ["opencv_core", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_cudacodec", "lib": "cudacodec", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_cudafeatures2d", "lib": "cudafeatures2d", "requires": ["opencv_core", "opencv_cudafilters"] + eigen() + ipp()}, - {"target": "opencv_cudafilters", "lib": "cudafilters", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_cudaimgproc", "lib": "cudaimgproc", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_cudalegacy", "lib": "cudalegacy", "requires": ["opencv_core", "opencv_video"] + eigen() + ipp()}, - {"target": "opencv_cudaobjdetect", "lib": "cudaobjdetect", "requires": ["opencv_core", "opencv_objdetect"] + eigen() + ipp()}, - {"target": "opencv_cudaoptflow", "lib": "cudaoptflow", "requires": ["opencv_core"] + eigen() + ipp()}, - {"target": "opencv_cudastereo", "lib": "cudastereo", "requires": ["opencv_core", "opencv_calib3d"] + eigen() + ipp()}, - {"target": "opencv_cudawarping", "lib": "cudawarping", "requires": ["opencv_core", "opencv_imgproc"] + eigen() + ipp()}, - {"target": "opencv_cudev", "lib": "cudev", "requires": [] + eigen() + ipp()}, - ]) - - if self.options.with_ade: - opencv_components.extend([ - {"target": "opencv_gapi", "lib": "gapi", "requires": ["opencv_imgproc", "opencv_calib3d", "opencv_video", "ade::ade"]}, - ]) - - return opencv_components + @staticmethod + def _cmake_target(module): + if module in ("ippiw", "correspondence", "multiview", "numeric"): + return module + return f"opencv_{module}" def package_info(self): version = self.version.split(".") version = "".join(version) if self.settings.os == "Windows" else "" debug = "d" if self.settings.build_type == "Debug" and self.settings.os == "Windows" else "" - def get_lib_name(module): + def get_libs(module): if module == "ippiw": - return f"{module}{debug}" + return [ + f"{module}{debug}", + "ippicvmt" if self.settings.os == "Windows" else "ippicv", + ] elif module in ("correspondence", "multiview", "numeric"): - return module + return [module] else: - return f"opencv_{module}{version}{debug}" - - def add_components(components): - for component in components: - conan_component = component["target"] - cmake_target = component["target"] - cmake_component = component["lib"] - lib_name = get_lib_name(component["lib"]) - requires = component["requires"] - # TODO: we should also define COMPONENTS names of each target for find_package() but not possible yet in CMakeDeps - # see https://github.com/conan-io/conan/issues/10258 + libs = [f"opencv_{module}{version}{debug}"] + if module in ["core", "world"] and not self.options.shared: + lib_exclude_filter = "(opencv_|ippi|correspondence|multiview|numeric).*" + libs += list(filter(lambda x: not re.match(lib_exclude_filter, x), collect_libs(self))) + return libs + + def add_components(modules): + if self.options.world: + self.cpp_info.components["opencv_world"].set_property("cmake_target_name", "opencv_world") + self.cpp_info.components["opencv_world"].libs = get_libs("world") + self.cpp_info.components["opencv_world"].resdirs = ["res"] + if self.settings.os != "Windows": + self.cpp_info.components["opencv_world"].includedirs.append(os.path.join("include", "opencv4")) + world_requires = set() + world_requires_exclude = set() + world_system_libs = set() + world_frameworks = set() + + for module, values in modules.items(): + if not values.get("is_built"): + continue + cmake_target = self._cmake_target(module) + conan_component = cmake_target + # TODO: we should also define COMPONENTS names of each target for find_package() but + # not possible yet in CMakeDeps. See https://github.com/conan-io/conan/issues/10258 self.cpp_info.components[conan_component].set_property("cmake_target_name", cmake_target) - self.cpp_info.components[conan_component].libs = [lib_name] - if lib_name.startswith("ippiw"): - self.cpp_info.components[conan_component].libs.append("ippicvmt" if self.settings.os == "Windows" else "ippicv") + self.cpp_info.components[conan_component].resdirs = ["res"] if self.settings.os != "Windows": self.cpp_info.components[conan_component].includedirs.append(os.path.join("include", "opencv4")) - self.cpp_info.components[conan_component].requires = requires - if self.settings.os == "Linux": - self.cpp_info.components[conan_component].system_libs = ["dl", "m", "pthread", "rt"] - - if self.settings.os == "Android": - self.cpp_info.components[conan_component].system_libs.append("log") - if int(str(self.settings.os.api_level)) > 20: - self.cpp_info.components[conan_component].system_libs.append("mediandk") - if conan_component == "opencv_core" and not self.options.shared: - lib_exclude_filter = "(opencv_|ippi|correspondence|multiview|numeric).*" - libs = list(filter(lambda x: not re.match(lib_exclude_filter, x), collect_libs(self))) - self.cpp_info.components[conan_component].libs += libs + module_requires = values.get("requires", []) + module_system_libs = [] + for _condition, _system_libs in values.get("system_libs", []): + if _condition: + module_system_libs.extend(_system_libs) + module_frameworks = [] + for _condition, _frameworks in values.get("frameworks", []): + if _condition: + module_frameworks.extend(_frameworks) + + if self.options.world and values.get("is_part_of_world", True): + self.cpp_info.components[conan_component].requires = ["opencv_world"] + world_requires.update(module_requires) + world_requires_exclude.add(conan_component) + world_system_libs.update(module_system_libs) + world_frameworks.update(module_frameworks) + else: + self.cpp_info.components[conan_component].libs = get_libs(module) + self.cpp_info.components[conan_component].requires = module_requires + self.cpp_info.components[conan_component].system_libs = module_system_libs + self.cpp_info.components[conan_component].frameworks = module_frameworks # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.components[conan_component].names["cmake_find_package"] = cmake_target self.cpp_info.components[conan_component].names["cmake_find_package_multi"] = cmake_target self.cpp_info.components[conan_component].build_modules["cmake_find_package"] = [self._module_file_rel_path] self.cpp_info.components[conan_component].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - if cmake_component != cmake_target: + if module != cmake_target: conan_component_alias = conan_component + "_alias" - self.cpp_info.components[conan_component_alias].names["cmake_find_package"] = cmake_component - self.cpp_info.components[conan_component_alias].names["cmake_find_package_multi"] = cmake_component + self.cpp_info.components[conan_component_alias].names["cmake_find_package"] = module + self.cpp_info.components[conan_component_alias].names["cmake_find_package_multi"] = module self.cpp_info.components[conan_component_alias].requires = [conan_component] self.cpp_info.components[conan_component_alias].bindirs = [] self.cpp_info.components[conan_component_alias].includedirs = [] self.cpp_info.components[conan_component_alias].libdirs = [] - self.cpp_info.set_property("cmake_file_name", "OpenCV") + if self.options.world: + self.cpp_info.components["opencv_world"].requires = list(world_requires - world_requires_exclude) + self.cpp_info.components["opencv_world"].system_libs = list(world_system_libs) + self.cpp_info.components["opencv_world"].frameworks = list(world_frameworks) + + # TODO: to remove in conan v2 once cmake_find_package* generators removed + self.cpp_info.components["opencv_world"].build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.components["opencv_world"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - add_components(self._opencv_components) + self.cpp_info.set_property("cmake_file_name", "OpenCV") - if self.settings.os == "Windows": - self.cpp_info.components["opencv_highgui"].system_libs = ["comctl32", "gdi32", "ole32", "setupapi", "ws2_32", "vfw32"] - elif self.settings.os == "Macos": - self.cpp_info.components["opencv_highgui"].frameworks = ["Cocoa"] - self.cpp_info.components["opencv_videoio"].frameworks = ["Cocoa", "Accelerate", "AVFoundation", "CoreGraphics", "CoreMedia", "CoreVideo", "QuartzCore"] - elif self.settings.os == "iOS": - self.cpp_info.components["opencv_videoio"].frameworks = ["AVFoundation", "QuartzCore"] + add_components(self._opencv_modules) # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "OpenCV" diff --git a/recipes/opencv/4.x/patches/4.1.2-0005-tracking-no-plot-deps.patch b/recipes/opencv/4.x/patches/4.1.2-0005-tracking-no-plot-deps.patch new file mode 100644 index 00000000000000..91130587911100 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0005-tracking-no-plot-deps.patch @@ -0,0 +1,7 @@ +--- a/contrib/modules/tracking/CMakeLists.txt ++++ b/contrib/modules/tracking/CMakeLists.txt +@@ -1,3 +1,3 @@ + set(the_description "Tracking API") +-ocv_define_module(tracking opencv_imgproc opencv_core opencv_video opencv_plot OPTIONAL opencv_dnn opencv_datasets WRAP java python) ++ocv_define_module(tracking opencv_imgproc opencv_core opencv_video OPTIONAL opencv_plot opencv_dnn opencv_datasets WRAP java python) + ocv_warnings_disable(CMAKE_CXX_FLAGS -Wno-shadow /wd4458) diff --git a/recipes/opencv/4.x/patches/4.1.2-0006-hdf.patch b/recipes/opencv/4.x/patches/4.1.2-0006-hdf.patch new file mode 100644 index 00000000000000..29f4b36e65dc27 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0006-hdf.patch @@ -0,0 +1,21 @@ +--- a/contrib/modules/hdf/CMakeLists.txt ++++ b/contrib/modules/hdf/CMakeLists.txt +@@ -1,6 +1,4 @@ +-set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${CMAKE_CURRENT_SOURCE_DIR}) +- +-if(WIN32) ++if(0) + # windows cmake internal lookups are broken for now + # will lookup for headers and shared libs given HDF_DIR env + find_path(HDF5_INCLUDE_DIRS hdf5.h HINTS "$ENV{HDF5_DIR}\\..\\include") +@@ -16,8 +14,8 @@ if(WIN32) + set(HDF5_FOUND "NO") + endif() + else() +- if(NOT CMAKE_CROSSCOMPILING) # iOS build should not reuse OSX package +- find_package(HDF5) ++ if(1) ++ find_package(HDF5 CONFIG) + endif() + endif() + diff --git a/recipes/opencv/4.x/patches/4.1.2-0008-link-qt-targets.patch b/recipes/opencv/4.x/patches/4.1.2-0008-link-qt-targets.patch new file mode 100644 index 00000000000000..b32a2916816cb7 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0008-link-qt-targets.patch @@ -0,0 +1,29 @@ +--- a/contrib/modules/cvv/CMakeLists.txt ++++ b/contrib/modules/cvv/CMakeLists.txt +@@ -14,7 +14,7 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON) + foreach(dt5_dep Core Gui Widgets) + add_definitions(${Qt5${dt5_dep}_DEFINITIONS}) + include_directories(${Qt5${dt5_dep}_INCLUDE_DIRS}) +- list(APPEND CVV_LIBRARIES ${Qt5${dt5_dep}_LIBRARIES}) ++ list(APPEND CVV_LIBRARIES Qt5::${dt5_dep}) + endforeach() + + ocv_glob_module_sources() +--- a/modules/highgui/CMakeLists.txt ++++ b/modules/highgui/CMakeLists.txt +@@ -58,13 +58,13 @@ if(HAVE_QT5) + foreach(dt5_dep Core Gui Widgets Test Concurrent) + add_definitions(${Qt5${dt5_dep}_DEFINITIONS}) + include_directories(${Qt5${dt5_dep}_INCLUDE_DIRS}) +- list(APPEND HIGHGUI_LIBRARIES ${Qt5${dt5_dep}_LIBRARIES}) ++ list(APPEND HIGHGUI_LIBRARIES Qt5::${dt5_dep}) + endforeach() + + if(HAVE_QT_OPENGL) + add_definitions(${Qt5OpenGL_DEFINITIONS}) + include_directories(${Qt5OpenGL_INCLUDE_DIRS}) +- list(APPEND HIGHGUI_LIBRARIES ${Qt5OpenGL_LIBRARIES}) ++ list(APPEND HIGHGUI_LIBRARIES Qt5::OpenGL) + endif() + + elseif(HAVE_QT) diff --git a/recipes/opencv/4.x/patches/4.1.2-0009-sfm-deps.patch b/recipes/opencv/4.x/patches/4.1.2-0009-sfm-deps.patch new file mode 100644 index 00000000000000..c4ff008107555d --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0009-sfm-deps.patch @@ -0,0 +1,49 @@ +--- a/contrib/modules/sfm/CMakeLists.txt ++++ b/contrib/modules/sfm/CMakeLists.txt +@@ -9,8 +9,14 @@ find_package(Ceres QUIET) + if(NOT Ceres_FOUND) # Looks like Ceres find glog on the own, so separate search isn't necessary + find_package(Glog QUIET) + endif() ++if(NOT GFLAGS_LIBRARIES AND TARGET gflags::gflags) ++ set(GFLAGS_LIBRARIES gflags::gflags) ++endif() ++if(NOT GLOG_LIBRARIES AND TARGET glog::glog) ++ set(GLOG_LIBRARIES glog::glog) ++endif() + +-if((gflags_FOUND OR GFLAGS_FOUND OR GFLAGS_INCLUDE_DIRS) AND (glog_FOUND OR GLOG_FOUND OR GLOG_INCLUDE_DIRS)) ++if(0) + set(_fname "${CMAKE_CURRENT_BINARY_DIR}/test_sfm_deps.cpp") + file(WRITE "${_fname}" "#include \n#include \nint main() { (void)(0); return 0; }\n") + try_compile(SFM_DEPS_OK "${CMAKE_BINARY_DIR}" "${_fname}" +@@ -21,7 +27,7 @@ if((gflags_FOUND OR GFLAGS_FOUND OR GFLAGS_INCLUDE_DIRS) AND (glog_FOUND OR GLOG + file(REMOVE "${_fname}") + message(STATUS "Checking SFM deps... ${SFM_DEPS_OK}") + else() +- set(SFM_DEPS_OK FALSE) ++ set(SFM_DEPS_OK TRUE) + endif() + + if(NOT HAVE_EIGEN OR NOT SFM_DEPS_OK) +--- a/contrib/modules/sfm/src/libmv_light/libmv/correspondence/CMakeLists.txt ++++ b/contrib/modules/sfm/src/libmv_light/libmv/correspondence/CMakeLists.txt +@@ -8,7 +8,7 @@ FILE(GLOB CORRESPONDENCE_HDRS *.h) + + ADD_LIBRARY(correspondence STATIC ${CORRESPONDENCE_SRC} ${CORRESPONDENCE_HDRS}) + +-TARGET_LINK_LIBRARIES(correspondence LINK_PRIVATE ${GLOG_LIBRARY} multiview) ++TARGET_LINK_LIBRARIES(correspondence LINK_PRIVATE ${GLOG_LIBRARIES} multiview) + IF(TARGET Eigen3::Eigen) + TARGET_LINK_LIBRARIES(correspondence LINK_PUBLIC Eigen3::Eigen) + ENDIF() +--- a/contrib/modules/sfm/src/libmv_light/libmv/multiview/CMakeLists.txt ++++ b/contrib/modules/sfm/src/libmv_light/libmv/multiview/CMakeLists.txt +@@ -17,7 +17,7 @@ SET(MULTIVIEW_SRC conditioning.cc + FILE(GLOB MULTIVIEW_HDRS *.h) + + ADD_LIBRARY(multiview STATIC ${MULTIVIEW_SRC} ${MULTIVIEW_HDRS}) +-TARGET_LINK_LIBRARIES(multiview LINK_PRIVATE ${GLOG_LIBRARY} numeric) ++TARGET_LINK_LIBRARIES(multiview LINK_PRIVATE ${GLOG_LIBRARIES} numeric) + IF(TARGET Eigen3::Eigen) + TARGET_LINK_LIBRARIES(multiview LINK_PUBLIC Eigen3::Eigen) + ENDIF() diff --git a/recipes/opencv/4.x/patches/4.1.2-0010-compat-protobuf-ge-3.18.patch b/recipes/opencv/4.x/patches/4.1.2-0010-compat-protobuf-ge-3.18.patch new file mode 100644 index 00000000000000..5bd6bfd1b3816e --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0010-compat-protobuf-ge-3.18.patch @@ -0,0 +1,22 @@ +--- a/modules/dnn/src/caffe/caffe_io.cpp ++++ b/modules/dnn/src/caffe/caffe_io.cpp +@@ -92,6 +92,7 @@ + #ifdef HAVE_PROTOBUF + #include + #include ++#include + #include + + #include +@@ -1111,7 +1112,11 @@ static const int kProtoReadBytesLimit = INT_MAX; // Max size of 2 GB minus 1 by + + bool ReadProtoFromBinary(ZeroCopyInputStream* input, Message *proto) { + CodedInputStream coded_input(input); ++#if GOOGLE_PROTOBUF_VERSION >= 3006000 ++ coded_input.SetTotalBytesLimit(kProtoReadBytesLimit); ++#else + coded_input.SetTotalBytesLimit(kProtoReadBytesLimit, 536870912); ++#endif + + return proto->ParseFromCodedStream(&coded_input); + } diff --git a/recipes/opencv/4.x/patches/4.1.2-0011-compat-openexr3.patch b/recipes/opencv/4.x/patches/4.1.2-0011-compat-openexr3.patch new file mode 100644 index 00000000000000..3854d36a913a06 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.1.2-0011-compat-openexr3.patch @@ -0,0 +1,10 @@ +--- a/modules/imgcodecs/src/grfmt_exr.cpp ++++ b/modules/imgcodecs/src/grfmt_exr.cpp +@@ -56,6 +56,7 @@ + #include + #include + ++#include + #include + #include + #include diff --git a/recipes/opencv/4.x/patches/4.5.1-0001-tracking-no-plot-deps.patch b/recipes/opencv/4.x/patches/4.5.1-0001-tracking-no-plot-deps.patch new file mode 100644 index 00000000000000..6e57a96b98355c --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.1-0001-tracking-no-plot-deps.patch @@ -0,0 +1,13 @@ +--- a/contrib/modules/tracking/CMakeLists.txt ++++ b/contrib/modules/tracking/CMakeLists.txt +@@ -9,9 +9,9 @@ ocv_define_module(tracking + opencv_imgproc + opencv_core + opencv_video +- opencv_plot # samples only + ${debug_modules} + OPTIONAL ++ opencv_plot + opencv_dnn + opencv_datasets + opencv_highgui diff --git a/recipes/opencv/4.x/patches/4.5.1-0002-alphamat-header.patch b/recipes/opencv/4.x/patches/4.5.1-0002-alphamat-header.patch new file mode 100644 index 00000000000000..847eeaa9e98695 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.1-0002-alphamat-header.patch @@ -0,0 +1,11 @@ +--- a/contrib/modules/alphamat/include/opencv2/alphamat.hpp ++++ b/contrib/modules/alphamat/include/opencv2/alphamat.hpp +@@ -7,6 +7,8 @@ + #ifndef _OPENCV_ALPHAMAT_HPP_ + #define _OPENCV_ALPHAMAT_HPP_ + ++#include ++ + /** + * @defgroup alphamat Alpha Matting + * Alpha matting is used to extract a foreground object with soft boundaries from a background image. diff --git a/recipes/opencv/4.x/patches/4.5.3-0002-link-qt-targets.patch b/recipes/opencv/4.x/patches/4.5.3-0002-link-qt-targets.patch new file mode 100644 index 00000000000000..b9b34a95156fe0 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.3-0002-link-qt-targets.patch @@ -0,0 +1,30 @@ +--- a/contrib/modules/cvv/CMakeLists.txt ++++ b/contrib/modules/cvv/CMakeLists.txt +@@ -14,7 +14,7 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON) + foreach(dt5_dep Core Gui Widgets) + add_definitions(${Qt5${dt5_dep}_DEFINITIONS}) + include_directories(${Qt5${dt5_dep}_INCLUDE_DIRS}) +- list(APPEND CVV_LIBRARIES ${Qt5${dt5_dep}_LIBRARIES}) ++ list(APPEND CVV_LIBRARIES Qt5::${dt5_dep}) + endforeach() + + ocv_glob_module_sources() +--- a/modules/highgui/CMakeLists.txt ++++ b/modules/highgui/CMakeLists.txt +@@ -69,14 +69,14 @@ if(HAVE_QT5) + foreach(dt5_dep Core Gui Widgets Test Concurrent) + add_definitions(${Qt5${dt5_dep}_DEFINITIONS}) + include_directories(${Qt5${dt5_dep}_INCLUDE_DIRS}) +- list(APPEND HIGHGUI_LIBRARIES ${Qt5${dt5_dep}_LIBRARIES}) ++ list(APPEND HIGHGUI_LIBRARIES Qt5::${dt5_dep}) + endforeach() + + if(HAVE_QT_OPENGL) + add_definitions(-DHAVE_QT_OPENGL) + add_definitions(${Qt5OpenGL_DEFINITIONS}) + include_directories(${Qt5OpenGL_INCLUDE_DIRS}) +- list(APPEND HIGHGUI_LIBRARIES ${Qt5OpenGL_LIBRARIES}) ++ list(APPEND HIGHGUI_LIBRARIES Qt5::OpenGL) + endif() + elseif(HAVE_QT) + set(OPENCV_HIGHGUI_BUILTIN_BACKEND "QT4") diff --git a/recipes/opencv/4.x/patches/4.5.5-0002-objdetect-without-dnn.patch b/recipes/opencv/4.x/patches/4.5.5-0002-objdetect-without-dnn.patch new file mode 100644 index 00000000000000..5313e7b762001f --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.5-0002-objdetect-without-dnn.patch @@ -0,0 +1,97 @@ +--- a/modules/objdetect/CMakeLists.txt ++++ b/modules/objdetect/CMakeLists.txt +@@ -1,5 +1,16 @@ + set(the_description "Object Detection") +-ocv_define_module(objdetect opencv_core opencv_imgproc opencv_calib3d opencv_dnn WRAP java objc python js) ++ocv_define_module(objdetect ++ opencv_core ++ opencv_imgproc ++ opencv_calib3d ++ OPTIONAL ++ opencv_dnn ++ WRAP ++ python ++ java ++ objc ++ js ++) + + if(HAVE_QUIRC) + get_property(QUIRC_INCLUDE GLOBAL PROPERTY QUIRC_INCLUDE_DIR) +--- a/modules/objdetect/src/face_detect.cpp ++++ b/modules/objdetect/src/face_detect.cpp +@@ -6,13 +6,16 @@ + + #include "opencv2/imgproc.hpp" + #include "opencv2/core.hpp" ++#ifdef HAVE_OPENCV_DNN + #include "opencv2/dnn.hpp" ++#endif + + #include + + namespace cv + { + ++#ifdef HAVE_OPENCV_DNN + class FaceDetectorYNImpl : public FaceDetectorYN + { + public: +@@ -273,6 +276,7 @@ class FaceDetectorYNImpl : public FaceDetectorYN + + std::vector priors; + }; ++#endif + + Ptr FaceDetectorYN::create(const String& model, + const String& config, +@@ -283,7 +287,12 @@ Ptr FaceDetectorYN::create(const String& model, + const int backend_id, + const int target_id) + { ++#ifdef HAVE_OPENCV_DNN + return makePtr(model, config, input_size, score_threshold, nms_threshold, top_k, backend_id, target_id); ++#else ++ CV_UNUSED(model); CV_UNUSED(config); CV_UNUSED(input_size); CV_UNUSED(score_threshold); CV_UNUSED(nms_threshold); CV_UNUSED(top_k); CV_UNUSED(backend_id); CV_UNUSED(target_id); ++ CV_Error(cv::Error::StsNotImplemented, "cv::FaceDetectorYN requires enabled 'dnn' module."); ++#endif + } + + } // namespace cv +--- a/modules/objdetect/src/face_recognize.cpp ++++ b/modules/objdetect/src/face_recognize.cpp +@@ -4,13 +4,17 @@ + + #include "precomp.hpp" + ++#include "opencv2/core.hpp" ++#ifdef HAVE_OPENCV_DNN + #include "opencv2/dnn.hpp" ++#endif + + #include + + namespace cv + { + ++#ifdef HAVE_OPENCV_DNN + class FaceRecognizerSFImpl : public FaceRecognizerSF + { + public: +@@ -173,10 +177,16 @@ class FaceRecognizerSFImpl : public FaceRecognizerSF + private: + dnn::Net net; + }; ++#endif + + Ptr FaceRecognizerSF::create(const String& model, const String& config, int backend_id, int target_id) + { ++#ifdef HAVE_OPENCV_DNN + return makePtr(model, config, backend_id, target_id); ++#else ++ CV_UNUSED(model); CV_UNUSED(config); CV_UNUSED(backend_id); CV_UNUSED(target_id); ++ CV_Error(cv::Error::StsNotImplemented, "cv::FaceRecognizerSF requires enabled 'dnn' module"); ++#endif + } + + } // namespace cv diff --git a/recipes/opencv/4.x/patches/4.5.5-0003-find-quirc.patch b/recipes/opencv/4.x/patches/4.5.5-0003-find-quirc.patch new file mode 100644 index 00000000000000..e53df28368b3b1 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.5-0003-find-quirc.patch @@ -0,0 +1,12 @@ +--- a/modules/objdetect/CMakeLists.txt ++++ b/modules/objdetect/CMakeLists.txt +@@ -13,7 +13,6 @@ ocv_define_module(objdetect + ) + + if(HAVE_QUIRC) +- get_property(QUIRC_INCLUDE GLOBAL PROPERTY QUIRC_INCLUDE_DIR) +- ocv_include_directories(${QUIRC_INCLUDE}) +- ocv_target_link_libraries(${the_module} quirc) ++ find_package(quirc REQUIRED CONFIG) ++ ocv_target_link_libraries(${the_module} quirc::quirc) + endif() diff --git a/recipes/opencv/4.x/patches/4.5.5-0004-link-qt-targets.patch b/recipes/opencv/4.x/patches/4.5.5-0004-link-qt-targets.patch new file mode 100644 index 00000000000000..4c497271a4d6a6 --- /dev/null +++ b/recipes/opencv/4.x/patches/4.5.5-0004-link-qt-targets.patch @@ -0,0 +1,22 @@ +--- a/contrib/modules/cvv/CMakeLists.txt ++++ b/contrib/modules/cvv/CMakeLists.txt +@@ -14,7 +14,7 @@ set(CMAKE_INCLUDE_CURRENT_DIR ON) + foreach(dt5_dep Core Gui Widgets) + add_definitions(${Qt5${dt5_dep}_DEFINITIONS}) + include_directories(${Qt5${dt5_dep}_INCLUDE_DIRS}) +- list(APPEND CVV_LIBRARIES ${Qt5${dt5_dep}_LIBRARIES}) ++ list(APPEND CVV_LIBRARIES Qt5::${dt5_dep}) + endforeach() + + ocv_glob_module_sources() +--- a/modules/highgui/CMakeLists.txt ++++ b/modules/highgui/CMakeLists.txt +@@ -89,7 +89,7 @@ if(HAVE_QT) + foreach(dt_dep ${qt_deps}) + add_definitions(${Qt${QT_VERSION_MAJOR}${dt_dep}_DEFINITIONS}) + include_directories(${Qt${QT_VERSION_MAJOR}${dt_dep}_INCLUDE_DIRS}) +- list(APPEND HIGHGUI_LIBRARIES ${Qt${QT_VERSION_MAJOR}${dt_dep}_LIBRARIES}) ++ list(APPEND HIGHGUI_LIBRARIES Qt${QT_VERSION_MAJOR}::${dt_dep}) + endforeach() + else() + ocv_assert(QT_VERSION_MAJOR EQUAL 4) diff --git a/recipes/opencv/4.x/test_package/CMakeLists.txt b/recipes/opencv/4.x/test_package/CMakeLists.txt index e49280ad955c0b..5404f6ff239151 100644 --- a/recipes/opencv/4.x/test_package/CMakeLists.txt +++ b/recipes/opencv/4.x/test_package/CMakeLists.txt @@ -1,32 +1,33 @@ cmake_minimum_required(VERSION 3.8) project(test_package LANGUAGES CXX) -option(built_dnn "Enabled if opencv is built dnn" OFF) -option(built_with_ade "Enabled if opencv is built with ade" OFF) -option(built_with_ffmpeg "Enabled if opencv is built with ffmpeg" OFF) -option(built_contrib_sfm "Enabled if opencv is built contrib sfm" OFF) +enable_testing() -find_package(OpenCV REQUIRED imgcodecs highgui objdetect CONFIG) - -add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE - opencv_imgcodecs - opencv_highgui - opencv_objdetect - $ - $ - $ +set(TESTED_MODULES + # Main modules + "calib3d" "core" "dnn" "features2d" "flann" "gapi" "highgui" "imgcodecs" + "imgproc" "ml" "objdetect" "photo" "stitching" "video" "videoio" + # Extra modules + "alphamat" "aruco" "bgsegm" "bioinspired" "ccalib" "datasets" "dnn_superres" + "face" "freetype" "fuzzy" "hdf" "hfs" "img_hash" "intensity_transform" + "line_descriptor" "mcc" "optflow" "phase_unwrapping" "plot" "quality" "reg" + "rgbd" "saliency" "sfm" "shape" "structured_light" "superres" + "surface_matching" "text" "tracking" "wechat_qrcode" "xfeatures2d" + "ximgproc" "xobjdetect" "xphoto" ) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) -if(built_dnn) - target_link_libraries(${PROJECT_NAME} PRIVATE opencv_dnn) -endif() -if(built_with_ade) - target_compile_definitions(${PROJECT_NAME} PRIVATE BUILT_WITH_ADE) -endif() -if(built_with_ffmpeg) - target_compile_definitions(${PROJECT_NAME} PRIVATE BUILT_WITH_FFMPEG) -endif() -if(built_contrib_sfm) - target_compile_definitions(${PROJECT_NAME} PRIVATE BUILT_CONTRIB_SFM) -endif() + +find_package(OpenCV REQUIRED core CONFIG) + +foreach(_module ${TESTED_MODULES}) + string(TOUPPER ${_module} _module_upper) + if(OPENCV_WITH_${_module_upper}) + set(_test_target test_${_module}) + set(_module_target opencv_${_module}) + add_executable(${_test_target} ${_test_target}.cpp) + target_link_libraries(${_test_target} PRIVATE ${_module_target}) + target_compile_features(${_test_target} PRIVATE cxx_std_11) + if(NOT ${_module} STREQUAL "highgui") + add_test(NAME ${_test_target} COMMAND ${_test_target}) + endif() + endif() +endforeach() diff --git a/recipes/opencv/4.x/test_package/conanfile.py b/recipes/opencv/4.x/test_package/conanfile.py index 5d9136c00ec0e7..e5b25fb84dd4bf 100644 --- a/recipes/opencv/4.x/test_package/conanfile.py +++ b/recipes/opencv/4.x/test_package/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile -from conan.tools.build import can_run +from conan.tools.build import build_jobs, can_run from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -import os +from conan.tools.files import chdir class TestPackageConan(ConanFile): @@ -9,6 +9,21 @@ class TestPackageConan(ConanFile): generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" + @property + def _tested_modules(self): + return [ + # Main modules + "calib3d", "core", "dnn", "features2d", "flann", "gapi", "highgui", "imgcodecs", + "imgproc", "ml", "objdetect", "photo", "stitching", "video", "videoio", + # Extra modules + "alphamat", "aruco", "bgsegm", "bioinspired", "ccalib", "datasets", "dnn_superres", + "face", "freetype", "fuzzy", "hdf", "hfs", "img_hash", "intensity_transform", + "line_descriptor", "mcc", "optflow", "phase_unwrapping", "plot", "quality", "reg", + "rgbd", "saliency", "sfm", "shape", "structured_light", "superres", + "surface_matching", "text", "tracking", "wechat_qrcode", "xfeatures2d", + "ximgproc", "xobjdetect", "xphoto", + ] + def layout(self): cmake_layout(self) @@ -17,10 +32,16 @@ def requirements(self): def generate(self): tc = CMakeToolchain(self) - tc.variables["built_dnn"] = self.dependencies["opencv"].options.dnn - tc.variables["built_with_ade"] = self.dependencies["opencv"].options.with_ade - tc.variables["built_with_ffmpeg"] = self.dependencies["opencv"].options.with_ffmpeg - tc.variables["built_contrib_sfm"] = self.dependencies["opencv"].options.contrib and self.dependencies["opencv"].options.contrib_sfm + for module in self._tested_modules: + cmake_option = f"OPENCV_WITH_{module.upper()}" + if module == "core": + tc.variables[cmake_option] = True + elif module == "imgcodecs": + tc.variables[cmake_option] = self.dependencies["opencv"].options.imgcodecs and self.dependencies["opencv"].options.with_png + elif module == "videoio": + tc.variables[cmake_option] = self.dependencies["opencv"].options.videoio and self.dependencies["opencv"].options.with_ffmpeg + else: + tc.variables[cmake_option] = self.dependencies["opencv"].options.get_safe(module, False) tc.generate() def build(self): @@ -30,5 +51,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") - self.run(bin_path, env="conanrun") + with chdir(self, self.build_folder): + self.run(f"ctest --output-on-failure -C {self.settings.build_type} -j {build_jobs(self)}", env="conanrun") diff --git a/recipes/opencv/4.x/test_package/test_alphamat.cpp b/recipes/opencv/4.x/test_package/test_alphamat.cpp new file mode 100644 index 00000000000000..af8ea966d97159 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_alphamat.cpp @@ -0,0 +1,10 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::ones(400, 400, CV_8UC3) * 50; + cv::Mat tmap = cv::Mat::ones(400, 400, CV_8U) * 120; + cv::Mat result; + cv::alphamat::infoFlow(image, tmap, result); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_aruco.cpp b/recipes/opencv/4.x/test_package/test_aruco.cpp new file mode 100644 index 00000000000000..bc510aeaf4b180 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_aruco.cpp @@ -0,0 +1,9 @@ +#include +#include + +int main() { + cv::Mat markerImage; + auto dictionary = cv::aruco::getPredefinedDictionary(cv::aruco::DICT_6X6_250); + cv::aruco::drawMarker(dictionary, 23, 200, markerImage, 1); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_bgsegm.cpp b/recipes/opencv/4.x/test_package/test_bgsegm.cpp new file mode 100644 index 00000000000000..ba01af2fd18619 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_bgsegm.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto bkg_subtractor = cv::bgsegm::createBackgroundSubtractorCNT(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_bioinspired.cpp b/recipes/opencv/4.x/test_package/test_bioinspired.cpp new file mode 100644 index 00000000000000..219fc935596f3e --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_bioinspired.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto retina_tone_mapping = cv::bioinspired::RetinaFastToneMapping::create(cv::Size(10, 10)); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_calib3d.cpp b/recipes/opencv/4.x/test_package/test_calib3d.cpp new file mode 100644 index 00000000000000..ce5c7e8b7c8214 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_calib3d.cpp @@ -0,0 +1,26 @@ +#include +#include + +#include +#include + +int main() { + const int point_count = 100; + std::vector points1; + points1.reserve(point_count); + std::vector points2; + points2.reserve(point_count); + for (int i = 0; i < point_count; ++i) { + points1.emplace_back( + cv::Point2f(static_cast(100 + 30 * std::cos(i * CV_PI * 2 / 5)), + static_cast(100 - 30 * std::sin(i * CV_PI * 2 / 5))) + ); + points2.emplace_back( + cv::Point2f(static_cast(100 + 30 * std::sin(i * CV_PI * 2 / 5)), + static_cast(100 - 30 * std::cos(i * CV_PI * 2 / 5))) + ); + } + auto fundamental_matrix = cv::findFundamentalMat(points1, points2, cv::FM_RANSAC, 3, 0.99); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_ccalib.cpp b/recipes/opencv/4.x/test_package/test_ccalib.cpp new file mode 100644 index 00000000000000..079bcb7ba21ce6 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_ccalib.cpp @@ -0,0 +1,8 @@ +#include + +int main() { + cv::randpattern::RandomPatternGenerator generator(50, 50); + generator.generatePattern(); + auto pattern = generator.getPattern(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_core.cpp b/recipes/opencv/4.x/test_package/test_core.cpp new file mode 100644 index 00000000000000..b9635e35d0fc8a --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_core.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + cv::Mat m = cv::Mat::zeros(400, 400, CV_8UC3); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_datasets.cpp b/recipes/opencv/4.x/test_package/test_datasets.cpp new file mode 100644 index 00000000000000..16c5eca1c92055 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_datasets.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto dataset = cv::datasets::AR_hmdb::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_dnn.cpp b/recipes/opencv/4.x/test_package/test_dnn.cpp new file mode 100644 index 00000000000000..3d8474fcdd230e --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_dnn.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto backends = cv::dnn::getAvailableBackends(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_dnn_superres.cpp b/recipes/opencv/4.x/test_package/test_dnn_superres.cpp new file mode 100644 index 00000000000000..bbe3442b46dc42 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_dnn_superres.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + cv::dnn_superres::DnnSuperResImpl dnn_superres_impl; + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_face.cpp b/recipes/opencv/4.x/test_package/test_face.cpp new file mode 100644 index 00000000000000..9e3953a255cc0f --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_face.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto face_recognizer = cv::face::FisherFaceRecognizer::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_features2d.cpp b/recipes/opencv/4.x/test_package/test_features2d.cpp new file mode 100644 index 00000000000000..2154a2126ebb1d --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_features2d.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto matcher = cv::DescriptorMatcher::create(cv::DescriptorMatcher::BRUTEFORCE); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_flann.cpp b/recipes/opencv/4.x/test_package/test_flann.cpp new file mode 100644 index 00000000000000..0461a2651192b4 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_flann.cpp @@ -0,0 +1,28 @@ +#include +#include + +#include +#include + +int main() { + const int point_count = 100; + std::vector points; + points.reserve(point_count); + for (int i = 0; i < point_count; ++i) { + points.emplace_back( + cv::Point2f(static_cast(100 + 30 * std::cos(i * CV_PI * 2 / 5)), + static_cast(100 - 30 * std::sin(i * CV_PI * 2 / 5))) + ); + } + + cv::flann::KDTreeIndexParams indexParams; + cv::flann::Index kdtree(cv::Mat(points).reshape(1), indexParams); + + std::vector query{110, 98}; + + std::vector indices; + std::vector dists; + kdtree.knnSearch(query, indices, dists, 3); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_freetype.cpp b/recipes/opencv/4.x/test_package/test_freetype.cpp new file mode 100644 index 00000000000000..49ee14c10ed6ab --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_freetype.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto ft2 = cv::freetype::createFreeType2(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_fuzzy.cpp b/recipes/opencv/4.x/test_package/test_fuzzy.cpp new file mode 100644 index 00000000000000..ad4485785acc47 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_fuzzy.cpp @@ -0,0 +1,9 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::zeros(400, 400, CV_8UC3); + cv::Mat output; + cv::ft::FT02D_FL_process(image, 10, output); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_gapi.cpp b/recipes/opencv/4.x/test_package/test_gapi.cpp new file mode 100644 index 00000000000000..1894733df9580a --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_gapi.cpp @@ -0,0 +1,18 @@ +#include +#include +#include + +int main() { + // derived from https://docs.opencv.org/4.5.0/d0/d1e/gapi.html + cv::GMat in; + cv::GMat vga = cv::gapi::resize(in, cv::Size(), 0.5, 0.5); + cv::GMat gray = cv::gapi::BGR2Gray(vga); + cv::GMat blurred = cv::gapi::blur(gray, cv::Size(5,5)); + cv::GMat edges = cv::gapi::Canny(blurred, 32, 128, 3); + cv::GMat b,g,r; + std::tie(b,g,r) = cv::gapi::split3(vga); + cv::GMat out = cv::gapi::merge3(b, g | edges, r); + cv::GComputation ac(in, out); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_hdf.cpp b/recipes/opencv/4.x/test_package/test_hdf.cpp new file mode 100644 index 00000000000000..94d3e97ba46b4b --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_hdf.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto hdf5 = cv::hdf::open("test_package_hdf.h5"); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_hfs.cpp b/recipes/opencv/4.x/test_package/test_hfs.cpp new file mode 100644 index 00000000000000..8d5391b6b1421b --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_hfs.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto hfs_segment = cv::hfs::HfsSegment::create(100, 100); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_highgui.cpp b/recipes/opencv/4.x/test_package/test_highgui.cpp new file mode 100644 index 00000000000000..69025d66e0e23b --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_highgui.cpp @@ -0,0 +1,8 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::zeros(400, 400, CV_8UC3); + cv::imshow("test highgui", image); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_img_hash.cpp b/recipes/opencv/4.x/test_package/test_img_hash.cpp new file mode 100644 index 00000000000000..73ca6849810923 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_img_hash.cpp @@ -0,0 +1,10 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::zeros(400, 400, CV_8UC3); + auto func = cv::img_hash::AverageHash::create(); + cv::Mat hash; + func->compute(image, hash); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_imgcodecs.cpp b/recipes/opencv/4.x/test_package/test_imgcodecs.cpp new file mode 100644 index 00000000000000..909d28ae9465da --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_imgcodecs.cpp @@ -0,0 +1,9 @@ +#include +#include + +int main() { + cv::Mat img = cv::Mat::zeros(400, 400, CV_8UC3); + cv::imwrite("test_imgcodecs.png", img); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_imgproc.cpp b/recipes/opencv/4.x/test_package/test_imgproc.cpp new file mode 100644 index 00000000000000..23784d8f0a1b60 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_imgproc.cpp @@ -0,0 +1,14 @@ +#include +#include + +int main() { + const int width = 400; + cv::Mat image = cv::Mat::zeros(width, width, CV_8UC3); + + cv::ellipse( + image, cv::Point(width / 2, width / 2), cv::Size(width / 4, width / 16), + 90, 0, 360, cv::Scalar(255, 0, 0), 2, 8 + ); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_intensity_transform.cpp b/recipes/opencv/4.x/test_package/test_intensity_transform.cpp new file mode 100644 index 00000000000000..dce55e2e9e3a7a --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_intensity_transform.cpp @@ -0,0 +1,9 @@ +#include +#include + +int main() { + cv::Mat src_image = cv::Mat::zeros(400, 400, CV_8UC3); + cv::Mat dst_image; + cv::intensity_transform::autoscaling(src_image, dst_image); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_line_descriptor.cpp b/recipes/opencv/4.x/test_package/test_line_descriptor.cpp new file mode 100644 index 00000000000000..a9c8f66bb0d01e --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_line_descriptor.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto descriptor = cv::line_descriptor::BinaryDescriptor::createBinaryDescriptor(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_mcc.cpp b/recipes/opencv/4.x/test_package/test_mcc.cpp new file mode 100644 index 00000000000000..7b2647b223c4d0 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_mcc.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto checker_detector = cv::mcc::CCheckerDetector::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_ml.cpp b/recipes/opencv/4.x/test_package/test_ml.cpp new file mode 100644 index 00000000000000..e53dbd4cf97eec --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_ml.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto dtrees = cv::ml::DTrees::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_objdetect.cpp b/recipes/opencv/4.x/test_package/test_objdetect.cpp new file mode 100644 index 00000000000000..2533cbb506d597 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_objdetect.cpp @@ -0,0 +1,17 @@ +#include +#include + +#include + +int main() { + std::vector rectangles; + rectangles.reserve(100); + for (int i = 0; i < 10; ++i) { + for (int j = 0; j < 10; ++j) { + rectangles.emplace_back(cv::Rect(10 * i, 5 * (i + j), 2, 3)); + } + } + cv::groupRectangles(rectangles, 2); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_optflow.cpp b/recipes/opencv/4.x/test_package/test_optflow.cpp new file mode 100644 index 00000000000000..f7ef8c92b736e2 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_optflow.cpp @@ -0,0 +1,7 @@ +#include +#include + +int main() { + auto tree = cv::optflow::GPCTree::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_package.cpp b/recipes/opencv/4.x/test_package/test_package.cpp deleted file mode 100644 index 220a68d7c84b1b..00000000000000 --- a/recipes/opencv/4.x/test_package/test_package.cpp +++ /dev/null @@ -1,235 +0,0 @@ -// Test file borrowed from OpenCV tutorial: https://docs.opencv.org/master/d3/d96/tutorial_basic_geometric_drawing.html - -/** - * @file Drawing_1.cpp - * @brief Simple geometric drawing - * @author OpenCV team - */ -#include -#include -#ifdef BUILT_WITH_ADE -#include -#include -#include -#endif -#ifdef BUILT_WITH_FFMPEG -#include -#include -#endif -#ifdef BUILT_CONTRIB_SFM -#include -#endif - -#define w 400 - -using namespace cv; - -/// Function headers -void MyEllipse( Mat img, double angle ); -void MyFilledCircle( Mat img, Point center ); -void MyPolygon( Mat img ); -void MyLine( Mat img, Point start, Point end ); -// to test `with_ade` option -void TestGAPI(); -void TestVideo(); -void TestSFM(); - -/** - * @function main - * @brief Main function - */ -int main( void ){ - - //![create_images] - /// Windows names - char atom_window[] = "Drawing 1: Atom"; - char rook_window[] = "Drawing 2: Rook"; - - /// Create black empty images - Mat atom_image = Mat::zeros( w, w, CV_8UC3 ); - Mat rook_image = Mat::zeros( w, w, CV_8UC3 ); - //![create_images] - - /// 1. Draw a simple atom: - /// ----------------------- - - //![draw_atom] - /// 1.a. Creating ellipses - MyEllipse( atom_image, 90 ); - MyEllipse( atom_image, 0 ); - MyEllipse( atom_image, 45 ); - MyEllipse( atom_image, -45 ); - - /// 1.b. Creating circles - MyFilledCircle( atom_image, Point( w/2, w/2) ); - //![draw_atom] - - /// 2. Draw a rook - /// ------------------ - - //![draw_rook] - /// 2.a. Create a convex polygon - MyPolygon( rook_image ); - - //![rectangle] - /// 2.b. Creating rectangles - rectangle( rook_image, - Point( 0, 7*w/8 ), - Point( w, w), - Scalar( 0, 255, 255 ), - FILLED, - LINE_8 ); - //![rectangle] - - /// 2.c. Create a few lines - MyLine( rook_image, Point( 0, 15*w/16 ), Point( w, 15*w/16 ) ); - MyLine( rook_image, Point( w/4, 7*w/8 ), Point( w/4, w ) ); - MyLine( rook_image, Point( w/2, 7*w/8 ), Point( w/2, w ) ); - MyLine( rook_image, Point( 3*w/4, 7*w/8 ), Point( 3*w/4, w ) ); - //![draw_rook] - TestGAPI(); - TestVideo(); - TestSFM(); - - return(0); -} - -/// Function Declaration - -/** - * @function MyEllipse - * @brief Draw a fixed-size ellipse with different angles - */ -//![my_ellipse] -void MyEllipse( Mat img, double angle ) -{ - int thickness = 2; - int lineType = 8; - - ellipse( img, - Point( w/2, w/2 ), - Size( w/4, w/16 ), - angle, - 0, - 360, - Scalar( 255, 0, 0 ), - thickness, - lineType ); -} -//![my_ellipse] - -/** - * @function MyFilledCircle - * @brief Draw a fixed-size filled circle - */ -//![my_filled_circle] -void MyFilledCircle( Mat img, Point center ) -{ - circle( img, - center, - w/32, - Scalar( 0, 0, 255 ), - FILLED, - LINE_8 ); -} -//![my_filled_circle] - -/** - * @function MyPolygon - * @brief Draw a simple concave polygon (rook) - */ -//![my_polygon] -void MyPolygon( Mat img ) -{ - int lineType = LINE_8; - - /** Create some points */ - Point rook_points[1][20]; - rook_points[0][0] = Point( w/4, 7*w/8 ); - rook_points[0][1] = Point( 3*w/4, 7*w/8 ); - rook_points[0][2] = Point( 3*w/4, 13*w/16 ); - rook_points[0][3] = Point( 11*w/16, 13*w/16 ); - rook_points[0][4] = Point( 19*w/32, 3*w/8 ); - rook_points[0][5] = Point( 3*w/4, 3*w/8 ); - rook_points[0][6] = Point( 3*w/4, w/8 ); - rook_points[0][7] = Point( 26*w/40, w/8 ); - rook_points[0][8] = Point( 26*w/40, w/4 ); - rook_points[0][9] = Point( 22*w/40, w/4 ); - rook_points[0][10] = Point( 22*w/40, w/8 ); - rook_points[0][11] = Point( 18*w/40, w/8 ); - rook_points[0][12] = Point( 18*w/40, w/4 ); - rook_points[0][13] = Point( 14*w/40, w/4 ); - rook_points[0][14] = Point( 14*w/40, w/8 ); - rook_points[0][15] = Point( w/4, w/8 ); - rook_points[0][16] = Point( w/4, 3*w/8 ); - rook_points[0][17] = Point( 13*w/32, 3*w/8 ); - rook_points[0][18] = Point( 5*w/16, 13*w/16 ); - rook_points[0][19] = Point( w/4, 13*w/16 ); - - const Point* ppt[1] = { rook_points[0] }; - int npt[] = { 20 }; - - fillPoly( img, - ppt, - npt, - 1, - Scalar( 255, 255, 255 ), - lineType ); -} -//![my_polygon] - -/** - * @function MyLine - * @brief Draw a simple line - */ -//![my_line] -void MyLine( Mat img, Point start, Point end ) -{ - int thickness = 2; - int lineType = LINE_8; - - line( img, - start, - end, - Scalar( 0, 0, 0 ), - thickness, - lineType ); -} -//![my_line] - -/** - * @function TestGAPI - @brief to test `with_ade` - derived from https://docs.opencv.org/4.5.0/d0/d1e/gapi.html -*/ -void TestGAPI() -{ -#ifdef BUILT_WITH_ADE - cv::GMat in; - cv::GMat vga = cv::gapi::resize(in, cv::Size(), 0.5, 0.5); - cv::GMat gray = cv::gapi::BGR2Gray(vga); - cv::GMat blurred = cv::gapi::blur(gray, cv::Size(5,5)); - cv::GMat edges = cv::gapi::Canny(blurred, 32, 128, 3); - cv::GMat b,g,r; - std::tie(b,g,r) = cv::gapi::split3(vga); - cv::GMat out = cv::gapi::merge3(b, g | edges, r); - cv::GComputation ac(in, out); -#endif -} - -void TestVideo() -{ -#ifdef BUILT_WITH_FFMPEG - if (!videoio_registry::hasBackend(CAP_FFMPEG)) - throw std::runtime_error("FFmpeg backend was not found"); -#endif -} - -void TestSFM() -{ -#ifdef BUILT_CONTRIB_SFM - Vec3f a; - a << 1,2,3; - Matx33f ax = sfm::skew(a); -#endif -} diff --git a/recipes/opencv/4.x/test_package/test_phase_unwrapping.cpp b/recipes/opencv/4.x/test_package/test_phase_unwrapping.cpp new file mode 100644 index 00000000000000..d8863b429ecd49 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_phase_unwrapping.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto histogram_phase_unwrapping = cv::phase_unwrapping::HistogramPhaseUnwrapping::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_photo.cpp b/recipes/opencv/4.x/test_package/test_photo.cpp new file mode 100644 index 00000000000000..4a94f1b4c0c8fc --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_photo.cpp @@ -0,0 +1,10 @@ +#include +#include + +int main() { + auto src_image = cv::Mat::zeros(400, 400, CV_8UC3); + cv::Mat dst_image; + cv::fastNlMeansDenoising(src_image, dst_image); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_plot.cpp b/recipes/opencv/4.x/test_package/test_plot.cpp new file mode 100644 index 00000000000000..40dc21023a5fca --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_plot.cpp @@ -0,0 +1,12 @@ +#include +#include + +int main() { + cv::Mat xData; + xData.create(1, 100, CV_64F); + for (int i = 0; i < 100; ++i) { + xData.at(i) = i / 10.0; + } + auto plot = cv::plot::Plot2d::create(xData); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_quality.cpp b/recipes/opencv/4.x/test_package/test_quality.cpp new file mode 100644 index 00000000000000..75faaa7e15666b --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_quality.cpp @@ -0,0 +1,8 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::ones(10, 10, CV_8UC3) * 40; + auto quality_mse = cv::quality::QualityMSE::create(image); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_reg.cpp b/recipes/opencv/4.x/test_package/test_reg.cpp new file mode 100644 index 00000000000000..26957e3fa333bf --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_reg.cpp @@ -0,0 +1,9 @@ +#include + +int main() { + cv::reg::MapProjec map; + map.scale(5.5); + map.inverseMap(); + map.normalize(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_rgbd.cpp b/recipes/opencv/4.x/test_package/test_rgbd.cpp new file mode 100644 index 00000000000000..f4c2a3c31ec3bb --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_rgbd.cpp @@ -0,0 +1,7 @@ +#include +#include + +int main() { + auto depth_cleaner = cv::rgbd::DepthCleaner::create(5); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_saliency.cpp b/recipes/opencv/4.x/test_package/test_saliency.cpp new file mode 100644 index 00000000000000..c3938011335b0b --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_saliency.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto objectness_bing = cv::saliency::ObjectnessBING::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_sfm.cpp b/recipes/opencv/4.x/test_package/test_sfm.cpp new file mode 100644 index 00000000000000..e4b4bacb2a25a0 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_sfm.cpp @@ -0,0 +1,10 @@ +#include +#include + +int main() { + cv::Vec3f a; + a << 1,2,3; + cv::Matx33f ax = cv::sfm::skew(a); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_shape.cpp b/recipes/opencv/4.x/test_package/test_shape.cpp new file mode 100644 index 00000000000000..ef5e9500abe479 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_shape.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto extractor = cv::createChiHistogramCostExtractor(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_stitching.cpp b/recipes/opencv/4.x/test_package/test_stitching.cpp new file mode 100644 index 00000000000000..8a445823efb350 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_stitching.cpp @@ -0,0 +1,13 @@ +#include +#include + +int main() { + cv::Rect roi; + bool overlap = cv::detail::overlapRoi( + cv::Point2f(2, 3), cv::Point2f(4, -3), + cv::Size(10, 10), cv::Size(3, 4), + roi + ); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_structured_light.cpp b/recipes/opencv/4.x/test_package/test_structured_light.cpp new file mode 100644 index 00000000000000..d6f0b0661cdba5 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_structured_light.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto pattern = cv::structured_light::GrayCodePattern::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_superres.cpp b/recipes/opencv/4.x/test_package/test_superres.cpp new file mode 100644 index 00000000000000..70097500036ec7 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_superres.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto frame_source = cv::superres::createFrameSource_Empty(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_surface_matching.cpp b/recipes/opencv/4.x/test_package/test_surface_matching.cpp new file mode 100644 index 00000000000000..3a215084288be3 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_surface_matching.cpp @@ -0,0 +1,7 @@ +#include +#include + +int main() { + cv::ppf_match_3d::PPF3DDetector detector(0.03, 0.05); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_text.cpp b/recipes/opencv/4.x/test_package/test_text.cpp new file mode 100644 index 00000000000000..1c8dbed4b8ea28 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_text.cpp @@ -0,0 +1,11 @@ +#include +#include + +#include + +int main() { + cv::Mat image = cv::Mat::zeros(10, 10, CV_8UC3); + std::vector channels; + cv::text::computeNMChannels(image, channels); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_tracking.cpp b/recipes/opencv/4.x/test_package/test_tracking.cpp new file mode 100644 index 00000000000000..69efe349df2226 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_tracking.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto kcf_tracker = cv::TrackerKCF::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_video.cpp b/recipes/opencv/4.x/test_package/test_video.cpp new file mode 100644 index 00000000000000..09a4342add1a12 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_video.cpp @@ -0,0 +1,7 @@ +#include + +int main() { + auto bkg_subtractor_knn = cv::createBackgroundSubtractorKNN(); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_videoio.cpp b/recipes/opencv/4.x/test_package/test_videoio.cpp new file mode 100644 index 00000000000000..7b0955e888a065 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_videoio.cpp @@ -0,0 +1,11 @@ +#include +#include + +#include + +int main() { + if (!cv::videoio_registry::hasBackend(cv::CAP_FFMPEG)) + throw std::runtime_error("FFmpeg backend was not found"); + + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_wechat_qrcode.cpp b/recipes/opencv/4.x/test_package/test_wechat_qrcode.cpp new file mode 100644 index 00000000000000..6dce15eeb7b403 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_wechat_qrcode.cpp @@ -0,0 +1,9 @@ +#include +#include + +int main() { + cv::Mat image = cv::Mat::ones(100, 100, CV_8UC3) * 50; + cv::wechat_qrcode::WeChatQRCode wechat_qrcode; + auto decoded_strings = wechat_qrcode.detectAndDecode(image); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_xfeatures2d.cpp b/recipes/opencv/4.x/test_package/test_xfeatures2d.cpp new file mode 100644 index 00000000000000..673b9737b4fddc --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_xfeatures2d.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto vgg = cv::xfeatures2d::VGG::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_ximgproc.cpp b/recipes/opencv/4.x/test_package/test_ximgproc.cpp new file mode 100644 index 00000000000000..b4804362da9b29 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_ximgproc.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto feature_getter = cv::ximgproc::createRFFeatureGetter(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_xobjdetect.cpp b/recipes/opencv/4.x/test_package/test_xobjdetect.cpp new file mode 100644 index 00000000000000..15cecaff5b8ef9 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_xobjdetect.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto detector = cv::xobjdetect::WBDetector::create(); + return 0; +} diff --git a/recipes/opencv/4.x/test_package/test_xphoto.cpp b/recipes/opencv/4.x/test_package/test_xphoto.cpp new file mode 100644 index 00000000000000..5c0eb661f221c5 --- /dev/null +++ b/recipes/opencv/4.x/test_package/test_xphoto.cpp @@ -0,0 +1,6 @@ +#include + +int main() { + auto grayworld_wb = cv::xphoto::createGrayworldWB(); + return 0; +} diff --git a/recipes/opencv/4.x/test_v1_package/CMakeLists.txt b/recipes/opencv/4.x/test_v1_package/CMakeLists.txt index 0d20897301b68b..c23ed5cfe6d983 100644 --- a/recipes/opencv/4.x/test_v1_package/CMakeLists.txt +++ b/recipes/opencv/4.x/test_v1_package/CMakeLists.txt @@ -1,5 +1,7 @@ cmake_minimum_required(VERSION 3.1) -project(test_package) +project(test_v1_package) + +enable_testing() include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) diff --git a/recipes/opencv/4.x/test_v1_package/conanfile.py b/recipes/opencv/4.x/test_v1_package/conanfile.py index dc9799aa32b63e..9aa234fbd88b8a 100644 --- a/recipes/opencv/4.x/test_v1_package/conanfile.py +++ b/recipes/opencv/4.x/test_v1_package/conanfile.py @@ -1,21 +1,47 @@ from conans import ConanFile, CMake, tools -import os +from conans.errors import ConanException class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "cmake", "cmake_find_package_multi" + @property + def _tested_modules(self): + return [ + # Main modules + "calib3d", "core", "dnn", "features2d", "flann", "gapi", "highgui", "imgcodecs", + "imgproc", "ml", "objdetect", "photo", "stitching", "video", "videoio", + # Extra modules + "alphamat", "aruco", "bgsegm", "bioinspired", "ccalib", "datasets", "dnn_superres", + "face", "freetype", "fuzzy", "hdf", "hfs", "img_hash", "intensity_transform", + "line_descriptor", "mcc", "optflow", "phase_unwrapping", "plot", "quality", "reg", + "rgbd", "saliency", "sfm", "shape", "structured_light", "superres", + "surface_matching", "text", "tracking", "wechat_qrcode", "xfeatures2d", + "ximgproc", "xobjdetect", "xphoto", + ] + + def _opencv_option(self, name, default): + try: + return getattr(self.options["opencv"], name, default) + except (AttributeError, ConanException): + return default + def build(self): cmake = CMake(self) - cmake.definitions["built_dnn"] = self.options["opencv"].dnn - cmake.definitions["built_with_ade"] = self.options["opencv"].with_ade - cmake.definitions["built_with_ffmpeg"] = self.options["opencv"].with_ffmpeg - cmake.definitions["built_contrib_sfm"] = self.options["opencv"].contrib and self.options["opencv"].contrib_sfm + for module in self._tested_modules: + cmake_option = f"OPENCV_WITH_{module.upper()}" + if module == "core": + cmake.definitions[cmake_option] = True + elif module == "imgcodecs": + cmake.definitions[cmake_option] = self.options["opencv"].imgcodecs and self.options["opencv"].with_png + elif module == "videoio": + cmake.definitions[cmake_option] = self.options["opencv"].videoio and self.options["opencv"].with_ffmpeg + else: + cmake.definitions[cmake_option] = self._opencv_option(module, False) cmake.configure() cmake.build() def test(self): if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + self.run(f"ctest --output-on-failure -C {self.settings.build_type} -j {tools.cpu_count()}", run_environment=True) From 05e5a14450621593004cac50d4fd4f5c6ceb3111 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 14:03:38 +0300 Subject: [PATCH 0185/1140] (#18117) dtl: migrate to Conan v2 * dtl: migrate to Conan v2 * dtl: undo addition of cxx_std_11 in test_package No min cppstd check is done in the recipe, so this should not be necessary. * dtl: add check_min_cppstd * dtl: restore test_v1_package * dtl: drop cppstd check * dtl: restore VirtualRunEnv in test_package --------- Co-authored-by: Carlos Zoido --- recipes/dtl/all/conanfile.py | 32 +++++++++++++------ recipes/dtl/all/test_package/CMakeLists.txt | 7 ++-- recipes/dtl/all/test_package/conanfile.py | 21 ++++++++---- .../dtl/all/test_v1_package/CMakeLists.txt | 8 +++++ recipes/dtl/all/test_v1_package/conanfile.py | 17 ++++++++++ 5 files changed, 64 insertions(+), 21 deletions(-) create mode 100644 recipes/dtl/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/dtl/all/test_v1_package/conanfile.py diff --git a/recipes/dtl/all/conanfile.py b/recipes/dtl/all/conanfile.py index 6d45ac4104004b..c53d228db89218 100644 --- a/recipes/dtl/all/conanfile.py +++ b/recipes/dtl/all/conanfile.py @@ -1,28 +1,40 @@ -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + class DtlConan(ConanFile): name = "dtl" description = "diff template library written by C++" - topics = ("diff", "library", "algorithm") license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/cubicdaiya/dtl" + topics = ("diff", "library", "algorithm", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() + self.info.clear() def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(os.path.join("dtl", "*.hpp"), dst="include", src=self._source_subfolder) - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, os.path.join("dtl", "*.hpp"), + dst=os.path.join(self.package_folder, "include"), src=self.source_folder) + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/dtl/all/test_package/CMakeLists.txt b/recipes/dtl/all/test_package/CMakeLists.txt index 9710bb88ce36ce..f8aa0df23cba23 100644 --- a/recipes/dtl/all/test_package/CMakeLists.txt +++ b/recipes/dtl/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(dtl CONFIG REQUIRED) diff --git a/recipes/dtl/all/test_package/conanfile.py b/recipes/dtl/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/dtl/all/test_package/conanfile.py +++ b/recipes/dtl/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/dtl/all/test_v1_package/CMakeLists.txt b/recipes/dtl/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/dtl/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/dtl/all/test_v1_package/conanfile.py b/recipes/dtl/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/dtl/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From c3618f1cd9521d601aece7c402853b6f9a34d0f1 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 13 Aug 2023 20:28:06 +0900 Subject: [PATCH 0186/1140] (#18495) mongo-cxx-driver: add version 3.8.0, update mongo-c-driver * mongo-cxx-driver: add version 3.8.0, update mongo-c-driver * update mongo-c-driver --- recipes/mongo-cxx-driver/all/conandata.yml | 10 +++ recipes/mongo-cxx-driver/all/conanfile.py | 2 +- .../all/patches/3.8.0-0001-dirs.patch | 82 +++++++++++++++++++ recipes/mongo-cxx-driver/config.yml | 2 + 4 files changed, 95 insertions(+), 1 deletion(-) create mode 100644 recipes/mongo-cxx-driver/all/patches/3.8.0-0001-dirs.patch diff --git a/recipes/mongo-cxx-driver/all/conandata.yml b/recipes/mongo-cxx-driver/all/conandata.yml index 5f674bff2da011..3d37bb8ee6cf30 100644 --- a/recipes/mongo-cxx-driver/all/conandata.yml +++ b/recipes/mongo-cxx-driver/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.8.0": + url: "https://github.com/mongodb/mongo-cxx-driver/releases/download/r3.8.0/mongo-cxx-driver-r3.8.0.tar.gz" + sha256: "60c7a53a0f6b984aab0b231dc0b31c85c8950059f42a354fb522672b059d5089" "3.7.2": url: "https://github.com/mongodb/mongo-cxx-driver/releases/download/r3.7.2/mongo-cxx-driver-r3.7.2.tar.gz" sha256: "bc0f5193a8184db47a75685b58acd484b0e489eb0476b4d931d1bf4f5fc2186e" @@ -18,6 +21,13 @@ sources: url: "https://github.com/mongodb/mongo-cxx-driver/releases/download/r3.6.1/mongo-cxx-driver-r3.6.1.tar.gz" sha256: "83523e897ef18f7ce05d85d1632dd4ba486c264a1b89c09020163ab29e11eab7" patches: + "3.8.0": + - patch_file: "patches/3.8.0-0001-dirs.patch" + patch_description: "disable documentation features, fix directories" + patch_type: "conan" + - patch_file: "patches/3.7.2-0002-poly_use_std_define.patch" + patch_description: "use poly macro instead __cplusplus" + patch_type: "portability" "3.7.2": - patch_file: "patches/3.7.2-0001-dirs.patch" patch_description: "disable documentation features, fix directories" diff --git a/recipes/mongo-cxx-driver/all/conanfile.py b/recipes/mongo-cxx-driver/all/conanfile.py index 557880613c87cd..26e997f666df15 100644 --- a/recipes/mongo-cxx-driver/all/conanfile.py +++ b/recipes/mongo-cxx-driver/all/conanfile.py @@ -47,7 +47,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("mongo-c-driver/1.23.5") + self.requires("mongo-c-driver/1.24.3") if self.options.polyfill == "boost": self.requires("boost/1.82.0", transitive_headers=True) diff --git a/recipes/mongo-cxx-driver/all/patches/3.8.0-0001-dirs.patch b/recipes/mongo-cxx-driver/all/patches/3.8.0-0001-dirs.patch new file mode 100644 index 00000000000000..e057a4548d890e --- /dev/null +++ b/recipes/mongo-cxx-driver/all/patches/3.8.0-0001-dirs.patch @@ -0,0 +1,82 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 20254fa..98add65 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -206,6 +206,7 @@ set (BUILD_SOURCE_DIR ${CMAKE_BINARY_DIR}) + + include (MakeDistFiles) + ++if(FALSE) + add_custom_target(hugo_dir + COMMAND ${CMAKE_COMMAND} -E make_directory hugo + ) +@@ -261,6 +262,7 @@ add_custom_target(format-lint + add_custom_target(docs + DEPENDS hugo doxygen-current + ) ++endif() + + set(THIRD_PARTY_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/src/third_party) + +@@ -270,6 +272,9 @@ if (ENABLE_TESTS) + enable_testing() + endif () + ++set(MONGO_CXX_PROJECT_DIR ${CMAKE_CURRENT_SOURCE_DIR}) ++set(MONGO_CXX_PROJECT_BIN_DIR ${CMAKE_CURRENT_BINARY_DIR}) ++ + add_subdirectory(src) + + add_subdirectory(examples EXCLUDE_FROM_ALL) +@@ -281,6 +286,7 @@ add_subdirectory(benchmark EXCLUDE_FROM_ALL) + # CMake does not implement anything like 'dist' from autotools. + # This implementation is based on the one in GnuCash. + ++if(FALSE) + add_subdirectory (cmake) + add_subdirectory (data) + add_subdirectory (docs) +@@ -381,4 +387,4 @@ endif () + if (CMAKE_GENERATOR_TOOLSET) + message (STATUS "\tinstance: ${CMAKE_GENERATOR_TOOLSET}") + endif () +- ++endif () +diff --git a/src/bsoncxx/CMakeLists.txt b/src/bsoncxx/CMakeLists.txt +index f30aea8..09e907c 100644 +--- a/src/bsoncxx/CMakeLists.txt ++++ b/src/bsoncxx/CMakeLists.txt +@@ -71,7 +71,7 @@ set(BSONCXX_VERSION_NO_EXTRA ${BSONCXX_VERSION_MAJOR}.${BSONCXX_VERSION_MINOR}.$ + set(BSONCXX_VERSION ${BSONCXX_VERSION_NO_EXTRA}${BSONCXX_VERSION_EXTRA}) + message ("bsoncxx version: ${BSONCXX_VERSION}") + set(BSONCXX_INLINE_NAMESPACE "v${BSONCXX_ABI_VERSION}") +-set(BSONCXX_HEADER_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}/bsoncxx/${BSONCXX_INLINE_NAMESPACE}" CACHE INTERNAL "") ++set(BSONCXX_HEADER_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}" CACHE INTERNAL "") + + set(LIBBSON_REQUIRED_VERSION 1.24.0) + set(LIBBSON_REQUIRED_ABI_VERSION 1.0) +@@ -95,8 +95,9 @@ if(TARGET bson_shared OR TARGET bson_static) + endif() + else() + # Attempt to find libbson by new package name (without lib). +- find_package(bson-${LIBBSON_REQUIRED_ABI_VERSION} ${LIBBSON_REQUIRED_VERSION} QUIET) +- ++ find_package(bson-${LIBBSON_REQUIRED_ABI_VERSION} REQUIRED) ++ set(bson-${LIBBSON_REQUIRED_ABI_VERSION}_FOUND TRUE) ++ + if(bson-${LIBBSON_REQUIRED_ABI_VERSION}_FOUND) + message ("found libbson version ${bson-${LIBBSON_REQUIRED_ABI_VERSION}_VERSION}") + if(NOT BSONCXX_LINK_WITH_STATIC_MONGOC) +diff --git a/src/mongocxx/CMakeLists.txt b/src/mongocxx/CMakeLists.txt +index 45fd3ad..3248655 100644 +--- a/src/mongocxx/CMakeLists.txt ++++ b/src/mongocxx/CMakeLists.txt +@@ -27,7 +27,7 @@ set(MONGOCXX_VERSION_NO_EXTRA ${MONGOCXX_VERSION_MAJOR}.${MONGOCXX_VERSION_MINOR + set(MONGOCXX_VERSION ${MONGOCXX_VERSION_NO_EXTRA}${MONGOCXX_VERSION_EXTRA}) + message ("mongocxx version: ${MONGOCXX_VERSION}") + set(MONGOCXX_INLINE_NAMESPACE "v${MONGOCXX_ABI_VERSION}") +-set(MONGOCXX_HEADER_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}/mongocxx/${MONGOCXX_INLINE_NAMESPACE}" CACHE INTERNAL "") ++set(MONGOCXX_HEADER_INSTALL_DIR "${CMAKE_INSTALL_INCLUDEDIR}/" CACHE INTERNAL "") + + set(LIBMONGOC_REQUIRED_VERSION 1.24.0) + set(LIBMONGOC_REQUIRED_ABI_VERSION 1.0) diff --git a/recipes/mongo-cxx-driver/config.yml b/recipes/mongo-cxx-driver/config.yml index 454f3110a5ccaf..21ad02b8d94663 100644 --- a/recipes/mongo-cxx-driver/config.yml +++ b/recipes/mongo-cxx-driver/config.yml @@ -1,4 +1,6 @@ versions: + "3.8.0": + folder: all "3.7.2": folder: all "3.7.0": From 9eafdf0628c3ec6ce434ef4b83711d593151c6f7 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 13 Aug 2023 21:26:46 +0900 Subject: [PATCH 0187/1140] (#18601) glaze: add version 1.3.5, remove older versions * glaze: add version 1.3.3, remove older versions * add 1.3.3 to config.yml * drop support msvc 16 since 1.3.3 * drop support msvc 192 on glaze/1.3.3 * update 1.3.4 * update 1.3.5 --- recipes/glaze/all/conandata.yml | 12 +++--------- recipes/glaze/all/conanfile.py | 4 ++-- recipes/glaze/config.yml | 8 ++------ 3 files changed, 7 insertions(+), 17 deletions(-) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index 9a250bd76e55c0..ca57858e477eab 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.5": + url: "https://github.com/stephenberry/glaze/archive/v1.3.5.tar.gz" + sha256: "de5d59cb7f31193d45f67f25d8ced1499df50c0d926a1461432b87f2b2368817" "1.3.2": url: "https://github.com/stephenberry/glaze/archive/v1.3.2.tar.gz" sha256: "c7dd5fd8da63708328e02efbaa91f58df5573114a11c91ae025b711cb0d7f7ab" @@ -14,15 +17,6 @@ sources: "1.2.5": url: "https://github.com/stephenberry/glaze/archive/v1.2.5.tar.gz" sha256: "bc3ff0b24c8c71557e7aabc5a2bfedd51acea92548c208c3a51815848d2b2c5a" - "1.2.3": - url: "https://github.com/stephenberry/glaze/archive/v1.2.3.tar.gz" - sha256: "003cd3922795319253f080b328dd5c957bc8f446cc2a8145324c2748f4acf10f" - "1.2.2": - url: "https://github.com/stephenberry/glaze/archive/v1.2.2.tar.gz" - sha256: "9bacbe5b07819de9799c8b9aa4861224768d2f87b0cb2f16bd1a4639c6e54755" - "1.2.0": - url: "https://github.com/stephenberry/glaze/archive/v1.2.0.tar.gz" - sha256: "f324a88885da5ed832ddb3ab4e3b0c8994815167b2608615fabfe0373c48a0a4" "1.1.2": url: "https://github.com/stephenberry/glaze/archive/v1.1.2.tar.gz" sha256: "ee22d55b7f40d63f510a41f22765cb24e9e70d312978bad4eb9c94c7ba2fe58c" diff --git a/recipes/glaze/all/conanfile.py b/recipes/glaze/all/conanfile.py index 253e1e45cba721..41a166e34e3ca8 100644 --- a/recipes/glaze/all/conanfile.py +++ b/recipes/glaze/all/conanfile.py @@ -25,8 +25,8 @@ def _min_cppstd(self): @property def _compilers_minimum_version(self): return { - "Visual Studio": "16", - "msvc": "192", + "Visual Studio": "17" if Version(self.version) >= "1.3.3" else "16", + "msvc": "193" if Version(self.version) >= "1.3.3" else "192", "gcc": "12", "clang": "12" if Version(self.version) > "1.0.0" else "13", "apple-clang": "13.1", diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index c9458b20872bed..ae1392b97f20d9 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.5": + folder: all "1.3.2": folder: all "1.3.1": @@ -9,12 +11,6 @@ versions: folder: all "1.2.5": folder: all - "1.2.3": - folder: all - "1.2.2": - folder: all - "1.2.0": - folder: all "1.1.2": folder: all "0.3.6": From 89cff30b30f698002105c2c9ee3230070f2a2403 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 16:06:12 +0300 Subject: [PATCH 0188/1140] (#18667) rvo2: migrate to Conan v2 * rvo2: migrate to Conan v2 * rvo2: fix_apple_shared_install_name() * rvo2: restore VirtualRunEnv in test_package --- recipes/rvo2/all/CMakeLists.txt | 11 --- recipes/rvo2/all/conanfile.py | 75 ++++++++++--------- recipes/rvo2/all/test_package/CMakeLists.txt | 9 +-- recipes/rvo2/all/test_package/conanfile.py | 21 ++++-- .../rvo2/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/rvo2/all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 83 insertions(+), 58 deletions(-) delete mode 100644 recipes/rvo2/all/CMakeLists.txt create mode 100644 recipes/rvo2/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rvo2/all/test_v1_package/conanfile.py diff --git a/recipes/rvo2/all/CMakeLists.txt b/recipes/rvo2/all/CMakeLists.txt deleted file mode 100644 index 4e4f66d9ee7ef2..00000000000000 --- a/recipes/rvo2/all/CMakeLists.txt +++ /dev/null @@ -1,11 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup() - -if(WIN32 AND BUILD_SHARED_LIBS) - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) -endif() - -add_subdirectory(source_subfolder) diff --git a/recipes/rvo2/all/conanfile.py b/recipes/rvo2/all/conanfile.py index c7ee9cc9e46889..f5f8524c916a7b 100644 --- a/recipes/rvo2/all/conanfile.py +++ b/recipes/rvo2/all/conanfile.py @@ -1,16 +1,23 @@ import os -from conans import ConanFile, tools, CMake + +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, replace_in_file + +required_conan_version = ">=1.53.0" class Rvo2Conan(ConanFile): name = "rvo2" description = "Optimal Reciprocal Collision Avoidance" - topics = ("conan", "collision", "avoidance", ) + license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/snape/RVO2" - license = "Apache-2.0" + topics = ("collision", "avoidance") - settings = "os", "compiler", "build_type", "arch" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -20,55 +27,51 @@ class Rvo2Conan(ConanFile): "fPIC": True, } - exports_sources = ["CMakeLists.txt"] - generators = "cmake" - - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "RVO2-{}".format(self.version) - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True + tc.generate() def _patch_sources(self): - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), - "add_subdirectory(examples)", - "") - tools.replace_in_file(os.path.join(self._source_subfolder, "src", "CMakeLists.txt"), - "DESTINATION include", - "DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}") - tools.replace_in_file(os.path.join(self._source_subfolder, "src", "CMakeLists.txt"), - "RVO DESTINATION lib", - "RVO RUNTIME LIBRARY ARCHIVE") + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "add_subdirectory(examples)", "") + replace_in_file( + self, + os.path.join(self.source_folder, "src", "CMakeLists.txt"), + "DESTINATION include", + "DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}", + ) + replace_in_file( + self, + os.path.join(self.source_folder, "src", "CMakeLists.txt"), + "RVO DESTINATION lib", + "RVO RUNTIME LIBRARY ARCHIVE", + ) def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=os.path.join(self.source_folder, self._source_subfolder), dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() + fix_apple_shared_install_name(self) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = ["RVO"] diff --git a/recipes/rvo2/all/test_package/CMakeLists.txt b/recipes/rvo2/all/test_package/CMakeLists.txt index 196188113685c8..17ebed2c5661da 100644 --- a/recipes/rvo2/all/test_package/CMakeLists.txt +++ b/recipes/rvo2/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(rvo2 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE rvo2::rvo2) diff --git a/recipes/rvo2/all/test_package/conanfile.py b/recipes/rvo2/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/rvo2/all/test_package/conanfile.py +++ b/recipes/rvo2/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rvo2/all/test_v1_package/CMakeLists.txt b/recipes/rvo2/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rvo2/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rvo2/all/test_v1_package/conanfile.py b/recipes/rvo2/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/rvo2/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 60231935b32310ddb54fcd81f85a1a22cdeb1428 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 16:26:15 +0300 Subject: [PATCH 0189/1140] (#18683) usrsctp: migrate to Conan v2 * usrsctp: migrate to Conan v2 * usrsctp: set CMP0091 to NEW * usrsctp: restore VirtualRunEnv in test_package * usrsctp: fix CMP0091 error * usrsctp: clean up imports --- recipes/usrsctp/all/CMakeLists.txt | 11 --- recipes/usrsctp/all/conandata.yml | 1 - recipes/usrsctp/all/conanfile.py | 95 +++++++++++-------- .../usrsctp/all/test_package/CMakeLists.txt | 5 +- recipes/usrsctp/all/test_package/conanfile.py | 21 ++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../usrsctp/all/test_v1_package/conanfile.py | 17 ++++ 7 files changed, 94 insertions(+), 64 deletions(-) delete mode 100644 recipes/usrsctp/all/CMakeLists.txt create mode 100644 recipes/usrsctp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/usrsctp/all/test_v1_package/conanfile.py diff --git a/recipes/usrsctp/all/CMakeLists.txt b/recipes/usrsctp/all/CMakeLists.txt deleted file mode 100644 index 3bead6a0d93200..00000000000000 --- a/recipes/usrsctp/all/CMakeLists.txt +++ /dev/null @@ -1,11 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup() - -if (WIN32 AND BUILD_SHARED_LIBS) - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) -endif() - -add_subdirectory(source_subfolder) diff --git a/recipes/usrsctp/all/conandata.yml b/recipes/usrsctp/all/conandata.yml index 61e799fd3d4645..9dffac4dd65c94 100644 --- a/recipes/usrsctp/all/conandata.yml +++ b/recipes/usrsctp/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "0.9.5.0": - patch_file: "patches/0001-install.patch" - base_path: "source_subfolder" diff --git a/recipes/usrsctp/all/conanfile.py b/recipes/usrsctp/all/conanfile.py index 73752d1325d3b5..9eba2832eb8dde 100644 --- a/recipes/usrsctp/all/conanfile.py +++ b/recipes/usrsctp/all/conanfile.py @@ -1,27 +1,33 @@ -from conans import ConanFile, CMake, tools import os +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, replace_in_file + +required_conan_version = ">=1.53.0" + class UsrsctpConan(ConanFile): name = "usrsctp" + description = " A portable SCTP userland stack" license = "BSD-3-Clause" - homepage = "https://github.com/sctplab/usrsctp" url = "https://github.com/conan-io/conan-center-index" - topics = ("conan", "network", "sctp") - description = " A portable SCTP userland stack" - settings = "os", "compiler", "arch", "build_type" - options = {"shared": [True, False], - "fPIC": [True, False]} - default_options = {"shared": False, - "fPIC": True} - exports_sources = ["CMakeLists.txt", "patches/*"] - generators = "cmake" + homepage = "https://github.com/sctplab/usrsctp" + topics = ("network", "sctp") - _cmake = None + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -29,46 +35,51 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "usrsctp-{}".format(self.version) - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["sctp_debug"] = False + tc.variables["sctp_werror"] = False + tc.variables["sctp_build_shared_lib"] = self.options.shared + tc.variables["sctp_build_programs"] = False + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared + tc.generate() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["sctp_debug"] = False - self._cmake.definitions["sctp_werror"] = False - self._cmake.definitions["sctp_build_shared_lib"] = self.options.shared - self._cmake.definitions["sctp_build_programs"] = False - self._cmake.configure() - return self._cmake + def _patch_sources(self): + apply_conandata_patches(self) + # Fix "The CMake policy CMP0091 must be NEW, but is ''" + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "project(usrsctplib C)\ncmake_minimum_required(VERSION 3.0)", + "cmake_minimum_required(VERSION 3.15)\nproject(usrsctplib C)") def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE.md", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE.md", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): - self.cpp_info.names["pkg_config"] = "usrsctp" + self.cpp_info.set_property("pkg_config_name", "usrsctp") if self.settings.os == "Windows": - self.cpp_info.system_libs.extend(['ws2_32', 'iphlpapi']) - elif self.settings.os == "Linux": - self.cpp_info.system_libs.extend(['pthread']) + self.cpp_info.system_libs = ["ws2_32", "iphlpapi"] + elif self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["pthread"] suffix = "_import" if self.settings.os == "Windows" and self.options.shared else "" self.cpp_info.libs = ["usrsctp" + suffix] diff --git a/recipes/usrsctp/all/test_package/CMakeLists.txt b/recipes/usrsctp/all/test_package/CMakeLists.txt index a60174007a2341..d8fa3f6efba339 100644 --- a/recipes/usrsctp/all/test_package/CMakeLists.txt +++ b/recipes/usrsctp/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(usrsctp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/usrsctp/all/test_package/conanfile.py b/recipes/usrsctp/all/test_package/conanfile.py index 7e2dfe859bb27b..ef5d7042163ecc 100644 --- a/recipes/usrsctp/all/test_package/conanfile.py +++ b/recipes/usrsctp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/usrsctp/all/test_v1_package/CMakeLists.txt b/recipes/usrsctp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/usrsctp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/usrsctp/all/test_v1_package/conanfile.py b/recipes/usrsctp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/usrsctp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 8cb127aa2e4e16161412266771d85f907f8982ba Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 16:45:51 +0300 Subject: [PATCH 0190/1140] (#18692) fusepp: migrate to Conan v2 * fusepp: migrate to Conan v2 * fusepp: add m * fusepp: restore VirtualRunEnv in test_package --- recipes/fusepp/all/CMakeLists.txt | 16 ++-- recipes/fusepp/all/conanfile.py | 85 ++++++++++--------- .../fusepp/all/test_package/CMakeLists.txt | 9 +- recipes/fusepp/all/test_package/conanfile.py | 21 +++-- .../fusepp/all/test_v1_package/CMakeLists.txt | 8 ++ .../fusepp/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 97 insertions(+), 59 deletions(-) create mode 100644 recipes/fusepp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/fusepp/all/test_v1_package/conanfile.py diff --git a/recipes/fusepp/all/CMakeLists.txt b/recipes/fusepp/all/CMakeLists.txt index 661f0d421c5455..95ef7fe5638955 100644 --- a/recipes/fusepp/all/CMakeLists.txt +++ b/recipes/fusepp/all/CMakeLists.txt @@ -1,18 +1,16 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) +cmake_minimum_required(VERSION 3.12) +project(cmake_wrapper LANGUAGES CXX) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(KEEP_RPATHS) +find_package(libfuse REQUIRED CONFIG) -set(SOURCE_SUBFOLDER ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder) +set(SOURCE_SUBFOLDER ${CMAKE_CURRENT_LIST_DIR}/src) file(GLOB_RECURSE INCLUDE_FILES "${SOURCE_SUBFOLDER}/Fuse*.h" "${SOURCE_SUBFOLDER}/Fuse.cpp") add_library(fusepp ${SOURCE_SUBFOLDER}/Fuse.cpp) - +target_link_libraries(fusepp PUBLIC libfuse::libfuse) set_target_properties(fusepp PROPERTIES PUBLIC_HEADER "${INCLUDE_FILES}") + +include(GNUInstallDirs) install(TARGETS fusepp - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) diff --git a/recipes/fusepp/all/conanfile.py b/recipes/fusepp/all/conanfile.py index f23b9daa7e8748..36394b1187d48c 100644 --- a/recipes/fusepp/all/conanfile.py +++ b/recipes/fusepp/all/conanfile.py @@ -1,15 +1,24 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" class FuseppConan(ConanFile): name = "fusepp" description = "A simple C++ wrapper for the FUSE filesystem." license = "MIT" - topics = ("fuse", "fusepp", "wrapper", "filesystem") - homepage = "https://github.com/jachappell/Fusepp" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/jachappell/Fusepp" + topics = ("fuse", "wrapper", "filesystem") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -17,23 +26,11 @@ class FuseppConan(ConanFile): } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } - exports_sources = "CMakeLists.txt" - - generators = "cmake" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - def validate(self): - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, "11") - if self.settings.compiler == "gcc": - if tools.Version(self.settings.compiler.version) < "6": - raise ConanInvalidConfiguration("gcc < 6 is unsupported") + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -41,38 +38,50 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") - def source(self): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libfuse/3.10.5") + self.requires("libfuse/3.10.5", transitive_headers=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + if self.settings.compiler == "gcc": + if Version(self.settings.compiler.version) < "6": + raise ConanInvalidConfiguration("gcc < 6 is unsupported") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): self.cpp_info.libs = ["fusepp"] + self.cpp_info.set_property("cmake_file_name", "fusepp") + self.cpp_info.set_property("cmake_target_name", "fusepp::fusepp") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] + # TODO: Remove after Conan 2.0 self.cpp_info.names["cmake_find_package"] = "fusepp" self.cpp_info.names["cmake_find_package_multi"] = "fusepp" - - self.cpp_info.set_property("cmake_file_name", "fusepp") - self.cpp_info.set_property("cmake_target_name", "fusepp") diff --git a/recipes/fusepp/all/test_package/CMakeLists.txt b/recipes/fusepp/all/test_package/CMakeLists.txt index 00168e2e070002..03f33e510f02d6 100644 --- a/recipes/fusepp/all/test_package/CMakeLists.txt +++ b/recipes/fusepp/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(fusepp CONFIG REQUIRED) +find_package(fusepp REQUIRED CONFIG) add_executable(${PROJECT_NAME} example.cpp) target_link_libraries(${PROJECT_NAME} fusepp::fusepp) diff --git a/recipes/fusepp/all/test_package/conanfile.py b/recipes/fusepp/all/test_package/conanfile.py index 46d9d6bbaf311f..23d14d1e4b9f6f 100644 --- a/recipes/fusepp/all/test_package/conanfile.py +++ b/recipes/fusepp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run("%s --version" % bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(f"{bin_path} --version", env="conanrun") diff --git a/recipes/fusepp/all/test_v1_package/CMakeLists.txt b/recipes/fusepp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/fusepp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/fusepp/all/test_v1_package/conanfile.py b/recipes/fusepp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..46d9d6bbaf311f --- /dev/null +++ b/recipes/fusepp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run("%s --version" % bin_path, run_environment=True) From 4a6374ce6b8eb87879040618df4e95ef386e00cf Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 17:06:15 +0300 Subject: [PATCH 0191/1140] (#18695) etc2comp: migrate to Conan v2 * etc2comp: migrate to Conan v2 * etc2comp: use collect_libs() for Windows * etc2comp: restore VirtualRunEnv in test_package --- recipes/etc2comp/all/CMakeLists.txt | 7 -- recipes/etc2comp/all/conandata.yml | 1 - recipes/etc2comp/all/conanfile.py | 85 ++++++++++--------- .../etc2comp/all/test_package/CMakeLists.txt | 9 +- .../etc2comp/all/test_package/conanfile.py | 22 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../etc2comp/all/test_v1_package/conanfile.py | 16 ++++ 7 files changed, 88 insertions(+), 60 deletions(-) delete mode 100644 recipes/etc2comp/all/CMakeLists.txt create mode 100644 recipes/etc2comp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/etc2comp/all/test_v1_package/conanfile.py diff --git a/recipes/etc2comp/all/CMakeLists.txt b/recipes/etc2comp/all/CMakeLists.txt deleted file mode 100644 index c986d294c75479..00000000000000 --- a/recipes/etc2comp/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/etc2comp/all/conandata.yml b/recipes/etc2comp/all/conandata.yml index c09fa8bdc3d9b0..a0bae7c1226dd7 100644 --- a/recipes/etc2comp/all/conandata.yml +++ b/recipes/etc2comp/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "cci.20170424": - patch_file: "patches/fix-cmake.patch" - base_path: "source_subfolder" diff --git a/recipes/etc2comp/all/conanfile.py b/recipes/etc2comp/all/conanfile.py index 4a9a0df7d22660..0293dc8b7a9962 100644 --- a/recipes/etc2comp/all/conanfile.py +++ b/recipes/etc2comp/all/conanfile.py @@ -1,16 +1,22 @@ import os -import glob -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get + +required_conan_version = ">=1.53.0" + class Etc2compConan(ConanFile): name = "etc2comp" description = "Open source c++ skeletal animation library and toolset." - license = "Apache-2.0", - topics = ("conan", "texture", "etc2", "compressor") - homepage = "https://github.com/google/etc2comp" + license = ("Apache-2.0",) url = "https://github.com/conan-io/conan-center-index" - exports_sources = ["CMakeLists.txt", "patches/**"] - generators = "cmake" + homepage = "https://github.com/google/etc2comp" + topics = ("texture", "etc2", "compressor") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -21,54 +27,51 @@ class Etc2compConan(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 11) + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob('etc2comp-*/')[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.lib", dst="lib", keep_path=False) - self.copy("*.dll", dst="bin", keep_path=False) - self.copy("*.so*", dst="lib", keep_path=False, symlinks=True) - self.copy("*.dylib", dst="lib", keep_path=False) - self.copy("*.a", dst="lib", keep_path=False) - self.copy("*.h", dst=os.path.join("include"), src=os.path.join(self._source_subfolder, "EtcLib"), keep_path=False) + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + for pattern in ["*.lib", "*.a", "*.so*", "*.dylib"]: + copy(self, pattern, dst=os.path.join(self.package_folder, "lib"), src=self.build_folder, keep_path=False) + copy(self, "*.dll", dst=os.path.join(self.package_folder, "bin"), src=self.build_folder, keep_path=False) + copy( + self, + "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "EtcLib"), + keep_path=False, + ) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - if self.settings.os == "Linux": - self.cpp_info.system_libs.append("pthread") + self.cpp_info.libs = collect_libs(self) + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["pthread"] diff --git a/recipes/etc2comp/all/test_package/CMakeLists.txt b/recipes/etc2comp/all/test_package/CMakeLists.txt index aede60e3b1e4a0..174341b077e2c4 100644 --- a/recipes/etc2comp/all/test_package/CMakeLists.txt +++ b/recipes/etc2comp/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(etc2comp REQUIRED CONFIG) add_executable(${CMAKE_PROJECT_NAME} test_package.cpp) -target_link_libraries(${CMAKE_PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE etc2comp::etc2comp) set_property(TARGET ${CMAKE_PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/etc2comp/all/test_package/conanfile.py b/recipes/etc2comp/all/test_package/conanfile.py index 4903f1a7e8fa0f..ef5d7042163ecc 100644 --- a/recipes/etc2comp/all/test_package/conanfile.py +++ b/recipes/etc2comp/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/etc2comp/all/test_v1_package/CMakeLists.txt b/recipes/etc2comp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/etc2comp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/etc2comp/all/test_v1_package/conanfile.py b/recipes/etc2comp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/etc2comp/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 5a508201e7d09789f3b37253725eefe68e8b9452 Mon Sep 17 00:00:00 2001 From: Carel Date: Sun, 13 Aug 2023 16:27:05 +0200 Subject: [PATCH 0192/1140] (#18829) hunspell/1.7.2: migrate conan 2 and update * Migrate recipe to conan 2 - Test for both * Add 1.7.2 - Newest at this time * Use v2 test package * Remove visibility * Fix includes * Check min gcc * Check C++ standard * Update recipes/hunspell/all/conanfile.py Co-authored-by: Chris Mc * C++11 by default * Remove unused file * Update recipes/hunspell/all/conanfile.py Co-authored-by: Uilian Ries * Review feedback - Use cmake path - Use CMAKE_CURRENT_SOURCE_DIR instead of passing it in through conan * Fix string append Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Chris Mc Co-authored-by: Uilian Ries --- recipes/hunspell/all/CMakeLists.txt | 8 +-- recipes/hunspell/all/conandata.yml | 9 +++ recipes/hunspell/all/conanfile.py | 63 +++++++++------- .../all/patches/0001-fix-basic-string.patch | 71 +++++++++++++++++++ .../hunspell/all/test_package/CMakeLists.txt | 11 ++- .../hunspell/all/test_package/conanfile.py | 20 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../hunspell/all/test_v1_package/conanfile.py | 16 +++++ recipes/hunspell/config.yml | 2 + 9 files changed, 167 insertions(+), 41 deletions(-) create mode 100644 recipes/hunspell/all/patches/0001-fix-basic-string.patch create mode 100644 recipes/hunspell/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/hunspell/all/test_v1_package/conanfile.py diff --git a/recipes/hunspell/all/CMakeLists.txt b/recipes/hunspell/all/CMakeLists.txt index b2bc98f40adabc..8fb4e22ab52aa5 100644 --- a/recipes/hunspell/all/CMakeLists.txt +++ b/recipes/hunspell/all/CMakeLists.txt @@ -1,10 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(hunspell VERSION "${CONAN_hunspell_VERSION}" LANGUAGES CXX) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS KEEP_RPATHS) -set(src src/hunspell) +set(src "${CMAKE_CURRENT_SOURCE_DIR}/src/src/hunspell") # ---- Configure hunvisapi.h ---- @@ -28,6 +26,8 @@ add_library( "${src}/suggestmgr.cxx" ) +target_compile_features(hunspell PRIVATE cxx_std_11) + if(MSVC) target_compile_options(hunspell PRIVATE /wd4267 /wd4996) endif() diff --git a/recipes/hunspell/all/conandata.yml b/recipes/hunspell/all/conandata.yml index 6c8c08bc2e4b03..69ac32949f949c 100644 --- a/recipes/hunspell/all/conandata.yml +++ b/recipes/hunspell/all/conandata.yml @@ -1,4 +1,13 @@ sources: + "1.7.2": + sha256: "69fa312d3586c988789266eaf7ffc9861d9f6396c31fc930a014d551b59bbd6e" + url: https://github.com/hunspell/hunspell/archive/refs/tags/v1.7.2.tar.gz "1.7.0": sha256: "57be4e03ae9dd62c3471f667a0d81a14513e314d4d92081292b90435944ff951" url: https://github.com/hunspell/hunspell/files/2573619/hunspell-1.7.0.tar.gz +patches: + "1.7.2": + - patch_file: "patches/0001-fix-basic-string.patch" + patch_description: "Fix build problem with basic_string::append()" + patch_type: "official" + patch_source: "https://github.com/hunspell/hunspell/commit/a6cb9f609b0292df12e2e855c97303de306bae44" diff --git a/recipes/hunspell/all/conanfile.py b/recipes/hunspell/all/conanfile.py index 6c74ea78eaba74..914e9604ac575f 100644 --- a/recipes/hunspell/all/conanfile.py +++ b/recipes/hunspell/all/conanfile.py @@ -1,21 +1,21 @@ -import functools +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, export_conandata_patches, apply_conandata_patches import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class HunspellConan(ConanFile): name = "hunspell" - description = ( - "Hunspell is a free spell checker and morphological analyzer library" - ) + description = "Hunspell is a free spell checker and morphological analyzer library" url = "https://github.com/conan-io/conan-center-index" homepage = "https://hunspell.github.io/" topics = "spell", "spell-check" license = "MPL-1.1", "GPL-2.0-or-later", "LGPL-2.1-or-later" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -25,10 +25,11 @@ class HunspellConan(ConanFile): "shared": False, "fPIC": True, } - generators = "cmake" - # FIXME: Remove once the pending upstream PR for CMake support is merged - exports_sources = "CMakeLists.txt" - no_copy_source = True + + def export_sources(self): + export_conandata_patches(self) + # TODO: Remove once PR is merged: https://github.com/hunspell/hunspell/pull/704/ + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -36,30 +37,44 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) # NOTE: The source contains a pre-configured hunvisapi.h and it would # prevent no_copy_source and building without patches. h = os.path.join(self.source_folder, "src", "hunspell", "hunvisapi.h") os.remove(h) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["CONAN_hunspell_VERSION"] = self.version - cmake.configure() - return cmake + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CONAN_hunspell_VERSION"] = self.version + tc.generate() def build(self): - self._configure_cmake().build() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) + cmake.build() def package(self): - self._configure_cmake().install() - self.copy("COPYING", "licenses") - self.copy("COPYING.LESSER", "licenses") - self.copy("license.hunspell", "licenses") + cmake = CMake(self) + cmake.install() + copy(self, "COPYING*", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + keep_path=False) + copy(self, "license.hunspell", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + keep_path=False) def package_info(self): self.cpp_info.libs = ["hunspell"] diff --git a/recipes/hunspell/all/patches/0001-fix-basic-string.patch b/recipes/hunspell/all/patches/0001-fix-basic-string.patch new file mode 100644 index 00000000000000..71aa1cdafa6c8e --- /dev/null +++ b/recipes/hunspell/all/patches/0001-fix-basic-string.patch @@ -0,0 +1,71 @@ +diff --git a/src/hunspell/affentry.cxx b/src/hunspell/affentry.cxx +index 46e8b5826..6ee23bec9 100644 +--- a/src/hunspell/affentry.cxx ++++ b/src/hunspell/affentry.cxx +@@ -290,7 +290,7 @@ struct hentry* PfxEntry::check_twosfx(const std::string& word, + // back any characters that would have been stripped + + std::string tmpword(strip); +- tmpword.append(word, start + appnd.size()); ++ tmpword.append(word, start + appnd.size(), tmpl); + + // now make sure all of the conditions on characters + // are met. Please see the appendix at the end of +@@ -338,7 +338,7 @@ std::string PfxEntry::check_twosfx_morph(const std::string& word, + // back any characters that would have been stripped + + std::string tmpword(strip); +- tmpword.append(word, start + appnd.size()); ++ tmpword.append(word, start + appnd.size(), tmpl); + + // now make sure all of the conditions on characters + // are met. Please see the appendix at the end of +@@ -386,7 +386,7 @@ std::string PfxEntry::check_morph(const std::string& word, + // back any characters that would have been stripped + + std::string tmpword(strip); +- tmpword.append(word, start + appnd.size()); ++ tmpword.append(word, start + appnd.size(), tmpl); + + // now make sure all of the conditions on characters + // are met. Please see the appendix at the end of +diff --git a/src/hunspell/affixmgr.cxx b/src/hunspell/affixmgr.cxx +index 4d1ad2f12..a8931c14a 100644 +--- a/src/hunspell/affixmgr.cxx ++++ b/src/hunspell/affixmgr.cxx +@@ -2465,7 +2465,7 @@ int AffixMgr::compound_check_morph(const std::string& word, + result.append(presult); + result.push_back(MSEP_FLD); + result.append(MORPH_PART); +- result.append(word, i); ++ result.append(word, i, word.size()); + if (complexprefixes && HENTRY_DATA(rv)) + result.append(HENTRY_DATA2(rv)); + if (!HENTRY_FIND(rv, MORPH_STEM)) { +@@ -2522,7 +2522,7 @@ int AffixMgr::compound_check_morph(const std::string& word, + result.append(presult); + result.push_back(MSEP_FLD); + result.append(MORPH_PART); +- result.append(word, i); ++ result.append(word, i, word.size()); + + if (HENTRY_DATA(rv)) { + if (complexprefixes) +@@ -2573,7 +2573,7 @@ int AffixMgr::compound_check_morph(const std::string& word, + if (!m.empty()) { + result.push_back(MSEP_FLD); + result.append(MORPH_PART); +- result.append(word, i); ++ result.append(word, i, word.size()); + line_uniq_app(m, MSEP_REC); + result.append(m); + } +@@ -2665,7 +2665,7 @@ int AffixMgr::compound_check_morph(const std::string& word, + if (!m.empty()) { + result.push_back(MSEP_FLD); + result.append(MORPH_PART); +- result.append(word, i); ++ result.append(word, i, word.size()); + line_uniq_app(m, MSEP_REC); + result.push_back(MSEP_FLD); + result.append(m); diff --git a/recipes/hunspell/all/test_package/CMakeLists.txt b/recipes/hunspell/all/test_package/CMakeLists.txt index 73177e055de6d8..45217182fc8cf5 100644 --- a/recipes/hunspell/all/test_package/CMakeLists.txt +++ b/recipes/hunspell/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(hunspell REQUIRED CONFIG) -add_executable(test_package test_package.cxx) -target_link_libraries(test_package PRIVATE hunspell::hunspell) +add_executable(${PROJECT_NAME} test_package.cxx) +target_link_libraries(${PROJECT_NAME} PRIVATE hunspell::hunspell) diff --git a/recipes/hunspell/all/test_package/conanfile.py b/recipes/hunspell/all/test_package/conanfile.py index a8c92dea633357..0a6bc68712d901 100644 --- a/recipes/hunspell/all/test_package/conanfile.py +++ b/recipes/hunspell/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout import os -from conans import ConanFile, CMake, tools - class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/hunspell/all/test_v1_package/CMakeLists.txt b/recipes/hunspell/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..5d38c542b67a46 --- /dev/null +++ b/recipes/hunspell/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/hunspell/all/test_v1_package/conanfile.py b/recipes/hunspell/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a500b98343c743 --- /dev/null +++ b/recipes/hunspell/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/hunspell/config.yml b/recipes/hunspell/config.yml index 0f57b11de8fb0a..cc37272dbe648e 100644 --- a/recipes/hunspell/config.yml +++ b/recipes/hunspell/config.yml @@ -1,3 +1,5 @@ versions: + "1.7.2": + folder: all "1.7.0": folder: all From 7521c744ff1b5b295228de8d29a6f0a8d5f1ae61 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 13 Aug 2023 23:47:28 +0900 Subject: [PATCH 0193/1140] (#18843) sol2: add version 3.3.1, add package_type, update lua --- recipes/sol2/all/conandata.yml | 3 +++ recipes/sol2/all/conanfile.py | 5 +++-- recipes/sol2/config.yml | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/recipes/sol2/all/conandata.yml b/recipes/sol2/all/conandata.yml index aa516653323cff..f83f4a6a367354 100644 --- a/recipes/sol2/all/conandata.yml +++ b/recipes/sol2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.3.1": + url: "https://github.com/ThePhD/sol2/archive/v3.3.1.tar.gz" + sha256: "ad121461047d52b449aa84234a6b578fa3ed95d67d1a0703902eba72417f61bb" "3.3.0": url: "https://github.com/ThePhD/sol2/archive/v3.3.0.tar.gz" sha256: "b82c5de030e18cb2bcbcefcd5f45afd526920c517a96413f0b59b4332d752a1e" diff --git a/recipes/sol2/all/conanfile.py b/recipes/sol2/all/conanfile.py index 93f899011d3355..4ebb24964da6a9 100644 --- a/recipes/sol2/all/conanfile.py +++ b/recipes/sol2/all/conanfile.py @@ -17,7 +17,8 @@ class Sol2Conan(ConanFile): license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/ThePhD/sol2" - topics = ("lua", "c++", "bindings", "scripting") + topics = ("lua", "c++", "bindings", "scripting", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -66,7 +67,7 @@ def requirements(self): # v2.x.x & v3.0.x supports up to Lua 5.3 self.requires("lua/5.3.6") else: - self.requires("lua/5.4.4") + self.requires("lua/5.4.6") elif self.options.with_lua == "luajit": self.requires("luajit/2.1.0-beta3") diff --git a/recipes/sol2/config.yml b/recipes/sol2/config.yml index 28097c1cf11a25..d6be5bd0bfdf0f 100644 --- a/recipes/sol2/config.yml +++ b/recipes/sol2/config.yml @@ -1,4 +1,6 @@ versions: + "3.3.1": + folder: "all" "3.3.0": folder: "all" "3.2.3": From ec4868889aabf53e9b7a87e6b2af16936efaa769 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 18:27:48 +0300 Subject: [PATCH 0194/1140] (#18944) nmslib: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * nmslib: migrate to Conan v2 * nmslib: add m, fix_apple_shared_install_name() * nmslib: add mvec * Update recipes/nmslib/all/conanfile.py Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/nmslib/all/CMakeLists.txt | 7 -- recipes/nmslib/all/conandata.yml | 12 +-- recipes/nmslib/all/conanfile.py | 93 +++++++++++-------- .../nmslib/all/test_package/CMakeLists.txt | 5 +- recipes/nmslib/all/test_package/conanfile.py | 21 +++-- .../nmslib/all/test_v1_package/CMakeLists.txt | 8 ++ .../nmslib/all/test_v1_package/conanfile.py | 17 ++++ 7 files changed, 100 insertions(+), 63 deletions(-) delete mode 100644 recipes/nmslib/all/CMakeLists.txt create mode 100644 recipes/nmslib/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/nmslib/all/test_v1_package/conanfile.py diff --git a/recipes/nmslib/all/CMakeLists.txt b/recipes/nmslib/all/CMakeLists.txt deleted file mode 100644 index c8e560d40aa56d..00000000000000 --- a/recipes/nmslib/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(source_subfolder/similarity_search) diff --git a/recipes/nmslib/all/conandata.yml b/recipes/nmslib/all/conandata.yml index bc747087c62bd3..a76e6327ac2f8d 100644 --- a/recipes/nmslib/all/conandata.yml +++ b/recipes/nmslib/all/conandata.yml @@ -4,11 +4,7 @@ sources: sha256: d1f5c60a62e0e61e14c92b37d6f1420ed4bb3c6fd19ced67c84b7e0e0e3f07c5 patches: "2.1.1": - - base_path: source_subfolder - patch_file: patches/0001-cmake-disable-app-build.patch - - base_path: source_subfolder - patch_file: patches/0002-cmake-fix-install.patch - - base_path: source_subfolder - patch_file: patches/0003-cmake-fix-flags.patch - - base_path: source_subfolder - patch_file: patches/0004-missing-utils-header.patch + - patch_file: patches/0001-cmake-disable-app-build.patch + - patch_file: patches/0002-cmake-fix-install.patch + - patch_file: patches/0003-cmake-fix-flags.patch + - patch_file: patches/0004-missing-utils-header.patch diff --git a/recipes/nmslib/all/conanfile.py b/recipes/nmslib/all/conanfile.py index 637febf0d43bb8..0aeec8ba9e93f9 100644 --- a/recipes/nmslib/all/conanfile.py +++ b/recipes/nmslib/all/conanfile.py @@ -1,66 +1,83 @@ import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get +from conan.tools.microsoft import is_msvc, check_min_vs + +required_conan_version = ">=1.53.0" class Nmslib(ConanFile): name = "nmslib" + description = ( + "Non-Metric Space Library (NMSLIB): An efficient similarity search library " + "and a toolkit for evaluation of k-NN methods for generic non-metric spaces." + ) + license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/nmslib/nmslib" - description = "Non-Metric Space Library (NMSLIB): An efficient similarity search library and a toolkit for evaluation of k-NN methods for generic non-metric spaces." topics = ("knn-search", "non-metric", "neighborhood-graphs", "neighborhood-graphs", "vp-tree") - license = "Apache-2.0" + + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - exports_sources = "CMakeLists.txt", "patches/**" - generators = "cmake" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - _cmake = None + def export_sources(self): + export_conandata_patches(self) - def validate(self): - if self.settings.compiler == "Visual Studio": - if self.settings.compiler.version == "14": - raise ConanInvalidConfiguration("Visual Studio 14 builds are not supported") # TODO: add reason in message - if self.options.shared: - raise ConanInvalidConfiguration("Visual Studio shared builds are not supported (.lib artifacts missing)") + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC + def layout(self): + cmake_layout(self, src_folder="src") - @property - def _source_subfolder(self): - return "source_subfolder" + def validate(self): + check_min_vs(self, 190) # TODO: add reason in message + if is_msvc(self) and self.options.shared: + raise ConanInvalidConfiguration( + "Visual Studio shared builds are not supported (.lib artifacts missing)" + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, - destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake is None: - cmake = CMake(self) - cmake.definitions["WITHOUT_TESTS"] = True - cmake.configure() - self._cmake = cmake - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["WITHOUT_TESTS"] = True + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, "similarity_search")) cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["NonMetricSpaceLib"] - if self.settings.os == "Linux": - self.cpp_info.system_libs = ["pthread"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["pthread", "m"] + if self.settings.arch in ["x86", "x86_64"]: + self.cpp_info.system_libs.append("mvec") diff --git a/recipes/nmslib/all/test_package/CMakeLists.txt b/recipes/nmslib/all/test_package/CMakeLists.txt index 7b52b104457446..a7336347af2da7 100644 --- a/recipes/nmslib/all/test_package/CMakeLists.txt +++ b/recipes/nmslib/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - find_package(nmslib REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/nmslib/all/test_package/conanfile.py b/recipes/nmslib/all/test_package/conanfile.py index abcaeed3f89b67..ef5d7042163ecc 100644 --- a/recipes/nmslib/all/test_package/conanfile.py +++ b/recipes/nmslib/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/nmslib/all/test_v1_package/CMakeLists.txt b/recipes/nmslib/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/nmslib/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/nmslib/all/test_v1_package/conanfile.py b/recipes/nmslib/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/nmslib/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b0cdc00b50640a5acdb6b9dbca7ef710a401b1ad Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 13 Aug 2023 18:48:13 +0300 Subject: [PATCH 0195/1140] (#18981) libsafec: migrate to Conan v2 * libsafec: migrate to Conan v2 * libsafec: add fix_apple_shared_install_name() --- recipes/libsafec/all/conanfile.py | 113 +++++++++--------- .../libsafec/all/test_package/CMakeLists.txt | 7 +- .../libsafec/all/test_package/conanfile.py | 21 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../libsafec/all/test_v1_package/conanfile.py | 17 +++ 5 files changed, 102 insertions(+), 64 deletions(-) create mode 100644 recipes/libsafec/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libsafec/all/test_v1_package/conanfile.py diff --git a/recipes/libsafec/all/conanfile.py b/recipes/libsafec/all/conanfile.py index 6924adfd04703a..7086816ccca537 100644 --- a/recipes/libsafec/all/conanfile.py +++ b/recipes/libsafec/all/conanfile.py @@ -1,23 +1,28 @@ +import os + from conan import ConanFile from conan.errors import ConanInvalidConfiguration, ConanException -from conan.tools.files import get, rmdir, copy, rm, chdir +from conan.tools.apple import is_apple_os, fix_apple_shared_install_name +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import chdir, copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout from conan.tools.microsoft import is_msvc from conan.tools.scm import Version -from conans import AutoToolsBuildEnvironment, tools -import os required_conan_version = ">=1.53.0" class LibSafeCConan(ConanFile): name = "libsafec" - description = "This library implements the secure C11 Annex K[^5] functions" \ - " on top of most libc implementations, which are missing from them." + description = ("This library implements the secure C11 Annex K[^5] functions" + " on top of most libc implementations, which are missing from them.") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/rurban/safeclib" - license = "MIT" - topics = ("safec", "libc", "bounds-checking") + topics = ("safec", "libc", "bounds-checking", "pre-built") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -32,16 +37,20 @@ class LibSafeCConan(ConanFile): "memmax": 268435456, } - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) + @property + def _supported_compiler(self): + compiler = self.settings.compiler + version = Version(self.settings.compiler.version) + if is_msvc(self): + return False + if compiler == "gcc" and version < "5": + return False + return True + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -52,71 +61,67 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") - def build_requirements(self): - self.tool_requires("libtool/2.4.6") - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): - self.tool_requires("msys2/cci.latest") - - @property - def _supported_compiler(self): - compiler = self.settings.compiler - version = Version(self.settings.compiler.version) - if is_msvc(self): - return False - if compiler == "gcc" and version < "5": - return False - return True + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.os == "Macos" and self.settings.arch == "armv8": - raise ConanInvalidConfiguration(f"This platform is not yet supported by {self.ref} (os=Macos arch=armv8)") + if is_apple_os(self) and self.settings.arch == "armv8": + raise ConanInvalidConfiguration( + f"This platform is not yet supported by {self.ref} (os=Macos arch=armv8)" + ) if not self._supported_compiler: raise ConanInvalidConfiguration( - f"{self.ref} doesn't support {self.settings.compiler}-{self.settings.compiler.version}") + f"{self.ref} doesn't support {self.settings.compiler}-{self.settings.compiler.version}" + ) if not str(self.info.options.strmax).isdigit(): raise ConanException(f"{self.ref} option 'strmax' must be a valid integer number.") + def build_requirements(self): + self.tool_requires("libtool/2.4.7") + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") + def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + tc = AutotoolsToolchain(self) yes_no = lambda v: "yes" if v else "no" - args = [ - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-static={}".format(yes_no(not self.options.shared)), - "--enable-debug={}".format(yes_no(self.settings.build_type == "Debug")), + tc.configure_args += [ + f"--enable-debug={yes_no(self.settings.build_type == 'Debug')}", "--disable-doc", "--disable-Werror", - "--enable-strmax={}".format(self.options.strmax), - "--enable-memmax={}".format(self.options.memmax), + f"--enable-strmax={self.options.strmax}", + f"--enable-memmax={self.options.memmax}", ] - self._autotools.configure(args=args, configure_dir=self._source_subfolder) - return self._autotools + tc.generate() def build(self): - with chdir(self, self._source_subfolder): - self.run("{} -fiv".format(tools.get_env("AUTORECONF")), - win_bash=tools.os_info.is_windows, run_environment=True) - autotools = self._configure_autotools() - autotools.make() + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.autoreconf() + autotools.configure() + autotools.make() def package(self): - copy(self, "COPYING", src=self._source_subfolder, dst=os.path.join(self.package_folder, "licenses")) - autotools = self._configure_autotools() - autotools.install() + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rm(self, "*.la", os.path.join(self.package_folder, "lib")) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.includedirs.append(os.path.join("include", "libsafec")) - self.cpp_info.libs = ["safec-{}".format(self.version)] + self.cpp_info.libs = [f"safec-{self.version}"] self.cpp_info.set_property("pkg_config_name", "libsafec") bin_dir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_dir)) + self.output.info(f"Appending PATH environment variable: {bin_dir}") self.env_info.PATH.append(bin_dir) diff --git a/recipes/libsafec/all/test_package/CMakeLists.txt b/recipes/libsafec/all/test_package/CMakeLists.txt index 31762006efa776..2a28db28a9c5d2 100644 --- a/recipes/libsafec/all/test_package/CMakeLists.txt +++ b/recipes/libsafec/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libsafec REQUIRED CONFIG) add_executable(test_package test_package.c) -target_link_libraries(test_package ${CONAN_LIBS}) +target_link_libraries(test_package PRIVATE libsafec::libsafec) diff --git a/recipes/libsafec/all/test_package/conanfile.py b/recipes/libsafec/all/test_package/conanfile.py index b7cd0e8fa4f622..ef5d7042163ecc 100644 --- a/recipes/libsafec/all/test_package/conanfile.py +++ b/recipes/libsafec/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import CMake, ConanFile, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libsafec/all/test_v1_package/CMakeLists.txt b/recipes/libsafec/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libsafec/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libsafec/all/test_v1_package/conanfile.py b/recipes/libsafec/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..043b77522562fc --- /dev/null +++ b/recipes/libsafec/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import CMake, ConanFile, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 22b6c2bc6389ecbb29f021bf9970063ccecb0294 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 01:09:14 +0900 Subject: [PATCH 0196/1140] (#18985) ctre: add version 3.8, add package_type * ctre: add version 3.8, add package_type * drop support clang/12.0 without cppstd on ctre/3.4.1 * fix condition expr --- recipes/ctre/all/conandata.yml | 3 +++ recipes/ctre/all/conanfile.py | 10 +++++++--- recipes/ctre/config.yml | 2 ++ 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/recipes/ctre/all/conandata.yml b/recipes/ctre/all/conandata.yml index 0cbb6fc297fa12..84177523424ed2 100644 --- a/recipes/ctre/all/conandata.yml +++ b/recipes/ctre/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.8": + url: "https://github.com/hanickadot/compile-time-regular-expressions/archive/v3.8.tar.gz" + sha256: "6462ee41fa6aa12075f6b9d13f42358091d32963087443a6669d2c94232eea04" "3.7.2": url: "https://github.com/hanickadot/compile-time-regular-expressions/archive/v3.7.2.tar.gz" sha256: "0711a6f97496e010f72adab69839939a9e50ba35ad87779e422ae3ff3b0edfc3" diff --git a/recipes/ctre/all/conanfile.py b/recipes/ctre/all/conanfile.py index 4a9068c2ee4fea..7170bf3ad64257 100644 --- a/recipes/ctre/all/conanfile.py +++ b/recipes/ctre/all/conanfile.py @@ -17,6 +17,7 @@ class CtreConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/hanickadot/compile-time-regular-expressions" topics = ("cpp17", "regex", "compile-time-regular-expressions", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -38,8 +39,11 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} doesn't support MSVC < 16") elif compiler == "gcc" and compiler_version < min_gcc: raise ConanInvalidConfiguration(f"{self.ref} doesn't support gcc < {min_gcc}") - elif compiler == "clang" and compiler_version < "6.0": - raise ConanInvalidConfiguration(f"{self.ref} doesn't support clang < 6.0") + elif compiler == "clang": + if compiler_version < "6.0": + raise ConanInvalidConfiguration(f"{self.ref} doesn't support clang < 6.0") + if ctre_version == "3.4.1" and compiler_version >= "12.0" and not self.settings.compiler.get_safe("cppstd"): + raise ConanInvalidConfiguration(f"{self.ref} doesn't support clang >= 12.0 without cppstd. Please set cppstd.") elif compiler == "apple-clang": if compiler_version < "10.0": raise ConanInvalidConfiguration(f"{self.ref} doesn't support Apple clang < 10.0") @@ -53,7 +57,7 @@ def package_id(self): self.info.clear() def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, pattern="*.hpp", src=os.path.join(self.source_folder, "include"), dst=os.path.join(self.package_folder, "include")) diff --git a/recipes/ctre/config.yml b/recipes/ctre/config.yml index 791985db544208..e8d08c6a4805a3 100644 --- a/recipes/ctre/config.yml +++ b/recipes/ctre/config.yml @@ -1,4 +1,6 @@ versions: + "3.8": + folder: all "3.7.2": folder: all "3.7.1": From fcfa9587260464528a82ed7980a7352ec634fde6 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 01:48:06 +0900 Subject: [PATCH 0197/1140] (#18991) luau: add version 0.589, remove older versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * luau: add version 0.588, remove older versions * apply patch for 0.588 * update 0.589 --------- Co-authored-by: Rubén Rincón Blanco --- recipes/luau/all/conandata.yml | 37 +++++++--------------------------- recipes/luau/config.yml | 8 ++------ 2 files changed, 9 insertions(+), 36 deletions(-) diff --git a/recipes/luau/all/conandata.yml b/recipes/luau/all/conandata.yml index 1dc4953f665e9e..ce7fa7f71284a0 100644 --- a/recipes/luau/all/conandata.yml +++ b/recipes/luau/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.589": + url: "https://github.com/Roblox/luau/archive/0.589.tar.gz" + sha256: "dc4489de52dbf29cd3d04d78c1112f812e04a03b68d57585749260ba791e65ed" "0.582": url: "https://github.com/Roblox/luau/archive/0.582.tar.gz" sha256: "ee6da6329e58afc956bcca907ed9c6bc0455cd580990aa73f7cfb285aea22a6d" @@ -26,16 +29,11 @@ sources: "0.548": url: "https://github.com/Roblox/luau/archive/0.548.tar.gz" sha256: "1ec0aa919955aaa2d88dbef115801681d3b4dbfa7a276435a03d20230918659c" - "0.544": - url: "https://github.com/Roblox/luau/archive/0.544.tar.gz" - sha256: "c1e2d4e04fe6f191192d1570bd83f96531804fc484a0bc0e00b53248a01d7dee" - "0.541": - url: "https://github.com/Roblox/luau/archive/0.541.tar.gz" - sha256: "02d50b8c0396a353ed641a61959851d6858607d535ed7373478b8fbc2a508eba" - "0.540": - url: "https://github.com/Roblox/luau/archive/0.540.tar.gz" - sha256: "84b3e52b3b0ccf4d5bc0e0c04055f3a9b2f045c1281e203a858335a6fe76b0ff" patches: + "0.589": + - patch_file: "patches/0.572-0001-fix-cmake.patch" + patch_description: "enable shared build" + patch_type: "portability" "0.582": - patch_file: "patches/0.572-0001-fix-cmake.patch" patch_description: "enable shared build" @@ -87,24 +85,3 @@ patches: - patch_file: "patches/0.536-0002-rename-lerp.patch" patch_description: "rename lerp function to avoid name conflict" patch_type: "portability" - "0.544": - - patch_file: "patches/0.536-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" - "0.541": - - patch_file: "patches/0.536-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" - "0.540": - - patch_file: "patches/0.536-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" diff --git a/recipes/luau/config.yml b/recipes/luau/config.yml index 8a8c09827d38eb..da348c98224536 100644 --- a/recipes/luau/config.yml +++ b/recipes/luau/config.yml @@ -1,4 +1,6 @@ versions: + "0.589": + folder: all "0.582": folder: all "0.577": @@ -17,9 +19,3 @@ versions: folder: all "0.548": folder: all - "0.544": - folder: all - "0.541": - folder: all - "0.540": - folder: all From 981f569c41e5ed12812ef425433000abee36efda Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Sun, 13 Aug 2023 19:08:21 +0200 Subject: [PATCH 0198/1140] (#19039) hictk: new recipe * Add hictk * Add CMake to build_requirements * Bugfix * Bugfix * Bugfix * Specify transitive_headers=True in requirements * Update recipes/hictk/all/conanfile.py Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/hictk/all/conandata.yml | 4 + recipes/hictk/all/conanfile.py | 127 ++++++++++++++++++ recipes/hictk/all/test_package/CMakeLists.txt | 9 ++ recipes/hictk/all/test_package/conanfile.py | 27 ++++ .../hictk/all/test_package/test_package.cpp | 8 ++ recipes/hictk/config.yml | 3 + 6 files changed, 178 insertions(+) create mode 100644 recipes/hictk/all/conandata.yml create mode 100644 recipes/hictk/all/conanfile.py create mode 100644 recipes/hictk/all/test_package/CMakeLists.txt create mode 100644 recipes/hictk/all/test_package/conanfile.py create mode 100644 recipes/hictk/all/test_package/test_package.cpp create mode 100644 recipes/hictk/config.yml diff --git a/recipes/hictk/all/conandata.yml b/recipes/hictk/all/conandata.yml new file mode 100644 index 00000000000000..b46596ee0372e8 --- /dev/null +++ b/recipes/hictk/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.0.1": + url: "https://github.com/paulsengroup/hictk/archive/refs/tags/v0.0.1.tar.gz" + sha256: "460985413c3b2e80121f7697c6c824a91955a38051de770d7eb946ddafa88460" diff --git a/recipes/hictk/all/conanfile.py b/recipes/hictk/all/conanfile.py new file mode 100644 index 00000000000000..cf1428272f4659 --- /dev/null +++ b/recipes/hictk/all/conanfile.py @@ -0,0 +1,127 @@ +import os.path + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir + +required_conan_version = ">=1.50.0" + + +class HictkConan(ConanFile): + name = "hictk" + description = "Blazing fast toolkit to work with .hic and .cool files" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/paulsengroup/hictk" + topics = "hictk", "bioinformatics", "hic" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + options = {"with_eigen": [True, False]} + default_options = {"with_eigen": True} + + @property + def _minimum_cpp_standard(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "apple-clang": "11", + "clang": "7", + "gcc": "8", + "Visual Studio": "16", + "msvc": "192", + } + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("fast_float/5.2.0", transitive_headers=True) + if self.options.with_eigen: + self.requires("eigen/3.4.0", transitive_headers=True) + self.requires("fmt/10.0.0", transitive_headers=True) + self.requires("hdf5/1.14.0", transitive_headers=True) + self.requires("highfive/2.7.1", transitive_headers=True) + self.requires("libdeflate/1.18", transitive_headers=True) + self.requires("parallel-hashmap/1.3.11", transitive_headers=True) + self.requires("spdlog/1.12.0", transitive_headers=True) + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.get_safe("compiler.cppstd"): + check_min_cppstd(self, self._minimum_cpp_standard) + + def loose_lt_semver(v1, v2): + lv1 = [int(v) for v in v1.split(".")] + lv2 = [int(v) for v in v2.split(".")] + min_length = min(len(lv1), len(lv2)) + return lv1[:min_length] < lv2[:min_length] + + compiler = str(self.settings.compiler) + version = str(self.settings.compiler.version) + try: + minimum_version = self._compilers_minimum_version[str(compiler)] + if minimum_version and loose_lt_semver(version, minimum_version): + msg = ( + f"{self.ref} requires C++{self._minimum_cpp_standard} features " + f"which are not supported by compiler {compiler} {version}." + ) + raise ConanInvalidConfiguration(msg) + except KeyError: + msg = ( + f"{self.ref} recipe lacks information about the {compiler} compiler, " + f"support for the required C++{self._minimum_cpp_standard} features is assumed" + ) + self.output.warn(msg) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def build_requirements(self): + self.tool_requires("cmake/[>=3.25 <4]") + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["HICTK_BUILD_BENCHMARKS"] = "OFF" + tc.variables["HICTK_BUILD_EXAMPLES"] = "OFF" + tc.variables["HICTK_BUILD_TOOLS"] = "OFF" + tc.variables["HICTK_ENABLE_GIT_VERSION_TRACKING"] = "OFF" + tc.variables["HICTK_ENABLE_TESTING"] = "OFF" + tc.variables["HICTK_WITH_EIGEN"] = self.options.with_eigen + tc.generate() + + cmakedeps = CMakeDeps(self) + cmakedeps.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy( + self, + "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + ) + cmake = CMake(self) + cmake.install() + + rmdir(self, os.path.join(self.package_folder, "lib")) + rmdir(self, os.path.join(self.package_folder, "share")) + + def package_info(self): + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "hictk") + self.cpp_info.set_property("cmake_target_name", "hictk::libhictk") + self.cpp_info.set_property("pkg_config_name", "hictk") + + # TODO: to remove in conan v2 once legacy generators removed + self.cpp_info.names["cmake_find_package"] = "hictk" + self.cpp_info.names["cmake_find_package_multi"] = "hictk" diff --git a/recipes/hictk/all/test_package/CMakeLists.txt b/recipes/hictk/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..969fb76fe7be13 --- /dev/null +++ b/recipes/hictk/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.8) + +project(test_package LANGUAGES CXX) + +find_package(hictk REQUIRED CONFIG) + +add_executable(${CMAKE_PROJECT_NAME} test_package.cpp) +target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE hictk::libhictk) +target_compile_features(${CMAKE_PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/hictk/all/test_package/conanfile.py b/recipes/hictk/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3bfefffc36b5c4 --- /dev/null +++ b/recipes/hictk/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +import os + +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout + + +class HictkTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/hictk/all/test_package/test_package.cpp b/recipes/hictk/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..bbe13ab6a32190 --- /dev/null +++ b/recipes/hictk/all/test_package/test_package.cpp @@ -0,0 +1,8 @@ +#include +#include "hictk/fmt.hpp" +#include "hictk/cooler/utils.hpp" + + +int main(int argc, char** argv) { + fmt::print("{}\n", hictk::cooler::utils::is_cooler(argv[0])); +} diff --git a/recipes/hictk/config.yml b/recipes/hictk/config.yml new file mode 100644 index 00000000000000..f6f5b5679b9d41 --- /dev/null +++ b/recipes/hictk/config.yml @@ -0,0 +1,3 @@ +versions: + "0.0.1": + folder: all From 5a0102f41398597c046baac8a93e1a9889ca5898 Mon Sep 17 00:00:00 2001 From: Frank Schoenmann Date: Sun, 13 Aug 2023 19:30:07 +0200 Subject: [PATCH 0199/1140] (#19060) fast-cdr: add version 1.1.0 --- recipes/fast-cdr/all/conandata.yml | 3 +++ recipes/fast-cdr/all/conanfile.py | 5 +++++ recipes/fast-cdr/config.yml | 2 ++ 3 files changed, 10 insertions(+) diff --git a/recipes/fast-cdr/all/conandata.yml b/recipes/fast-cdr/all/conandata.yml index 6a9ba778684496..48019c99a16475 100644 --- a/recipes/fast-cdr/all/conandata.yml +++ b/recipes/fast-cdr/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.0": + url: "https://github.com/eProsima/Fast-CDR/archive/v1.1.0.tar.gz" + sha256: "5c4b2ad5493abd30b9475b14856641a8944c98077a36bd0760c1d83c65216e67" "1.0.27": url: "https://github.com/eProsima/Fast-CDR/archive/v1.0.27.tar.gz" sha256: "a9bc8fd31a2c2b95e6d2fb46e6ce1ad733e86dc4442f733479e33ed9cdc54bf6" diff --git a/recipes/fast-cdr/all/conanfile.py b/recipes/fast-cdr/all/conanfile.py index c39c56b44ddc4a..29f8a4528ad1d7 100644 --- a/recipes/fast-cdr/all/conanfile.py +++ b/recipes/fast-cdr/all/conanfile.py @@ -4,6 +4,7 @@ from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import collect_libs, copy, get, rm, rmdir, save from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +from conan.tools.scm import Version import os import textwrap @@ -40,6 +41,10 @@ def configure(self): def layout(self): cmake_layout(self, src_folder="src") + def build_requirements(self): + if Version(self.version) >= "1.1.0": + self.tool_requires("cmake/[>=3.16.3 <4]") + def validate(self): if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, 11) diff --git a/recipes/fast-cdr/config.yml b/recipes/fast-cdr/config.yml index 3527dfb5e8511d..c67335370b9c41 100644 --- a/recipes/fast-cdr/config.yml +++ b/recipes/fast-cdr/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.0": + folder: all "1.0.27": folder: all "1.0.26": From e8f108ac51b7b20595d32f6ea6cb926f6d3a017e Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Sun, 13 Aug 2023 20:04:42 +0200 Subject: [PATCH 0200/1140] (#19062) aws-checksums: add version 0.1.17 * aws-checksums: add version 0.1.17 * cleanup: remove test_v1_package folder * add patch_type and patch_description * Revert "cleanup: remove test_v1_package folder" This reverts commit f607f6ef718552f3022a949bdf7204e27845a5e7. --- recipes/aws-checksums/all/conandata.yml | 9 +++++++++ recipes/aws-checksums/all/conanfile.py | 6 +++++- recipes/aws-checksums/config.yml | 2 ++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/recipes/aws-checksums/all/conandata.yml b/recipes/aws-checksums/all/conandata.yml index ddf66e3fcf5ae4..989708680b889a 100644 --- a/recipes/aws-checksums/all/conandata.yml +++ b/recipes/aws-checksums/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.1.17": + url: "https://github.com/awslabs/aws-checksums/archive/v0.1.17.tar.gz" + sha256: "83c1fbae826631361a529e9565e64a942c412baaec6b705ae5da3f056b97b958" "0.1.13": url: "https://github.com/awslabs/aws-checksums/archive/v0.1.13.tar.gz" sha256: "0f897686f1963253c5069a0e495b85c31635ba146cd3ac38cc2ea31eaf54694d" @@ -14,5 +17,11 @@ sources: patches: "0.1.5": - patch_file: "patches/0001-use-PROJECT_SOURCE_DIR.patch" + patch_description: "use PROJECT_NAME instead of CMAKE_PROJECT_NAME" + patch_type: "conan" - patch_file: "patches/0002-disable-overriding-fPIC.patch" + patch_description: "disable overriding -fPIC" + patch_type: "conan" - patch_file: "patches/0003-disable-building-tests.patch" + patch_description: "build no tests" + patch_type: "conan" diff --git a/recipes/aws-checksums/all/conanfile.py b/recipes/aws-checksums/all/conanfile.py index 80a0c88a8c55b4..401b1b679aa040 100644 --- a/recipes/aws-checksums/all/conanfile.py +++ b/recipes/aws-checksums/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rmdir, save +from conan.tools.scm import Version import os import textwrap @@ -45,7 +46,10 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2") + if Version(self.version) < "0.1.17": + self.requires("aws-c-common/0.8.2") + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/aws-checksums/config.yml b/recipes/aws-checksums/config.yml index 55fedf4c307f5e..efe23bdebe7e1b 100644 --- a/recipes/aws-checksums/config.yml +++ b/recipes/aws-checksums/config.yml @@ -1,4 +1,6 @@ versions: + "0.1.17": + folder: all "0.1.13": folder: all "0.1.12": From ff506944bdda4e9bcbb800ba2c8c7f4f86d59b76 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Sun, 13 Aug 2023 20:14:30 +0200 Subject: [PATCH 0201/1140] (#19063) aws-c-sdkutils: add version 0.1.12 * aws-c-sdkutils: add version 0.1.12 * cleanup: remove test_v1_package folder * Revert "cleanup: remove test_v1_package folder" This reverts commit f1d5863bea6420124d93603037791f12b34a869c. --- recipes/aws-c-sdkutils/all/conandata.yml | 3 +++ recipes/aws-c-sdkutils/all/conanfile.py | 6 +++++- recipes/aws-c-sdkutils/config.yml | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/recipes/aws-c-sdkutils/all/conandata.yml b/recipes/aws-c-sdkutils/all/conandata.yml index 7ec4906cf9a7f3..4f2cc09884562a 100644 --- a/recipes/aws-c-sdkutils/all/conandata.yml +++ b/recipes/aws-c-sdkutils/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.1.12": + url: "https://github.com/awslabs/aws-c-sdkutils/archive/v0.1.12.tar.gz" + sha256: "c876c3ce2918f1181c24829f599c8f06e29733f0bd6556d4c4fb523390561316" "0.1.3": url: "https://github.com/awslabs/aws-c-sdkutils/archive/v0.1.3.tar.gz" sha256: "13d99c0877424a8fad40f312762968012dd54ec60a4438fb601ee65ff8b2484b" diff --git a/recipes/aws-c-sdkutils/all/conanfile.py b/recipes/aws-c-sdkutils/all/conanfile.py index f2158c8d10fa89..2312d025b2cb00 100644 --- a/recipes/aws-c-sdkutils/all/conanfile.py +++ b/recipes/aws-c-sdkutils/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import get, copy, rmdir, save +from conan.tools.scm import Version import os import textwrap @@ -39,7 +40,10 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + if Version(self.version) <= "0.1.3": + self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True, transitive_libs=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/aws-c-sdkutils/config.yml b/recipes/aws-c-sdkutils/config.yml index b2ced6f0d7ab75..c2aa05a42982f7 100644 --- a/recipes/aws-c-sdkutils/config.yml +++ b/recipes/aws-c-sdkutils/config.yml @@ -1,4 +1,6 @@ versions: + "0.1.12": + folder: all "0.1.3": folder: all "0.1.2": From 6aed7ce0bf02f685291f61d589cff9d801ab14da Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Sun, 13 Aug 2023 20:47:48 +0200 Subject: [PATCH 0202/1140] (#19067) [rtmidi/6.0.0] Add version * [rtmidi/6.0.0] Add version * Add cmake as build requirement --- recipes/rtmidi/all/conandata.yml | 3 +++ recipes/rtmidi/all/conanfile.py | 6 +++++- recipes/rtmidi/config.yml | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/recipes/rtmidi/all/conandata.yml b/recipes/rtmidi/all/conandata.yml index 53cfe6b1111673..4359539b48015b 100644 --- a/recipes/rtmidi/all/conandata.yml +++ b/recipes/rtmidi/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.0.0": + url: "https://www.music.mcgill.ca/~gary/rtmidi/release/rtmidi-6.0.0.tar.gz" + sha256: "3336248e8c1f054ea5e51a4449558490dca51edd324fcde0eea27df33b80a9ed" "5.0.0": url: "https://www.music.mcgill.ca/~gary/rtmidi/release/rtmidi-5.0.0.tar.gz" sha256: "48db0ed58c8c0e207b5d7327a0210b5bcaeb50e26387935d02829239b0f3c2b9" diff --git a/recipes/rtmidi/all/conanfile.py b/recipes/rtmidi/all/conanfile.py index a347f4bbefb6f8..ab614a8ee05fb9 100644 --- a/recipes/rtmidi/all/conanfile.py +++ b/recipes/rtmidi/all/conanfile.py @@ -48,6 +48,9 @@ def requirements(self): if self._with_alsa: self.requires("libalsa/1.2.7.2") + def build_requirements(self): + self.tool_requires("cmake/[>=3.24 <4]") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -60,7 +63,8 @@ def generate(self): def _patch_sources(self): apply_conandata_patches(self) - replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "${ALSA_LIBRARY}", "ALSA::ALSA") + if Version(self.version) < "6.0.0": + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "${ALSA_LIBRARY}", "ALSA::ALSA") def build(self): self._patch_sources() diff --git a/recipes/rtmidi/config.yml b/recipes/rtmidi/config.yml index 30e9497f54064e..f7c2ad14131bca 100644 --- a/recipes/rtmidi/config.yml +++ b/recipes/rtmidi/config.yml @@ -1,4 +1,6 @@ versions: + "6.0.0": + folder: "all" "5.0.0": folder: "all" "4.0.0": From 5454aab8ab0a1af9abaaedf32d8646aa56887319 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 04:08:28 +0900 Subject: [PATCH 0203/1140] (#19100) blend2d: add version 0.10 --- recipes/blend2d/all/conandata.yml | 7 +++++ .../0.10-0001-disable-embed-asmjit.patch | 27 +++++++++++++++++++ recipes/blend2d/config.yml | 2 ++ 3 files changed, 36 insertions(+) create mode 100644 recipes/blend2d/all/patches/0.10-0001-disable-embed-asmjit.patch diff --git a/recipes/blend2d/all/conandata.yml b/recipes/blend2d/all/conandata.yml index a8918f809e2b06..ddbc54ae6e873a 100644 --- a/recipes/blend2d/all/conandata.yml +++ b/recipes/blend2d/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.10": + url: "https://blend2d.com/download/blend2d-0.10.tar.xz" + sha256: "eaed6cc5f1fc33061a99d70cf166836994d952f75762bfacb397ee388e13ccc9" "0.9": url: "https://blend2d.com/download/blend2d-0.9.tar.xz" sha256: "a70a2a57c67017afa1067a11807fef9808788c69b4012ba4d56a5c47a5ba87c3" @@ -12,6 +15,10 @@ sources: url: "https://blend2d.com/download/blend2d-beta17.zip" sha256: "06ee8fb0bea281d09291e498900093139426501a1a7f09dba0ec801dd340635e" patches: + "0.10": + - patch_file: "patches/0.10-0001-disable-embed-asmjit.patch" + patch_description: "use asmjit cci package" + patch_type: "conan" "0.9": - patch_file: "patches/0.9-0001-disable-embed-asmjit.patch" patch_description: "use asmjit cci package" diff --git a/recipes/blend2d/all/patches/0.10-0001-disable-embed-asmjit.patch b/recipes/blend2d/all/patches/0.10-0001-disable-embed-asmjit.patch new file mode 100644 index 00000000000000..29e6457e6c6f5a --- /dev/null +++ b/recipes/blend2d/all/patches/0.10-0001-disable-embed-asmjit.patch @@ -0,0 +1,27 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 02507bc..8fa7dcf 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -392,7 +392,7 @@ endif() + + # Find asmjit dependency if building with JIT support. + if (NOT BLEND2D_NO_JIT) +- if (NOT DEFINED ASMJIT_DIR) ++ if (0) + foreach(dir "${BLEND2D_DIR}/3rdparty/asmjit" + "${CMAKE_CURRENT_LIST_DIR}/../asmjit") + if (EXISTS ${dir}/CMakeLists.txt) +@@ -410,10 +410,9 @@ if (NOT BLEND2D_NO_JIT) + endif() + + set(ASMJIT_NO_FOREIGN TRUE) +- include("${ASMJIT_DIR}/CMakeLists.txt") +- list(APPEND BLEND2D_DEPS ${ASMJIT_LIBS}) +- list(APPEND BLEND2D_PRIVATE_CFLAGS ${ASMJIT_CFLAGS}) +- list(APPEND BLEND2D_PRIVATE_CFLAGS -DASMJIT_NO_STDCXX) ++ find_package(asmjit CONFIG REQUIRED) ++ list(APPEND BLEND2D_DEPS asmjit::asmjit) ++ list(APPEND BLEND2D_PRIVATE_CFLAGS ${asmjit_DEFINITIONS_DEBUG}${asmjit_DEFINITIONS_RELEASE}) + + # A possibility to reduce the resulting binary size by disabling asmjit logging. + if (BLEND2D_NO_JIT_LOGGING) diff --git a/recipes/blend2d/config.yml b/recipes/blend2d/config.yml index bf1e95c0dd1d18..447f9c7043b58c 100644 --- a/recipes/blend2d/config.yml +++ b/recipes/blend2d/config.yml @@ -1,4 +1,6 @@ versions: + "0.10": + folder: all "0.9": folder: all "0.8": From bba042306f6f59358aec73c96b099b387bc9b2cc Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Sun, 13 Aug 2023 22:50:16 +0300 Subject: [PATCH 0204/1140] (#19110) [vulkan-loader] Bump version to 1.3.243.0 vulkan-loader and vulkan-headers should be kept in sync otherwise packages that requiere both will have problems. --- recipes/vulkan-loader/all/conandata.yml | 3 +++ recipes/vulkan-loader/all/conanfile.py | 10 +++++++--- recipes/vulkan-loader/config.yml | 2 ++ 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/recipes/vulkan-loader/all/conandata.yml b/recipes/vulkan-loader/all/conandata.yml index fceeca688d80b6..ad864b56911fdc 100644 --- a/recipes/vulkan-loader/all/conandata.yml +++ b/recipes/vulkan-loader/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.243.0": + url: "https://github.com/KhronosGroup/Vulkan-Loader/archive/refs/tags/sdk-1.3.243.0.tar.gz" + sha256: "89a09547be30491ee0a11cd7c883e78a637fb761280d6c6c2174f37188527dc3" "1.3.239.0": url: "https://github.com/KhronosGroup/Vulkan-Loader/archive/refs/tags/sdk-1.3.239.0.tar.gz" sha256: "fa2078408793b2173f174173a8784de56b6bbfbcb5fb958a07e46ef126c7eada" diff --git a/recipes/vulkan-loader/all/conanfile.py b/recipes/vulkan-loader/all/conanfile.py index 7d7adac29c32fb..d0c415a0ecae61 100644 --- a/recipes/vulkan-loader/all/conanfile.py +++ b/recipes/vulkan-loader/all/conanfile.py @@ -95,6 +95,8 @@ def build_requirements(self): self.tool_requires("pkgconf/1.9.3") if self._is_mingw: self.tool_requires("jwasm/2.13") + if Version(self.version) >= "1.3.234": + self.tool_requires("cmake/[>=3.17.2 <4.0]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -147,12 +149,14 @@ def _patch_sources(self): replace_in_file(self, cmakelists, "/WX", "") # This fix is needed due to CMAKE_FIND_PACKAGE_PREFER_CONFIG ON in CMakeToolchain (see https://github.com/conan-io/conan/issues/10387). # Indeed we want to use upstream Find modules of xcb, x11, wayland and directfb. There are properly using pkgconfig under the hood. - replace_in_file(self, cmakelists, "find_package(XCB REQUIRED)", "find_package(XCB REQUIRED MODULE)") - replace_in_file(self, cmakelists, "find_package(X11 REQUIRED)", "find_package(X11 REQUIRED MODULE)") + if Version(self.version) < "1.3.234": + replace_in_file(self, cmakelists, "find_package(XCB REQUIRED)", "find_package(XCB REQUIRED MODULE)") + replace_in_file(self, cmakelists, "find_package(X11 REQUIRED)", "find_package(X11 REQUIRED MODULE)") # find_package(Wayland REQUIRED) was removed, as it was unused if Version(self.version) < "1.3.231": replace_in_file(self, cmakelists, "find_package(Wayland REQUIRED)", "find_package(Wayland REQUIRED MODULE)") - replace_in_file(self, cmakelists, "find_package(DirectFB REQUIRED)", "find_package(DirectFB REQUIRED MODULE)") + if Version(self.version) < "1.3.234": + replace_in_file(self, cmakelists, "find_package(DirectFB REQUIRED)", "find_package(DirectFB REQUIRED MODULE)") def build(self): self._patch_sources() diff --git a/recipes/vulkan-loader/config.yml b/recipes/vulkan-loader/config.yml index 493a9fc0ba0351..3d8ee9ef8d9840 100644 --- a/recipes/vulkan-loader/config.yml +++ b/recipes/vulkan-loader/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.243.0": + folder: all "1.3.239.0": folder: all "1.3.236.0": From a9fb8ebed168897087ac27fa556d4584bf0a39b8 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 13 Aug 2023 22:47:33 +0200 Subject: [PATCH 0205/1140] (#19115) Add new recipe: libmpdclient/2.20 * add libmpdclient/2.20 * remove share folder * drop msvc shared --- recipes/libmpdclient/all/conandata.yml | 4 + recipes/libmpdclient/all/conanfile.py | 111 ++++++++++++++++++ .../all/test_package/CMakeLists.txt | 7 ++ .../all/test_package/conanfile.py | 26 ++++ .../all/test_package/test_package.c | 25 ++++ .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ recipes/libmpdclient/config.yml | 3 + 8 files changed, 201 insertions(+) create mode 100644 recipes/libmpdclient/all/conandata.yml create mode 100644 recipes/libmpdclient/all/conanfile.py create mode 100644 recipes/libmpdclient/all/test_package/CMakeLists.txt create mode 100644 recipes/libmpdclient/all/test_package/conanfile.py create mode 100644 recipes/libmpdclient/all/test_package/test_package.c create mode 100644 recipes/libmpdclient/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libmpdclient/all/test_v1_package/conanfile.py create mode 100644 recipes/libmpdclient/config.yml diff --git a/recipes/libmpdclient/all/conandata.yml b/recipes/libmpdclient/all/conandata.yml new file mode 100644 index 00000000000000..254f1016519492 --- /dev/null +++ b/recipes/libmpdclient/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "2.20": + url: "https://www.musicpd.org/download/libmpdclient/2/libmpdclient-2.20.tar.xz" + sha256: "18793f68e939c3301e34d8fcadea1f7daa24143941263cecadb80126194e277d" diff --git a/recipes/libmpdclient/all/conanfile.py b/recipes/libmpdclient/all/conanfile.py new file mode 100644 index 00000000000000..6a838ea6cdaa35 --- /dev/null +++ b/recipes/libmpdclient/all/conanfile.py @@ -0,0 +1,111 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import copy, get, rmdir +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson, MesonToolchain +from conan.tools.microsoft import is_msvc +import os + +required_conan_version = ">=1.53.0" + + +class LibmpdclientConan(ConanFile): + name = "libmpdclient" + description = "libmpdclient is a C library which implements the Music Player Daemon protocol." + license = "BSD-3-Clause" + topics = ("music", "music-player-demon", "sound") + homepage = "https://www.musicpd.org/libs/libmpdclient" + url = "https://github.com/conan-io/conan-center-index" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "default_socket": ["ANY"], + "default_host": ["ANY"], + "default_port": ["ANY"], + "tcp": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + "default_socket": "/var/run/mpd/socket", + "default_host": "localhost", + "default_port": "6600", + "tcp": True, + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + del self.options.default_socket + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + basic_layout(self, src_folder="src") + + def validate(self): + if is_msvc(self) and self.options.shared: + raise ConanInvalidConfiguration(f"{self.ref} doesn't support build of shared lib with msvc") + + def build_requirements(self): + self.tool_requires("meson/1.2.1") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + tc = MesonToolchain(self) + if self.settings.os != "Windows": + tc.project_options["default_socket"] = str(self.options.default_socket) + tc.project_options["default_host"] = str(self.options.default_host) + tc.project_options["default_port"] = str(self.options.default_port) + tc.project_options["tcp"] = self.options.tcp + tc.project_options["documentation"] = False + tc.project_options["test"] = False + tc.generate() + + def build(self): + meson = Meson(self) + meson.configure() + meson.build() + + def package(self): + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + meson = Meson(self) + meson.install() + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) + fix_apple_shared_install_name(self) + fix_msvc_libname(self) + + def package_info(self): + self.cpp_info.set_property("pkg_config_name", "libmpdclient") + self.cpp_info.libs = ["mpdclient"] + if self.settings.os == "Windows": + self.cpp_info.system_libs.append("ws2_32") + +def fix_msvc_libname(conanfile, remove_lib_prefix=True): + """remove lib prefix & change extension to .lib in case of cl like compiler""" + from conan.tools.files import rename + import glob + if not conanfile.settings.get_safe("compiler.runtime"): + return + libdirs = getattr(conanfile.cpp.package, "libdirs") + for libdir in libdirs: + for ext in [".dll.a", ".dll.lib", ".a"]: + full_folder = os.path.join(conanfile.package_folder, libdir) + for filepath in glob.glob(os.path.join(full_folder, f"*{ext}")): + libname = os.path.basename(filepath)[0:-len(ext)] + if remove_lib_prefix and libname[0:3] == "lib": + libname = libname[3:] + rename(conanfile, filepath, os.path.join(os.path.dirname(filepath), f"{libname}.lib")) diff --git a/recipes/libmpdclient/all/test_package/CMakeLists.txt b/recipes/libmpdclient/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..f00d9cb1c388cf --- /dev/null +++ b/recipes/libmpdclient/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package LANGUAGES C) + +find_package(libmpdclient CONFIG REQUIRED) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE libmpdclient::libmpdclient) diff --git a/recipes/libmpdclient/all/test_package/conanfile.py b/recipes/libmpdclient/all/test_package/conanfile.py new file mode 100644 index 00000000000000..0a6bc68712d901 --- /dev/null +++ b/recipes/libmpdclient/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libmpdclient/all/test_package/test_package.c b/recipes/libmpdclient/all/test_package/test_package.c new file mode 100644 index 00000000000000..bb53ebecfee6d6 --- /dev/null +++ b/recipes/libmpdclient/all/test_package/test_package.c @@ -0,0 +1,25 @@ +#include +#include + +#include +#include + +int main() +{ + struct mpd_connection *conn = mpd_connection_new(NULL, 0, 0); + + if (conn == NULL) { + fprintf(stderr, "Out of memory\n"); + return 1; + } + if (mpd_connection_get_error(conn) != MPD_ERROR_SUCCESS) { + fprintf(stderr, "%s\n", mpd_connection_get_error_message(conn)); + mpd_connection_free(conn); + return 0; + } + + mpd_run_next(conn); + mpd_connection_free(conn); + + return 0; +} diff --git a/recipes/libmpdclient/all/test_v1_package/CMakeLists.txt b/recipes/libmpdclient/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..0d20897301b68b --- /dev/null +++ b/recipes/libmpdclient/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/libmpdclient/all/test_v1_package/conanfile.py b/recipes/libmpdclient/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/libmpdclient/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/libmpdclient/config.yml b/recipes/libmpdclient/config.yml new file mode 100644 index 00000000000000..e36906bed874c8 --- /dev/null +++ b/recipes/libmpdclient/config.yml @@ -0,0 +1,3 @@ +versions: + "2.20": + folder: "all" From 08ae7205365c86fc7e80cd8c9aecebdc49e8643f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 14 Aug 2023 00:08:34 +0300 Subject: [PATCH 0206/1140] (#19116) cuda-samples: add new package * cuda-samples: add new package * cuda-samples: use helper_string.h for test, which is available in v10.2. --- recipes/cuda-samples/all/conandata.yml | 10 ++++ recipes/cuda-samples/all/conanfile.py | 51 +++++++++++++++++++ .../all/test_package/CMakeLists.txt | 7 +++ .../all/test_package/conanfile.py | 26 ++++++++++ .../all/test_package/test_package.cpp | 16 ++++++ recipes/cuda-samples/config.yml | 7 +++ 6 files changed, 117 insertions(+) create mode 100644 recipes/cuda-samples/all/conandata.yml create mode 100644 recipes/cuda-samples/all/conanfile.py create mode 100644 recipes/cuda-samples/all/test_package/CMakeLists.txt create mode 100644 recipes/cuda-samples/all/test_package/conanfile.py create mode 100644 recipes/cuda-samples/all/test_package/test_package.cpp create mode 100644 recipes/cuda-samples/config.yml diff --git a/recipes/cuda-samples/all/conandata.yml b/recipes/cuda-samples/all/conandata.yml new file mode 100644 index 00000000000000..0fc2e78f080c82 --- /dev/null +++ b/recipes/cuda-samples/all/conandata.yml @@ -0,0 +1,10 @@ +sources: + "12.2": + url: "https://github.com/NVIDIA/cuda-samples/archive/refs/tags/v12.2.tar.gz" + sha256: "c9fbdee420fd4567edb1239420e2a5c93d9652b4ccf3a828fcb3e0de3152e466" + "11.8": + url: "https://github.com/NVIDIA/cuda-samples/archive/refs/tags/v11.8.tar.gz" + sha256: "1bc02c0ca42a323f3c7a05b5682eae703681a91e95b135bfe81f848b2d6a2c51" + "10.2": + url: "https://github.com/NVIDIA/cuda-samples/archive/refs/tags/v10.2.tar.gz" + sha256: "f3d224dcc7028d055617360b481947c27346d87dd1ccfbdd134ab24648c084e8" diff --git a/recipes/cuda-samples/all/conanfile.py b/recipes/cuda-samples/all/conanfile.py new file mode 100644 index 00000000000000..aa2ee3b794d8a8 --- /dev/null +++ b/recipes/cuda-samples/all/conanfile.py @@ -0,0 +1,51 @@ +import os + +from conan import ConanFile +from conan.tools.files import copy, get, rmdir +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + + +class CudaSamplesConan(ConanFile): + name = "cuda-samples" + description = ("Common headers from NVIDIA CUDA Samples - " + "samples for CUDA developers which demonstrate features in CUDA Toolkit") + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/NVIDIA/cuda-samples" + topics = ("cuda", "cuda-kernels", "cuda-driver-api", "cuda-opengl", "nvcudasamples") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + # Package only headers under Common/ folder + rmdir(self, os.path.join(self.source_folder, "Samples")) + rmdir(self, os.path.join(self.source_folder, "bin")) + # Skip GL headers and precompiled libs, since these should be provided by separate Conan packages + rmdir(self, os.path.join(self.source_folder, "Common", "GL")) + rmdir(self, os.path.join(self.source_folder, "Common", "lib")) + rmdir(self, os.path.join(self.source_folder, "Common", "data")) + + def build(self): + pass + + def package(self): + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include", "Common"), + src=os.path.join(self.source_folder, "Common")) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.includedirs.append(os.path.join("include", "Common")) diff --git a/recipes/cuda-samples/all/test_package/CMakeLists.txt b/recipes/cuda-samples/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..fc3bd6fda4c9c5 --- /dev/null +++ b/recipes/cuda-samples/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(cuda-samples REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE cuda-samples::cuda-samples) diff --git a/recipes/cuda-samples/all/test_package/conanfile.py b/recipes/cuda-samples/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/cuda-samples/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cuda-samples/all/test_package/test_package.cpp b/recipes/cuda-samples/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..041e701c086ac5 --- /dev/null +++ b/recipes/cuda-samples/all/test_package/test_package.cpp @@ -0,0 +1,16 @@ +#include +#include + +// One of the few non-CUDA-specific headers in the CUDA Samples. +#include "helper_string.h" + + +int main() { + char file[] = "hello_world.jpg"; + char *ext = NULL; + getFileExtension(file, &ext); + + std::cout << "getFileExtension(\"" << file << "\") returned \"" << ext << "\"." << std::endl; + + return EXIT_SUCCESS; +} diff --git a/recipes/cuda-samples/config.yml b/recipes/cuda-samples/config.yml new file mode 100644 index 00000000000000..0cc56090a313f6 --- /dev/null +++ b/recipes/cuda-samples/config.yml @@ -0,0 +1,7 @@ +versions: + "12.2": + folder: all + "11.8": + folder: all + "10.2": + folder: all From fd48ba967c4a6f90a18b2aa89931c80ecbca06da Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 06:29:06 +0900 Subject: [PATCH 0207/1140] (#19129) daw_header_libraries: add version 2.95.0, remove older versions --- recipes/daw_header_libraries/all/conandata.yml | 18 +++--------------- recipes/daw_header_libraries/config.yml | 12 ++---------- 2 files changed, 5 insertions(+), 25 deletions(-) diff --git a/recipes/daw_header_libraries/all/conandata.yml b/recipes/daw_header_libraries/all/conandata.yml index 29376e7702ee0c..76073e7c9033b9 100644 --- a/recipes/daw_header_libraries/all/conandata.yml +++ b/recipes/daw_header_libraries/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.95.0": + url: "https://github.com/beached/header_libraries/archive/v2.95.0.tar.gz" + sha256: "8799c06f0587b202fd6049d95e70b04675acbfdbf6e86ac3bbd061cbb9d42b54" "2.93.1": url: "https://github.com/beached/header_libraries/archive/v2.93.1.tar.gz" sha256: "200690094237e4a2c37ac81c23c8c5138ba90ccdeeb2a1dda37690a9d32301ad" @@ -23,18 +26,3 @@ sources: "2.74.2": url: "https://github.com/beached/header_libraries/archive/v2.74.2.tar.gz" sha256: "32871df3d314cc9b4e293a9a8c79968d1c963dfd3dd60965dbf704eb18acb218" - "2.73.1": - url: "https://github.com/beached/header_libraries/archive/v2.73.1.tar.gz" - sha256: "62bd26398afa7eba1aae7bbbf107865044b8be0539d266085c36aed82557ae07" - "2.72.0": - url: "https://github.com/beached/header_libraries/archive/v2.72.0.tar.gz" - sha256: "f681755183af4af35f4741f3bcb7d99c6707911806e39e3acc982f9532aacc08" - "2.71.0": - url: "https://github.com/beached/header_libraries/archive/v2.71.0.tar.gz" - sha256: "50b9ddebdbc808a5714408a45f686fafe9d1d3b78c988df3973c12c9928828b9" - "2.68.3": - url: "https://github.com/beached/header_libraries/archive/v2.68.3.tar.gz" - sha256: "9bb7d25d161b89ad4a0ac857c28734c061cf53f6e80212c7fe70b8e0fd14789f" - "1.29.7": - url: "https://github.com/beached/header_libraries/archive/refs/tags/v1.29.7.tar.gz" - sha256: "524c34f3f5d2af498e7bcaff7802b914ba42acde29f7e3ecce41a035db0bf5bd" diff --git a/recipes/daw_header_libraries/config.yml b/recipes/daw_header_libraries/config.yml index 1983a1c07c0153..6a27257347e52a 100644 --- a/recipes/daw_header_libraries/config.yml +++ b/recipes/daw_header_libraries/config.yml @@ -1,4 +1,6 @@ versions: + "2.95.0": + folder: all "2.93.1": folder: all "2.92.0": @@ -15,13 +17,3 @@ versions: folder: all "2.74.2": folder: all - "2.73.1": - folder: all - "2.72.0": - folder: all - "2.71.0": - folder: all - "2.68.3": - folder: all - "1.29.7": - folder: all From 8e798f632fbe4f88bc4a489cb7488e09aba21b2e Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 06:49:33 +0900 Subject: [PATCH 0208/1140] (#19131) capnproto: add version 1.0.0 * capnproto: add version 1.0.0 * add patch descriptions * drop support gcc 5, 6 * link math lib * drop support MSVC Release build --- recipes/capnproto/all/conandata.yml | 80 ++++++-- recipes/capnproto/all/conanfile.py | 12 +- .../0015-disable-tests-for-1.0.0.patch | 176 ++++++++++++++++++ recipes/capnproto/config.yml | 2 + 4 files changed, 249 insertions(+), 21 deletions(-) create mode 100644 recipes/capnproto/all/patches/0015-disable-tests-for-1.0.0.patch diff --git a/recipes/capnproto/all/conandata.yml b/recipes/capnproto/all/conandata.yml index 9becf4a51dc853..64808b6c7cee44 100644 --- a/recipes/capnproto/all/conandata.yml +++ b/recipes/capnproto/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.0": + url: "https://github.com/capnproto/capnproto/archive/v1.0.0.tar.gz" + sha256: "bcd44dde78055313a7786cb6ab020cbef19b9045b53857f90cce101c9453f715" "0.10.4": url: "https://github.com/capnproto/capnproto/archive/v0.10.4.tar.gz" sha256: "c6f25940688c87ddb24e0c4e475c3213d9b044aad2ba305439cc8c224f559da6" @@ -19,28 +22,71 @@ sources: sha256: "6d8b43a7ec2a764b4dfe4139a7cdd070ad9057f106898050d9f4db3754b98820" "0.7.0": url: "https://github.com/capnproto/capnproto/archive/v0.7.0.tar.gz" - sha256: 76c7114a3d142ad08b7208b3964a26e72a6320ee81331d3f0b87569fc9c47a28 + sha256: "76c7114a3d142ad08b7208b3964a26e72a6320ee81331d3f0b87569fc9c47a28" patches: + "1.0.0": + - patch_file: "patches/0015-disable-tests-for-1.0.0.patch" + patch_description: "disable test build" + patch_type: "conan" "0.10.4": - - patch_file: patches/0014-disable-tests-for-0.10.1.patch + - patch_file: "patches/0014-disable-tests-for-0.10.1.patch" + patch_description: "disable test build" + patch_type: "conan" "0.10.3": - - patch_file: patches/0014-disable-tests-for-0.10.1.patch + - patch_file: "patches/0014-disable-tests-for-0.10.1.patch" + patch_description: "disable test build" + patch_type: "conan" "0.10.1": - - patch_file: patches/0014-disable-tests-for-0.10.1.patch + - patch_file: "patches/0014-disable-tests-for-0.10.1.patch" + patch_description: "disable test build" + patch_type: "conan" "0.10.0": - - patch_file: patches/0013-disable-tests-for-0.10.0.patch + - patch_file: "patches/0013-disable-tests-for-0.10.0.patch" + patch_description: "disable test build" + patch_type: "conan" "0.9.1": - - patch_file: patches/0010-disable-tests-for-0.9.1.patch - - patch_file: patches/0011-msvc-cpp17-hassubstring-fix-0.9.1.patch - - patch_file: patches/0012-msvc-nogdi-fix-0.9.1.patch + - patch_file: "patches/0010-disable-tests-for-0.9.1.patch" + patch_description: "disable test build" + patch_type: "conan" + - patch_file: "patches/0011-msvc-cpp17-hassubstring-fix-0.9.1.patch" + patch_description: "fix compilation errors on Windows Clang" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/pull/1344" + - patch_file: "patches/0012-msvc-nogdi-fix-0.9.1.patch" + patch_description: "fix compilation error on Windows" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/issues/1421" "0.8.0": - - patch_file: patches/0001-disable-tests.patch - - patch_file: patches/0002-cmake-compat-header-install.patch - - patch_file: patches/0003-kj-tls-windows.patch - - patch_file: patches/0004-cmake-module-path.patch - - patch_file: patches/0005-msvc-16.7-ice-workaround.patch - - patch_file: patches/0009-windows-symlink-fix-0.8.0.patch + - patch_file: "patches/0001-disable-tests.patch" + patch_description: "disable test build" + patch_type: "conan" + - patch_file: "patches/0002-cmake-compat-header-install.patch" + patch_description: "fix compilation error for std::copy with list types" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/pull/895" + - patch_file: "patches/0003-kj-tls-windows.patch" + patch_description: "add kj-tls target" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/commit/7da6abf233fdf74a4ad4db56b6e98778b162dd7d" + - patch_file: "patches/0004-cmake-module-path.patch" + patch_description: "append cmake module path instead set" + patch_type: "conan" + - patch_file: "patches/0005-msvc-16.7-ice-workaround.patch" + patch_description: "Workaround for internal compiler error with msvc 16.7.x" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/pull/1058" + - patch_file: "patches/0009-windows-symlink-fix-0.8.0.patch" + patch_description: "orkaround for install step on Windows where symlinks might be not supported." + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/pull/1240" "0.7.0": - - patch_file: patches/0006-symlink.patch - - patch_file: patches/0007-cmake-module-path.patch - - patch_file: patches/0008-disable-tests.patch + - patch_file: "patches/0006-symlink.patch" + patch_description: "Fix capnpc extension handling on Windows" + patch_type: "portability" + patch_source: "https://github.com/capnproto/capnproto/pull/804" + - patch_file: "patches/0007-cmake-module-path.patch" + patch_description: "append cmake module path instead set" + patch_type: "conan" + - patch_file: "patches/0008-disable-tests.patch" + patch_description: "disable test build" + patch_type: "conan" diff --git a/recipes/capnproto/all/conanfile.py b/recipes/capnproto/all/conanfile.py index f101073a53368f..72462e3198e714 100644 --- a/recipes/capnproto/all/conanfile.py +++ b/recipes/capnproto/all/conanfile.py @@ -47,7 +47,7 @@ def _minimum_compilers_version(self): return { "Visual Studio": "15", "msvc": "191", - "gcc": "5", + "gcc": "5" if Version(self.version) < "1.0.0" else "7", "clang": "5", "apple-clang": "5.1", } @@ -93,6 +93,10 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} doesn't support shared libraries for Visual Studio") if self.settings.os == "Windows" and Version(self.version) < "0.8.0" and self.options.with_openssl: raise ConanInvalidConfiguration(f"{self.ref} doesn't support OpenSSL on Windows pre 0.8.0") + # MSVC Release build is not supported in 1.0.0 + # https://github.com/capnproto/capnproto/issues/1740 + if Version(self.version) == "1.0.0" and is_msvc(self) and self.settings.build_type == "Release": + raise ConanInvalidConfiguration(f"{self.ref} doesn't support MSVC Release build") def build_requirements(self): if self.settings.os != "Windows": @@ -218,9 +222,9 @@ def package_info(self): self._register_component(component) if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["capnpc"].system_libs = ["pthread"] - self.cpp_info.components["kj"].system_libs = ["pthread"] - self.cpp_info.components["kj-async"].system_libs = ["pthread"] + self.cpp_info.components["capnpc"].system_libs = ["pthread", "m"] + self.cpp_info.components["kj"].system_libs = ["pthread", "m"] + self.cpp_info.components["kj-async"].system_libs = ["pthread", "m"] elif self.settings.os == "Windows": self.cpp_info.components["kj-async"].system_libs = ["ws2_32"] diff --git a/recipes/capnproto/all/patches/0015-disable-tests-for-1.0.0.patch b/recipes/capnproto/all/patches/0015-disable-tests-for-1.0.0.patch new file mode 100644 index 00000000000000..38c9dd1ee414b4 --- /dev/null +++ b/recipes/capnproto/all/patches/0015-disable-tests-for-1.0.0.patch @@ -0,0 +1,176 @@ +diff --git a/c++/Makefile.am b/c++/Makefile.am +index 1567491..95ebc4a 100644 +--- a/c++/Makefile.am ++++ b/c++/Makefile.am +@@ -457,171 +457,4 @@ endif LITE_MODE + # src/capnp/benchmark/... + # src/capnp/compiler/... + +-# Tests ============================================================== +- +-test_capnpc_inputs = \ +- src/capnp/test.capnp \ +- src/capnp/test-import.capnp \ +- src/capnp/test-import2.capnp \ +- src/capnp/compat/json-test.capnp +- +-test_capnpc_outputs = \ +- src/capnp/test.capnp.c++ \ +- src/capnp/test.capnp.h \ +- src/capnp/test-import.capnp.c++ \ +- src/capnp/test-import.capnp.h \ +- src/capnp/test-import2.capnp.c++ \ +- src/capnp/test-import2.capnp.h \ +- src/capnp/compat/json-test.capnp.c++ \ +- src/capnp/compat/json-test.capnp.h +- +-if USE_EXTERNAL_CAPNP +- +-test_capnpc_middleman: $(test_capnpc_inputs) +- @$(MKDIR_P) src +- $(CAPNP) compile --src-prefix=$(srcdir)/src -o$(CAPNPC_CXX):src -I$(srcdir)/src $$(for FILE in $(test_capnpc_inputs); do echo $(srcdir)/$$FILE; done) +- touch test_capnpc_middleman + +-else +- +-test_capnpc_middleman: capnp$(EXEEXT) capnpc-c++$(EXEEXT) $(test_capnpc_inputs) +- @$(MKDIR_P) src +- ./capnp$(EXEEXT) compile --src-prefix=$(srcdir)/src -o./capnpc-c++$(EXEEXT):src -I$(srcdir)/src $$(for FILE in $(test_capnpc_inputs); do echo $(srcdir)/$$FILE; done) +- touch test_capnpc_middleman +- +-endif +- +-$(test_capnpc_outputs): test_capnpc_middleman +- +-BUILT_SOURCES = $(test_capnpc_outputs) +- +-check_LIBRARIES = libcapnp-test.a +-libcapnp_test_a_SOURCES = \ +- src/capnp/test-util.c++ \ +- src/capnp/test-util.h +-nodist_libcapnp_test_a_SOURCES = $(test_capnpc_outputs) +- +-if LITE_MODE +- +-check_PROGRAMS = capnp-test +-compiler_tests = +-capnp_test_LDADD = libcapnp-test.a libcapnp.la libkj-test.la libkj.la +- +-else !LITE_MODE +- +-check_PROGRAMS = capnp-test capnp-evolution-test capnp-afl-testcase +-if HAS_FUZZING_ENGINE +- check_PROGRAMS += capnp-llvm-fuzzer-testcase +-endif +-heavy_tests = \ +- src/kj/async-test.c++ \ +- src/kj/async-xthread-test.c++ \ +- src/kj/async-coroutine-test.c++ \ +- src/kj/async-unix-test.c++ \ +- src/kj/async-unix-xthread-test.c++ \ +- src/kj/async-win32-test.c++ \ +- src/kj/async-win32-xthread-test.c++ \ +- src/kj/async-io-test.c++ \ +- src/kj/async-queue-test.c++ \ +- src/kj/parse/common-test.c++ \ +- src/kj/parse/char-test.c++ \ +- src/kj/std/iostream-test.c++ \ +- src/kj/compat/url-test.c++ \ +- src/kj/compat/http-test.c++ \ +- $(MAYBE_KJ_GZIP_TESTS) \ +- $(MAYBE_KJ_TLS_TESTS) \ +- src/capnp/canonicalize-test.c++ \ +- src/capnp/capability-test.c++ \ +- src/capnp/membrane-test.c++ \ +- src/capnp/schema-test.c++ \ +- src/capnp/schema-loader-test.c++ \ +- src/capnp/schema-parser-test.c++ \ +- src/capnp/dynamic-test.c++ \ +- src/capnp/stringify-test.c++ \ +- src/capnp/serialize-async-test.c++ \ +- src/capnp/serialize-text-test.c++ \ +- src/capnp/rpc-test.c++ \ +- src/capnp/rpc-twoparty-test.c++ \ +- src/capnp/ez-rpc-test.c++ \ +- src/capnp/compat/json-test.c++ \ +- src/capnp/compat/websocket-rpc-test.c++ \ +- src/capnp/compiler/lexer-test.c++ \ +- src/capnp/compiler/type-id-test.c++ +-capnp_test_LDADD = \ +- libcapnp-test.a \ +- libcapnpc.la \ +- libcapnp-rpc.la \ +- libcapnp-websocket.la \ +- libcapnp-json.la \ +- libcapnp.la \ +- libkj-http.la \ +- $(MAYBE_KJ_GZIP_LA) \ +- $(MAYBE_KJ_TLS_LA) \ +- libkj-async.la \ +- libkj-test.la \ +- libkj.la \ +- $(ASYNC_LIBS) \ +- $(PTHREAD_LIBS) +- +-endif !LITE_MODE +- +-capnp_test_CPPFLAGS = -Wno-deprecated-declarations +-capnp_test_SOURCES = \ +- src/kj/common-test.c++ \ +- src/kj/memory-test.c++ \ +- src/kj/refcount-test.c++ \ +- src/kj/array-test.c++ \ +- src/kj/list-test.c++ \ +- src/kj/string-test.c++ \ +- src/kj/string-tree-test.c++ \ +- src/kj/table-test.c++ \ +- src/kj/map-test.c++ \ +- src/kj/encoding-test.c++ \ +- src/kj/exception-test.c++ \ +- src/kj/debug-test.c++ \ +- src/kj/arena-test.c++ \ +- src/kj/units-test.c++ \ +- src/kj/tuple-test.c++ \ +- src/kj/one-of-test.c++ \ +- src/kj/function-test.c++ \ +- src/kj/io-test.c++ \ +- src/kj/mutex-test.c++ \ +- src/kj/time-test.c++ \ +- src/kj/threadlocal-test.c++ \ +- src/kj/filesystem-test.c++ \ +- src/kj/filesystem-disk-test.c++ \ +- src/kj/test-test.c++ \ +- src/capnp/common-test.c++ \ +- src/capnp/blob-test.c++ \ +- src/capnp/endian-test.c++ \ +- src/capnp/endian-fallback-test.c++ \ +- src/capnp/endian-reverse-test.c++ \ +- src/capnp/layout-test.c++ \ +- src/capnp/any-test.c++ \ +- src/capnp/message-test.c++ \ +- src/capnp/encoding-test.c++ \ +- src/capnp/orphan-test.c++ \ +- src/capnp/serialize-test.c++ \ +- src/capnp/serialize-packed-test.c++ \ +- src/capnp/fuzz-test.c++ \ +- $(heavy_tests) +- +-if !LITE_MODE +-capnp_evolution_test_LDADD = libcapnpc.la libcapnp.la libkj.la +-capnp_evolution_test_SOURCES = src/capnp/compiler/evolution-test.c++ +- +-capnp_afl_testcase_LDADD = libcapnp-test.a libcapnp-rpc.la libcapnp.la libkj.la libkj-async.la +-capnp_afl_testcase_SOURCES = src/capnp/afl-testcase.c++ +- +-if HAS_FUZZING_ENGINE +- capnp_llvm_fuzzer_testcase_LDADD = libcapnp-test.a libcapnp-rpc.la libcapnp.la libkj.la libkj-async.la +- capnp_llvm_fuzzer_testcase_SOURCES = src/capnp/llvm-fuzzer-testcase.c++ +- capnp_llvm_fuzzer_testcase_LDFLAGS = $(LIB_FUZZING_ENGINE) +-endif +-endif !LITE_MODE +- +-if LITE_MODE +-TESTS = capnp-test +-else !LITE_MODE +-TESTS = capnp-test capnp-evolution-test src/capnp/compiler/capnp-test.sh +-endif !LITE_MODE diff --git a/recipes/capnproto/config.yml b/recipes/capnproto/config.yml index 884c84c332e24d..fe4f6cbbb70b3f 100644 --- a/recipes/capnproto/config.yml +++ b/recipes/capnproto/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.0": + folder: all "0.10.4": folder: all "0.10.3": From e9cb930aba4ff34985ba0193fb8f690e0d4d4455 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Mon, 14 Aug 2023 00:28:07 +0200 Subject: [PATCH 0209/1140] (#19140) [bandit] Add transitive headers for snowhouse * [bandit] Add transitive headers for snowhouse * Fix linters issues --- recipes/bandit/all/conanfile.py | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/recipes/bandit/all/conanfile.py b/recipes/bandit/all/conanfile.py index 31fd2c6978fa44..5bc2e2513915d3 100644 --- a/recipes/bandit/all/conanfile.py +++ b/recipes/bandit/all/conanfile.py @@ -1,39 +1,41 @@ from conan import ConanFile -from conan.tools.files import apply_conandata_patches, copy, get +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.layout import basic_layout import os -required_conan_version = ">=1.51.3" +required_conan_version = ">=1.52.0" class BanditConan(ConanFile): name = "bandit" description = "Human-friendly unit testing for C++11" - topics = ("testing", "header-only") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/banditcpp/bandit" - license = "MIT" + topics = ("testing", "header-only") + package_type = "header-library" def export_sources(self): - for p in self.conan_data.get("patches", {}).get(self.version, []): - copy(self, p["patch_file"], self.recipe_folder, self.export_sources_folder) + export_conandata_patches(self) def requirements(self): - self.requires("snowhouse/5.0.0") + self.requires("snowhouse/5.0.0", transitive_headers=True) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def layout(self): - basic_layout(self) + basic_layout(self, src_folder="src") def build(self): apply_conandata_patches(self) def package(self): copy(self, "LICENSE.txt", src=os.path.join(self.source_folder, "docs"), dst=os.path.join(self.package_folder, "licenses")) - copy(self, pattern="*", dst=os.path.join(self.package_folder, "include", "bandit"), src=os.path.join(self.source_folder, "bandit")) + copy(self, + pattern="*.h", + dst=os.path.join(self.package_folder, "include", "bandit"), + src=os.path.join(self.source_folder, "bandit")) def package_id(self): self.info.clear() @@ -43,4 +45,3 @@ def package_info(self): self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] self.cpp_info.resdirs = [] - From ac67b6e2e37fd8df29a66b8534793836bd62336a Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 07:49:13 +0900 Subject: [PATCH 0210/1140] (#19144) bzip3: add version 1.3.2, remove older versions * bzip3: add version 1.3.2, remove older versions * remove unused import --- recipes/bzip3/all/conandata.yml | 30 +++--------------------------- recipes/bzip3/all/conanfile.py | 4 +--- recipes/bzip3/config.yml | 10 ++-------- 3 files changed, 6 insertions(+), 38 deletions(-) diff --git a/recipes/bzip3/all/conandata.yml b/recipes/bzip3/all/conandata.yml index 0de00365a28f1a..e5219a4ddad454 100644 --- a/recipes/bzip3/all/conandata.yml +++ b/recipes/bzip3/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.2": + url: "https://github.com/kspalaiologos/bzip3/releases/download/1.3.2/bzip3-1.3.2.tar.xz" + sha256: "b1d04b8b1b89a3c490cf2b89ea8cee1281584b07f25276fcfd8d40ec2c488e94" "1.3.1": url: "https://github.com/kspalaiologos/bzip3/releases/download/1.3.1/bzip3-1.3.1.tar.xz" sha256: "b023c261307ff4e0e64935ea32bba0216377fd8fc2fd19ba86509a32cbb8a35a" @@ -20,30 +23,3 @@ sources: "1.1.8": url: "https://github.com/kspalaiologos/bzip3/releases/download/1.1.8/bzip3-1.1.8.tar.bz2" sha256: "bc15d0e4599aad18d9ed71ee0f7e859af89051bf5105b0751e8ca3a26117567d" - "1.1.7": - url: "https://github.com/kspalaiologos/bzip3/releases/download/1.1.7/bzip3-1.1.7.tar.bz2" - sha256: "1f74768dd1a76c45417f84779cc04d8d8b1f595ac564a2ea2aeb0248defca803" - "1.1.6": - url: "https://github.com/kspalaiologos/bzip3/releases/download/1.1.6/bzip3-1.1.6.tar.bz2" - sha256: "2bfd35dd57ab80b35b25e3ad628e0ff8f1f5e6dea02a8d472914823ea2e07e96" - "1.1.5": - url: "https://github.com/kspalaiologos/bzip3/releases/download/1.1.5/bzip3-1.1.5.tar.bz2" - sha256: "2f5012b0004b6c23d5f606deed9191fdce44849234edbcf26e0316bf7856d114" - "1.1.4": - url: "https://github.com/kspalaiologos/bzip3/releases/download/1.1.4/bzip3-1.1.4.tar.bz2" - sha256: "e23a06ae17fc36192e79d0151950b3bbd4e26381af50ba4b4fd7a2d9797e498f" -patches: - "1.1.5": - - patch_file: "patches/1.1.5-0002-export-symbols.patch" - patch_description: "fix hidden public symbols on shard build" - patch_type: "portability" - patch_source: "https://github.com/kspalaiologos/bzip3/issues/46" - "1.1.4": - - patch_file: "patches/1.1.4-0001-make-restrict-alias.patch" - patch_description: "make restrict alias" - patch_type: "portability" - patch_source: "https://github.com/kspalaiologos/bzip3/commit/c5bba99d1a655a177eef9aeb71207326929c66d9" - - patch_file: "patches/1.1.4-0002-export-symbols.patch" - patch_description: "fix hidden public symbols on shard build" - patch_type: "portability" - patch_source: "https://github.com/kspalaiologos/bzip3/issues/46" diff --git a/recipes/bzip3/all/conanfile.py b/recipes/bzip3/all/conanfile.py index 484c139e122f38..2102c952e4cf1c 100644 --- a/recipes/bzip3/all/conanfile.py +++ b/recipes/bzip3/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import export_conandata_patches, apply_conandata_patches, copy, get +from conan.tools.files import copy, get import os required_conan_version = ">=1.53.0" @@ -30,7 +30,6 @@ class BZip3Conan(ConanFile): def export_sources(self): copy(self, "CMakeLists.txt", self.recipe_folder, self.export_sources_folder) - export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -62,7 +61,6 @@ def generate(self): tc.generate() def build(self): - apply_conandata_patches(self) cmake = CMake(self) cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) cmake.build() diff --git a/recipes/bzip3/config.yml b/recipes/bzip3/config.yml index 014fd9d9039685..b6e0a161eb7bfe 100644 --- a/recipes/bzip3/config.yml +++ b/recipes/bzip3/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.2": + folder: all "1.3.1": folder: all "1.3.0": @@ -13,11 +15,3 @@ versions: folder: all "1.1.8": folder: all - "1.1.7": - folder: all - "1.1.6": - folder: all - "1.1.5": - folder: all - "1.1.4": - folder: all From 01752343eeb196ed114bb3acc6588fa4a70a8e48 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Mon, 14 Aug 2023 11:08:26 +0300 Subject: [PATCH 0211/1140] (#19183) args-parser: bump version --- recipes/args-parser/all/conandata.yml | 3 +++ recipes/args-parser/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/args-parser/all/conandata.yml b/recipes/args-parser/all/conandata.yml index 787c510a62b539..427c4c05d81dda 100644 --- a/recipes/args-parser/all/conandata.yml +++ b/recipes/args-parser/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.3.3": + url: "https://github.com/igormironchik/args-parser/archive/refs/tags/6.3.3.tar.gz" + sha256: "67867d7ab624a8c2f391230c54c37830e6127f7f5c716ff634165f674d876b64" "6.3.2": url: "https://github.com/igormironchik/args-parser/archive/refs/tags/6.3.2.tar.gz" sha256: "cd89549a9f5b5cfd16db2f8b9c93fd164cea334147c58890d5322365789e05e5" diff --git a/recipes/args-parser/config.yml b/recipes/args-parser/config.yml index 08a70490fa0abe..b67bad0e21e0f9 100644 --- a/recipes/args-parser/config.yml +++ b/recipes/args-parser/config.yml @@ -1,4 +1,6 @@ versions: + "6.3.3": + folder: all "6.3.2": folder: all "6.3.1": From 07b8de14d66d6acac4b09bae08e95f5aa4ebbbae Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 14 Aug 2023 10:59:36 +0200 Subject: [PATCH 0212/1140] Add new Conan v2-ready references (#19184) --- .c3i/conan_v2_ready_references.yml | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 2158d3f771f43f..f8823a111ab285 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -41,6 +41,7 @@ required_for_references: - asio - asio-grpc - asmjit +- assimp - astc-codec - astro-informatics-so3 - async_simple @@ -70,6 +71,7 @@ required_for_references: - backward-cpp - bacnet-stack - baical-p7 +- bandit - base64 - bazel - bdwgc @@ -205,6 +207,7 @@ required_for_references: - cubicinterpolation - cuda-api-wrappers - cuda-kat +- cuda-samples - cunit - cute_headers - cvplot @@ -230,6 +233,7 @@ required_for_references: - dice-template-library - dirent - discount +- djinni-generator - dlpack - docopt.cpp - doctest @@ -242,6 +246,7 @@ required_for_references: - drmp3 - drogon - drwav +- dtl - duckdb - eabase - earcut @@ -267,6 +272,7 @@ required_for_references: - enum-flags - erikzenker-hsm - erkir +- etc2comp - eternal - etl - exiv2 @@ -307,6 +313,7 @@ required_for_references: - foxglove-schemas-protobuf - foxi - fp16 +- fpzip - freeglut - freeimage - freetype @@ -317,6 +324,7 @@ required_for_references: - ftxui - function2 - functionalplus +- fusepp - fxdiv - g3log - gainput @@ -389,6 +397,7 @@ required_for_references: - heatshrink - hedley - hffix +- hictk - hidapi - highfive - highs @@ -399,6 +408,7 @@ required_for_references: - hlslpp - homog2d - http_parser +- hunspell - hwloc - icecream-cpp - icu @@ -410,6 +420,7 @@ required_for_references: - imgui - imguizmo - implot +- imutils-cpp - incbin - indicators - indirect_value @@ -544,6 +555,7 @@ required_for_references: - libmorton - libmount - libmp3lame +- libmpdclient - libmysqlclient - libnabo - libnet @@ -569,6 +581,7 @@ required_for_references: - librealsense - libressl - librttopo +- libsafec - libsamplerate - libschrift - libsecret @@ -711,6 +724,7 @@ required_for_references: - mppp - ms-gsl - msdf-atlas-gen +- msdfgen - msgpack-c - msgpack-cxx - msys2 @@ -736,6 +750,7 @@ required_for_references: - nlohmann_json - nlopt - nmea +- nmslib - nng - nodejs - norm @@ -774,6 +789,7 @@ required_for_references: - openddl-parser - openexr - openfbx +- openfst - openfx - opengl - opengl-registry @@ -859,6 +875,7 @@ required_for_references: - pthreads4w - pugixml - pulseaudio +- pupnp - pybind11 - pybind11_json - pystring @@ -909,6 +926,7 @@ required_for_references: - rtmidi - rttr - ruy +- rvo2 - rxcpp - s2n - safeint @@ -1048,6 +1066,7 @@ required_for_references: - upx - uriparser - usockets +- usrsctp - utf8proc - utfcpp - util-linux-libuuid From b9ae7dabcc2a39779feaa0ec7f0fae0cd4b1b8b1 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 14 Aug 2023 11:23:19 +0200 Subject: [PATCH 0213/1140] (#19176) [bot] Update list of references (prod-v2/ListPackages) From c36b516eab85b345af0180743eecd8ec75b23db6 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 20:30:26 +0900 Subject: [PATCH 0214/1140] (#19169) fmt: add version 10.1.0 --- recipes/fmt/all/conandata.yml | 3 +++ recipes/fmt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/fmt/all/conandata.yml b/recipes/fmt/all/conandata.yml index 2125f36949279c..0ab235a8e96faf 100644 --- a/recipes/fmt/all/conandata.yml +++ b/recipes/fmt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "10.1.0": + url: "https://github.com/fmtlib/fmt/releases/download/10.1.0/fmt-10.1.0.zip" + sha256: "d725fa83a8b57a3cedf238828fa6b167f963041e8f9f7327649bddc68ae316f4" "10.0.0": url: "https://github.com/fmtlib/fmt/releases/download/10.0.0/fmt-10.0.0.zip" sha256: "4943cb165f3f587f26da834d3056ee8733c397e024145ca7d2a8a96bb71ac281" diff --git a/recipes/fmt/config.yml b/recipes/fmt/config.yml index 44e12e4e3ddc72..94b218a3040259 100644 --- a/recipes/fmt/config.yml +++ b/recipes/fmt/config.yml @@ -1,4 +1,6 @@ versions: + "10.1.0": + folder: all "10.0.0": folder: all "9.1.0": From 27b1d23c14ad209a03aa6f52b69d80e7b251ecff Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 14 Aug 2023 14:54:39 +0200 Subject: [PATCH 0215/1140] osgearth/all: bump deps (#18500) * osgearth/all: bump deps * fix linter error * override libpng version * remove openssl override * bump libcurl --------- Co-authored-by: Carlos Zoido --- recipes/osgearth/all/conanfile.py | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/recipes/osgearth/all/conanfile.py b/recipes/osgearth/all/conanfile.py index 5e59c1a6652d93..611835c64bf484 100644 --- a/recipes/osgearth/all/conanfile.py +++ b/recipes/osgearth/all/conanfile.py @@ -105,13 +105,13 @@ def requirements(self): self.requires("opengl/system") self.requires("gdal/3.4.3") self.requires("openscenegraph/3.6.5") - self.requires("libcurl/7.83.1") + self.requires("libcurl/8.2.0") self.requires("lerc/2.2") self.requires("rapidjson/1.1.0") - self.requires("zlib/1.2.12", override=True) - self.requires("libtiff/4.3.0", override=True) - self.requires("openssl/1.1.1l", override=True) + self.requires("zlib/1.2.13") # override + self.requires("libtiff/4.5.1") # override + self.requires("libpng/1.6.40") # override # if self.options.build_triton_nodekit: # self.requires("triton_nodekit") @@ -122,11 +122,11 @@ def requirements(self): if self.options.build_rocksdb_cache: self.requires("rocksdb/6.20.3") if self.options.build_zip_plugin: - self.requires("zstd/1.4.9") # override + self.requires("zstd/1.5.5") # override if self.options.with_geos: - self.requires("geos/3.10.2") + self.requires("geos/3.11.1") if self.options.with_sqlite3: - self.requires("sqlite3/3.38.5") + self.requires("sqlite3/3.42.0") if self.options.with_draco: self.requires("draco/1.4.3") # if self.options.with_basisu: @@ -134,9 +134,9 @@ def requirements(self): # if self.options.with_glew: # self.requires("glew/2.2.0") if self.options.with_protobuf: - self.requires("protobuf/3.17.1") + self.requires("protobuf/3.21.9") if self.options.with_webp: - self.requires("libwebp/1.2.0") + self.requires("libwebp/1.3.1") def _patch_sources(self): for patch in self.conan_data.get("patches", {}).get(self.version, []): From 8ea2f3a855477a90b8519354e34c93b97bab39af Mon Sep 17 00:00:00 2001 From: Chris Mc Date: Mon, 14 Aug 2023 06:06:56 -0700 Subject: [PATCH 0216/1140] Fix link to CLA (#19007) --- CONTRIBUTING.md | 2 +- docs/CONTRIBUTOR_LICENSE_AGREEMENT.md | 23 ----------------------- docs/adding_packages/README.md | 2 +- docs/review_process.md | 2 +- 4 files changed, 3 insertions(+), 26 deletions(-) delete mode 100644 docs/CONTRIBUTOR_LICENSE_AGREEMENT.md diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index e3e7f52de2da86..6e24832e93e988 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -23,7 +23,7 @@ To contribute follow the next steps: 1. Comment in the corresponding issue that you want to contribute the package/fix proposed. If there is no open issue, we strongly suggest opening one to gather feedback. -2. Make sure to [request access](docs/adding_packages/README.md#request-access) and be aware there is a [CLA](docs/CONTRIBUTOR_LICENSE_AGREEMENT.md). +2. Make sure to [request access](docs/adding_packages/README.md#request-access) and be aware there is a [contributor licenses agreement](https://cla-assistant.io/conan-io/conan-center-index). 3. Get setup by following the [Developing Recipes](docs/developing_recipes_locally.md) guide and learn the basic commands. 4. Check the [How To Add Packages](docs/adding_packages/README.md) page for the break down of ConanCenterIndex specific conventions and practices. 5. In your fork create a `package/xxx` branch from the `master` branch and develop diff --git a/docs/CONTRIBUTOR_LICENSE_AGREEMENT.md b/docs/CONTRIBUTOR_LICENSE_AGREEMENT.md deleted file mode 100644 index 39acf20a7aebd5..00000000000000 --- a/docs/CONTRIBUTOR_LICENSE_AGREEMENT.md +++ /dev/null @@ -1,23 +0,0 @@ -Conan-Center-Index project Contributor License Agreement --------------------------------------------------------- - -The following terms are used throughout this agreement: - -- You - the person or legal entity including its affiliates asked to accept this agreement. An affiliate is any entity that controls or is controlled by the legal entity, or is under common control with it. -- Contribution - any type of work that is submitted to the repository, including any modifications or additions to existing work. -- Project - Conan-Center-Index project (https://github.com/conan-io/conan-center-index) -- Submitted - conveyed to a Project via a pull request, commit, issue, or any form of electronic, written, or verbal communication with the copyright owner, contributors or maintainers. - -1. Grant of Copyright License. - - Subject to the terms and conditions of this agreement, You grant to JFrog LTD, a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable copyright license to reproduce, prepare derivative works of, publicly display, publicly perform, sublicense, and distribute your contributions and such derivative works. - -2. Grant of Patent License. - - Subject to the terms and conditions of this agreement, You grant to JFrog LTD, a perpetual, worldwide, non-exclusive, no-charge, royalty-free, irrevocable (except as stated in this section) patent license to make, have made, use, offer to sell, sell, import, and otherwise transfer your contributions, where such license applies only to those patent claims licensable by you that are necessarily infringed by your contribution or by combination of your contribution with the project to which this contribution was submitted. - - If any entity institutes patent litigation - including cross-claim or counterclaim in a lawsuit - against You alleging that your contribution or any project it was submitted to constitutes or is responsible for direct or contributory patent infringement, then any patent licenses granted to that entity under this agreement shall terminate as of the date such litigation is filed. - -3. Source of Contribution. - - Your contribution is either your original creation, based upon previous work that, to the best of your knowledge, is covered under an appropriate open source license and you have the right under that license to submit that work with modifications, whether created in whole or in part by you, or you have clearly identified the source of the contribution and any license or other restriction (like related patents, trademarks, and license agreements) of which you are personally aware. diff --git a/docs/adding_packages/README.md b/docs/adding_packages/README.md index 3f310562fdf6a1..409f61c38fc0eb 100644 --- a/docs/adding_packages/README.md +++ b/docs/adding_packages/README.md @@ -30,7 +30,7 @@ generally approved on a weekly basis. Feel free to continue to step :two: while > All interactions are subject to the expectations of the [code of conduct](../code_of_conduct.md). Any misuse or inappropriate behavior > are subject to the same principals. -When submitting a pull request for the first time, you will be prompted to sign the [CLA](../CONTRIBUTOR_LICENSE_AGREEMENT.md) for your +When submitting a pull request for the first time, you will be prompted to sign the [CLA](https://cla-assistant.io/conan-io/conan-center-index) for your code contributions. You can view your signed CLA's by going to and signing in. ## Inactivity and user removal diff --git a/docs/review_process.md b/docs/review_process.md index 55eadf1bd07381..cf9d98f130d9b9 100644 --- a/docs/review_process.md +++ b/docs/review_process.md @@ -101,7 +101,7 @@ The bot runs Automatic Merges every 20 minutes. Currently, it can only merge a s PR is selected for the merge only if: - Author is already [approved](https://github.com/conan-io/conan-center-index/issues/4). -- Author has signed the [CLA](CONTRIBUTOR_LICENSE_AGREEMENT.md). +- Author has signed the [CLA](https://cla-assistant.io/conan-io/conan-center-index). - PR is not a Draft. - PR has a green status (successful build). - PR doesn't have merge conflicts with `master` branch. From b1ee96c53a09de3126ac5fc422b820e8bc0eb0b6 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 14 Aug 2023 23:26:45 +0900 Subject: [PATCH 0217/1140] (#18598) fakeit: make bindirs and libdirs empty, update dependencies --- recipes/fakeit/all/conanfile.py | 28 +++++++++---------- .../fakeit/all/test_package/CMakeLists.txt | 2 +- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/recipes/fakeit/all/conanfile.py b/recipes/fakeit/all/conanfile.py index 821c0ce34e3878..790c00d882ca36 100644 --- a/recipes/fakeit/all/conanfile.py +++ b/recipes/fakeit/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.files import get, copy from conan.tools.layout import basic_layout import os @@ -11,35 +11,34 @@ class FakeItConan(ConanFile): name = "fakeit" description = "C++ mocking made easy. A simple yet very expressive, headers only library for c++ mocking." - topics = ("mock", "fake", "spy") license = "MIT" - homepage = "https://github.com/eranpeer/FakeIt" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/eranpeer/FakeIt" + topics = ("mock", "fake", "spy", "header-only") package_type = "header-library" settings = "os", "arch", "compiler", "build_type" options = { - "integration": ["boost", "catch", "cute", "gtest", "mettle", "nunit", "mstest", "qtest", "standalone", "tpunit"] + "integration": ["boost", "catch", "cute", "gtest", "mettle", "nunit", "mstest", "qtest", "standalone", "tpunit"], + } + default_options = { + "integration": "standalone", } - default_options = {"integration": "standalone"} no_copy_source = True @property def _min_cppstd(self): return 11 - def export_sources(self): - export_conandata_patches(self) - def layout(self): basic_layout(self, src_folder="src") def requirements(self): if self.options.integration == "boost": - self.requires("boost/1.79.0") + self.requires("boost/1.82.0") elif self.options.integration == "catch": - self.requires("catch2/2.13.9") + self.requires("catch2/3.4.0") elif self.options.integration == "gtest": - self.requires("gtest/1.11.0") + self.requires("gtest/1.13.0") elif self.options.integration == "qtest": self.requires("qt/6.3.0") elif self.options.integration == "standalone": @@ -60,9 +59,6 @@ def validate(self): def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build(self): - apply_conandata_patches(self) - def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy( @@ -71,3 +67,7 @@ def package(self): dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "single_header", str(self.options.integration)), ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/fakeit/all/test_package/CMakeLists.txt b/recipes/fakeit/all/test_package/CMakeLists.txt index bc2658ff1b34ed..6beebe71b3c838 100644 --- a/recipes/fakeit/all/test_package/CMakeLists.txt +++ b/recipes/fakeit/all/test_package/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.8) -project(test_package CXX) +project(test_package LANGUAGES CXX) find_package(fakeit REQUIRED CONFIG) From 058d67c5cd5428af095d97b65ca4fbefbbeaeb8e Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 00:12:56 +0900 Subject: [PATCH 0218/1140] (#19188) quill: update fmt/10.1.0 --- recipes/quill/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/quill/all/conanfile.py b/recipes/quill/all/conanfile.py index 8de97161e36194..ef58c5e9a36f97 100644 --- a/recipes/quill/all/conanfile.py +++ b/recipes/quill/all/conanfile.py @@ -69,7 +69,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fmt/10.0.0", transitive_headers=True) + self.requires("fmt/10.1.0", transitive_headers=True) def validate(self): supported_archs = ["x86", "x86_64", "armv6", "armv7", "armv7hf", "armv8"] From b5f7e8c2b80bf22fc849d4f34b917cc8d68fcd55 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 14 Aug 2023 18:29:34 +0200 Subject: [PATCH 0219/1140] (#19162) date: update libcurl --- recipes/date/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/date/all/conanfile.py b/recipes/date/all/conanfile.py index a42b06fc8f951c..74e5999eba368b 100644 --- a/recipes/date/all/conanfile.py +++ b/recipes/date/all/conanfile.py @@ -53,7 +53,7 @@ def layout(self): def requirements(self): if not self.options.header_only and not self.options.use_system_tz_db: - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.2.1") def package_id(self): if self.info.options.header_only: From 48d10319dedcc037ab7dc8452b691f4e76b57c5a Mon Sep 17 00:00:00 2001 From: Frank Schoenmann Date: Mon, 14 Aug 2023 19:08:48 +0200 Subject: [PATCH 0220/1140] (#19057) fast-dds: add version 2.11.1 --- recipes/fast-dds/all/conandata.yml | 7 +++++ ...11.1-0001-fix-find-asio-and-tinyxml2.patch | 31 +++++++++++++++++++ recipes/fast-dds/config.yml | 2 ++ 3 files changed, 40 insertions(+) create mode 100644 recipes/fast-dds/all/patches/2.11.1-0001-fix-find-asio-and-tinyxml2.patch diff --git a/recipes/fast-dds/all/conandata.yml b/recipes/fast-dds/all/conandata.yml index 89a0fa550b4d41..d1212c03f024a9 100644 --- a/recipes/fast-dds/all/conandata.yml +++ b/recipes/fast-dds/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.11.1": + url: "https://github.com/eProsima/Fast-DDS/archive/refs/tags/v2.11.1.tar.gz" + sha256: "3fe8b9f67a13a5d2aa40c0bd10581bd90f0a192b39c71f92ee233ffe584d3374" "2.10.1": url: "https://github.com/eProsima/Fast-DDS/archive/refs/tags/v2.10.1.tar.gz" sha256: "2cc2682db5dc7e87684b7f23166e2f32faf8d5c4b4a8c94c6c21211a8a38f553" @@ -12,6 +15,10 @@ sources: url: "https://github.com/eProsima/Fast-DDS/archive/refs/tags/v2.3.2.tar.gz" sha256: "4d8183cf4d37c3de9e6fd28d2850dd08023a9079001c4880b23c95f0d8c0b5ce" patches: + "2.11.1": + - patch_file: "patches/2.11.1-0001-fix-find-asio-and-tinyxml2.patch" + patch_type: "conan" + patch_description: "Fixup find asio and tinyxml2" "2.10.1": - patch_file: "patches/2.10.1-0001-fix-find-asio-and-tinyxml2.patch" patch_type: "conan" diff --git a/recipes/fast-dds/all/patches/2.11.1-0001-fix-find-asio-and-tinyxml2.patch b/recipes/fast-dds/all/patches/2.11.1-0001-fix-find-asio-and-tinyxml2.patch new file mode 100644 index 00000000000000..bada751126e810 --- /dev/null +++ b/recipes/fast-dds/all/patches/2.11.1-0001-fix-find-asio-and-tinyxml2.patch @@ -0,0 +1,31 @@ +From b8c533b0fb2b92e9bd2aada5e195d7a0b3c0c6a9 Mon Sep 17 00:00:00 2001 +From: Joakim Haugen +Date: Wed, 10 May 2023 13:17:11 +0200 +Subject: [PATCH] fix find asio and tinyxml2 + +--- + CMakeLists.txt | 8 +++++--- + 1 file changed, 5 insertions(+), 3 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index b01b2c470..7867feff3 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -232,9 +232,11 @@ if(NOT BUILD_SHARED_LIBS) + set(FASTDDS_STATIC ON) + endif() + +-eprosima_find_package(fastcdr REQUIRED) +-eprosima_find_thirdparty(Asio asio VERSION 1.10.8) +-eprosima_find_thirdparty(TinyXML2 tinyxml2) ++eprosima_find_thirdparty(fastcdr REQUIRED) ++eprosima_find_thirdparty(asio REQUIRED) ++eprosima_find_thirdparty(tinyxml2 REQUIRED) ++set(TINYXML2_LIBRARY tinyxml2::tinyxml2) ++set(Asio_INCLUDE_DIR ${asio_INCLUDE_DIR}) + + find_package(foonathan_memory REQUIRED) + message(STATUS "Found foonathan_memory: ${foonathan_memory_DIR}") +-- +2.30.2 + diff --git a/recipes/fast-dds/config.yml b/recipes/fast-dds/config.yml index 9d0fe488028aa8..b5f51dc05cbcf0 100644 --- a/recipes/fast-dds/config.yml +++ b/recipes/fast-dds/config.yml @@ -1,4 +1,6 @@ versions: + "2.11.1": + folder: all "2.10.1": folder: all "2.3.4": From 499445e03d9ddc8b9587e6ac6642617c12d39c97 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 02:50:05 +0900 Subject: [PATCH 0221/1140] (#19189) mppp: update dependencies --- recipes/mppp/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/mppp/all/conanfile.py b/recipes/mppp/all/conanfile.py index bf3dbe732b8b17..7fed2f8affb271 100644 --- a/recipes/mppp/all/conanfile.py +++ b/recipes/mppp/all/conanfile.py @@ -63,13 +63,13 @@ def layout(self): def requirements(self): self.requires("gmp/6.2.1", transitive_headers=True) if self.options.with_mpfr: - self.requires("mpfr/4.1.0") + self.requires("mpfr/4.2.0") if self.options.with_mpc: self.requires("mpc/1.2.0") if self.options.with_boost: self.requires("boost/1.82.0") if self.options.get_safe("with_fmt"): - self.requires("fmt/10.0.0", transitive_headers=True) + self.requires("fmt/10.1.0", transitive_headers=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): From 50d110e5d44681bf834e702f2a4ffea5853fa6d2 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 14 Aug 2023 21:28:09 +0200 Subject: [PATCH 0222/1140] (#19195) pngpp: update libpng --- recipes/pngpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pngpp/all/conanfile.py b/recipes/pngpp/all/conanfile.py index 9693d59416e60c..57559867af002e 100644 --- a/recipes/pngpp/all/conanfile.py +++ b/recipes/pngpp/all/conanfile.py @@ -22,7 +22,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("libpng/1.6.38") + self.requires("libpng/1.6.40") def package_id(self): self.info.clear() From 8b1d42814d553966f7e20fde4b5f5e30f589ea48 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 11:50:28 +0900 Subject: [PATCH 0223/1140] (#19197) blend2d: add version 0.10.4 --- recipes/blend2d/all/conandata.yml | 7 +++++++ recipes/blend2d/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/blend2d/all/conandata.yml b/recipes/blend2d/all/conandata.yml index ddbc54ae6e873a..81cc43bbe5bf8e 100644 --- a/recipes/blend2d/all/conandata.yml +++ b/recipes/blend2d/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.10.4": + url: "https://blend2d.com/download/blend2d-0.10.4.tar.xz" + sha256: "6363e5c13c1c9e4709f949585a6af772ee13a16f75b0084f91b3918dece2fff3" "0.10": url: "https://blend2d.com/download/blend2d-0.10.tar.xz" sha256: "eaed6cc5f1fc33061a99d70cf166836994d952f75762bfacb397ee388e13ccc9" @@ -15,6 +18,10 @@ sources: url: "https://blend2d.com/download/blend2d-beta17.zip" sha256: "06ee8fb0bea281d09291e498900093139426501a1a7f09dba0ec801dd340635e" patches: + "0.10.4": + - patch_file: "patches/0.10-0001-disable-embed-asmjit.patch" + patch_description: "use asmjit cci package" + patch_type: "conan" "0.10": - patch_file: "patches/0.10-0001-disable-embed-asmjit.patch" patch_description: "use asmjit cci package" diff --git a/recipes/blend2d/config.yml b/recipes/blend2d/config.yml index 447f9c7043b58c..abc5bb6a7611e5 100644 --- a/recipes/blend2d/config.yml +++ b/recipes/blend2d/config.yml @@ -1,4 +1,6 @@ versions: + "0.10.4": + folder: all "0.10": folder: all "0.9": From 5ce4d59ea7942f14863fa4dbffb80f22ee45b7d3 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 12:35:47 +0900 Subject: [PATCH 0224/1140] (#19198) fmtlog: update fmt/10.1.0 --- recipes/fmtlog/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/fmtlog/all/conanfile.py b/recipes/fmtlog/all/conanfile.py index 17e20eaf9c51b4..759d3b12c68610 100644 --- a/recipes/fmtlog/all/conanfile.py +++ b/recipes/fmtlog/all/conanfile.py @@ -67,7 +67,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fmt/10.0.0", transitive_headers=True, transitive_libs=True) + self.requires("fmt/10.1.0", transitive_headers=True, transitive_libs=True) def package_id(self): if self.info.options.header_only: From e98ebfe43280ed145c476ce8cf91086d12c08c6f Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 13:48:19 +0900 Subject: [PATCH 0225/1140] (#19199) jinja2cpp: update fmt/10.1.0 --- recipes/jinja2cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/jinja2cpp/all/conanfile.py b/recipes/jinja2cpp/all/conanfile.py index f6bfa2d0a3b341..c40b675dc715af 100644 --- a/recipes/jinja2cpp/all/conanfile.py +++ b/recipes/jinja2cpp/all/conanfile.py @@ -66,7 +66,7 @@ def requirements(self): self.requires("fmt/6.2.1") # not compatible with fmt >= 7.0.0 else: self.requires("nlohmann_json/3.11.2") - self.requires("fmt/10.0.0") + self.requires("fmt/10.1.0") def validate(self): if self.settings.compiler.get_safe("cppstd"): From 3298067ae4e38b4bdb6f9ed294197de01431e2d1 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 15 Aug 2023 18:16:21 +0900 Subject: [PATCH 0226/1140] (#18840) strong_type: add version v12 Co-authored-by: Carlos Zoido --- recipes/strong_type/all/conandata.yml | 3 +++ recipes/strong_type/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/strong_type/all/conandata.yml b/recipes/strong_type/all/conandata.yml index 93df54150e6a03..1b5da1a4d1c201 100644 --- a/recipes/strong_type/all/conandata.yml +++ b/recipes/strong_type/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "v12": + url: "https://github.com/rollbear/strong_type/archive/refs/tags/v12.tar.gz" + sha256: "8af0400c7ae76c7ec8646e929bacb37fc7fcae33e54eeaa61fa9f9df508a9248" "v11": url: "https://github.com/rollbear/strong_type/archive/refs/tags/v11.tar.gz" sha256: "b9879c8835501c05147603ac86097b263437f72a35299b5f96c90be789932418" diff --git a/recipes/strong_type/config.yml b/recipes/strong_type/config.yml index 547a5c53c28e34..3fcbeb72e7dd9c 100644 --- a/recipes/strong_type/config.yml +++ b/recipes/strong_type/config.yml @@ -1,4 +1,6 @@ versions: + "v12": + folder: all "v11": folder: all "v10": From 9833fcdbde0fdd4c1cb91d4521560e334b4593b3 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 01:48:18 +0900 Subject: [PATCH 0227/1140] (#19207) screen_capture_lite: add version 17.1.1369 --- recipes/screen_capture_lite/all/conandata.yml | 3 +++ recipes/screen_capture_lite/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/screen_capture_lite/all/conandata.yml b/recipes/screen_capture_lite/all/conandata.yml index aa72c475ba532d..7bc7e84245c172 100644 --- a/recipes/screen_capture_lite/all/conandata.yml +++ b/recipes/screen_capture_lite/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "17.1.1369": + url: "https://github.com/smasherprog/screen_capture_lite/archive/refs/tags/17.1.1369.tar.gz" + sha256: "72abf1cd9fc538e98547841ec56396ba75a36853e861f7bf721f21c64c34453e" "17.1.1327": url: "https://github.com/smasherprog/screen_capture_lite/archive/refs/tags/17.1.1327.tar.gz" sha256: "bc5c17f3df14c1013268fc0107b52a98c6d032803fd1faea1983772f3b7ac5ed" diff --git a/recipes/screen_capture_lite/config.yml b/recipes/screen_capture_lite/config.yml index 7298de37ef3631..d2022be0c81a17 100644 --- a/recipes/screen_capture_lite/config.yml +++ b/recipes/screen_capture_lite/config.yml @@ -1,4 +1,6 @@ versions: + "17.1.1369": + folder: "all" "17.1.1327": folder: "all" "17.1.1173": From 260f853130b76350e8b27a27a269a84ef6c763ab Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 02:36:02 +0900 Subject: [PATCH 0228/1140] (#19208) r8brain-free-src: add version 6.4 --- recipes/r8brain-free-src/all/conandata.yml | 3 +++ recipes/r8brain-free-src/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/r8brain-free-src/all/conandata.yml b/recipes/r8brain-free-src/all/conandata.yml index e43484f945f023..66f72e2a320487 100644 --- a/recipes/r8brain-free-src/all/conandata.yml +++ b/recipes/r8brain-free-src/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.4": + url: "https://github.com/avaneev/r8brain-free-src/archive/refs/tags/version-6.4.tar.gz" + sha256: "27e6749e140648894b79003fe16a4d416eca3bed8d067e0f00cfb2e246c556ca" "6.3": url: "https://github.com/avaneev/r8brain-free-src/archive/refs/tags/version-6.3.tar.gz" sha256: "f2cd46cd8806294d9be45ed4e6bda5f8ef1dc808625eec3facde784953d2bc23" diff --git a/recipes/r8brain-free-src/config.yml b/recipes/r8brain-free-src/config.yml index 8f56257b3441dc..2402c4c664c5ff 100644 --- a/recipes/r8brain-free-src/config.yml +++ b/recipes/r8brain-free-src/config.yml @@ -1,4 +1,6 @@ versions: + "6.4": + folder: all "6.3": folder: all "6.2": From 9a72a33917fb67865b4ddeecb23bacabbe382fb4 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 13:08:25 +0900 Subject: [PATCH 0229/1140] (#19216) maven: add version 3.9.4 --- recipes/maven/all/conandata.yml | 3 +++ recipes/maven/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/maven/all/conandata.yml b/recipes/maven/all/conandata.yml index 7cdcaeb46d6b1b..ce4fe6b87794c8 100644 --- a/recipes/maven/all/conandata.yml +++ b/recipes/maven/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.9.4": + url: "https://dlcdn.apache.org/maven/maven-3/3.9.4/binaries/apache-maven-3.9.4-bin.tar.gz" + sha256: "ff66b70c830a38d331d44f6c25a37b582471def9a161c93902bac7bea3098319" "3.9.2": url: "https://dlcdn.apache.org/maven/maven-3/3.9.2/binaries/apache-maven-3.9.2-bin.tar.gz" sha256: "809ef3220c6d179195c06c324cb9a6d34d8ecba566c5cfd8eb83167bc034117d" diff --git a/recipes/maven/config.yml b/recipes/maven/config.yml index 2f82b90ebcf020..95a41cd441c27b 100644 --- a/recipes/maven/config.yml +++ b/recipes/maven/config.yml @@ -1,3 +1,5 @@ versions: + "3.9.4": + folder: all "3.9.2": folder: all From 012bfc5bb3d7ee26ce9214fd2ed4c4bc6359cb39 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 13:29:38 +0900 Subject: [PATCH 0230/1140] (#19214) cppcommon: update fmt/10.1.0 --- recipes/cppcommon/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cppcommon/all/conanfile.py b/recipes/cppcommon/all/conanfile.py index 31e78b570dc50a..4997a9d1cf9fba 100644 --- a/recipes/cppcommon/all/conanfile.py +++ b/recipes/cppcommon/all/conanfile.py @@ -62,7 +62,7 @@ def requirements(self): if Version(self.version) < "1.0.3" or self.version == "cci.20201104": self.requires("fmt/8.1.1") else: - self.requires("fmt/10.0.0") + self.requires("fmt/10.1.0") if self.settings.os == "Linux": self.requires("util-linux-libuuid/2.39") From c0d4ff3f18cc1a68343e63bc80e0f66f3e152043 Mon Sep 17 00:00:00 2001 From: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> Date: Wed, 16 Aug 2023 07:02:08 +0100 Subject: [PATCH 0231/1140] (#19185) Update wording on patch policy * Update wording on patch policy * Update sources_and_patches.md --- docs/adding_packages/sources_and_patches.md | 69 +++------------------ 1 file changed, 10 insertions(+), 59 deletions(-) diff --git a/docs/adding_packages/sources_and_patches.md b/docs/adding_packages/sources_and_patches.md index 66f10a12327268..abd4c25d16e75a 100644 --- a/docs/adding_packages/sources_and_patches.md +++ b/docs/adding_packages/sources_and_patches.md @@ -138,62 +138,13 @@ def _patch_sources(self): replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "${CMAKE_SOURCE_DIR}", "${CMAKE_CURRENT_SOURCE_DIR}") ``` -### Rules - -These are the rules that apply to regular versions of Conan packages: - -**Build system patches.** In order to add libraries into ConanCenter sometimes -it is NEEDED to apply patches so they can consume existing packages -for requirements and binaries can be generated. These patches are totally -needed for the purpose of ConanCenter and Conan keeps adding features trying -to minimize these changes. - -**Source patches.** ConanCenter DOES NOT accept patches **backporting bugfixes or -features** from upcoming releases, they break the principle of minimum surprise, -they change the behavior of the library and it will no longer match the -documentation or the changelog originally delivered by the authors. - -However, ConanCenter DOES accept **working software patches**, these patches -are needed to generate the binaries for architectures not considered by -library maintainers, or to use some compilers or configurations. These patches -make it possible to generate binaries that cannot be generated otherwise, or -they can turn a crashing binary into a working software one (bugs, errors, or -faults are considered working software as long as they produce deterministic -results). - -Patches to sources to add support to newer versions of dependencies are -considered feature patches and they are not allowed either. They can -introduce new behaviors or bugs not considered when delivering the -library by maintainers. If a requirement is known not to work, the recipe -should raise a `ConanInvalidConfiguration` from the `validate()` method. - -**Vulnerability patches.** Patches published to CVE databases or declared as -vulnerabilities by the authors in non-mainstream libraries WILL be applied -to packages generated in Conan Center. - -**Official release patches.** If the library documents that a patch should be -applied to sources when building a tag/release from sources, ConanCenter WILL -apply that patch too. This is needed to match the documented behavior or the -binaries of that library offered by other means. -[Example here](https://www.boost.org/users/history/version_1_73_0.html). - -### Exceptions - -Exceptionally, we might find libraries that aren't actively developed and consumers -might benefit from having some bugfixes applied to previous versions while -waiting for the next release, or because the library is no longer maintained. These -are the rules for this exceptional scenario: - -* **new release**, based on some official release and clearly identifiable will - be created to apply these patches to: <>. -* **only patches backporting bugfixes** will be accepted after they have - been submitted to the upstream and there is a consensus that it's a bug and the patch is the solution. - -ConanCenter will build this patched release and serve its binaries like it does with -any other Conan reference. - -Notice that these <> releases are unique to ConanCenter -and they can get new patches or discard existing ones according to upstream -considerations. It means that these releases will modify their behavior without previous -notice, the documentation or changelog for these specific releases won't exist. Use -them carefully in your projects. +### Policy on patches + +Conan Center is a package repository, and the aim of the service is to provide the recipes to build libraries from the sources as provided by the library authors, and to provide binaries for Conan Center’s supported platforms and configurations. + +In general, patches to source code should be avoided and only done as a last resort. In situations where it is strictly necessary, the aim should be that the patches could be eventually merged upstream so that in the future they are no longer necessary. + +Pull Requests that introduce patches will be carefully reviewed by the Conan Team. We recognize that in some instances, patches are necessary in the build system/build scripts. +Patches that affect C and C++ code are strongly discouraged and will only be accepted at the discretion of the Conan Team, after a strict validation process. Patches are more likely to be accepted if they are first reported and acknowledged by the library authors. + +For scenarios that require patching source code, we greatly encourage raising a new issue explaining the need and motivation, reproducible steps and complete logs, behind the patch. Please note that for issues that strictly affect C and C++ source code, it is very unlikely that a patch will be accepted if an issue is not first raised with the original library authors, or if the patches are not addressing a known security advisory. From 625304d16b23e6c0465ff0277a0ab964d6b3bb13 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 16 Aug 2023 09:24:15 +0300 Subject: [PATCH 0232/1140] (#18233) rgbcx: migrate to Conan v2 * rgbcx: migrate to Conan v2 * rgbcx: restore test_v1_package * rgbcx: add cmake_find_package_multi generator to test_v1_package * rgbcx: fix v1 test on armv8 * rgbcx: restore VirtualRunEnv in test_package --- recipes/rgbcx/all/conanfile.py | 55 +++++++++++++------ recipes/rgbcx/all/test_package/CMakeLists.txt | 7 +-- recipes/rgbcx/all/test_package/conanfile.py | 20 +++++-- .../rgbcx/all/test_package/test_package.cpp | 3 + .../rgbcx/all/test_v1_package/CMakeLists.txt | 8 +++ .../rgbcx/all/test_v1_package/conanfile.py | 19 +++++++ 6 files changed, 85 insertions(+), 27 deletions(-) create mode 100644 recipes/rgbcx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rgbcx/all/test_v1_package/conanfile.py diff --git a/recipes/rgbcx/all/conanfile.py b/recipes/rgbcx/all/conanfile.py index 62f3ee9f485a55..2978797a9067e4 100644 --- a/recipes/rgbcx/all/conanfile.py +++ b/recipes/rgbcx/all/conanfile.py @@ -1,34 +1,53 @@ import os -import glob -from conans import ConanFile, tools + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, replace_in_file +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class RgbcxConan(ConanFile): name = "rgbcx" description = "High-performance scalar BC1-5 encoders." - homepage = "https://github.com/richgel999/bc7enc" + license = ("MIT", "Unlicense") url = "https://github.com/conan-io/conan-center-index" - topics = ("conan", "BC1", "BC5", "BCx", "encoding") - license = "MIT", "Unlicense" + homepage = "https://github.com/richgel999/bc7enc" + topics = ("BC1", "BC5", "BCx", "encoding", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob('bc7enc-*/')[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): - tools.replace_in_file(os.path.join(self._source_subfolder, "rgbcx.h"), - "#include ", - "#include \n#include ") + replace_in_file(self, + os.path.join(self.source_folder, "rgbcx.h"), + "#include ", + "#include \n#include ") def package(self): - self.copy("rgbcx.h", dst="include", src=self._source_subfolder) - self.copy("rgbcx_table4.h", dst="include", src=self._source_subfolder) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "rgbcx.h", dst=os.path.join(self.package_folder, "include"), src=self.source_folder) + copy(self, "rgbcx_table4.h", dst=os.path.join(self.package_folder, "include"), src=self.source_folder) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/rgbcx/all/test_package/CMakeLists.txt b/recipes/rgbcx/all/test_package/CMakeLists.txt index 454c47bb2cbab0..e86d42248fffd9 100644 --- a/recipes/rgbcx/all/test_package/CMakeLists.txt +++ b/recipes/rgbcx/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(rgbcx REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE rgbcx::rgbcx) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/rgbcx/all/test_package/conanfile.py b/recipes/rgbcx/all/test_package/conanfile.py index be0a94674e5bdf..ef5d7042163ecc 100644 --- a/recipes/rgbcx/all/test_package/conanfile.py +++ b/recipes/rgbcx/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,5 +21,6 @@ def build(self): cmake.build() def test(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rgbcx/all/test_package/test_package.cpp b/recipes/rgbcx/all/test_package/test_package.cpp index 136968a37d7d17..c4faf6d5e5b499 100644 --- a/recipes/rgbcx/all/test_package/test_package.cpp +++ b/recipes/rgbcx/all/test_package/test_package.cpp @@ -1,3 +1,6 @@ +// Workaround for a missing math.h include in rgbcx.h +#include + #define RGBCX_IMPLEMENTATION #include "rgbcx.h" diff --git a/recipes/rgbcx/all/test_v1_package/CMakeLists.txt b/recipes/rgbcx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rgbcx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rgbcx/all/test_v1_package/conanfile.py b/recipes/rgbcx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..f96c48347ffda3 --- /dev/null +++ b/recipes/rgbcx/all/test_v1_package/conanfile.py @@ -0,0 +1,19 @@ +import os + +from conan.tools.build import can_run +from conans import ConanFile, CMake + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From d29f9060f9e58aee8fdd05bf2cbd400b6caa8884 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Wed, 16 Aug 2023 08:44:18 +0200 Subject: [PATCH 0233/1140] (#18400) openmvg: add with_jpeg option * add jpeg option * fix * review * Update recipes/openmvg/all/conanfile.py Co-authored-by: Martin Valgur * add workaround for build rpath issue on Linux --------- Co-authored-by: Martin Valgur Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/openmvg/all/conanfile.py | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/recipes/openmvg/all/conanfile.py b/recipes/openmvg/all/conanfile.py index b320aba511407c..6774e8b893191b 100644 --- a/recipes/openmvg/all/conanfile.py +++ b/recipes/openmvg/all/conanfile.py @@ -30,6 +30,7 @@ class Openmvgconan(ConanFile): "with_openmp": [True, False], "with_avx": [False, "avx", "avx2"], "programs": [True, False], + "with_jpeg": ["libjpeg", "libjpeg-turbo", "mozjpeg"] } default_options = { "shared": False, @@ -37,6 +38,7 @@ class Openmvgconan(ConanFile): "with_openmp": False, "with_avx": False, "programs": True, + "with_jpeg": "libjpeg" } short_paths = True @@ -66,7 +68,12 @@ def requirements(self): self.requires("coin-utils/2.11.6") self.requires("eigen/3.4.0", transitive_headers=True) self.requires("flann/1.9.2", transitive_headers=True, transitive_libs=True) - self.requires("libjpeg/9e") + if self.options.with_jpeg == "libjpeg": + self.requires("libjpeg/9e") + elif self.options.with_jpeg == "libjpeg-turbo": + self.requires("libjpeg-turbo/3.0.0") + elif self.options.with_jpeg == "mozjpeg": + self.requires("mozjpeg/4.1.1") self.requires("libpng/1.6.40") self.requires("libtiff/4.5.1") @@ -108,6 +115,12 @@ def generate(self): # see https://github.com/conan-io/conan/issues/10281 if Version(self.dependencies["ceres-solver"].ref.version) >= "2.0.0" and not valid_min_cppstd(self, "14"): tc.variables["CMAKE_CXX_STANDARD"] = "14" + + if self.settings.os == "Linux": + # Workaround for: https://github.com/conan-io/conan/issues/13560 + libdirs_host = [l for dependency in self.dependencies.host.values() for l in dependency.cpp_info.aggregated_components().libdirs] + tc.variables["CMAKE_BUILD_RPATH"] = ";".join(libdirs_host) + tc.generate() deps = CMakeDeps(self) @@ -131,6 +144,14 @@ def package(self): @property def _openmvg_components(self): + def jpeg(): + if self.options.with_jpeg == "libjpeg": + return ["libjpeg::libjpeg"] + elif self.options.with_jpeg == "libjpeg-turbo": + return ["libjpeg-turbo::jpeg"] + elif self.options.with_jpeg == "mozjpeg": + return ["mozjpeg::libjpeg"] + return { "openmvg_camera": { "target": "openMVG_camera", @@ -162,7 +183,7 @@ def _openmvg_components(self): "openmvg_image": { "target": "openMVG_image", "libs": ["openMVG_image"], - "requires": ["openmvg_numeric", "libjpeg::libjpeg", "libpng::libpng", "libtiff::libtiff"], + "requires": ["openmvg_numeric", "libpng::libpng", "libtiff::libtiff"] + jpeg(), }, "openmvg_linearprogramming": { "target": "openMVG_linearProgramming", From 316603b08544d37338cf42e65c322d0702b99d8f Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Wed, 16 Aug 2023 09:05:03 +0200 Subject: [PATCH 0234/1140] (#18467) Update nodesoup to conan v2 * Update nodesoup to conan v2 * Apply patches * Delete unused CMakeLists * Drop minimum conan version * Enable export of symbols on Windows --- recipes/nodesoup/all/CMakeLists.txt | 9 --- recipes/nodesoup/all/conandata.yml | 1 - recipes/nodesoup/all/conanfile.py | 67 +++++++++---------- .../nodesoup/all/test_package/CMakeLists.txt | 3 - .../nodesoup/all/test_package/conanfile.py | 21 ++++-- 5 files changed, 48 insertions(+), 53 deletions(-) delete mode 100644 recipes/nodesoup/all/CMakeLists.txt diff --git a/recipes/nodesoup/all/CMakeLists.txt b/recipes/nodesoup/all/CMakeLists.txt deleted file mode 100644 index 881b1cb39250b4..00000000000000 --- a/recipes/nodesoup/all/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -add_subdirectory(source_subfolder) diff --git a/recipes/nodesoup/all/conandata.yml b/recipes/nodesoup/all/conandata.yml index bf507c033f50b6..633f6755af50c8 100644 --- a/recipes/nodesoup/all/conandata.yml +++ b/recipes/nodesoup/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "cci.20200905": - patch_file: "patches/0001-install-shared-windows.patch" - base_path: "source_subfolder" diff --git a/recipes/nodesoup/all/conanfile.py b/recipes/nodesoup/all/conanfile.py index 19ef9ea3f19236..86e6f75fa66160 100644 --- a/recipes/nodesoup/all/conanfile.py +++ b/recipes/nodesoup/all/conanfile.py @@ -1,9 +1,11 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout +from conan.tools.files import copy, get, rmdir, apply_conandata_patches, export_conandata_patches +from conan.tools.scm import Version +from conan.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" - class NodesoupConan(ConanFile): name = "nodesoup" @@ -13,6 +15,7 @@ class NodesoupConan(ConanFile): homepage = "https://github.com/olvb/nodesoup" url = "https://github.com/conan-io/conan-center-index" settings = "os", "arch", "compiler", "build_type" + package_type = "library" options = { "shared": [True, False], "fPIC": [True, False], @@ -22,18 +25,8 @@ class NodesoupConan(ConanFile): "fPIC": True, } - generators = "cmake" - exports_sources = "CMakeLists.txt", "patches/*" - - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def layout(self): + cmake_layout(self, src_folder="src") def config_options(self): if self.settings.os == "Windows": @@ -41,38 +34,44 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + @property + def _min_cppstd(self): + return 14 def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 14) + check_min_cppstd(self, self._min_cppstd) if self.settings.compiler == "clang": - if tools.Version(self.settings.compiler.version) < "5.0" and self.settings.compiler.libcxx in ("libstdc++", "libstdc++11"): + if Version(self.settings.compiler.version) < "5.0" and self.settings.compiler.libcxx in ("libstdc++", "libstdc++11"): raise ConanInvalidConfiguration("The version of libstdc++(11) of the current compiler does not support building nodesoup") + def export_sources(self): + export_conandata_patches(self) + def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_DEMO"] = False + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True + tc.generate() + deps = CMakeDeps(self) + deps.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): self.cpp_info.includedirs.append(os.path.join("include", "nodesoup")) diff --git a/recipes/nodesoup/all/test_package/CMakeLists.txt b/recipes/nodesoup/all/test_package/CMakeLists.txt index 027a67d403fb19..881aec891e1d02 100644 --- a/recipes/nodesoup/all/test_package/CMakeLists.txt +++ b/recipes/nodesoup/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ cmake_minimum_required(VERSION 3.1) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(nodesoup REQUIRED CONFIG) add_executable(${CMAKE_PROJECT_NAME} test_package.cpp) diff --git a/recipes/nodesoup/all/test_package/conanfile.py b/recipes/nodesoup/all/test_package/conanfile.py index 49a3a66ea5bad4..8a5bb47f50c4ce 100644 --- a/recipes/nodesoup/all/test_package/conanfile.py +++ b/recipes/nodesoup/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") From f9fd67a038d28e63a31ed40fbf0fb666f5ad1c0f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 16 Aug 2023 10:27:20 +0300 Subject: [PATCH 0235/1140] (#18781) libfuse: fix fPIC handling on Windows * libfuse: fix fPIC handling on Windows * libfuse: restore VirtualRunEnv in test_package * libfuse: bump deps --- recipes/libfuse/2.x.x/conanfile.py | 12 ++++++++---- recipes/libfuse/2.x.x/test_package/CMakeLists.txt | 2 +- .../libfuse/2.x.x/test_v1_package/CMakeLists.txt | 2 +- recipes/libfuse/all/conanfile.py | 13 ++++++++----- recipes/libfuse/all/test_package/CMakeLists.txt | 2 +- recipes/libfuse/all/test_v1_package/CMakeLists.txt | 2 +- 6 files changed, 20 insertions(+), 13 deletions(-) diff --git a/recipes/libfuse/2.x.x/conanfile.py b/recipes/libfuse/2.x.x/conanfile.py index 4cc77383a646b9..d233b32a706317 100644 --- a/recipes/libfuse/2.x.x/conanfile.py +++ b/recipes/libfuse/2.x.x/conanfile.py @@ -14,7 +14,8 @@ class LibfuseConan(ConanFile): homepage = "https://github.com/libfuse/libfuse" license = "LGPL-2.1" description = "The reference implementation of the Linux FUSE interface" - topics = ("fuse", "libfuse", "filesystem", "linux") + topics = ("fuse", "filesystem", "linux") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -26,9 +27,13 @@ class LibfuseConan(ConanFile): "fPIC": True, } + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") @@ -72,6 +77,5 @@ def package_info(self): self.cpp_info.system_libs = ["pthread"] # libfuse requires this define to compile successfully self.cpp_info.defines = ["_FILE_OFFSET_BITS=64"] - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs.append("dl") - diff --git a/recipes/libfuse/2.x.x/test_package/CMakeLists.txt b/recipes/libfuse/2.x.x/test_package/CMakeLists.txt index 701d331873021b..b328202f167f95 100644 --- a/recipes/libfuse/2.x.x/test_package/CMakeLists.txt +++ b/recipes/libfuse/2.x.x/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(libfuse REQUIRED CONFIG) diff --git a/recipes/libfuse/2.x.x/test_v1_package/CMakeLists.txt b/recipes/libfuse/2.x.x/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/libfuse/2.x.x/test_v1_package/CMakeLists.txt +++ b/recipes/libfuse/2.x.x/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) diff --git a/recipes/libfuse/all/conanfile.py b/recipes/libfuse/all/conanfile.py index 0f2c7852403e0a..2b5f67a4fee988 100644 --- a/recipes/libfuse/all/conanfile.py +++ b/recipes/libfuse/all/conanfile.py @@ -15,7 +15,7 @@ class LibfuseConan(ConanFile): homepage = "https://github.com/libfuse/libfuse" license = "LGPL-2.1" description = "The reference implementation of the Linux FUSE interface" - topics = ("fuse", "libfuse", "filesystem", "linux") + topics = ("fuse", "filesystem", "linux") package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -27,9 +27,13 @@ class LibfuseConan(ConanFile): "fPIC": True, } + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") @@ -41,7 +45,7 @@ def validate(self): raise ConanInvalidConfiguration("libfuse supports only Linux and FreeBSD") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.0") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -72,6 +76,5 @@ def package_info(self): self.cpp_info.libs = ["fuse3"] self.cpp_info.includedirs = [os.path.join("include", "fuse3")] self.cpp_info.system_libs = ["pthread"] - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs.extend(["dl", "rt"]) - diff --git a/recipes/libfuse/all/test_package/CMakeLists.txt b/recipes/libfuse/all/test_package/CMakeLists.txt index c8bc174f2164d2..2fd81a9f515e75 100644 --- a/recipes/libfuse/all/test_package/CMakeLists.txt +++ b/recipes/libfuse/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(libfuse REQUIRED CONFIG) diff --git a/recipes/libfuse/all/test_v1_package/CMakeLists.txt b/recipes/libfuse/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/libfuse/all/test_v1_package/CMakeLists.txt +++ b/recipes/libfuse/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) From 4ca516712774b522ad76bb68f1f04aac531d83f8 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Wed, 16 Aug 2023 11:48:00 +0400 Subject: [PATCH 0236/1140] (#19171) onetbb: set package_type --- recipes/onetbb/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index 165436b84b383b..fa6e990f3c8293 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -21,6 +21,7 @@ class OneTBBConan(ConanFile): " programs that take full advantage of multicore performance, that are portable, composable" " and have future-proof scalability.") topics = ("tbb", "threading", "parallelism", "tbbmalloc") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { From f4260277bcf0768a5b078a089de9b5e474cd813d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 16 Aug 2023 10:22:29 +0200 Subject: [PATCH 0237/1140] (#19186) [bot] Update authorized users list (2023-08-14) --- .c3i/authorized_users.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 29f7167d2ab9c5..d4bb58861e74d1 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1212,3 +1212,6 @@ authorized_users: - matthewT53 - sjlamerton - marxin +- Arkokat +- adattatri +- jwfallawuiuc From 63042b5a95505b78ca3c5c9a37c23611a48dfdbb Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Wed, 16 Aug 2023 10:43:11 +0200 Subject: [PATCH 0238/1140] (#19217) [docs] Regenerate tables of contents Co-authored-by: conan-center-bot --- docs/adding_packages/sources_and_patches.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docs/adding_packages/sources_and_patches.md b/docs/adding_packages/sources_and_patches.md index abd4c25d16e75a..56ff5130c26e4c 100644 --- a/docs/adding_packages/sources_and_patches.md +++ b/docs/adding_packages/sources_and_patches.md @@ -16,8 +16,7 @@ These are a very important aspects and it helps us to establish the quality of t * [Format and Conventions](#format-and-conventions) * [Exporting Patches](#exporting-patches) * [Applying Patches](#applying-patches) - * [Rules](#rules) - * [Exceptions](#exceptions) + * [Policy on patches](#policy-on-patches) ## Picking the Sources From 37ab4bd027654c453211528d3f4d411ea2389129 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 18:12:50 +0900 Subject: [PATCH 0239/1140] (#19166) xbyak: add version 6.73, add package_type --- recipes/xbyak/all/conandata.yml | 3 +++ recipes/xbyak/all/conanfile.py | 17 ++++++++--------- recipes/xbyak/config.yml | 2 ++ 3 files changed, 13 insertions(+), 9 deletions(-) diff --git a/recipes/xbyak/all/conandata.yml b/recipes/xbyak/all/conandata.yml index 2e045a1c8a0821..a0e8dd18cf451a 100644 --- a/recipes/xbyak/all/conandata.yml +++ b/recipes/xbyak/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.73": + url: "https://github.com/herumi/xbyak/archive/v6.73.tar.gz" + sha256: "41f3dc7727a48c751024c92fa4da24a4a1e0ed16b7930c79d05b76960b19562d" "6.62": url: "https://github.com/herumi/xbyak/archive/v6.62.tar.gz" sha256: "fd5f074d64cdfcacad3bbe8664727a8eab569f131cadd725a778c028fa6b0ccd" diff --git a/recipes/xbyak/all/conanfile.py b/recipes/xbyak/all/conanfile.py index 9523784e16e7c5..724743a916f474 100644 --- a/recipes/xbyak/all/conanfile.py +++ b/recipes/xbyak/all/conanfile.py @@ -11,21 +11,21 @@ class XbyakConan(ConanFile): description = "Xbyak is a C++ header library that enables dynamically to " \ "assemble x86(IA32), x64(AMD64, x86-64) mnemonic." license = "BSD-3-Clause" - topics = ("xbyak", "jit", "assembler") - homepage = "https://github.com/herumi/xbyak" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/herumi/xbyak" + topics = ("jit", "assembler", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True - def package_id(self): - self.info.clear() - def layout(self): basic_layout(self, src_folder="src") + def package_id(self): + self.info.clear() + def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -37,7 +37,6 @@ def package(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "xbyak") self.cpp_info.set_property("cmake_target_name", "xbyak::xbyak") + self.cpp_info.bindirs = [] - self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] diff --git a/recipes/xbyak/config.yml b/recipes/xbyak/config.yml index 9006396a7028a6..65c8029e207c3c 100644 --- a/recipes/xbyak/config.yml +++ b/recipes/xbyak/config.yml @@ -1,4 +1,6 @@ versions: + "6.73": + folder: all "6.62": folder: all "6.61.2": From 7443a4a506e944b4d98600bf65064137974168ba Mon Sep 17 00:00:00 2001 From: Rasmus Thomsen Date: Wed, 16 Aug 2023 11:50:38 +0200 Subject: [PATCH 0240/1140] (#19201) libpq: add 15.4 * libpq: add 15.4 * libpq: update openssl dependency --- recipes/libpq/all/conandata.yml | 3 +++ recipes/libpq/all/conanfile.py | 5 ++++- recipes/libpq/config.yml | 2 ++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/recipes/libpq/all/conandata.yml b/recipes/libpq/all/conandata.yml index eef5fefc1dd9a2..cf627d10addbc9 100644 --- a/recipes/libpq/all/conandata.yml +++ b/recipes/libpq/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "15.4": + url: "https://ftp.postgresql.org/pub/source/v15.4/postgresql-15.4.tar.bz2" + sha256: "baec5a4bdc4437336653b6cb5d9ed89be5bd5c0c58b94e0becee0a999e63c8f9" "15.3": url: "https://ftp.postgresql.org/pub/source/v15.3/postgresql-15.3.tar.bz2" sha256: "ffc7d4891f00ffbf5c3f4eab7fbbced8460b8c0ee63c5a5167133b9e6599d932" diff --git a/recipes/libpq/all/conanfile.py b/recipes/libpq/all/conanfile.py index b4e66be74d3631..cc7d54df6ee850 100644 --- a/recipes/libpq/all/conanfile.py +++ b/recipes/libpq/all/conanfile.py @@ -65,7 +65,10 @@ def layout(self): def requirements(self): if self.options.with_openssl: - self.requires("openssl/1.1.1t") + if Version(self.version) < "13.5": + self.requires("openssl/1.1.1u") + else: + self.requires("openssl/[>=1.1 <4]") def build_requirements(self): if is_msvc(self): diff --git a/recipes/libpq/config.yml b/recipes/libpq/config.yml index bf80d539d9d1e2..5a83ac4481a63c 100644 --- a/recipes/libpq/config.yml +++ b/recipes/libpq/config.yml @@ -1,4 +1,6 @@ versions: + "15.4": + folder: all "15.3": folder: all "14.8": From 7758eb75ce0f8b198bfa278726cfdf6959b57c3b Mon Sep 17 00:00:00 2001 From: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> Date: Wed, 16 Aug 2023 11:44:25 +0100 Subject: [PATCH 0241/1140] (#19220) jwt-cpp: update version range for OpenSSL --- recipes/jwt-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/jwt-cpp/all/conanfile.py b/recipes/jwt-cpp/all/conanfile.py index bbf3918d2b2357..5a0889c19e2e19 100644 --- a/recipes/jwt-cpp/all/conanfile.py +++ b/recipes/jwt-cpp/all/conanfile.py @@ -24,7 +24,7 @@ def export_sources(self): export_conandata_patches(self) def requirements(self): - self.requires("openssl/[>1.1.1c,<1.1.1u]") + self.requires("openssl/[>=1.1 <4]") if not self._supports_generic_json: self.requires("picojson/1.3.0") From 0ed2d49cc6f00afc04a3691de086144532688ebd Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 16 Aug 2023 20:09:20 +0900 Subject: [PATCH 0242/1140] (#18678) implot: add version 0.15 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * implot: add version 0.15 * improve CMakeLists.txt * update checksum of 0.15 * drop support shared imgui on msvc * Update recipes/implot/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Carlos Zoido --- recipes/implot/all/CMakeLists.txt | 14 +++++++------- recipes/implot/all/conandata.yml | 3 +++ recipes/implot/all/conanfile.py | 21 ++++++++++++++------- recipes/implot/config.yml | 2 ++ 4 files changed, 26 insertions(+), 14 deletions(-) diff --git a/recipes/implot/all/CMakeLists.txt b/recipes/implot/all/CMakeLists.txt index ec869caed90292..84afb4ed40721f 100644 --- a/recipes/implot/all/CMakeLists.txt +++ b/recipes/implot/all/CMakeLists.txt @@ -1,14 +1,12 @@ cmake_minimum_required(VERSION 3.4) -project(implot CXX) -set(CMAKE_CXX_STANDARD 11) -set(CMAKE_CXX_STANDARD_REQUIRED ON) +project(implot LANGUAGES CXX) -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -file(GLOB SOURCE_FILES ${IMPLOT_SRC_DIR}/*.cpp) file(GLOB HEADER_FILES ${IMPLOT_SRC_DIR}/*.h) -add_library(${PROJECT_NAME} ${SOURCE_FILES}) +add_library(${PROJECT_NAME} + ${IMPLOT_SRC_DIR}/implot.cpp + ${IMPLOT_SRC_DIR}/implot_items.cpp +) target_include_directories(${PROJECT_NAME} PRIVATE ${IMPLOT_SRC_DIR}) find_package(imgui CONFIG REQUIRED) @@ -16,6 +14,8 @@ find_package(imgui CONFIG REQUIRED) target_link_libraries(${PROJECT_NAME} PUBLIC imgui::imgui) target_compile_definitions(${PROJECT_NAME} PRIVATE IMGUI_DEFINE_MATH_OPERATORS) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +set_target_properties(${PROJECT_NAME} PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS ON) include(GNUInstallDirs) diff --git a/recipes/implot/all/conandata.yml b/recipes/implot/all/conandata.yml index 21af4dfe87312a..a9c9c08b5ed786 100644 --- a/recipes/implot/all/conandata.yml +++ b/recipes/implot/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.15": + url: "https://github.com/epezent/implot/archive/v0.15.tar.gz" + sha256: "4c20f22fbfbe4ad055f3d344581918d62cde72070b233dad75419a4334f82146" "0.14": url: "https://github.com/epezent/implot/archive/v0.14.tar.gz" sha256: "1613af3e6554c0a74de20c6e60e9bce5ce35c2d4f9e1aa5ff963f7fe2d48af88" diff --git a/recipes/implot/all/conanfile.py b/recipes/implot/all/conanfile.py index ce2e069d3196dc..20e340b605f31e 100644 --- a/recipes/implot/all/conanfile.py +++ b/recipes/implot/all/conanfile.py @@ -1,28 +1,29 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import get, copy from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc import os required_conan_version = ">=1.54" class ImplotConan(ConanFile): name = "implot" + description = "Advanced 2D Plotting for Dear ImGui" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/epezent/implot" - description = "Advanced 2D Plotting for Dear ImGui" topics = ("imgui", "plot", "graphics", ) - license = "MIT" - settings = "os", "arch", "compiler", "build_type" package_type = "library" - + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False] + "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } def export_sources(self): @@ -37,7 +38,9 @@ def configure(self): self.options.rm_safe("fPIC") def requirements(self): - if Version(self.version) >= "0.14": + if Version(self.version) >= "0.15": + self.requires("imgui/1.89.8", transitive_headers=True) + elif Version(self.version) >= "0.14": self.requires("imgui/1.89.4", transitive_headers=True) elif Version(self.version) >= "0.13": # imgui 1.89 renamed ImGuiKeyModFlags_* to ImGuiModFlags_* @@ -48,6 +51,10 @@ def requirements(self): def layout(self): cmake_layout(self, src_folder="src") + def validate(self): + if Version(self.version) < "0.13" and is_msvc(self) and self.dependencies["imgui"].options.shared: + raise ConanInvalidConfiguration(f"{self.ref} doesn't support shared imgui.") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/implot/config.yml b/recipes/implot/config.yml index d62abd0d999a89..5c3099f028cc24 100644 --- a/recipes/implot/config.yml +++ b/recipes/implot/config.yml @@ -1,4 +1,6 @@ versions: + "0.15": + folder: "all" "0.14": folder: "all" "0.13": From da7183df6b05a6b97ae127d88394ddd19d670e55 Mon Sep 17 00:00:00 2001 From: Raziel Alphadios <64050682+RazielXYZ@users.noreply.github.com> Date: Wed, 16 Aug 2023 16:54:48 +0300 Subject: [PATCH 0243/1140] (#16134) Add bgfx MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Add bgfx with locally tested files * Fix projs list Add required system libs Better shared lib support * Add opengl/system requirement * Minimum apple-clang to 12 for now to keep CCI from compiling on macOS older than 11 Add apparently missing macOS frameworks * Apparently apple dylibs break if renamed * Fix oops of using settings instead of options * Fix conditional logic * Why is macos so difficult? * Fix test for Conan 2.x * Maybe this helps on macos * Make suggested changes * Update recipes/bgfx/all/test_package/conanfile.py Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> * Fix shared some more --------- Co-authored-by: Raziel Alphadios Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Co-authored-by: Francisco Ramírez --- recipes/bgfx/all/conandata.yml | 4 + recipes/bgfx/all/conanfile.py | 321 ++++++++++++++++++ recipes/bgfx/all/test_package/CMakeLists.txt | 9 + recipes/bgfx/all/test_package/conanfile.py | 25 ++ .../bgfx/all/test_package/test_package.cpp | 36 ++ .../bgfx/all/test_v1_package/CMakeLists.txt | 9 + recipes/bgfx/all/test_v1_package/conanfile.py | 17 + recipes/bgfx/config.yml | 3 + 8 files changed, 424 insertions(+) create mode 100644 recipes/bgfx/all/conandata.yml create mode 100644 recipes/bgfx/all/conanfile.py create mode 100644 recipes/bgfx/all/test_package/CMakeLists.txt create mode 100644 recipes/bgfx/all/test_package/conanfile.py create mode 100644 recipes/bgfx/all/test_package/test_package.cpp create mode 100644 recipes/bgfx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/bgfx/all/test_v1_package/conanfile.py create mode 100644 recipes/bgfx/config.yml diff --git a/recipes/bgfx/all/conandata.yml b/recipes/bgfx/all/conandata.yml new file mode 100644 index 00000000000000..47606f9539fe5a --- /dev/null +++ b/recipes/bgfx/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "cci.20230216": + url: "https://github.com/bkaradzic/bgfx/archive/9d5b980f5c060e54cc30dec18500a5b54db00405.tar.gz" + sha256: "291739720E369C5C2422273D887AEC590084B29E5C9DC5C9441F5A68869B6736" diff --git a/recipes/bgfx/all/conanfile.py b/recipes/bgfx/all/conanfile.py new file mode 100644 index 00000000000000..9de812b7f94ea5 --- /dev/null +++ b/recipes/bgfx/all/conanfile.py @@ -0,0 +1,321 @@ +from conan import ConanFile +from conan.tools.files import copy, get, rename +from conan.tools.build import check_min_cppstd +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc, check_min_vs, is_msvc_static_runtime +from conan.tools.apple import fix_apple_shared_install_name, is_apple_os +from conan.tools.scm import Version +from conan.errors import ConanInvalidConfiguration +from conan.tools.microsoft import MSBuild, VCVars +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.env import VirtualBuildEnv +from pathlib import Path +import os + +required_conan_version = ">=1.50.0" + +class bgfxConan(ConanFile): + name = "bgfx" + license = "BSD-2-Clause" + homepage = "https://github.com/bkaradzic/bgfx" + url = "https://github.com/conan-io/conan-center-index" + description = "Cross-platform, graphics API agnostic, \"Bring Your Own Engine/Framework\" style rendering library." + topics = ("rendering", "graphics") + settings = "os", "compiler", "arch", "build_type" + options = {"shared": [True, False], "tools": [True, False]} + default_options = {"shared": False, "tools": False} + + @property + def _bx_folder(self): + return "bx" + + @property + def _bimg_folder(self): + return "bimg" + + @property + def _bgfx_folder(self): + return "bgfx" + + @property + def _bgfx_path(self): + return os.path.join(self.source_folder, self._bgfx_folder) + + @property + def _genie_extra(self): + genie_extra = "" + if is_msvc(self) and not is_msvc_static_runtime(self): + genie_extra += " --with-dynamic-runtime" + if self.options.shared: + genie_extra += " --with-shared-lib" + if self.options.tools: + genie_extra += " --with-tools" + return genie_extra + + @property + def _lib_target_prefix(self): + if self.settings.os == "Windows": + return "libs\\" + else: + return "" + + @property + def _tool_target_prefix(self): + if self.settings.os == "Windows": + return "tools\\" + else: + return "" + + @property + def _shaderc_target_prefix(self): + if self.settings.os == "Windows": + return "shaderc\\" + else: + return "" + + @property + def _projs(self): + if self.options.shared: + projs = [f"{self._lib_target_prefix}bgfx-shared-lib"] + else: + projs = [f"{self._lib_target_prefix}bgfx"] + if self.options.tools: + projs.extend([f"{self._tool_target_prefix}{self._shaderc_target_prefix}shaderc", + f"{self._tool_target_prefix}texturev", + f"{self._tool_target_prefix}geometryc", + f"{self._tool_target_prefix}geometryv"]) + return projs + + @property + def _compiler_required(self): + return { + "gcc": "8", + "clang": "3.3", + "apple-clang": "12", #to keep CCI compiling on osx 11.0 or higher, for now + "msvc": "191", + "Visual Studio": "15" #TODO remove with conan 2.0 + } + + @property + def _bx_version(self): #mapping of bgfx version to required/used bx version + return {"cci.20230216": "cci.20221116"} + + @property + def _bimg_version(self): #mapping of bgfx version to required/used bimg version + return {"cci.20230216": "cci.20230114"} + + @property + def _settings_build(self): + return getattr(self, "settings_build", self.settings) + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + # bgfx's C99 API absolutely requires a header from bx so we need those to be transitive + self.requires(f"bx/{self._bx_version[self.version]}", transitive_headers=True) + self.requires(f"bimg/{self._bimg_version[self.version]}") + self.requires("opengl/system") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 14) + check_min_vs(self, 191) + if not is_msvc(self): + try: + minimum_required_compiler_version = self._compiler_required[str(self.settings.compiler)] + if Version(self.settings.compiler.version) < minimum_required_compiler_version: + raise ConanInvalidConfiguration("This package requires C++14 support. The current compiler does not support it.") + except KeyError: + self.output.warn("This recipe has no checking for the current compiler. Please consider adding it.") + + def build_requirements(self): + self.tool_requires("genie/1170") + if not is_msvc(self) and self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True, + destination=os.path.join(self.source_folder, self._bgfx_folder)) + # bgfx's genie project, and the projects generated by it, expect bx and bimg source to be present on the same relative root as bimg's in order to build + # usins a pre-built bx and bimg instead would require significant changes to the genie project but may be worth looking into in the future + get(self, **self.dependencies["bx"].conan_data["sources"][self._bx_version[self.version]], strip_root=True, + destination=os.path.join(self.source_folder, self._bx_folder)) + get(self, **self.dependencies["bimg"].conan_data["sources"][self._bimg_version[self.version]], strip_root=True, + destination=os.path.join(self.source_folder, self._bimg_folder)) + + def generate(self): + vbe = VirtualBuildEnv(self) + vbe.generate() + if is_msvc(self): + tc = VCVars(self) + tc.generate() + else: + tc = AutotoolsToolchain(self) + tc.generate() + + def build(self): + if is_msvc(self): + # Conan to Genie translation maps + vs_ver_to_genie = {"17": "2022", "16": "2019", "15": "2017", + "193": "2022", "192": "2019", "191": "2017"} + + # Use genie directly, then msbuild on specific projects based on requirements + genie_VS = f"vs{vs_ver_to_genie[str(self.settings.compiler.version)]}" + genie_gen = f"{self._genie_extra} {genie_VS}" + self.run(f"genie {genie_gen}", cwd=self._bgfx_path) + + msbuild = MSBuild(self) + # customize to Release when RelWithDebInfo + msbuild.build_type = "Debug" if self.settings.build_type == "Debug" else "Release" + # use Win32 instead of the default value when building x86 + msbuild.platform = "Win32" if self.settings.arch == "x86" else msbuild.platform + msbuild.build(os.path.join(self._bgfx_path, ".build", "projects", genie_VS, "bgfx.sln"), targets=self._projs) + else: + # Not sure if XCode can be spefically handled by conan for building through, so assume everything not VS is make + # gcc-multilib and g++-multilib required for 32bit cross-compilation, should see if we can check and install through conan + + # Conan to Genie translation maps + compiler_str = str(self.settings.compiler) + compiler_and_os_to_genie = {"Windows": f"--gcc=mingw-{compiler_str}", "Linux": f"--gcc=linux-{compiler_str}", + "FreeBSD": "--gcc=freebsd", "Macos": "--gcc=osx", + "Android": "--gcc=android", "iOS": "--gcc=ios"} + gmake_os_to_proj = {"Windows": "mingw", "Linux": "linux", "FreeBSD": "freebsd", "Macos": "osx", "Android": "android", "iOS": "ios"} + gmake_arch_to_genie_suffix = {"x86": "-x86", "x86_64": "-x64", "armv8": "-arm64", "armv7": "-arm"} + os_to_use_arch_config_suffix = {"Windows": False, "Linux": False, "FreeBSD": False, "Macos": True, "Android": True, "iOS": True} + + build_type_to_make_config = {"Debug": "config=debug", "Release": "config=release"} + arch_to_make_config_suffix = {"x86": "32", "x86_64": "64"} + os_to_use_make_config_suffix = {"Windows": True, "Linux": True, "FreeBSD": True, "Macos": False, "Android": False, "iOS": False} + + # Generate projects through genie + genieGen = f"{self._genie_extra} {compiler_and_os_to_genie[str(self.settings.os)]}" + if os_to_use_arch_config_suffix[str(self.settings.os)]: + genieGen += f"{gmake_arch_to_genie_suffix[str(self.settings.arch)]}" + genieGen += " gmake" + self.run(f"genie {genieGen}", cwd=self._bgfx_path) + + # Build project folder and path from given settings + projFolder = f"gmake-{gmake_os_to_proj[str(self.settings.os)]}" + if self.settings.os == "Windows" or compiler_str not in ["gcc", "apple-clang"]: + projFolder += f"-{compiler_str}" #mingw-gcc or mingw-clang for windows; -clang for linux (where gcc on linux has no extra) + if os_to_use_arch_config_suffix[str(self.settings.os)]: + projFolder += gmake_arch_to_genie_suffix[str(self.settings.arch)] + proj_path = os.path.sep.join([self._bgfx_path, ".build", "projects", projFolder]) + + # Build make args from settings + conf = build_type_to_make_config[str(self.settings.build_type)] + if os_to_use_make_config_suffix[str(self.settings.os)]: + conf += arch_to_make_config_suffix[str(self.settings.arch)] + if self.settings.os == "Windows": + mingw = "MINGW=$MINGW_PREFIX" + proj_path = proj_path.replace("\\", "/") # Fix path for msys... + else: + mingw = "" + autotools = Autotools(self) + # Build with make + for proj in self._projs: + autotools.make(target=proj, args=["-R", f"-C {proj_path}", mingw, conf]) + + def package(self): + # Set platform suffixes and prefixes + if self.settings.os == "Windows": + if self.options.shared: + lib_pat = "*bgfx-shared-lib*.lib" + else: + lib_pat = "*bgfx*.lib" + package_lib_prefix = "" + elif self.settings.os in ["Linux", "FreeBSD"]: + if self.options.shared: + lib_pat = "*bgfx*.so" + else: + lib_pat = "*bgfx*.a" + package_lib_prefix = "lib" + elif self.settings.os in ["Macos", "iOS"]: + if self.options.shared: + lib_pat = "*bgfx*.dylib" + else: + lib_pat = "*bgfx*.a" + package_lib_prefix = "lib" + + # Get build bin folder + for bimg_out_dir in os.listdir(os.path.join(self._bgfx_path, ".build")): + if not bimg_out_dir=="projects": + build_bin = os.path.join(self._bgfx_path, ".build", bimg_out_dir, "bin") + break + + # Copy license + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self._bgfx_path) + # Copy includes + copy(self, pattern="*.h", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self._bgfx_path, "include")) + # Copy libs + copy(self, pattern=lib_pat, dst=os.path.join(self.package_folder, "lib"), src=build_bin, keep_path=False) + if self.options.shared: + copy(self, pattern="*.dll", dst=os.path.join(self.package_folder, "bin"), src=build_bin, keep_path=False) + + # Copy tools + if self.options.tools: + copy(self, pattern="shaderc*", dst=os.path.join(self.package_folder, "bin"), src=build_bin, keep_path=False) + copy(self, pattern="texturev*", dst=os.path.join(self.package_folder, "bin"), src=build_bin, keep_path=False) + copy(self, pattern="geometryc*", dst=os.path.join(self.package_folder, "bin"), src=build_bin, keep_path=False) + copy(self, pattern="geometryv*", dst=os.path.join(self.package_folder, "bin"), src=build_bin, keep_path=False) + + # Rename for consistency across platforms and configs + if not (is_apple_os(self) and self.options.shared): #Apparently apple dylibs break if renamed + for bgfx_file in Path(os.path.join(self.package_folder, "lib")).glob("*bgfx*"): + rename(self, os.path.join(self.package_folder, "lib", bgfx_file.name), + os.path.join(self.package_folder, "lib", f"{package_lib_prefix}bgfx{bgfx_file.suffix}")) + if self.options.tools: + for bgfx_file in Path(os.path.join(self.package_folder, "bin")).glob("*shaderc*"): + rename(self, os.path.join(self.package_folder, "bin", bgfx_file.name), + os.path.join(self.package_folder, "bin", f"shaderc{bgfx_file.suffix}")) + for bgfx_file in Path(os.path.join(self.package_folder, "bin")).glob("*texturev*"): + rename(self, os.path.join(self.package_folder, "bin", bgfx_file.name), + os.path.join(self.package_folder, "bin", f"texturev{bgfx_file.suffix}")) + for bgfx_file in Path(os.path.join(self.package_folder, "bin")).glob("*geometryc*"): + rename(self, os.path.join(self.package_folder, "bin", bgfx_file.name), + os.path.join(self.package_folder, "bin", f"geometryc{bgfx_file.suffix}")) + for bgfx_file in Path(os.path.join(self.package_folder, "bin")).glob("*geometryv*"): + rename(self, os.path.join(self.package_folder, "bin", bgfx_file.name), + os.path.join(self.package_folder, "bin", f"geometryv{bgfx_file.suffix}")) + + # Maybe this helps + if is_apple_os(self): + fix_apple_shared_install_name(self) + + def package_info(self): + self.cpp_info.includedirs = ["include"] + if self.options.shared and self.settings.os in ["Macos", "iOS"]: + self.cpp_info.libs = [f"bgfx-shared-lib{self.settings.build_type}"] + else: + self.cpp_info.libs = ["bgfx"] + + if self.options.shared: + self.cpp_info.defines.extend(["BGFX_SHARED_LIB_USE=1"]) + + if self.settings.os == "Windows": + self.cpp_info.system_libs.extend(["gdi32"]) + if not is_msvc(self): + self.cpp_info.system_libs.extend(["comdlg32"]) + elif self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.extend(["X11", "GL"]) + elif self.settings.os in ["Macos", "iOS"]: + self.cpp_info.frameworks.extend(["CoreFoundation", "AppKit", "IOKit", "QuartzCore", "Metal"]) + if self.settings.os in ["Macos"]: + self.cpp_info.frameworks.extend(["OpenGL"]) + else: + self.cpp_info.frameworks.extend(["OpenGLES", "UIKit"]) + elif self.settings.os in ["Android"]: + self.cpp_info.system_libs.extend(["EGL", "GLESv2"]) + + self.cpp_info.set_property("cmake_file_name", "bgfx") + self.cpp_info.set_property("cmake_target_name", "bgfx::bgfx") + self.cpp_info.set_property("pkg_config_name", "bgfx") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.filenames["cmake_find_package"] = "bgfx" + self.cpp_info.filenames["cmake_find_package_multi"] = "bgfx" + self.cpp_info.names["cmake_find_package"] = "bgfx" + self.cpp_info.names["cmake_find_package_multi"] = "bgfx" diff --git a/recipes/bgfx/all/test_package/CMakeLists.txt b/recipes/bgfx/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..2c968e2dda7184 --- /dev/null +++ b/recipes/bgfx/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.8) + +project(test_package LANGUAGES CXX) + +find_package(bgfx REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) +target_link_libraries(${PROJECT_NAME} bgfx::bgfx) diff --git a/recipes/bgfx/all/test_package/conanfile.py b/recipes/bgfx/all/test_package/conanfile.py new file mode 100644 index 00000000000000..4e578144a798ad --- /dev/null +++ b/recipes/bgfx/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/bgfx/all/test_package/test_package.cpp b/recipes/bgfx/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..630c14bc99ec9a --- /dev/null +++ b/recipes/bgfx/all/test_package/test_package.cpp @@ -0,0 +1,36 @@ +//Important: bgfx shared on windows only works with the C99 API, the C++ API is not exported +#include + +#if BGFX_SHARED_LIB_USE && (BX_PLATFORM_WINDOWS || BX_PLATFORM_WINRT) +#include +#else +#include +#endif + +int main() { +#if BGFX_SHARED_LIB_USE && (BX_PLATFORM_WINDOWS || BX_PLATFORM_WINRT) + bgfx_init_t init; + bgfx_init_ctor(&init); + init.type = bgfx_renderer_type::BGFX_RENDERER_TYPE_NOOP; + init.vendorId = BGFX_PCI_ID_NONE; + init.platformData.nwh = nullptr; + init.platformData.ndt = nullptr; + init.resolution.width = 0; + init.resolution.height = 0; + init.resolution.reset = BGFX_RESET_NONE; + bgfx_init(&init); + bgfx_shutdown(); + return 0; +#else + bgfx::Init init; + init.type = bgfx::RendererType::Noop; + init.vendorId = BGFX_PCI_ID_NONE; + init.platformData.nwh = nullptr; + init.platformData.ndt = nullptr; + init.resolution.width = 0; + init.resolution.height = 0; + init.resolution.reset = BGFX_RESET_NONE; + bgfx::init(init); + bgfx::shutdown(); +#endif +} diff --git a/recipes/bgfx/all/test_v1_package/CMakeLists.txt b/recipes/bgfx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..667976629550a3 --- /dev/null +++ b/recipes/bgfx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.8) + +project(test_package LANGUAGES CXX) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/bgfx/all/test_v1_package/conanfile.py b/recipes/bgfx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..056e75eddb91cb --- /dev/null +++ b/recipes/bgfx/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class BimgTestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/bgfx/config.yml b/recipes/bgfx/config.yml new file mode 100644 index 00000000000000..0fa69d015c8447 --- /dev/null +++ b/recipes/bgfx/config.yml @@ -0,0 +1,3 @@ +versions: + "cci.20230216": + folder: all From b7cf54029b6ba9176ef313f0213acd382784c712 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 16 Aug 2023 17:31:57 +0300 Subject: [PATCH 0244/1140] (#18258) rangesnext: migrate to Conan v2 * rangesnext: migrate to Conan v2 * rangesnext: restore test_v1_package * rangesnext: update min compiler versions * rangesnext: not compatible with Clang * rangesnext: restore VirtualRunEnv in test_package * rangesnext: fix min Visual Studio version --------- Co-authored-by: Daniel --- recipes/rangesnext/all/conandata.yml | 3 +- recipes/rangesnext/all/conanfile.py | 65 ++++++++++++++----- .../all/test_package/CMakeLists.txt | 7 +- .../rangesnext/all/test_package/conanfile.py | 22 +++++-- .../all/test_package/test_package.cpp | 7 +- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 16 +++++ 7 files changed, 95 insertions(+), 33 deletions(-) create mode 100644 recipes/rangesnext/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rangesnext/all/test_v1_package/conanfile.py diff --git a/recipes/rangesnext/all/conandata.yml b/recipes/rangesnext/all/conandata.yml index 72383f2492ee79..29a3d8ef00ff09 100644 --- a/recipes/rangesnext/all/conandata.yml +++ b/recipes/rangesnext/all/conandata.yml @@ -1,8 +1,7 @@ sources: "cci.20210426": url: "https://github.com/cor3ntin/rangesnext/archive/10fd1cffe7a2a9688a31f91ec8754668c4cdd9a6.tar.gz" - sha256: 8b4ba9129346818d1ad2ab1fe00ccb85c5c1b35fef91868aece97aa079e0dec4 + sha256: "8b4ba9129346818d1ad2ab1fe00ccb85c5c1b35fef91868aece97aa079e0dec4" patches: "cci.20210426": - patch_file: "patches/0001-cmake-disable-tests.patch" - base_path: "source_subfolder" diff --git a/recipes/rangesnext/all/conanfile.py b/recipes/rangesnext/all/conanfile.py index b438391b226f93..6c7782838deee2 100644 --- a/recipes/rangesnext/all/conanfile.py +++ b/recipes/rangesnext/all/conanfile.py @@ -1,37 +1,68 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class RangesnextConan(ConanFile): name = "rangesnext" description = "ranges features for C++23 ported to C++20" - topics = ("conan", "rangesnext", "ranges", "backport", "backport-cpp") + license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/cor3ntin/rangesnext" - license = "BSL-1.0" - settings = "compiler" + topics = ("ranges", "backport", "backport-cpp", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - _compilers_minimum_version = { - "gcc": "10", - "Visual Studio": "19", - "clang": "13" - } - _source_subfolder = "source_subfolder" + @property + def _min_cppstd(self): + return 20 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "10", + "msvc": "193", + "Visual Studio": "17", + } + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, "20") + check_min_cppstd(self, self._min_cppstd) + + if "clang" in str(self.settings.compiler): + raise ConanInvalidConfiguration("rangesnext is not compatible with Clang") minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version or tools.Version(self.settings.compiler.version) < minimum_version: + if not minimum_version or Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration("rangesnext requires C++20, which your compiler does not fully support.") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - include_folder = os.path.join(self._source_subfolder, "include") - self.copy(pattern="LICENSE.md", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*", dst="include", src=include_folder) + include_folder = os.path.join(self.source_folder, "include") + copy(self, "LICENSE.md", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=include_folder) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/rangesnext/all/test_package/CMakeLists.txt b/recipes/rangesnext/all/test_package/CMakeLists.txt index 2bd2a465ffb060..9b8b15ab7a013f 100644 --- a/recipes/rangesnext/all/test_package/CMakeLists.txt +++ b/recipes/rangesnext/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(rangesnext REQUIRED CONFIG) diff --git a/recipes/rangesnext/all/test_package/conanfile.py b/recipes/rangesnext/all/test_package/conanfile.py index 6c9d5dba712c72..ef5d7042163ecc 100644 --- a/recipes/rangesnext/all/test_package/conanfile.py +++ b/recipes/rangesnext/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rangesnext/all/test_package/test_package.cpp b/recipes/rangesnext/all/test_package/test_package.cpp index e25f23d0966045..f1a7ea7bef564d 100644 --- a/recipes/rangesnext/all/test_package/test_package.cpp +++ b/recipes/rangesnext/all/test_package/test_package.cpp @@ -1,6 +1,7 @@ -#include #include +#include + namespace rangesnext = cor3ntin::rangesnext; template @@ -12,11 +13,11 @@ bool test_enumerate_with(RangeT &&range) { bool success = true; for (auto &&[i, v] : enumerated_range) { - std::cout << i << " - " << v << "\n"; + std::cout << i << " - " << v << "\n"; success = (i == idx_ref++) && (v == *it_ref++); if (success == false) { - return false; + return false; } } diff --git a/recipes/rangesnext/all/test_v1_package/CMakeLists.txt b/recipes/rangesnext/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rangesnext/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rangesnext/all/test_v1_package/conanfile.py b/recipes/rangesnext/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/rangesnext/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 0461dc91a45fed5cbcd02bbe4ee7dfc957ab41ea Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 16 Aug 2023 18:22:07 +0300 Subject: [PATCH 0245/1140] (#18266) platform.exceptions: migrate to Conan v2 * platform.exceptions: migrate to Conan v2 * platform.exceptions: restore test_v1_package * platform.exceptions: add cmake_find_package_multi generator to test_v1_package * platform.exceptions: restore VirtualRunEnv in test_package * platform.exceptions: bump deps --- recipes/platform.exceptions/all/conanfile.py | 75 +++++++++++-------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 21 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++++ 5 files changed, 86 insertions(+), 42 deletions(-) create mode 100644 recipes/platform.exceptions/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/platform.exceptions/all/test_v1_package/conanfile.py diff --git a/recipes/platform.exceptions/all/conanfile.py b/recipes/platform.exceptions/all/conanfile.py index e352e58aa4f019..28942c0367e11c 100644 --- a/recipes/platform.exceptions/all/conanfile.py +++ b/recipes/platform.exceptions/all/conanfile.py @@ -1,28 +1,34 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class PlatformExceptionsConan(ConanFile): name = "platform.exceptions" + description = "platform.exceptions is one of the libraries of the LinksPlatform modular framework, to ensure exceptions" license = "MIT" - homepage = "https://github.com/linksplatform/Exceptions" url = "https://github.com/conan-io/conan-center-index" - description = "platform.exceptions is one of the libraries of the LinksPlatform modular framework, " \ - "to ensure exceptions" - topics = ("linksplatform", "cpp20", "exceptions", "any", "ranges", "native") - settings = "compiler", "arch" + homepage = "https://github.com/linksplatform/Exceptions" + topics = ("linksplatform", "cpp20", "exceptions", "any", "ranges", "native", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _minimum_cpp_standard(self): + return 20 @property def _internal_cpp_subfolder(self): - return os.path.join(self._source_subfolder, "cpp", "Platform.Exceptions") + return os.path.join(self.source_folder, "cpp", "Platform.Exceptions") @property def _compilers_minimum_version(self): @@ -30,42 +36,47 @@ def _compilers_minimum_version(self): "gcc": "10", "Visual Studio": "16", "clang": "11", - "apple-clang": "11" + "apple-clang": "11", } - @property - def _minimum_cpp_standard(self): - return 20 + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): - if tools.Version(self.version) >= "0.3.0": - self.requires("platform.delegates/0.2.7") + if Version(self.version) >= "0.3.0": + self.requires("platform.delegates/0.3.7") else: self.requires("platform.delegates/0.1.3") + def package_id(self): + self.info.clear() + def validate(self): minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) if not minimum_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") - elif tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{}/{} requires c++{}, " - "which is not supported by {} {}.".format( - self.name, self.version, self._minimum_cpp_standard, self.settings.compiler, - self.settings.compiler.version)) + elif Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.name}/{self.version} requires c++{self._minimum_cpp_standard}, which is not supported" + f" by {self.settings.compiler} {self.settings.compiler.version}." + ) if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) - - def package_id(self): - self.info.header_only() + check_min_cppstd(self, self._minimum_cpp_standard) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*.h", dst="include", src=self._internal_cpp_subfolder) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=self._internal_cpp_subfolder) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/platform.exceptions/all/test_package/CMakeLists.txt b/recipes/platform.exceptions/all/test_package/CMakeLists.txt index dadfcbe5ecf0af..a63090495da9c5 100644 --- a/recipes/platform.exceptions/all/test_package/CMakeLists.txt +++ b/recipes/platform.exceptions/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(platform.exceptions REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE platform.exceptions::platform.exceptions) set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 20) diff --git a/recipes/platform.exceptions/all/test_package/conanfile.py b/recipes/platform.exceptions/all/test_package/conanfile.py index d4128b04507778..ef5d7042163ecc 100644 --- a/recipes/platform.exceptions/all/test_package/conanfile.py +++ b/recipes/platform.exceptions/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/platform.exceptions/all/test_v1_package/CMakeLists.txt b/recipes/platform.exceptions/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/platform.exceptions/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/platform.exceptions/all/test_v1_package/conanfile.py b/recipes/platform.exceptions/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/platform.exceptions/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 239d75c4ca6d6047017f325902f6e4c7f9e56c5f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludwig=20F=C3=BCchsl?= Date: Wed, 16 Aug 2023 18:55:19 +0200 Subject: [PATCH 0246/1140] (#19224) [package] lz4/1.9.4 : Bugfix / Patch to support lz4 and xxhash at the same time. * Patch to support lz4 and xxhash at the same time. * Remove whitespace --- recipes/lz4/all/conandata.yml | 5 +++++ ...pace-declaration-for-xxhash-in-CMake.patch | 19 +++++++++++++++++++ 2 files changed, 24 insertions(+) create mode 100644 recipes/lz4/all/patches/0004-Added-namespace-declaration-for-xxhash-in-CMake.patch diff --git a/recipes/lz4/all/conandata.yml b/recipes/lz4/all/conandata.yml index 577763acfe7a6a..fc3f8472653fd5 100644 --- a/recipes/lz4/all/conandata.yml +++ b/recipes/lz4/all/conandata.yml @@ -9,6 +9,11 @@ sources: sha256: 658ba6191fa44c92280d4aa2c271b0f4fbc0e34d249578dd05e50e76d0e5efcc url: https://github.com/lz4/lz4/archive/v1.9.2.tar.gz patches: + "1.9.4": + - patch_file: "patches/0004-Added-namespace-declaration-for-xxhash-in-CMake.patch" + patch_description: "Added namespace/prefix for xxHash functions by altering CMakeLists.txt" + patch_type: official + patch_source: "https://github.com/lz4/lz4/pull/1258" "1.9.3": - patch_file: "patches/0003-cmake-minimum-required-first-1.9.3.patch" patch_description: "Move cmake_minimum_required to the top of CMakeFile.txt" diff --git a/recipes/lz4/all/patches/0004-Added-namespace-declaration-for-xxhash-in-CMake.patch b/recipes/lz4/all/patches/0004-Added-namespace-declaration-for-xxhash-in-CMake.patch new file mode 100644 index 00000000000000..04a888ec1c4442 --- /dev/null +++ b/recipes/lz4/all/patches/0004-Added-namespace-declaration-for-xxhash-in-CMake.patch @@ -0,0 +1,19 @@ +--- a/build/cmake/CMakeLists.txt ++++ b/build/cmake/CMakeLists.txt +@@ -131,6 +131,16 @@ if(BUILD_STATIC_LIBS) + list(APPEND LZ4_LIBRARIES_BUILT lz4_static) + endif() + ++# xxhash namesapce ++if(BUILD_SHARED_LIBS) ++ target_compile_definitions(lz4_shared PRIVATE ++ XXH_NAMESPACE=LZ4_) ++endif() ++if(BUILD_STATIC_LIBS) ++ target_compile_definitions(lz4_static PRIVATE ++ XXH_NAMESPACE=LZ4_) ++endif() ++ + if(BUILD_STATIC_LIBS) + set(LZ4_LINK_LIBRARY lz4_static) + else() From bdfa780b1a265b8c5fb01b5b3294bc836ddab1b7 Mon Sep 17 00:00:00 2001 From: Stefan Floeren <42731906+stefan-floeren@users.noreply.github.com> Date: Wed, 16 Aug 2023 21:53:22 +0200 Subject: [PATCH 0247/1140] (#19225) utfcpp: add 3.2.4 - Add version 3.2.4 - Set target to utf8cpp::utf8cpp Co-authored-by: Stefan Floeren --- recipes/utfcpp/all/conandata.yml | 3 +++ recipes/utfcpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/utfcpp/all/conandata.yml b/recipes/utfcpp/all/conandata.yml index f435f56f7acf1c..572f41ae51de7e 100644 --- a/recipes/utfcpp/all/conandata.yml +++ b/recipes/utfcpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.4": + url: "https://github.com/nemtrif/utfcpp/archive/refs/tags/v3.2.4.tar.gz" + sha256: "fde21a4c519eed25f095a1cd8490167409cc70d7b5e9c38756142e588ccb7c7e" "3.2.3": url: "https://github.com/nemtrif/utfcpp/archive/v3.2.3.tar.gz" sha256: "3ba9b0dbbff08767bdffe8f03b10e596ca351228862722e4c9d4d126d2865250" diff --git a/recipes/utfcpp/config.yml b/recipes/utfcpp/config.yml index 00df0fb881cb8a..b0811297690469 100644 --- a/recipes/utfcpp/config.yml +++ b/recipes/utfcpp/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.4": + folder: all "3.2.3": folder: all "3.2.2": From fb392e83252f231a5f22694d7390a56b33c995c8 Mon Sep 17 00:00:00 2001 From: Pat Mancuso <46453397+patmantru@users.noreply.github.com> Date: Wed, 16 Aug 2023 22:48:45 -0400 Subject: [PATCH 0248/1140] (#18896) Adds opentdf-client versions 1.4.0 and 1.5.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Adds versions 1.4.0 and 1.5.0 * Need magic_enum for 1.4.0 also * Update to new release content * Update to newest release tag content * Change OpenSSL version references to ranges per CCI requirements * fix typo * Try different range spec for 1.1.x * Try another range spec for openssl 1.1.x * Another try at version ranges * Still another try at ranges for openssl 1.1.x * Pick a version range that is also compatible with jwt-cpp * openssl/[>=3.1 <3.2] range is not compatible with jwt-cpp. Use fixed version to override * One more try with newer jwt-cpp and ranges * Avoid jwt-cpp complaint about OpenSSL 1.1.1u * Override 3.1.1 for openssl to avoid jwt-cpp complaint * jwt-cpp requires are broken forr 0.5.0 and 0.6.0, avoid * opentdf-client: update openssl version ranges --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/opentdf-client/all/conandata.yml | 6 ++++++ recipes/opentdf-client/all/conanfile.py | 11 ++++++++++- recipes/opentdf-client/config.yml | 4 ++++ 3 files changed, 20 insertions(+), 1 deletion(-) diff --git a/recipes/opentdf-client/all/conandata.yml b/recipes/opentdf-client/all/conandata.yml index 17500dcbe918bd..382304e4f3de03 100644 --- a/recipes/opentdf-client/all/conandata.yml +++ b/recipes/opentdf-client/all/conandata.yml @@ -1,4 +1,10 @@ sources: + "1.5.0": + url: "https://github.com/opentdf/client-cpp/archive/1.5.0.tar.gz" + sha256: "0d6134634c0c6fde5e8457361332242259e1ef238e5254ccbed2f94549998c48" + "1.4.0": + url: "https://github.com/opentdf/client-cpp/archive/1.4.0.tar.gz" + sha256: "0ef9cdf5e49f83a8ddcde10d64cdf9108652e781396cfab000f50cc067e6f795" "1.3.10": url: "https://github.com/opentdf/client-cpp/archive/1.3.10.tar.gz" sha256: "539bd5e64bceb86f63b3f7db75de470d5ea1d52ae6436a6a2d6789f7d0710dd4" diff --git a/recipes/opentdf-client/all/conanfile.py b/recipes/opentdf-client/all/conanfile.py index 06337331572114..1c4773399329ba 100644 --- a/recipes/opentdf-client/all/conanfile.py +++ b/recipes/opentdf-client/all/conanfile.py @@ -66,7 +66,14 @@ def validate(self): raise ConanInvalidConfiguration(f'{self.name} can not be built with MT or MTd at this time') def requirements(self): - self.requires("openssl/1.1.1q") + # Uses openssl 3.x for 1.5.0 and newer + if Version(self.version) >= "1.5.0": + self.requires("openssl/[>=3.1 <4]") + else: + self.requires("openssl/1.1.1u") + # Uses magic_enum for 1.4.0 and newer + if Version(self.version) >= "1.4.0": + self.requires("magic_enum/0.8.2") self.requires("ms-gsl/2.1.0") self.requires("nlohmann_json/3.11.1") self.requires("jwt-cpp/0.4.0") @@ -121,3 +128,5 @@ def package_info(self): self.cpp_info.components["libopentdf"].requires = ["openssl::openssl", "boost::boost", "ms-gsl::ms-gsl", "libxml2::libxml2", "jwt-cpp::jwt-cpp", "nlohmann_json::nlohmann_json"] if Version(self.version) < "1.1.0": self.cpp_info.components["libopentdf"].requires.append("libarchive::libarchive") + if Version(self.version) >= "1.4.0": + self.cpp_info.components["libopentdf"].requires.append("magic_enum::magic_enum") diff --git a/recipes/opentdf-client/config.yml b/recipes/opentdf-client/config.yml index 6747766ab2d490..109b67265732eb 100644 --- a/recipes/opentdf-client/config.yml +++ b/recipes/opentdf-client/config.yml @@ -1,4 +1,8 @@ versions: + "1.5.0": + folder: all + "1.4.0": + folder: all "1.3.10": folder: all "1.3.9": From acde2b2419e6e131d86a5aac656d40d9fe267932 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 17 Aug 2023 12:29:44 +0900 Subject: [PATCH 0249/1140] (#19236) json-c: add version 0.17 --- recipes/json-c/all/conandata.yml | 3 +++ recipes/json-c/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/json-c/all/conandata.yml b/recipes/json-c/all/conandata.yml index 7ed706059e17cb..a27364e09b956a 100644 --- a/recipes/json-c/all/conandata.yml +++ b/recipes/json-c/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.17": + url: "https://github.com/json-c/json-c/archive/json-c-0.17-20230812.tar.gz" + sha256: "024d302a3aadcbf9f78735320a6d5aedf8b77876c8ac8bbb95081ca55054c7eb" "0.16": url: "https://github.com/json-c/json-c/archive/json-c-0.16-20220414.tar.gz" sha256: "3ecaeedffd99a60b1262819f9e60d7d983844073abc74e495cb822b251904185" diff --git a/recipes/json-c/config.yml b/recipes/json-c/config.yml index 1e4023fe840463..301a8d09f5b3a5 100644 --- a/recipes/json-c/config.yml +++ b/recipes/json-c/config.yml @@ -1,4 +1,6 @@ versions: + "0.17": + folder: all "0.16": folder: all "0.15": From 3f28198497dafd9fe2cce348d2a7c182b7d3d7e0 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 17 Aug 2023 07:27:25 +0200 Subject: [PATCH 0250/1140] (#19180) onnxruntime: bump deps --- recipes/onnxruntime/all/conanfile.py | 10 +++++----- .../patches/1.14.1-0002-cmake-dependencies.patch | 13 ------------- .../patches/1.15.1-0001-cmake-dependencies.patch | 13 ------------- 3 files changed, 5 insertions(+), 31 deletions(-) diff --git a/recipes/onnxruntime/all/conanfile.py b/recipes/onnxruntime/all/conanfile.py index 7d8bf9dd19bda8..f8951c6e253746 100644 --- a/recipes/onnxruntime/all/conanfile.py +++ b/recipes/onnxruntime/all/conanfile.py @@ -72,22 +72,22 @@ def _onnx_version(self): }[f"{version.major}.{version.minor}"] def requirements(self): - self.requires("abseil/20230125.2") + self.requires("abseil/20230125.3") self.requires("protobuf/3.21.9") self.requires("date/3.0.1") self.requires("re2/20230301") self.requires(f"onnx/{self._onnx_version}") self.requires("flatbuffers/1.12.0") - self.requires("boost/1.81.0", headers=True, libs=False, run=False) # for mp11, header only, no need for libraries to link/run + self.requires("boost/1.82.0", headers=True, libs=False, run=False) # for mp11, header only, no need for libraries to link/run self.requires("safeint/3.0.28") self.requires("nlohmann_json/3.11.2") self.requires("eigen/3.4.0") self.requires("ms-gsl/4.0.0") - self.requires("cpuinfo/cci.20220228") + self.requires("cpuinfo/cci.20220618") if self.settings.os != "Windows": - self.requires("nsync/1.25.0") + self.requires("nsync/1.26.0") else: - self.requires("wil/1.0.230202.1") + self.requires("wil/1.0.230629.1") if self.options.with_xnnpack: self.requires("xnnpack/cci.20220801") diff --git a/recipes/onnxruntime/all/patches/1.14.1-0002-cmake-dependencies.patch b/recipes/onnxruntime/all/patches/1.14.1-0002-cmake-dependencies.patch index 9d0a0f67636135..6dbbfc4af9df48 100644 --- a/recipes/onnxruntime/all/patches/1.14.1-0002-cmake-dependencies.patch +++ b/recipes/onnxruntime/all/patches/1.14.1-0002-cmake-dependencies.patch @@ -149,19 +149,6 @@ index 1fc2c6ccdc..a2c28957f9 100644 set(onnxruntime_EXTERNAL_LIBRARIES_XNNPACK XNNPACK pthreadpool) -diff --git a/cmake/onnxruntime_common.cmake b/cmake/onnxruntime_common.cmake -index 0410d3361c..685df7a487 100644 ---- a/cmake/onnxruntime_common.cmake -+++ b/cmake/onnxruntime_common.cmake -@@ -195,7 +195,7 @@ if (ARM64 OR ARM OR X86 OR X64 OR X86_64) - # Its functionality in detecting x86 cpu features are lacking, so is support for Windows. - if (CPUINFO_SUPPORTED) - onnxruntime_add_include_to_target(onnxruntime_common cpuinfo::cpuinfo) -- list(APPEND onnxruntime_EXTERNAL_LIBRARIES cpuinfo::cpuinfo cpuinfo::clog) -+ list(APPEND onnxruntime_EXTERNAL_LIBRARIES cpuinfo::cpuinfo) - endif() - endif() - endif() diff --git a/cmake/onnxruntime_providers.cmake b/cmake/onnxruntime_providers.cmake index 7a99bac233..bbf1955494 100644 --- a/cmake/onnxruntime_providers.cmake diff --git a/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch b/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch index 7da019aa807e9d..bee9115bc809ef 100644 --- a/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch +++ b/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch @@ -142,19 +142,6 @@ index 1fc2c6ccdc..a2c28957f9 100644 set(onnxruntime_EXTERNAL_LIBRARIES_XNNPACK XNNPACK pthreadpool) -diff --git a/cmake/onnxruntime_common.cmake b/cmake/onnxruntime_common.cmake -index 0410d3361c..685df7a487 100644 ---- a/cmake/onnxruntime_common.cmake -+++ b/cmake/onnxruntime_common.cmake -@@ -195,7 +195,7 @@ if (ARM64 OR ARM OR X86 OR X64 OR X86_64) - # Its functionality in detecting x86 cpu features are lacking, so is support for Windows. - if (CPUINFO_SUPPORTED) - onnxruntime_add_include_to_target(onnxruntime_common cpuinfo::cpuinfo) -- list(APPEND onnxruntime_EXTERNAL_LIBRARIES cpuinfo::cpuinfo cpuinfo::clog) -+ list(APPEND onnxruntime_EXTERNAL_LIBRARIES cpuinfo::cpuinfo) - endif() - endif() - endif() diff --git a/cmake/onnxruntime_providers.cmake b/cmake/onnxruntime_providers.cmake index 0daa1b8a3d..1f25467a8c 100644 --- a/cmake/onnxruntime_providers.cmake From 9e96c5b7242eab7c628d3af961793d2c0863385e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 08:44:48 +0300 Subject: [PATCH 0251/1140] (#18115) panzi-portable-endian: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * panzi-portable-endian: migrate to Conan v2 * panzi-portable-endian: convert test_package from C++ to C * panzi-portable-endian: restore test_v1_package * panzi-portable-endian: add cmake_find_package_multi generator to test_v1_package * panzi-portable-endian: bump version for MSVC bugfix * panzi-portable-endian: restore VirtualRunEnv in test_package * Set proper license --------- Co-authored-by: Rubén Rincón --- .../panzi-portable-endian/all/conandata.yml | 6 +-- .../panzi-portable-endian/all/conanfile.py | 45 +++++++++++-------- .../all/test_package/CMakeLists.txt | 12 +++-- .../all/test_package/conanfile.py | 21 ++++++--- .../{test_package.cpp => test_package.c} | 2 +- .../all/test_v1_package/CMakeLists.txt | 8 ++++ .../all/test_v1_package/conanfile.py | 17 +++++++ recipes/panzi-portable-endian/config.yml | 2 +- 8 files changed, 77 insertions(+), 36 deletions(-) rename recipes/panzi-portable-endian/all/test_package/{test_package.cpp => test_package.c} (81%) create mode 100644 recipes/panzi-portable-endian/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/panzi-portable-endian/all/test_v1_package/conanfile.py diff --git a/recipes/panzi-portable-endian/all/conandata.yml b/recipes/panzi-portable-endian/all/conandata.yml index 5cba065a6c8226..a4dfc7805d29ce 100644 --- a/recipes/panzi-portable-endian/all/conandata.yml +++ b/recipes/panzi-portable-endian/all/conandata.yml @@ -1,4 +1,4 @@ sources: - "cci.20150416": - url: "https://gist.github.com/panzi/6856583/archive/1eca2ab34f2301b9641aa73d1016b951fff3fc39.zip" - sha256: "488d5d08215f657e769b31764013ef845355832cc6f1d165e1809fa5fe168eeb" + "cci.20220509": + url: "https://gist.github.com/panzi/6856583/archive/f6512b0830a4e9e06b26e32fc2509d67bbfa93d8.zip" + sha256: "88593bad9a1050779e98f93194b028566df575e06da9f8a60e44fa97a36b92f8" diff --git a/recipes/panzi-portable-endian/all/conanfile.py b/recipes/panzi-portable-endian/all/conanfile.py index 9c18999c225be6..5655ba304a520a 100644 --- a/recipes/panzi-portable-endian/all/conanfile.py +++ b/recipes/panzi-portable-endian/all/conanfile.py @@ -1,34 +1,43 @@ import os -from conans import ConanFile, tools + +from conan import ConanFile +from conan.tools.files import copy, get, load, save +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class PanziPortableEndian(ConanFile): name = "panzi-portable-endian" + description = ("This provides the endian conversion functions from " + "endian.h on Windows, Linux, *BSD, and Mac OS X") + license = "LicenseRef-panzi-portable-endian-public-domain" url = "https://github.com/conan-io/conan-center-index" homepage = "https://gist.github.com/panzi/6856583" - description = "This provides the endian conversion functions form endian.h on Windows, Linux, *BSD, and Mac OS X" - topics = ("conan", "endian") - license = "Unlicense" + topics = ("endian", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def _extract_license(self): - header = tools.load(os.path.join( - self._source_subfolder, "portable_endian.h")) - license_contents = header[0:(header.find("#ifndef", 1))] - tools.save("LICENSE", license_contents) + header = load(self, os.path.join(self.source_folder, "portable_endian.h")) + license_contents = header[0: (header.find("#ifndef", 1))] + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_contents) def package(self): self._extract_license() - self.copy("LICENSE", dst="licenses") - self.copy(pattern="*.h", dst="include", - src=self._source_subfolder, keep_path=False) + copy(self, "*.h", dst=os.path.join(self.package_folder, "include"), src=self.source_folder, keep_path=False) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/panzi-portable-endian/all/test_package/CMakeLists.txt b/recipes/panzi-portable-endian/all/test_package/CMakeLists.txt index 454c47bb2cbab0..272ae426964be8 100644 --- a/recipes/panzi-portable-endian/all/test_package/CMakeLists.txt +++ b/recipes/panzi-portable-endian/all/test_package/CMakeLists.txt @@ -1,9 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(panzi-portable-endian REQUIRED CONFIG) -add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE panzi-portable-endian::panzi-portable-endian) diff --git a/recipes/panzi-portable-endian/all/test_package/conanfile.py b/recipes/panzi-portable-endian/all/test_package/conanfile.py index a59a26a52c8dcd..ef5d7042163ecc 100644 --- a/recipes/panzi-portable-endian/all/test_package/conanfile.py +++ b/recipes/panzi-portable-endian/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/panzi-portable-endian/all/test_package/test_package.cpp b/recipes/panzi-portable-endian/all/test_package/test_package.c similarity index 81% rename from recipes/panzi-portable-endian/all/test_package/test_package.cpp rename to recipes/panzi-portable-endian/all/test_package/test_package.c index d5884326032eaf..8a45d0928397d6 100644 --- a/recipes/panzi-portable-endian/all/test_package/test_package.cpp +++ b/recipes/panzi-portable-endian/all/test_package/test_package.c @@ -1,4 +1,4 @@ -#include +#include #include diff --git a/recipes/panzi-portable-endian/all/test_v1_package/CMakeLists.txt b/recipes/panzi-portable-endian/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/panzi-portable-endian/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/panzi-portable-endian/all/test_v1_package/conanfile.py b/recipes/panzi-portable-endian/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/panzi-portable-endian/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/panzi-portable-endian/config.yml b/recipes/panzi-portable-endian/config.yml index 5b6ed6e7fb0747..dcdd7cd8a501e1 100644 --- a/recipes/panzi-portable-endian/config.yml +++ b/recipes/panzi-portable-endian/config.yml @@ -1,3 +1,3 @@ versions: - "cci.20150416": + "cci.20220509": folder: all From 966858bb4a8db12d90f15a7ddec2c7f39cd5340d Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 09:05:31 +0300 Subject: [PATCH 0252/1140] (#18170) aggeom-agg: add package_type, tidy * aggeom-agg: add package_type, tidy * aggeom-agg: restore test_v1_package --------- Co-authored-by: Carlos Zoido --- recipes/aggeom-agg/all/conanfile.py | 119 +++++++++--------- .../all/test_v1_package/CMakeLists.txt | 6 +- 2 files changed, 61 insertions(+), 64 deletions(-) diff --git a/recipes/aggeom-agg/all/conanfile.py b/recipes/aggeom-agg/all/conanfile.py index 55a67e88a5f75c..991d2d1af6b1e3 100644 --- a/recipes/aggeom-agg/all/conanfile.py +++ b/recipes/aggeom-agg/all/conanfile.py @@ -1,49 +1,43 @@ +import os + from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import copy, get, rmdir -from conan.errors import ConanInvalidConfiguration - -import os required_conan_version = ">=1.53.0" class AggConan(ConanFile): - name = 'aggeom-agg' - description = 'AGG Anti-Grain Geometry Library' - topics = ('graphics') + name = "aggeom-agg" + description = "AGG Anti-Grain Geometry Library" + license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" - homepage = 'https://github.com/aggeom' - license = 'BSD-3-Clause' + homepage = "https://github.com/aggeom" + topics = ("graphics",) - settings = 'os', 'arch', 'compiler', 'build_type' + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { - 'shared': [True, False], - 'fPIC': [True, False], - 'with_gpc': [True, False], - 'with_freetype': [True, False], - 'with_agg2d': [True, False], - 'with_agg2d_freetype': [True, False], - 'with_platform': [True, False], - 'with_controls': [True, False], + "shared": [True, False], + "fPIC": [True, False], + "with_gpc": [True, False], + "with_freetype": [True, False], + "with_agg2d": [True, False], + "with_agg2d_freetype": [True, False], + "with_platform": [True, False], + "with_controls": [True, False], } - default_options = { - 'shared': False, - 'fPIC': True, - 'with_gpc': True, - 'with_freetype': True, - 'with_agg2d': True, - 'with_agg2d_freetype': True, - 'with_platform': True, - 'with_controls': True, + "shared": False, + "fPIC": True, + "with_gpc": True, + "with_freetype": True, + "with_agg2d": True, + "with_agg2d_freetype": True, + "with_platform": True, + "with_controls": True, } - def validate(self): - if self.settings.os not in ("Windows", "Linux"): - raise ConanInvalidConfiguration("OS is not supported") - if self.options.shared: - raise ConanInvalidConfiguration("Invalid configuration") - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -51,31 +45,37 @@ def config_options(self): def configure(self): self.options.rm_safe("fPIC") - def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root=True) - def layout(self): cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_freetype: - self.requires('freetype/2.13.0') + self.requires("freetype/2.13.0") if self.options.with_platform and self.settings.os in ["Linux"]: self.requires("xorg/system") + def validate(self): + if self.settings.os not in ("Windows", "Linux"): + raise ConanInvalidConfiguration("OS is not supported") + if self.options.shared: + raise ConanInvalidConfiguration("Invalid configuration") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + def generate(self): tc = CMakeToolchain(self) - tc.variables['agg_USE_EXPAT'] = False - tc.variables['agg_USE_SDL_PLATFORM'] = False - tc.variables['agg_BUILD_DEMO'] = False - tc.variables['agg_BUILD_EXAMPLES'] = False - - tc.variables['agg_USE_GPC'] = self.options.with_gpc - tc.variables['agg_USE_FREETYPE'] = self.options.with_freetype - tc.variables['agg_USE_AGG2D'] = self.options.with_agg2d - tc.variables['agg_USE_AGG2D_FREETYPE'] = self.options.with_agg2d_freetype - tc.variables['agg_BUILD_PLATFORM'] = self.options.with_platform - tc.variables['agg_BUILD_CONTROLS'] = self.options.with_controls + tc.variables["agg_USE_EXPAT"] = False + tc.variables["agg_USE_SDL_PLATFORM"] = False + tc.variables["agg_BUILD_DEMO"] = False + tc.variables["agg_BUILD_EXAMPLES"] = False + + tc.variables["agg_USE_GPC"] = self.options.with_gpc + tc.variables["agg_USE_FREETYPE"] = self.options.with_freetype + tc.variables["agg_USE_AGG2D"] = self.options.with_agg2d + tc.variables["agg_USE_AGG2D_FREETYPE"] = self.options.with_agg2d_freetype + tc.variables["agg_BUILD_PLATFORM"] = self.options.with_platform + tc.variables["agg_BUILD_CONTROLS"] = self.options.with_controls tc.generate() @@ -95,12 +95,11 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): - self.cpp_info.set_property("cmake_file_name", "agg") - self.cpp_info.filenames["cmake_find_package"]="agg" - self.cpp_info.filenames["cmake_find_package_multi"]="agg" - self.cpp_info.names["cmake_find_package"]="agg" - self.cpp_info.names["cmake_find_package_multi"]="agg" + self.cpp_info.filenames["cmake_find_package"] = "agg" + self.cpp_info.filenames["cmake_find_package_multi"] = "agg" + self.cpp_info.names["cmake_find_package"] = "agg" + self.cpp_info.names["cmake_find_package_multi"] = "agg" self.cpp_info.components["agg"].set_property("cmake_target_name", "agg::agg") self.cpp_info.components["agg"].libs = ["agg"] @@ -109,33 +108,31 @@ def package_info(self): if self.options.with_freetype: self.cpp_info.components["fontfreetype"].set_property("cmake_target_name", "agg::fontfreetype") self.cpp_info.components["fontfreetype"].libs = ["aggfontfreetype"] - self.cpp_info.components["fontfreetype"].includedirs = [os.path.join("include", "agg","fontfreetype")] + self.cpp_info.components["fontfreetype"].includedirs = [os.path.join("include", "agg", "fontfreetype")] self.cpp_info.components["fontfreetype"].requires = ["agg", "freetype::freetype"] - + if self.options.with_gpc: self.cpp_info.components["gpc"].set_property("cmake_target_name", "agg::gpc") - self.cpp_info.components["gpc"].libs = [ "agggpc"] - self.cpp_info.components["gpc"].includedirs = [os.path.join("include", "agg","gpc")] - + self.cpp_info.components["gpc"].libs = ["agggpc"] + self.cpp_info.components["gpc"].includedirs = [os.path.join("include", "agg", "gpc")] if self.options.with_agg2d: self.cpp_info.components["2d"].set_property("cmake_target_name", "agg::2d") self.cpp_info.components["2d"].libs = ["agg2d"] - self.cpp_info.components["2d"].includedirs = [os.path.join("include", "agg","2d")] + self.cpp_info.components["2d"].includedirs = [os.path.join("include", "agg", "2d")] self.cpp_info.components["2d"].requires = ["agg"] if self.options.with_agg2d_freetype: self.cpp_info.components["2d"].requires = ["agg", "fontfreetype"] if self.options.with_platform: - self.cpp_info.components["platform"].set_property("cmake_target_name", "agg::platform") self.cpp_info.components["platform"].libs = ["aggplatform"] - self.cpp_info.components["platform"].includedirs = [os.path.join("include", "agg","platform")] + self.cpp_info.components["platform"].includedirs = [os.path.join("include", "agg", "platform")] if self.settings.os in ["Linux"]: self.cpp_info.components["platform"].requires = ["xorg::xorg", "agg"] if self.options.with_controls: self.cpp_info.components["controls"].set_property("cmake_target_name", "agg::controls") self.cpp_info.components["controls"].libs = ["aggctrl"] - self.cpp_info.components["controls"].includedirs = [os.path.join("include", "agg","ctrl")] + self.cpp_info.components["controls"].includedirs = [os.path.join("include", "agg", "ctrl")] self.cpp_info.components["controls"].requires = ["agg"] diff --git a/recipes/aggeom-agg/all/test_v1_package/CMakeLists.txt b/recipes/aggeom-agg/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..91630d79f4abb3 100644 --- a/recipes/aggeom-agg/all/test_v1_package/CMakeLists.txt +++ b/recipes/aggeom-agg/all/test_v1_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) From a31873c0eed25c3536429ef1ef19459eb0b66605 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 09:25:01 +0300 Subject: [PATCH 0253/1140] (#18205) maddy: migrate to Conan v2 * maddy: migrate to Conan v2 * maddy: restore test_v1_package --- recipes/maddy/all/conanfile.py | 53 +++++++++---------- recipes/maddy/all/test_package/CMakeLists.txt | 13 +++-- recipes/maddy/all/test_package/conanfile.py | 19 +++++-- recipes/maddy/all/test_package/example.cpp | 0 .../maddy/all/test_v1_package/CMakeLists.txt | 8 +++ .../maddy/all/test_v1_package/conanfile.py | 17 ++++++ 6 files changed, 69 insertions(+), 41 deletions(-) mode change 100755 => 100644 recipes/maddy/all/test_package/example.cpp create mode 100755 recipes/maddy/all/test_v1_package/CMakeLists.txt create mode 100755 recipes/maddy/all/test_v1_package/conanfile.py diff --git a/recipes/maddy/all/conanfile.py b/recipes/maddy/all/conanfile.py index 7bcdd1cec24d52..1cc4a8a062ec26 100644 --- a/recipes/maddy/all/conanfile.py +++ b/recipes/maddy/all/conanfile.py @@ -1,47 +1,42 @@ -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class MaddyConan(ConanFile): name = "maddy" + description = "open-source, maddy is a C++ Markdown to HTML header-only parser library." + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/progsource/maddy" - description = ( - "open-source, maddy is a C++ Markdown to HTML header-only parser library." - ) - topics = ("maddy", "markdown", "header-only") - license = "MIT" + topics = ("markdown", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 14) + check_min_cppstd(self, 14) def source(self): - tools.get( - **self.conan_data["sources"][self.version], - destination=self._source_subfolder, - strip_root=True - ) - - def package_id(self): - self.info.header_only() + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy( - "LICENSE", - src=os.path.join(self.source_folder, self._source_subfolder), - dst="licenses", - ) - self.copy( - pattern="maddy/*.h", - src=os.path.join(self.source_folder, self._source_subfolder, "include"), - dst="include", - ) + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, pattern="maddy/*.h", src=os.path.join(self.source_folder, "include"), dst=os.path.join(self.package_folder, "include")) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/maddy/all/test_package/CMakeLists.txt b/recipes/maddy/all/test_package/CMakeLists.txt index b85bbd55815731..8b3d049ce58f5c 100755 --- a/recipes/maddy/all/test_package/CMakeLists.txt +++ b/recipes/maddy/all/test_package/CMakeLists.txt @@ -1,12 +1,11 @@ -cmake_minimum_required(VERSION 3.5) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(maddy REQUIRED CONFIG) add_executable(${PROJECT_NAME} example.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE maddy::maddy) -set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 14 CXX_STANDARD_REQUIRED - ON) +set_target_properties(${PROJECT_NAME} PROPERTIES + CXX_STANDARD 14 + CXX_STANDARD_REQUIRED ON +) diff --git a/recipes/maddy/all/test_package/conanfile.py b/recipes/maddy/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100755 --- a/recipes/maddy/all/test_package/conanfile.py +++ b/recipes/maddy/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/maddy/all/test_package/example.cpp b/recipes/maddy/all/test_package/example.cpp old mode 100755 new mode 100644 diff --git a/recipes/maddy/all/test_v1_package/CMakeLists.txt b/recipes/maddy/all/test_v1_package/CMakeLists.txt new file mode 100755 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/maddy/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/maddy/all/test_v1_package/conanfile.py b/recipes/maddy/all/test_v1_package/conanfile.py new file mode 100755 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/maddy/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 2c85b3b4769b2cdac6dc2511934ddce79b666c17 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 09:44:15 +0300 Subject: [PATCH 0254/1140] (#18206) dbg-macro: migrate to Conan v2 * dbg-macro: migrate to Conan v2 * dbg-macro: restore test_v1_package * dbg-macro: add cmake_find_package_multi generator to test_v1_package * Set min_cppstd to C++17 * Fix layout * Update CMakeLists.txt * dbg-macro: restore VirtualRunEnv in test_package --- recipes/dbg-macro/all/conanfile.py | 27 +++++++++++++------ .../dbg-macro/all/test_package/CMakeLists.txt | 2 +- .../dbg-macro/all/test_package/conanfile.py | 6 ++--- .../all/test_v1_package/CMakeLists.txt | 8 ++++++ .../all/test_v1_package/conanfile.py | 18 +++++++++++++ 5 files changed, 48 insertions(+), 13 deletions(-) create mode 100644 recipes/dbg-macro/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/dbg-macro/all/test_v1_package/conanfile.py diff --git a/recipes/dbg-macro/all/conanfile.py b/recipes/dbg-macro/all/conanfile.py index 7fdad007c10704..5955544e24b0db 100644 --- a/recipes/dbg-macro/all/conanfile.py +++ b/recipes/dbg-macro/all/conanfile.py @@ -1,25 +1,32 @@ import os + from conan import ConanFile -from conan.tools.files import get, copy -from conan.tools.build import check_min_cppstd from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout from conan.tools.scm import Version +required_conan_version = ">=1.52.0" + class DbgMacroConan(ConanFile): name = "dbg-macro" + description = "A dbg(...) macro for C++" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/sharkdp/dbg-macro" - license = "MIT" - description = "A dbg(...) macro for C++" topics = ("debugging", "macro", "pretty-printing", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + def layout(self): + basic_layout(self, src_folder="src") - def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root=True) + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.get_safe('cppstd'): @@ -33,9 +40,13 @@ def validate(self): if str(compiler) in min_versions and Version(compiler.version) < min_versions[str(compiler)]: raise ConanInvalidConfiguration("dbg-macro requires C++17 which your compiler does not support.") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + def package(self): copy(self, "dbg.h", src=self.source_folder, dst=os.path.join(self.package_folder, "include")) copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) - def package_id(self): - self.info.clear() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/dbg-macro/all/test_package/CMakeLists.txt b/recipes/dbg-macro/all/test_package/CMakeLists.txt index 38914f6edfd7d4..535b1e583d6c52 100644 --- a/recipes/dbg-macro/all/test_package/CMakeLists.txt +++ b/recipes/dbg-macro/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) find_package(dbg-macro REQUIRED CONFIG) diff --git a/recipes/dbg-macro/all/test_package/conanfile.py b/recipes/dbg-macro/all/test_package/conanfile.py index 61ef483bce0670..2ee2f747a7393e 100644 --- a/recipes/dbg-macro/all/test_package/conanfile.py +++ b/recipes/dbg-macro/all/test_package/conanfile.py @@ -1,16 +1,14 @@ import os from conan import ConanFile +from conan.tools.build import can_run from conan.tools.cmake import CMake, cmake_layout -from conan.tools.build import cross_building, can_run -from conan.tools.files import mkdir class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "CMakeDeps", "CMakeToolchain" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" test_type = "explicit" - def requirements(self): self.requires(self.tested_reference_str) diff --git a/recipes/dbg-macro/all/test_v1_package/CMakeLists.txt b/recipes/dbg-macro/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/dbg-macro/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/dbg-macro/all/test_v1_package/conanfile.py b/recipes/dbg-macro/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..e9e25c6e641afe --- /dev/null +++ b/recipes/dbg-macro/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + tools.mkdir("logs/") + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From d916e4dd25b4cecdeafe982de9bdb565df2f0715 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Thu, 17 Aug 2023 09:04:22 +0200 Subject: [PATCH 0255/1140] (#18059) autoconf: fix msvc debug build for test_package --- recipes/autoconf/all/test_package/conanfile.py | 3 +++ recipes/autoconf/all/test_v1_package/conanfile.py | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/autoconf/all/test_package/conanfile.py b/recipes/autoconf/all/test_package/conanfile.py index bb22349ed9696c..540a389d38f89b 100644 --- a/recipes/autoconf/all/test_package/conanfile.py +++ b/recipes/autoconf/all/test_package/conanfile.py @@ -29,6 +29,9 @@ def generate(self): env = VirtualBuildEnv(self) env.generate() tc = AutotoolsToolchain(self) + if is_msvc(self): + tc.extra_cflags.append("-FS") + tc.extra_cxxflags.append("-FS") tc.generate() if is_msvc(self): env = Environment() diff --git a/recipes/autoconf/all/test_v1_package/conanfile.py b/recipes/autoconf/all/test_v1_package/conanfile.py index 422d5f44c10cf5..7098a4c30759bf 100644 --- a/recipes/autoconf/all/test_v1_package/conanfile.py +++ b/recipes/autoconf/all/test_v1_package/conanfile.py @@ -34,6 +34,8 @@ def build(self): self.run("{} --help".format(os.path.join(self.build_folder, "configure").replace("\\", "/")), win_bash=tools.os_info.is_windows) autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) + if is_msvc(self): + autotools.flags.append("-FS") with self._build_context(): autotools.configure() autotools.make() From 842e078da29e162e2aa9820acdf28197678f3357 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 10:24:42 +0300 Subject: [PATCH 0256/1140] (#18239) cotila: migrate to Conan v2 * cotila: migrate to Conan v2 * cotila: restore test_v1_package * cotila: disable MSVC builds due to an internal compiler error * cotila: restore VirtualRunEnv in test_package --- recipes/cotila/all/conanfile.py | 77 ++++++++++--------- .../cotila/all/test_package/CMakeLists.txt | 7 +- recipes/cotila/all/test_package/conanfile.py | 23 ++++-- .../cotila/all/test_v1_package/CMakeLists.txt | 8 ++ .../cotila/all/test_v1_package/conanfile.py | 17 ++++ 5 files changed, 84 insertions(+), 48 deletions(-) create mode 100644 recipes/cotila/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cotila/all/test_v1_package/conanfile.py diff --git a/recipes/cotila/all/conanfile.py b/recipes/cotila/all/conanfile.py index eb47a8c74e0c9c..cbc8f6be750649 100644 --- a/recipes/cotila/all/conanfile.py +++ b/recipes/cotila/all/conanfile.py @@ -1,66 +1,71 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration +import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class CotilaConan(ConanFile): name = "cotila" description = "A compile time linear algebra system" - homepage = "https://github.com/calebzulawski/cotila" - topics = ("c++", "math", "linear algebra", "compile-time") license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" - no_copy_source = True + homepage = "https://github.com/calebzulawski/cotila" + topics = ("c++", "math", "linear algebra", "compile-time", "header-only") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _min_cppstd(self): - return "17" + return 17 @property def _compilers_minimum_version(self): return { "gcc": "7", - "Visual Studio": "15.7", "clang": "6.0", "apple-clang": "10", + "Visual Studio": "15.7", + "msvc": "193", } - def validate(self): - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, "17") + def layout(self): + basic_layout(self, src_folder="src") - def lazy_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] + def package_id(self): + self.info.clear() + def validate(self): + if is_msvc(self): + raise ConanInvalidConfiguration("cotila currently does not support MSVC. " + "See https://github.com/calebzulawski/cotila/issues/36.") + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("{} {} requires C++17. Your compiler is unknown. Assuming it supports C++17.".format(self.name, self.version)) - elif lazy_lt_semver(str(self.settings.compiler.version), minimum_version): - raise ConanInvalidConfiguration("{} {} requires C++17, which your compiler does not support.".format(self.name, self.version)) - - - def package_id(self): - self.info.header_only() + 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): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, - destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - self.copy(pattern="include/*", src=self._source_subfolder) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "cotila" - self.cpp_info.names["cmake_find_package_multi"] = "cotila" - + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/cotila/all/test_package/CMakeLists.txt b/recipes/cotila/all/test_package/CMakeLists.txt index fb76dc36e1dc69..cf3db6db5cc451 100644 --- a/recipes/cotila/all/test_package/CMakeLists.txt +++ b/recipes/cotila/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS) - -find_package(cotila CONFIG REQUIRED) +find_package(cotila REQUIRED CONFIG) add_executable(test_package test_package.cpp) target_compile_features(test_package PRIVATE cxx_std_17) diff --git a/recipes/cotila/all/test_package/conanfile.py b/recipes/cotila/all/test_package/conanfile.py index e1ab7e3d234d6b..ef5d7042163ecc 100644 --- a/recipes/cotila/all/test_package/conanfile.py +++ b/recipes/cotila/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class CotilaTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cotila/all/test_v1_package/CMakeLists.txt b/recipes/cotila/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cotila/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cotila/all/test_v1_package/conanfile.py b/recipes/cotila/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..e1ab7e3d234d6b --- /dev/null +++ b/recipes/cotila/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class CotilaTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 539ca1b3f83cf90280055a0bc8e28ebc7889e842 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 10:44:56 +0300 Subject: [PATCH 0257/1140] (#18240) immer: migrate to Conan v2 * immer: migrate to Conan v2 * immer: drop v0.6.2 test_package fails to build with it. * immer: restore test_v1_package * immer: fix removed version * immer: restore VirtualRunEnv in test_package --- recipes/immer/all/conandata.yml | 3 - recipes/immer/all/conanfile.py | 73 +++++++++++-------- recipes/immer/all/test_package/CMakeLists.txt | 9 +-- recipes/immer/all/test_package/conanfile.py | 21 ++++-- recipes/immer/all/test_package/example.cpp | 2 +- .../immer/all/test_v1_package/CMakeLists.txt | 8 ++ .../immer/all/test_v1_package/conanfile.py | 17 +++++ recipes/immer/config.yml | 2 - 8 files changed, 85 insertions(+), 50 deletions(-) create mode 100644 recipes/immer/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/immer/all/test_v1_package/conanfile.py diff --git a/recipes/immer/all/conandata.yml b/recipes/immer/all/conandata.yml index 811b858690dba0..6d029402576cc8 100644 --- a/recipes/immer/all/conandata.yml +++ b/recipes/immer/all/conandata.yml @@ -5,6 +5,3 @@ sources: "0.7.0": url: "https://github.com/arximboldi/immer/archive/v0.7.0.tar.gz" sha256: "cf67ab428aa3610eb0f72d0ea936c15cce3f91df26ee143ab783acd053507fe4" - "0.6.2": - url: "https://github.com/arximboldi/immer/archive/refs/tags/v0.6.2.tar.gz" - sha256: "c3bb8847034437dee64adacb04e1e0163ae640b596c582eb4c0aa1d7c6447cd7" diff --git a/recipes/immer/all/conanfile.py b/recipes/immer/all/conanfile.py index 952501519b5549..b605235f935530 100644 --- a/recipes/immer/all/conanfile.py +++ b/recipes/immer/all/conanfile.py @@ -1,40 +1,32 @@ -from conans import ConanFile, tools, errors +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" -required_conan_version = ">=1.33.0" class ImmerConan(ConanFile): name = "immer" + description = "Postmodern immutable and persistent data structures for C++ - value semantics at scale" license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/arximboldi/immer" - description = "Postmodern immutable and persistent data structures for C++---value semantics at scale" - topics = ("header", "header-only", "persistent", "modern", "immutable", - "data structures", "functional", "value semantics", "postmodern", - "rrb-tree") + topics = ("header", "header-only", "persistent", "modern", "immutable", "data structures", + "functional", "value semantics", "postmodern", "rrb-tree") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - settings = "compiler" @property def _minimum_cpp_standard(self): return 14 - @property - def _source_subfolder(self): - return "source_subfolder" - - def source(self): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, - destination=self._source_subfolder) - - def package(self): - include_folder = self._source_subfolder - self.copy(pattern="*.hpp", dst="include", src=include_folder) - self.copy(pattern="LICENSE", dst="licenses", src=include_folder) - - def package_id(self): - self.info.header_only() - @property def _minimum_compilers_version(self): # Reference: https://en.cppreference.com/w/cpp/compiler_support/14 @@ -44,17 +36,36 @@ def _minimum_compilers_version(self): "gcc": "6", "intel": "17", "sun-cc": "5.15", - "Visual Studio": "15" + "Visual Studio": "15", } + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._minimum_cpp_standard) min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) if not min_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") else: - if tools.Version(self.settings.compiler.version) < min_version: - raise errors.ConanInvalidConfiguration("{} requires C++{} support. The current compiler {} {} does not support it.".format( - self.name, self._minimum_cpp_standard, self.settings.compiler, self.settings.compiler.version)) + if Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" + f" {self.settings.compiler} {self.settings.compiler.version} does not support it." + ) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + include_folder = self.source_folder + copy(self, pattern="*.hpp", dst=os.path.join(self.package_folder, "include"), src=include_folder) + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=include_folder) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/immer/all/test_package/CMakeLists.txt b/recipes/immer/all/test_package/CMakeLists.txt index 870b269d2d6609..c9d3024076801f 100644 --- a/recipes/immer/all/test_package/CMakeLists.txt +++ b/recipes/immer/all/test_package/CMakeLists.txt @@ -1,13 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(immer CONFIG REQUIRED) +find_package(immer REQUIRED CONFIG) add_executable(example example.cpp) - target_link_libraries(example immer::immer) - target_compile_features(example PUBLIC cxx_std_14) diff --git a/recipes/immer/all/test_package/conanfile.py b/recipes/immer/all/test_package/conanfile.py index 0242d96a644cae..8d52b7021efe14 100644 --- a/recipes/immer/all/test_package/conanfile.py +++ b/recipes/immer/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/immer/all/test_package/example.cpp b/recipes/immer/all/test_package/example.cpp index 3778564a310823..78e26ad5b37e63 100644 --- a/recipes/immer/all/test_package/example.cpp +++ b/recipes/immer/all/test_package/example.cpp @@ -1,5 +1,5 @@ #include "immer/vector.hpp" -#include +#include int main() { const auto v0 = immer::vector{}; diff --git a/recipes/immer/all/test_v1_package/CMakeLists.txt b/recipes/immer/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/immer/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/immer/all/test_v1_package/conanfile.py b/recipes/immer/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..0242d96a644cae --- /dev/null +++ b/recipes/immer/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) diff --git a/recipes/immer/config.yml b/recipes/immer/config.yml index 9e53a8732b4037..7090494339fd49 100644 --- a/recipes/immer/config.yml +++ b/recipes/immer/config.yml @@ -3,5 +3,3 @@ versions: folder: all "0.7.0": folder: all - "0.6.2": - folder: all From 446330367ec0083e16c18034a28dbb44ca2dad8f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 11:06:02 +0300 Subject: [PATCH 0258/1140] (#18243) fpgen: migrate to Conan v2 * fpgen: migrate to Conan v2 * fpgen: restore test_v1_package * fpgen: fix package() * fpgen: drop older version with broken clang and msvc support --- recipes/fpgen/all/conandata.yml | 3 - recipes/fpgen/all/conanfile.py | 104 +++++++----------- recipes/fpgen/all/test_package/CMakeLists.txt | 5 +- recipes/fpgen/all/test_package/conanfile.py | 22 ++-- recipes/fpgen/all/test_package/main.cpp | 9 +- .../fpgen/all/test_v1_package/CMakeLists.txt | 8 ++ .../fpgen/all/test_v1_package/conanfile.py | 18 +++ recipes/fpgen/config.yml | 2 - 8 files changed, 89 insertions(+), 82 deletions(-) create mode 100644 recipes/fpgen/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/fpgen/all/test_v1_package/conanfile.py diff --git a/recipes/fpgen/all/conandata.yml b/recipes/fpgen/all/conandata.yml index 89315a6f71ce41..0ed9b7cc136ee0 100644 --- a/recipes/fpgen/all/conandata.yml +++ b/recipes/fpgen/all/conandata.yml @@ -1,7 +1,4 @@ sources: - "1.1.0": - url: "https://github.com/jay-tux/fpgen/archive/refs/tags/v1.1.0.tar.gz" - sha256: "5e5faf1fbdcb3d93306bd8a838f805afdccdbb9076d78356ad5443943555be7d" "1.1.0-clang": url: "https://github.com/jay-tux/fpgen/archive/refs/tags/v1.1.0-clang.tar.gz" sha256: "02936c1e790bcdba1479cf8164596b05cfc5b7401b3c71e0a1fd77e51fe8b93f" diff --git a/recipes/fpgen/all/conanfile.py b/recipes/fpgen/all/conanfile.py index b9e1ea43fa34a9..46fc8ca2ceba0b 100644 --- a/recipes/fpgen/all/conanfile.py +++ b/recipes/fpgen/all/conanfile.py @@ -1,94 +1,74 @@ import os -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, replace_in_file +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class FpgenConan(ConanFile): name = "fpgen" - description = " Functional programming in C++ using C++20 coroutines." + description = "Functional programming in C++ using C++20 coroutines." license = ["MPL2"] - topics = ( - "generators", - "coroutines", - "c++20", - "header-only", - "functional-programming", - "functional", - ) - homepage = "https://github.com/jay-tux/fpgen/" url = "https://github.com/conan-io/conan-center-index" - settings = "arch", "os", "compiler", "build_type" - no_copy_source = True + homepage = "https://github.com/jay-tux/fpgen/" + topics = ("generators", "coroutines", "c++20", "header-only", "functional-programming", "functional") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _min_cppstd(self): - return "20" + return 20 @property def _compilers_minimum_version(self): return { "gcc": "11", "clang": "13", + "apple-clang": "13.1", + "Visual Studio": "16", + "msvc": "192", } - def package_id(self): - self.info.header_only() + def layout(self): + basic_layout(self, src_folder="src") - def source(self): - tools.get( - **self.conan_data["sources"][self.version], - destination=self._source_subfolder, - strip_root=True, - ) + def package_id(self): + self.info.clear() def validate(self): - if self.settings.compiler == "clang" and "clang" not in str(self.version): - raise ConanInvalidConfiguration( - f"Use '{self.version}-clang' for Clang support." - ) - - if ( - self.settings.compiler == "clang" - and not self.settings.compiler.libcxx == "libc++" - ): - raise ConanInvalidConfiguration( - f"Use 'compiler.libcxx=libc++' for {self.name} on Clang." - ) + if self.settings.compiler == "clang" and not self.settings.compiler.libcxx == "libc++": + raise ConanInvalidConfiguration(f"Use 'compiler.libcxx=libc++' with Clang for {self.name}.") if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._min_cppstd) - - def lazy_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] - - minimum_version = self._compilers_minimum_version.get( - str(self.settings.compiler), False - ) - if not minimum_version: - raise ConanInvalidConfiguration( - f"{self.name} is currently not available for your compiler." - ) - elif lazy_lt_semver(str(self.settings.compiler.version), minimum_version): + 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.name} {self.version} requires C++20, which your compiler does not support." + 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) + def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - self.copy( - pattern="*.hpp", - dst=os.path.join("include", "fpgen"), - src=self._source_subfolder, - keep_path=False, - ) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include", "fpgen"), + src=self.source_folder, + keep_path=False) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.includedirs.append(os.path.join("include", "fpgen")) diff --git a/recipes/fpgen/all/test_package/CMakeLists.txt b/recipes/fpgen/all/test_package/CMakeLists.txt index 2d7e6737381f9b..7013b94735f0f1 100644 --- a/recipes/fpgen/all/test_package/CMakeLists.txt +++ b/recipes/fpgen/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.12) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - find_package(fpgen REQUIRED CONFIG) add_executable(${PROJECT_NAME} main.cpp) diff --git a/recipes/fpgen/all/test_package/conanfile.py b/recipes/fpgen/all/test_package/conanfile.py index 3f4a9f50f389e4..ef5d7042163ecc 100644 --- a/recipes/fpgen/all/test_package/conanfile.py +++ b/recipes/fpgen/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools - class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fpgen/all/test_package/main.cpp b/recipes/fpgen/all/test_package/main.cpp index 43bf51fe320f0d..d9d39d7a4b608c 100644 --- a/recipes/fpgen/all/test_package/main.cpp +++ b/recipes/fpgen/all/test_package/main.cpp @@ -1,13 +1,14 @@ +#include "fpgen/fpgen.hpp" + #include #include -#include "fpgen/fpgen.hpp" int main() { - std::vector vals = {0,1,2,3}; + std::vector vals = {0, 1, 2, 3}; auto gen = fpgen::from(vals); - for(auto &&val : gen) { - std::cout << val << std::endl; + for (auto &&val : gen) { + std::cout << val << std::endl; } return 0; } diff --git a/recipes/fpgen/all/test_v1_package/CMakeLists.txt b/recipes/fpgen/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/fpgen/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/fpgen/all/test_v1_package/conanfile.py b/recipes/fpgen/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..3f4a9f50f389e4 --- /dev/null +++ b/recipes/fpgen/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/fpgen/config.yml b/recipes/fpgen/config.yml index ec935d5cf64ffc..2786096f9ff863 100644 --- a/recipes/fpgen/config.yml +++ b/recipes/fpgen/config.yml @@ -1,5 +1,3 @@ versions: - "1.1.0": - folder: all "1.1.0-clang": folder: all From 1731012f043ef2981e286990c42694523395d258 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 11:30:28 +0300 Subject: [PATCH 0259/1140] (#18246) rangeless: migrate to Conan v2 * rangeless: migrate to Conan v2 * rangeless: restore test_v1_package * rangeless: add compilers_minimum_version check * rangeless: fix recipe bug * rangeless: restore VirtualRunEnv in test_package --- recipes/rangeless/all/conanfile.py | 64 ++++++++++++++----- .../rangeless/all/test_package/CMakeLists.txt | 9 ++- .../rangeless/all/test_package/conanfile.py | 22 +++++-- .../all/test_package/test_package.cpp | 2 +- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 16 +++++ 6 files changed, 93 insertions(+), 28 deletions(-) create mode 100644 recipes/rangeless/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rangeless/all/test_v1_package/conanfile.py diff --git a/recipes/rangeless/all/conanfile.py b/recipes/rangeless/all/conanfile.py index d37a7eb54aeb3e..4eb06ece4e6275 100644 --- a/recipes/rangeless/all/conanfile.py +++ b/recipes/rangeless/all/conanfile.py @@ -1,34 +1,66 @@ -from conans import ConanFile, tools import os -import glob + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class RangelessConan(ConanFile): name = "rangeless" description = "c++ LINQ -like library of higher-order functions for data manipulation" license = "MIT" - homepage = "https://github.com/ast-al/rangeless" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ast-al/rangeless" topics = ("range", "linq", "lazy-evaluation", "header-only") - settings = "compiler" + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 14 - def configure(self): - minimal_cpp_standard = "14" - if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, minimal_cpp_standard) + @property + def _compilers_minimum_version(self): + return { + "gcc": "5", + "clang": "3.4", + "apple-clang": "10", + "Visual Studio": "14", + "msvc": "191", + } + + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() + self.info.clear() + + def validate(self): + if self.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.get_safe("compiler.version")) < minimum_version: + raise ConanInvalidConfiguration(f"{self.ref} requires C++{self._min_cppstd}, " + "which your compiler does not support.") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob(self.name + "-*/")[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.hpp", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/rangeless/all/test_package/CMakeLists.txt b/recipes/rangeless/all/test_package/CMakeLists.txt index 5e1e9d9b89fe0a..6f31fb97ff44ca 100644 --- a/recipes/rangeless/all/test_package/CMakeLists.txt +++ b/recipes/rangeless/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(rangeless REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE rangeless::rangeless) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 14) diff --git a/recipes/rangeless/all/test_package/conanfile.py b/recipes/rangeless/all/test_package/conanfile.py index 6c9d5dba712c72..ef5d7042163ecc 100644 --- a/recipes/rangeless/all/test_package/conanfile.py +++ b/recipes/rangeless/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rangeless/all/test_package/test_package.cpp b/recipes/rangeless/all/test_package/test_package.cpp index 4f49c17e155f2b..96e45179153e6a 100644 --- a/recipes/rangeless/all/test_package/test_package.cpp +++ b/recipes/rangeless/all/test_package/test_package.cpp @@ -11,7 +11,7 @@ int main() { values = std::move(values) % fn::where([](auto&& _) { return _ % 2 == 0; }) % fn::transform([] (auto&& _) { return _ * 3; }); - + auto expected = std::vector{0,6,12,18,24,30}; bool success = values == expected; diff --git a/recipes/rangeless/all/test_v1_package/CMakeLists.txt b/recipes/rangeless/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rangeless/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rangeless/all/test_v1_package/conanfile.py b/recipes/rangeless/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/rangeless/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 83f9db87d6efb34d947bfd72a8f8249f94b080be Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 11:45:55 +0300 Subject: [PATCH 0260/1140] (#18249) neargye-semver: migrate to Conan v2 * neargye-semver: migrate to Conan v2 * neargye-semver: restore test_v1_package * neargye-semver: restore VirtualRunEnv in test_package --- recipes/neargye-semver/all/conanfile.py | 81 ++++++++++--------- .../all/test_package/CMakeLists.txt | 9 +-- .../all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 5 files changed, 88 insertions(+), 48 deletions(-) create mode 100644 recipes/neargye-semver/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/neargye-semver/all/test_v1_package/conanfile.py diff --git a/recipes/neargye-semver/all/conanfile.py b/recipes/neargye-semver/all/conanfile.py index 53652835d3593f..4c81f48ec928fc 100644 --- a/recipes/neargye-semver/all/conanfile.py +++ b/recipes/neargye-semver/all/conanfile.py @@ -1,63 +1,72 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration - import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class NeargyeSemverConan(ConanFile): name = "neargye-semver" description = "Semantic Versioning for modern C++" - topics = ("conan", "semver", "semantic", "versioning") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/Neargye/semver" - license = "MIT" - generators = "cmake", "cmake_find_package_multi" - settings = "compiler", "build_type" + topics = ("semver", "semantic", "versioning", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 17 - def configure(self): - compiler = str(self.settings.compiler) - compiler_version = tools.Version(self.settings.compiler.version) - - min_req_cppstd = "17" - if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, min_req_cppstd) - else: - self.output.warn("%s recipe lacks information about the %s compiler" - " standard version support." % (self.name, compiler)) - - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "Visual Studio": "16", + "msvc": "192", "gcc": "7.3", "clang": "6.0", "apple-clang": "10.0", } - # Exclude compilers not supported - if compiler not in minimal_version: - self.output.info("%s requires a compiler that supports at least C++%s" % (self.name, min_req_cppstd)) - return - if compiler_version < minimal_version[compiler]: + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("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( - "%s requires a compiler that supports at least C++%s. %s %s is not supported." % - (self.name, min_req_cppstd, compiler, tools.Version(self.settings.compiler.version.value))) + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." + ) + def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - self.copy("*.hpp", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*.hpp", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include")) def package_info(self): - self.cpp_info.names["pkg_config"] = "semver" + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + + self.cpp_info.set_property("pkg_config_name", "semver") + self.cpp_info.set_property("cmake_file_name", "semver") + self.cpp_info.set_property("cmake_target_name", "semver::semver") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.names["cmake_find_package"] = "semver" self.cpp_info.names["cmake_find_package_multi"] = "semver" - - def package_id(self): - self.info.header_only() diff --git a/recipes/neargye-semver/all/test_package/CMakeLists.txt b/recipes/neargye-semver/all/test_package/CMakeLists.txt index 4b4849803c2563..6915cbdbd4166e 100644 --- a/recipes/neargye-semver/all/test_package/CMakeLists.txt +++ b/recipes/neargye-semver/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(semver CONFIG REQUIRED) +find_package(semver REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} semver::semver) diff --git a/recipes/neargye-semver/all/test_package/conanfile.py b/recipes/neargye-semver/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/neargye-semver/all/test_package/conanfile.py +++ b/recipes/neargye-semver/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/neargye-semver/all/test_v1_package/CMakeLists.txt b/recipes/neargye-semver/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/neargye-semver/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/neargye-semver/all/test_v1_package/conanfile.py b/recipes/neargye-semver/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/neargye-semver/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b0c55109b6f799d08744a7782602de5a06bd4637 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 12:06:38 +0300 Subject: [PATCH 0261/1140] (#18252) yas: migrate to Conan v2 * yas: migrate to Conan v2 * yas: restore test_v1_package * yas: add cmake_find_package_multi generator to test_v1_package * yas: fix license packaging * yas: restore VirtualRunEnv in test_package --- recipes/yas/all/conanfile.py | 52 ++++++++++++------- recipes/yas/all/test_package/CMakeLists.txt | 9 ++-- recipes/yas/all/test_package/conanfile.py | 21 +++++--- .../yas/all/test_v1_package/CMakeLists.txt | 8 +++ recipes/yas/all/test_v1_package/conanfile.py | 17 ++++++ 5 files changed, 77 insertions(+), 30 deletions(-) create mode 100644 recipes/yas/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/yas/all/test_v1_package/conanfile.py diff --git a/recipes/yas/all/conanfile.py b/recipes/yas/all/conanfile.py index 8cfe2a15884cf5..4b089cd3a4efe2 100644 --- a/recipes/yas/all/conanfile.py +++ b/recipes/yas/all/conanfile.py @@ -1,39 +1,53 @@ -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, load, save +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class YasConan(ConanFile): name = "yas" description = "Yet Another Serialization" - topics = ("yas", "serialization", "header-only") + license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/niXman/yas" - license = "BSL-1.0" + topics = ("serialization", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def _extract_license(self): - header = tools.load(os.path.join( - self.source_folder, self._source_subfolder, - "include", "yas", "binary_oarchive.hpp")) - license_contents = header[:header.find("#")] \ - .replace("//", "").replace("\n ", "\n").lstrip() - tools.save("LICENSE", license_contents) + header = load(self, os.path.join(self.source_folder, "include", "yas", "binary_oarchive.hpp")) + license_contents = header[: header.find("#")].replace("//", "").replace("\n ", "\n").lstrip() + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_contents) def package(self): self._extract_license() - self.copy("LICENSE", dst="licenses") - self.copy("*", src=os.path.join(self._source_subfolder, "include"), - dst="include") + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/yas/all/test_package/CMakeLists.txt b/recipes/yas/all/test_package/CMakeLists.txt index 641059df6fa465..31c7068ad2a4f0 100644 --- a/recipes/yas/all/test_package/CMakeLists.txt +++ b/recipes/yas/all/test_package/CMakeLists.txt @@ -1,10 +1,9 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) set(CMAKE_CXX_STANDARD 11) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(yas REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE yas::yas) diff --git a/recipes/yas/all/test_package/conanfile.py b/recipes/yas/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/yas/all/test_package/conanfile.py +++ b/recipes/yas/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/yas/all/test_v1_package/CMakeLists.txt b/recipes/yas/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/yas/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/yas/all/test_v1_package/conanfile.py b/recipes/yas/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/yas/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From cbb48b98c3e26a954246f40caa32c37939f09313 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 12:26:13 +0300 Subject: [PATCH 0262/1140] (#18255) plusaes: migrate to Conan v2 * plusaes: migrate to Conan v2 * plusaes: restore test_v1_package * plusaes: restore VirtualRunEnv in test_package --- recipes/plusaes/all/conanfile.py | 37 +++++++++++++------ .../plusaes/all/test_package/CMakeLists.txt | 7 +--- recipes/plusaes/all/test_package/conanfile.py | 20 +++++++--- .../all/test_v1_package/CMakeLists.txt | 8 ++++ .../plusaes/all/test_v1_package/conanfile.py | 16 ++++++++ 5 files changed, 66 insertions(+), 22 deletions(-) create mode 100644 recipes/plusaes/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/plusaes/all/test_v1_package/conanfile.py diff --git a/recipes/plusaes/all/conanfile.py b/recipes/plusaes/all/conanfile.py index 5d1248265e161c..c0737891223108 100644 --- a/recipes/plusaes/all/conanfile.py +++ b/recipes/plusaes/all/conanfile.py @@ -1,35 +1,48 @@ -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + class PlusaesConan(ConanFile): name = "plusaes" description = "Header only C++ AES cipher library" - topics = ("encryption", "header-only") license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/kkAyataka/plusaes" + topics = ("encryption", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 11) + check_min_cppstd(self, self._min_cppstd) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - root_dir = self._source_subfolder + root_dir = self.source_folder include_dir = os.path.join(root_dir, "include") - self.copy(pattern="LICENSE_1_0.txt", dst="licenses", src=root_dir) - self.copy(pattern="*plusaes.hpp", dst="include", src=include_dir) + copy(self, "LICENSE_1_0.txt", dst=os.path.join(self.package_folder, "licenses"), src=root_dir) + copy(self, "*plusaes.hpp", dst=os.path.join(self.package_folder, "include"), src=include_dir) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/plusaes/all/test_package/CMakeLists.txt b/recipes/plusaes/all/test_package/CMakeLists.txt index 0a4d2fae5c706b..8b5b4793ec8d85 100644 --- a/recipes/plusaes/all/test_package/CMakeLists.txt +++ b/recipes/plusaes/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(plusaes REQUIRED CONFIG) diff --git a/recipes/plusaes/all/test_package/conanfile.py b/recipes/plusaes/all/test_package/conanfile.py index a500b98343c743..ef5d7042163ecc 100644 --- a/recipes/plusaes/all/test_package/conanfile.py +++ b/recipes/plusaes/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/plusaes/all/test_v1_package/CMakeLists.txt b/recipes/plusaes/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/plusaes/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/plusaes/all/test_v1_package/conanfile.py b/recipes/plusaes/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a500b98343c743 --- /dev/null +++ b/recipes/plusaes/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 350fb4e98d7d384ceaf234d336fb3d54da742f01 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 12:47:39 +0300 Subject: [PATCH 0263/1140] (#18779) tinyxml: enable with_stl by default --- recipes/tinyxml/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tinyxml/all/conanfile.py b/recipes/tinyxml/all/conanfile.py index 46d31e88896c2e..3616d277c7fb4b 100644 --- a/recipes/tinyxml/all/conanfile.py +++ b/recipes/tinyxml/all/conanfile.py @@ -25,7 +25,7 @@ class TinyXmlConan(ConanFile): default_options = { "shared": False, "fPIC": True, - "with_stl": False, + "with_stl": True, } exports_sources = "CMakeLists.txt" From 7e68b950b4e07d01ab84207c36883437a766fb10 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Thu, 17 Aug 2023 12:22:59 +0200 Subject: [PATCH 0264/1140] (#19244) [docs] Add changelog 17-Aug-2023 Signed-off-by: Uilian Ries --- docs/changelog.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 24c6950d686aad..3cf79f8d613275 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,11 @@ # Changelog +### 17-Aug-2023 - 11:42 CEST + +- [fix] Fix type error when catching generic exceptions in Jenkins +- [fix] Bump dependencies no longer allow version range +- [feature] Show recipe revision on the pull-request summary table + ### 04-Aug-2023 - 10:26 CEST - [feature] Enable Conan 2.0.8 From cbac272ef7ea6564c533079f6d4248d8195db1aa Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 17 Aug 2023 13:46:19 +0300 Subject: [PATCH 0265/1140] (#18808) opentracing-cpp: migrate to Conan v2 * opentracing-cpp: migrate to Conan v2 * opentracing-cpp: restore VirtualRunEnv in test_package --- recipes/opentracing-cpp/all/CMakeLists.txt | 7 - recipes/opentracing-cpp/all/conandata.yml | 3 +- recipes/opentracing-cpp/all/conanfile.py | 125 ++++++++---------- .../all/test_package/CMakeLists.txt | 5 +- .../all/test_package/conanfile.py | 21 ++- .../all/test_package/test_package.cpp | 2 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ 8 files changed, 100 insertions(+), 88 deletions(-) delete mode 100644 recipes/opentracing-cpp/all/CMakeLists.txt create mode 100644 recipes/opentracing-cpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/opentracing-cpp/all/test_v1_package/conanfile.py diff --git a/recipes/opentracing-cpp/all/CMakeLists.txt b/recipes/opentracing-cpp/all/CMakeLists.txt deleted file mode 100644 index bd3083b512cb93..00000000000000 --- a/recipes/opentracing-cpp/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/opentracing-cpp/all/conandata.yml b/recipes/opentracing-cpp/all/conandata.yml index 97fc5249ab98a2..98d819b31175b6 100644 --- a/recipes/opentracing-cpp/all/conandata.yml +++ b/recipes/opentracing-cpp/all/conandata.yml @@ -4,5 +4,4 @@ sources: sha256: 5b170042da4d1c4c231df6594da120875429d5231e9baa5179822ee8d1054ac3 patches: "1.6.0": - - base_path: "source_subfolder" - patch_file: "patches/0001-Set-default-installation-folders.patch" + - patch_file: "patches/0001-Set-default-installation-folders.patch" diff --git a/recipes/opentracing-cpp/all/conanfile.py b/recipes/opentracing-cpp/all/conanfile.py index 16f16b80280d27..bd664e12782243 100644 --- a/recipes/opentracing-cpp/all/conanfile.py +++ b/recipes/opentracing-cpp/all/conanfile.py @@ -1,17 +1,21 @@ import os -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir + +required_conan_version = ">=1.53.0" class OpenTracingConan(ConanFile): name = "opentracing-cpp" description = "C++ implementation of the OpenTracing API http://opentracing.io" license = "Apache-2.0" - topics = ("conan", "opentracing") - homepage = "https://github.com/opentracing/opentracing-cpp" url = "https://github.com/conan-io/conan-center-index" - exports_sources = ["CMakeLists.txt", "patches/*.patch"] - generators = "cmake" + homepage = "https://github.com/opentracing/opentracing-cpp" + topics = "opentracing" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -26,15 +30,8 @@ class OpenTracingConan(ConanFile): "enable_dynamic_load": False, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -42,78 +39,70 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 11) + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename(self.name + "-" + self.version, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_MOCKTRACER"] = self.options.enable_mocktracer + tc.variables["BUILD_DYNAMIC_LOADING"] = self.options.enable_dynamic_load + tc.variables["BUILD_SHARED_LIBS"] = self.options.shared + tc.variables["BUILD_STATIC_LIBS"] = not self.options.shared + tc.variables["BUILD_TESTING"] = False + tc.variables["ENABLE_LINTING"] = False + tc.generate() def build(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["BUILD_MOCKTRACER"] = self.options.enable_mocktracer - self._cmake.definitions[ - "BUILD_DYNAMIC_LOADING" - ] = self.options.enable_dynamic_load - self._cmake.definitions["BUILD_SHARED_LIBS"] = self.options.shared - self._cmake.definitions["BUILD_STATIC_LIBS"] = not self.options.shared - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.definitions["ENABLE_LINTING"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): - self.cpp_info.names["cmake_find_package"] = "OpenTracing" - self.cpp_info.names["cmake_find_package_multi"] = "OpenTracing" + self.cpp_info.set_property("cmake_file_name", "OpenTracing") + self.cpp_info.set_property("cmake_target_name", "OpenTracing::OpenTracing") target_suffix = "" if self.options.shared else "-static" - lib_suffix = ( - "" if self.options.shared or self.settings.os != "Windows" else "-static" - ) + lib_suffix = "" if self.options.shared or self.settings.os != "Windows" else "-static" + # opentracing - self.cpp_info.components["opentracing"].names["cmake_find_package"] = ( - "opentracing" + target_suffix - ) - self.cpp_info.components["opentracing"].names["cmake_find_package_multi"] = ( - "opentracing" + target_suffix - ) - self.cpp_info.components["opentracing"].libs = ["opentracing" + lib_suffix] + opentracing = self.cpp_info.components["opentracing"] + opentracing.set_property("cmake_target_name", "OpenTracing::opentracing" + target_suffix) + opentracing.names["cmake_find_package"] = "opentracing" + target_suffix + opentracing.names["cmake_find_package_multi"] = "opentracing" + target_suffix + opentracing.libs = ["opentracing" + lib_suffix] if not self.options.shared: - self.cpp_info.components["opentracing"].defines.append("OPENTRACING_STATIC") + opentracing.defines.append("OPENTRACING_STATIC") if self.options.enable_dynamic_load and self.settings.os in ("Linux", "FreeBSD"): - self.cpp_info.components["opentracing"].system_libs.append("dl") + opentracing.system_libs.append("dl") # opentracing_mocktracer if self.options.enable_mocktracer: - self.cpp_info.components["opentracing_mocktracer"].names[ - "cmake_find_package" - ] = ("opentracing_mocktracer" + target_suffix) - self.cpp_info.components["opentracing_mocktracer"].names[ - "cmake_find_package_multi" - ] = ("opentracing_mocktracer" + target_suffix) - self.cpp_info.components["opentracing_mocktracer"].libs = [ - "opentracing_mocktracer" + lib_suffix - ] - self.cpp_info.components["opentracing_mocktracer"].requires = [ - "opentracing" - ] + opentracing_mocktracer = self.cpp_info.components["opentracing_mocktracer"] + opentracing_mocktracer.set_property("cmake_target_name", "OpenTracing::opentracing_mocktracer" + target_suffix) + opentracing_mocktracer.names["cmake_find_package"] = "opentracing_mocktracer" + target_suffix + opentracing_mocktracer.names["cmake_find_package_multi"] = "opentracing_mocktracer" + target_suffix + opentracing_mocktracer.libs = ["opentracing_mocktracer" + lib_suffix] + opentracing_mocktracer.requires = ["opentracing"] if not self.options.shared: - self.cpp_info.components["opentracing_mocktracer"].defines.append( - "OPENTRACING_MOCK_TRACER_STATIC" - ) + opentracing_mocktracer.defines.append("OPENTRACING_MOCK_TRACER_STATIC") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "OpenTracing" + self.cpp_info.names["cmake_find_package_multi"] = "OpenTracing" diff --git a/recipes/opentracing-cpp/all/test_package/CMakeLists.txt b/recipes/opentracing-cpp/all/test_package/CMakeLists.txt index 124ca7e918838c..e9ddbfa9df1836 100644 --- a/recipes/opentracing-cpp/all/test_package/CMakeLists.txt +++ b/recipes/opentracing-cpp/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(OpenTracing REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/opentracing-cpp/all/test_package/conanfile.py b/recipes/opentracing-cpp/all/test_package/conanfile.py index abcaeed3f89b67..ef5d7042163ecc 100644 --- a/recipes/opentracing-cpp/all/test_package/conanfile.py +++ b/recipes/opentracing-cpp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/opentracing-cpp/all/test_package/test_package.cpp b/recipes/opentracing-cpp/all/test_package/test_package.cpp index ca88714cbdbf78..85d21515825726 100644 --- a/recipes/opentracing-cpp/all/test_package/test_package.cpp +++ b/recipes/opentracing-cpp/all/test_package/test_package.cpp @@ -7,6 +7,6 @@ int main() { auto tracer = MakeNoopTracer(); auto span1 = tracer->StartSpan("a"); - + return 0; } diff --git a/recipes/opentracing-cpp/all/test_v1_package/CMakeLists.txt b/recipes/opentracing-cpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/opentracing-cpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/opentracing-cpp/all/test_v1_package/conanfile.py b/recipes/opentracing-cpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/opentracing-cpp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 237d3a8e1607e48a7114ac2d3a69032797e78853 Mon Sep 17 00:00:00 2001 From: Michael Keck Date: Thu, 17 Aug 2023 13:34:38 +0200 Subject: [PATCH 0266/1140] (#19029) openssl: add 1.1.1v, 3.0.10, 3.1.2 --- recipes/openssl/1.x.x/conandata.yml | 27 +++++++++------------------ recipes/openssl/3.x.x/conandata.yml | 19 ++++++++++--------- recipes/openssl/config.yml | 14 ++++++-------- 3 files changed, 25 insertions(+), 35 deletions(-) diff --git a/recipes/openssl/1.x.x/conandata.yml b/recipes/openssl/1.x.x/conandata.yml index e9abce013a402a..14abde79960261 100644 --- a/recipes/openssl/1.x.x/conandata.yml +++ b/recipes/openssl/1.x.x/conandata.yml @@ -9,17 +9,6 @@ sources: url: - "https://www.openssl.org/source/openssl-1.1.0l.tar.gz" - "https://www.openssl.org/source/old/1.1.0/openssl-1.1.0l.tar.gz" - 1.1.1q: - sha256: d7939ce614029cdff0b6c20f0e2e5703158a489a72b2507b8bd51bf8c8fd10ca - url: - - "https://www.openssl.org/source/openssl-1.1.1q.tar.gz" - - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1q.tar.gz" - 1.1.1s: - sha256: c5ac01e760ee6ff0dab61d6b2bbd30146724d063eb322180c6f18a6f74e4b6aa - url: - - "https://www.openssl.org/source/openssl-1.1.1s.tar.gz" - - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1s.tar.gz" - - "https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1s/openssl-1.1.1s.tar.gz" 1.1.1t: sha256: 8dee9b24bdb1dcbf0c3d1e9b02fb8f6bf22165e807f45adeb7c9677536859d3b url: @@ -32,24 +21,26 @@ sources: - "https://www.openssl.org/source/openssl-1.1.1u.tar.gz" - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1u.tar.gz" - "https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1u/openssl-1.1.1u.tar.gz" + 1.1.1v: + sha256: d6697e2871e77238460402e9362d47d18382b15ef9f246aba6c7bd780d38a6b0 + url: + - "https://www.openssl.org/source/openssl-1.1.1v.tar.gz" + - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1v.tar.gz" + - "https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1v/openssl-1.1.1v.tar.gz" patches: 1.0.2u: - patch_file: patches/1.0.2u-darwin-arm64.patch patch_description: "Darwin ARM64 support" patch_type: "portability" - 1.1.1q: - - patch_file: patches/1.1.1-tvos-watchos.patch - patch_description: "TVOS and WatchOS don't like fork()" - patch_type: "portability" - 1.1.1s: + 1.1.1t: - patch_file: patches/1.1.1-tvos-watchos.patch patch_description: "TVOS and WatchOS don't like fork()" patch_type: "portability" - 1.1.1t: + 1.1.1u: - patch_file: patches/1.1.1-tvos-watchos.patch patch_description: "TVOS and WatchOS don't like fork()" patch_type: "portability" - 1.1.1u: + 1.1.1v: - patch_file: patches/1.1.1-tvos-watchos.patch patch_description: "TVOS and WatchOS don't like fork()" patch_type: "portability" diff --git a/recipes/openssl/3.x.x/conandata.yml b/recipes/openssl/3.x.x/conandata.yml index d51b393f65f34c..f1fe5a2743364d 100644 --- a/recipes/openssl/3.x.x/conandata.yml +++ b/recipes/openssl/3.x.x/conandata.yml @@ -1,4 +1,9 @@ sources: + 3.1.2: + url: + - "https://www.openssl.org/source/openssl-3.1.2.tar.gz" + - "https://github.com/openssl/openssl/releases/download/openssl-3.1.2/openssl-3.1.2.tar.gz" + sha256: a0ce69b8b97ea6a35b96875235aa453b966ba3cba8af2de23657d8b6767d6539 3.1.1: url: - "https://www.openssl.org/source/openssl-3.1.1.tar.gz" @@ -9,6 +14,11 @@ sources: - "https://www.openssl.org/source/openssl-3.1.0.tar.gz" - "https://github.com/openssl/openssl/releases/download/openssl-3.1.0/openssl-3.1.0.tar.gz" sha256: aaa925ad9828745c4cad9d9efeb273deca820f2cdcf2c3ac7d7c1212b7c497b4 + 3.0.10: + url: + - "https://www.openssl.org/source/openssl-3.0.10.tar.gz" + - "https://github.com/openssl/openssl/releases/download/openssl-3.0.10/openssl-3.0.10.tar.gz" + sha256: 1761d4f5b13a1028b9b6f3d4b8e17feb0cedc9370f6afe61d7193d2cdce83323 3.0.9: url: - "https://www.openssl.org/source/openssl-3.0.9.tar.gz" @@ -19,12 +29,3 @@ sources: - "https://www.openssl.org/source/openssl-3.0.8.tar.gz" - "https://github.com/openssl/openssl/releases/download/openssl-3.0.8/openssl-3.0.8.tar.gz" sha256: 6c13d2bf38fdf31eac3ce2a347073673f5d63263398f1f69d0df4a41253e4b3e - 3.0.7: - url: - - "https://www.openssl.org/source/openssl-3.0.7.tar.gz" - - "https://github.com/openssl/openssl/releases/download/openssl-3.0.7/openssl-3.0.7.tar.gz" - sha256: 83049d042a260e696f62406ac5c08bf706fd84383f945cf21bd61e9ed95c396e - 3.0.5: - url: - - "https://www.openssl.org/source/openssl-3.0.5.tar.gz" - sha256: aa7d8d9bef71ad6525c55ba11e5f4397889ce49c2c9349dcea6d3e4f0b024a7a diff --git a/recipes/openssl/config.yml b/recipes/openssl/config.yml index baf4bcb4f9215d..add37f9129c6c1 100644 --- a/recipes/openssl/config.yml +++ b/recipes/openssl/config.yml @@ -1,28 +1,26 @@ versions: # 3.1.x releases + 3.1.2: + folder: "3.x.x" 3.1.1: folder: "3.x.x" 3.1.0: folder: "3.x.x" # 3.0.x releases + 3.0.10: + folder: "3.x.x" 3.0.9: folder: "3.x.x" 3.0.8: folder: "3.x.x" - 3.0.7: - folder: "3.x.x" - 3.0.5: - folder: "3.x.x" # 1.1.1x releases + 1.1.1v: + folder: "1.x.x" 1.1.1u: folder: "1.x.x" 1.1.1t: folder: "1.x.x" - 1.1.1s: - folder: "1.x.x" - 1.1.1q: - folder: "1.x.x" # 1.1.0x releases 1.1.0l: folder: "1.x.x" From 8903e2251f9e2f68d86c026d09a3effecc0421ac Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 17 Aug 2023 22:20:32 +0900 Subject: [PATCH 0267/1140] (#19155) trompeloeil: add version 45 --- recipes/trompeloeil/all/conandata.yml | 7 +++-- recipes/trompeloeil/all/conanfile.py | 38 +++++++++++++++++++-------- recipes/trompeloeil/config.yml | 2 ++ 3 files changed, 34 insertions(+), 13 deletions(-) diff --git a/recipes/trompeloeil/all/conandata.yml b/recipes/trompeloeil/all/conandata.yml index bb27ac3c59d8a7..6aebe5771a442e 100644 --- a/recipes/trompeloeil/all/conandata.yml +++ b/recipes/trompeloeil/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "45": + url: "https://github.com/rollbear/trompeloeil/archive/v45.tar.gz" + sha256: "124b0aa45d84415193719376b6557fc1f1180cbfebf4dc4f7ca247cb404d6bd8" "43": url: "https://github.com/rollbear/trompeloeil/archive/v43.tar.gz" sha256: "86a0afa2e97347202a0a883ab43da78c1d4bfff0d6cb93205cfc433d0d9eb9eb" @@ -12,5 +15,5 @@ sources: url: "https://github.com/rollbear/trompeloeil/archive/v40.tar.gz" sha256: "e13e3649223a358a5a72fa5a8a1c36325b48e4f3d9d2f2277b17d746797e1734" "39": - url: https://github.com/rollbear/trompeloeil/archive/v39.tar.gz - sha256: 10506E48ABD605740BC9ED43E34059F5068BC80AF14476BD129A3ED3B54D522F + url: "https://github.com/rollbear/trompeloeil/archive/v39.tar.gz" + sha256: "10506E48ABD605740BC9ED43E34059F5068BC80AF14476BD129A3ED3B54D522F" diff --git a/recipes/trompeloeil/all/conanfile.py b/recipes/trompeloeil/all/conanfile.py index c2548bfe997b8b..e3776238f24cfe 100644 --- a/recipes/trompeloeil/all/conanfile.py +++ b/recipes/trompeloeil/all/conanfile.py @@ -1,22 +1,38 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os required_conan_version = ">=1.50.0" - class TrompeloeilConan(ConanFile): name = "trompeloeil" description = "Header only C++14 mocking framework" - topics = ("trompeloeil", "header-only", "mocking") - homepage = "https://github.com/rollbear/trompeloeil" - url = "https://github.com/conan-io/conan-center-index" license = "BSL-1.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/rollbear/trompeloeil" + topics = ("header-only", "mocking") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + return 14 + + @property + def _compilers_minimum_version(self): + return { + "Visual Studio": "15", + "msvc": "190", + "gcc": "5", + "clang": "5", + "apple-clang": "5.1", + } + def layout(self): basic_layout(self, src_folder="src") @@ -25,14 +41,15 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 14) + 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], - destination=self.source_folder, strip_root=True) - - def build(self): - pass + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, "LICENSE*.txt", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) @@ -43,4 +60,3 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "trompeloeil::trompeloeil") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] diff --git a/recipes/trompeloeil/config.yml b/recipes/trompeloeil/config.yml index 26645b05ba8da8..2353875452e464 100644 --- a/recipes/trompeloeil/config.yml +++ b/recipes/trompeloeil/config.yml @@ -1,4 +1,6 @@ versions: + "45": + folder: all "43": folder: all "42": From 4df95709fa0f55c17fc2aafe5ce6d270402d0a81 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Thu, 17 Aug 2023 18:48:13 +0400 Subject: [PATCH 0268/1140] (#19172) pugixml: set package_type --- recipes/pugixml/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/pugixml/all/conanfile.py b/recipes/pugixml/all/conanfile.py index c5890f6dbab550..7ac623ed2f0816 100644 --- a/recipes/pugixml/all/conanfile.py +++ b/recipes/pugixml/all/conanfile.py @@ -15,6 +15,7 @@ class PugiXmlConan(ConanFile): license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://pugixml.org/" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { From 323a1f889dc0f1c8b03b9e90f6f70c062b6d95af Mon Sep 17 00:00:00 2001 From: BogDan Vatra Date: Thu, 17 Aug 2023 19:17:03 +0300 Subject: [PATCH 0269/1140] (#19181) Added kdbindings/1.0.3 KDBindings enables reactive programming & data binding in C++ From plain C++ you get: - Signals + Slots. - Properties templated on the contained type. - Property bindings allowing reactive code to be written without having to do all the low-level, error prone plumbing by hand. Lazy evaluation of property bindings. - No more broken bindings. - Totally stand-alone "header-only" library. --- recipes/kdbindings/all/conandata.yml | 4 ++ recipes/kdbindings/all/conanfile.py | 54 ++++++++++++++++ .../all/test_package/CMakeLists.txt | 15 +++++ .../kdbindings/all/test_package/conanfile.py | 26 ++++++++ recipes/kdbindings/all/test_package/main.cpp | 63 +++++++++++++++++++ recipes/kdbindings/config.yml | 3 + 6 files changed, 165 insertions(+) create mode 100644 recipes/kdbindings/all/conandata.yml create mode 100644 recipes/kdbindings/all/conanfile.py create mode 100644 recipes/kdbindings/all/test_package/CMakeLists.txt create mode 100644 recipes/kdbindings/all/test_package/conanfile.py create mode 100644 recipes/kdbindings/all/test_package/main.cpp create mode 100644 recipes/kdbindings/config.yml diff --git a/recipes/kdbindings/all/conandata.yml b/recipes/kdbindings/all/conandata.yml new file mode 100644 index 00000000000000..fa9ce176c1b03e --- /dev/null +++ b/recipes/kdbindings/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.0.3": + url: "https://github.com/KDAB/KDBindings/archive/refs/tags/v1.0.3.tar.gz" + sha256: "da8de679d12bf123df6a3c63a482a862d4122a2f3d3567c9b3b2fc2c4f574393" diff --git a/recipes/kdbindings/all/conanfile.py b/recipes/kdbindings/all/conanfile.py new file mode 100644 index 00000000000000..9f1cf776a90f2c --- /dev/null +++ b/recipes/kdbindings/all/conanfile.py @@ -0,0 +1,54 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.scm import Version +import os + +class KDBindingsConan(ConanFile): + name = "kdbindings" + license = "MIT" + topics = ("c++17", "reactive", "kdab", "header-only") + description = "Reactive programming & data binding in C++" + homepage = "https://github.com/KDAB/KDBindings" + url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def package_id(self): + self.info.clear() + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True, destination=self.source_folder) + + @property + def _compilers_minimum_version(self): + return { + "gcc": "9", + "Visual Studio": "15.7", + "clang": "7", + "apple-clang": "11", + } + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 17) + + 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++17, which your compiler does not support.") + + def build(self): + pass + + def package(self): + copy(self, "*.h", os.path.join(self.source_folder, "src","kdbindings"), os.path.join(self.package_folder, "include", "kdbindings")) + copy(self, "LICENSES/*", dst=os.path.join(self.package_folder,"licenses"), src=self.source_folder) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "KDBindings") + self.cpp_info.set_property("cmake_target_name", "KDAB::KDBindings") + self.cpp_info.set_property("cmake_target_aliases", ["KDBindings"]) diff --git a/recipes/kdbindings/all/test_package/CMakeLists.txt b/recipes/kdbindings/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..cbd352d1e0df77 --- /dev/null +++ b/recipes/kdbindings/all/test_package/CMakeLists.txt @@ -0,0 +1,15 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) + +find_package(KDBindings REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} main.cpp) + +target_link_libraries(${PROJECT_NAME} PRIVATE KDAB::KDBindings) + +set_target_properties(${PROJECT_NAME} + PROPERTIES + CMAKE_INCLUDE_CURRENT_DIRS ON + CXX_STANDARD 17 + CXX_STANDARD_REQUIRED ON +) diff --git a/recipes/kdbindings/all/test_package/conanfile.py b/recipes/kdbindings/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e845ae751a3017 --- /dev/null +++ b/recipes/kdbindings/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/kdbindings/all/test_package/main.cpp b/recipes/kdbindings/all/test_package/main.cpp new file mode 100644 index 00000000000000..82e0dc503f17b6 --- /dev/null +++ b/recipes/kdbindings/all/test_package/main.cpp @@ -0,0 +1,63 @@ +/* + This file is part of KDBindings. + + SPDX-FileCopyrightText: 2021-2022 Klarälvdalens Datakonsult AB, a KDAB Group company + Author: Leon Matthes + + SPDX-License-Identifier: MIT + + Contact KDAB at for commercial licensing options. +*/ + +#include +#include + +#include +#include + +using namespace KDBindings; + +void display() +{ + std::cout << "Hello World!" << std::endl; +} + +void displayLabelled(const std::string &label, int value) +{ + std::cout << label << ": " << value << std::endl; +} + +class SignalHandler +{ +public: + bool received = 0; + + void receive() + { + received = true; + } +}; + +int main() +{ + Signal signal; + + // Signal::connect allows connecting functions that take too few arguments. + signal.connect(display); + + // As well as functions with too many arguments, as long as default values are provided. + signal.connect(displayLabelled, "Emitted value"); + + // This is very useful to connect member functions, where the first implicit argument + // is a pointer to the "this" object. + SignalHandler handler; + signal.connect(&SignalHandler::receive, &handler); + + // This will print "Hello World!" and "Emitted value: 5" in an unspecified order. + // It will also set handler.received to true + signal.emit(5); + + std::cout << std::boolalpha << handler.received << std::endl; + + return 0; +} diff --git a/recipes/kdbindings/config.yml b/recipes/kdbindings/config.yml new file mode 100644 index 00000000000000..372dd1cb646bd1 --- /dev/null +++ b/recipes/kdbindings/config.yml @@ -0,0 +1,3 @@ +versions: + "1.0.3": + folder: all From 9436459b4a909c4c533ffe27a95c1f21cbdbbfa8 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Thu, 17 Aug 2023 12:22:34 -0500 Subject: [PATCH 0270/1140] (#18211) gdcm: Switch libuuid to util-linux-libuuid * gdcm: Switch libuuid to util-linux-libuuid The util-linux-libuuid package relies on an actively maintained project. The libuuid package uses a stale project. Use the active project instead to fix conflicts. Fixes #18203. * Fix component requires * Revert patches --- recipes/gdcm/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/gdcm/all/conanfile.py b/recipes/gdcm/all/conanfile.py index d7959e0134184e..8a628f7457e273 100644 --- a/recipes/gdcm/all/conanfile.py +++ b/recipes/gdcm/all/conanfile.py @@ -63,7 +63,7 @@ def requirements(self): else: self.requires("zlib/1.2.13") if self.settings.os != "Windows": - self.requires("libuuid/1.0.3") + self.requires("util-linux-libuuid/2.39") if Version(self.version) >= Version("3.0.20"): self.requires("libiconv/1.17") if self.options.with_json: @@ -241,7 +241,7 @@ def zlib(): if self.options.with_json: self.cpp_info.components["gdcmMSFF"].requires.append("json-c::json-c") if self.settings.os != "Windows": - self.cpp_info.components["gdcmMSFF"].requires.append("libuuid::libuuid") + self.cpp_info.components["gdcmMSFF"].requires.append("util-linux-libuuid::util-linux-libuuid") if Version(self.version) >= Version("3.0.20"): self.cpp_info.components["gdcmMSFF"].requires.append("libiconv::libiconv") if not self.options.shared: From b81d32a6c3513836a1f36cd5b5ebd28c8f45685d Mon Sep 17 00:00:00 2001 From: Liss Heidrich <31625940+Clueliss@users.noreply.github.com> Date: Thu, 17 Aug 2023 20:41:02 +0200 Subject: [PATCH 0271/1140] (#19206) Add new metall versions * add new metall versions * update boost * newlines --------- Co-authored-by: Liss Heidrich --- recipes/metall/all/conandata.yml | 9 +++++++++ recipes/metall/all/conanfile.py | 2 +- recipes/metall/config.yml | 6 ++++++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/recipes/metall/all/conandata.yml b/recipes/metall/all/conandata.yml index 788ef5da15507e..96fee3029b84f2 100644 --- a/recipes/metall/all/conandata.yml +++ b/recipes/metall/all/conandata.yml @@ -8,3 +8,12 @@ sources: "0.23.1": url: "https://github.com/LLNL/metall/archive/refs/tags/v0.23.1.tar.gz" sha256: "25e8fbc424e66d09e0faf60029288e4612685675bfd947cc142bd9d6d0645ac4" + "0.24": + url: "https://github.com/LLNL/metall/archive/refs/tags/v0.24.tar.gz" + sha256: "872de2a1b76d44e6876c0b672c0cc518c6f334959e4a229f2f18cc7e01edf477" + "0.25": + url: "https://github.com/LLNL/metall/archive/refs/tags/v0.25.tar.gz" + sha256: "223cb54543b62a62fdbbe6274b02ddcc14b29806e344ee7e2fd3f055c2374295" + "0.26": + url: "https://github.com/LLNL/metall/archive/refs/tags/v0.26.tar.gz" + sha256: "7453c87d99708be8542e354e582cbeefac1e5ba65e609cd85d7126c5b25a6d7b" diff --git a/recipes/metall/all/conanfile.py b/recipes/metall/all/conanfile.py index 957ba5421027f1..c629633bf00943 100644 --- a/recipes/metall/all/conanfile.py +++ b/recipes/metall/all/conanfile.py @@ -27,7 +27,7 @@ def _compilers_minimum_version(self): } def requirements(self): - self.requires("boost/1.79.0") + self.requires("boost/1.81.0") def package_id(self): self.info.clear() diff --git a/recipes/metall/config.yml b/recipes/metall/config.yml index e3fb6e5067c490..11daea4abf351b 100644 --- a/recipes/metall/config.yml +++ b/recipes/metall/config.yml @@ -5,3 +5,9 @@ versions: folder: all "0.23.1": folder: all + "0.24": + folder: all + "0.25": + folder: all + "0.26": + folder: all From 3eb269f14ab9c3b5bfe5fa769011bb3bd78ec865 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 04:34:23 +0900 Subject: [PATCH 0272/1140] (#19210) gperftools: add version 2.11.0 * gperftools: add version 2.11 * enable C++11 * drop support gcc < 7 --- recipes/gperftools/all/conandata.yml | 3 +++ recipes/gperftools/all/conanfile.py | 19 ++++++++++++++----- .../all/test_package/CMakeLists.txt | 2 ++ recipes/gperftools/config.yml | 2 ++ 4 files changed, 21 insertions(+), 5 deletions(-) diff --git a/recipes/gperftools/all/conandata.yml b/recipes/gperftools/all/conandata.yml index 8b70af34880378..439e56462f63f3 100644 --- a/recipes/gperftools/all/conandata.yml +++ b/recipes/gperftools/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.11.0": + url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.11/gperftools-2.11.tar.gz" + sha256: "8ffda10e7c500fea23df182d7adddbf378a203c681515ad913c28a64b87e24dc" "2.10.0": url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.10/gperftools-2.10.tar.gz" sha256: "83e3bfdd28b8bcf53222c3798d4d395d52dadbbae59e8730c4a6d31a9c3732d8" diff --git a/recipes/gperftools/all/conanfile.py b/recipes/gperftools/all/conanfile.py index 60812b411ba177..d1bcecf43d3948 100644 --- a/recipes/gperftools/all/conanfile.py +++ b/recipes/gperftools/all/conanfile.py @@ -1,17 +1,16 @@ -import os - from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.apple import fix_apple_shared_install_name, is_apple_os, XCRun -from conan.tools.build import cross_building +from conan.tools.build import cross_building, check_min_cppstd from conan.tools.cmake import cmake_layout from conan.tools.env import VirtualRunEnv from conan.tools.files import get, copy, rm, rmdir, replace_in_file from conan.tools.gnu import AutotoolsToolchain, AutotoolsDeps, Autotools +from conan.tools.scm import Version +import os required_conan_version = ">=1.53.0" - class GperftoolsConan(ConanFile): name = "gperftools" description = "High-performance multi-threaded malloc()" @@ -58,6 +57,10 @@ class GperftoolsConan(ConanFile): "tcmalloc_pagesize": None, } + @property + def _min_cppstd(self): + return 11 + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -88,9 +91,15 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + if Version(self.version) >= "2.11.0" and self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "7": + raise ConanInvalidConfiguration(f"{self.ref} does not support gcc < 7.") + if self.settings.os == "Windows": raise ConanInvalidConfiguration( - "gperftools recipe does not currently support Windows. Contributions are welcome." + f"{self.ref} does not currently support Windows. Contributions are welcome." ) def requirements(self): diff --git a/recipes/gperftools/all/test_package/CMakeLists.txt b/recipes/gperftools/all/test_package/CMakeLists.txt index c9f3e082d85e90..0f311015a73f50 100644 --- a/recipes/gperftools/all/test_package/CMakeLists.txt +++ b/recipes/gperftools/all/test_package/CMakeLists.txt @@ -5,6 +5,8 @@ find_package(gperftools REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE gperftools::gperftools) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) add_executable(${PROJECT_NAME}_minimal test_package.cpp) target_link_libraries(${PROJECT_NAME}_minimal PRIVATE gperftools::tcmalloc_minimal) +target_compile_features(${PROJECT_NAME}_minimal PRIVATE cxx_std_11) diff --git a/recipes/gperftools/config.yml b/recipes/gperftools/config.yml index 22d65dcfdfac61..caf3d644433044 100644 --- a/recipes/gperftools/config.yml +++ b/recipes/gperftools/config.yml @@ -1,3 +1,5 @@ versions: + "2.11.0": + folder: all "2.10.0": folder: all From 0173669136e137d71f1dd9204756c0f7697fe07c Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 06:02:36 +0900 Subject: [PATCH 0273/1140] (#19258) plusaes: add version 1.0.0 --- recipes/plusaes/all/conandata.yml | 3 +++ recipes/plusaes/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/plusaes/all/conandata.yml b/recipes/plusaes/all/conandata.yml index 539b28539b8748..595f0e1a79d210 100644 --- a/recipes/plusaes/all/conandata.yml +++ b/recipes/plusaes/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.0": + url: "https://github.com/kkAyataka/plusaes/archive/refs/tags/v1.0.0.tar.gz" + sha256: "0e33e8d0e2ea5e6f9eb7a06093f576350ce8ef58339ce9de791514a8f433087d" "0.10.0": url: "https://github.com/kkAyataka/plusaes/archive/refs/tags/v0.10.0.tar.gz" sha256: "092d64f372f5b732c8e35ab8f1049d4c6ef2eaa4c6ababc56b541b26f4095e51" diff --git a/recipes/plusaes/config.yml b/recipes/plusaes/config.yml index 1b582dcf6716ba..f5fa9d899d2442 100644 --- a/recipes/plusaes/config.yml +++ b/recipes/plusaes/config.yml @@ -1,3 +1,5 @@ versions: + "1.0.0": + folder: all "0.10.0": folder: all From 09f811dc675618ada4ffb3455837772a4f010344 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 07:53:41 +0900 Subject: [PATCH 0274/1140] (#19255) s2n: add version 1.3.49 --- recipes/s2n/all/conandata.yml | 3 +++ recipes/s2n/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/s2n/all/conandata.yml b/recipes/s2n/all/conandata.yml index 1f39628799a666..26760a8527f224 100644 --- a/recipes/s2n/all/conandata.yml +++ b/recipes/s2n/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.49": + url: "https://github.com/aws/s2n-tls/archive/refs/tags/v1.3.49.tar.gz" + sha256: "2bc7b170a750a435ad02ab8e696c3ad6e9bb7a585c02899472793f87670184dd" "1.3.31": url: "https://github.com/aws/s2n-tls/archive/v1.3.31.tar.gz" sha256: "23cfb42f82cbe1ce94b59f3b1c1c8eb9d24af2a1ae4c8f854209ff88fddd3900" diff --git a/recipes/s2n/config.yml b/recipes/s2n/config.yml index 611e0f7be0d88e..7c0e248cb28f01 100644 --- a/recipes/s2n/config.yml +++ b/recipes/s2n/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.49": + folder: all "1.3.31": folder: all "1.3.15": From a5737003c16ba8df5b4f1184ab2745fdfbf0b049 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludwig=20F=C3=BCchsl?= Date: Fri, 18 Aug 2023 01:48:50 +0200 Subject: [PATCH 0275/1140] (#19250) [package] angelscript/2.36.1 (Update) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit (Maybe we need the last patch again) Co-authored-by: Rubén Rincón Blanco --- recipes/angelscript/all/conandata.yml | 3 +++ recipes/angelscript/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/angelscript/all/conandata.yml b/recipes/angelscript/all/conandata.yml index 1dec7ac1d3e717..edfe7e005b8552 100644 --- a/recipes/angelscript/all/conandata.yml +++ b/recipes/angelscript/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.36.1": + url: "https://www.angelcode.com/angelscript/sdk/files/angelscript_2.36.1.zip" + sha256: "58bb749af9c7e386304705f4e6e627ae41dfe03e0b6a73c3d0d2e017c4fc948f" "2.36.0": url: "https://www.angelcode.com/angelscript/sdk/files/angelscript_2.36.0.zip" sha256: "33f95f7597bc0d88b097d35e7b1320d15419ffc5779851d9d2a6cccec57811b3" diff --git a/recipes/angelscript/config.yml b/recipes/angelscript/config.yml index 22190418b16a22..f3cbb4fedf4543 100644 --- a/recipes/angelscript/config.yml +++ b/recipes/angelscript/config.yml @@ -1,4 +1,6 @@ versions: + "2.36.1": + folder: all "2.36.0": folder: all "2.35.1": From 4dc114ec7193f54889ecb64823e975a570622ae8 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 18 Aug 2023 03:07:01 +0300 Subject: [PATCH 0276/1140] (#19256) maven: fix dead URL, bump JDK dep * maven: remove old version with dead URL, bump JDK dep Based on https://repology.org/repository/conancenter/problems * maven: restore v3.9.2, use archive URL --- recipes/maven/all/conandata.yml | 6 ++++-- recipes/maven/all/conanfile.py | 2 +- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/recipes/maven/all/conandata.yml b/recipes/maven/all/conandata.yml index ce4fe6b87794c8..a0978eddc0d68f 100644 --- a/recipes/maven/all/conandata.yml +++ b/recipes/maven/all/conandata.yml @@ -1,7 +1,9 @@ sources: "3.9.4": - url: "https://dlcdn.apache.org/maven/maven-3/3.9.4/binaries/apache-maven-3.9.4-bin.tar.gz" + url: + - "https://dlcdn.apache.org/maven/maven-3/3.9.4/binaries/apache-maven-3.9.4-bin.tar.gz" + - "https://archive.apache.org/dist/maven/maven-3/3.9.4/binaries/apache-maven-3.9.4-bin.tar.gz" sha256: "ff66b70c830a38d331d44f6c25a37b582471def9a161c93902bac7bea3098319" "3.9.2": - url: "https://dlcdn.apache.org/maven/maven-3/3.9.2/binaries/apache-maven-3.9.2-bin.tar.gz" + url: "https://archive.apache.org/dist/maven/maven-3/3.9.2/binaries/apache-maven-3.9.2-bin.tar.gz" sha256: "809ef3220c6d179195c06c324cb9a6d34d8ecba566c5cfd8eb83167bc034117d" diff --git a/recipes/maven/all/conanfile.py b/recipes/maven/all/conanfile.py index f1f95efee4fb1c..31d963f2df4c14 100644 --- a/recipes/maven/all/conanfile.py +++ b/recipes/maven/all/conanfile.py @@ -18,7 +18,7 @@ def layout(self): pass def requirements(self): - self.requires("zulu-openjdk/11.0.15") + self.requires("zulu-openjdk/11.0.19") def package_id(self): del self.info.settings.arch From f0ded7723bf6e12a8226fb3e011952a2a1719c9b Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 18 Aug 2023 07:42:14 +0200 Subject: [PATCH 0277/1140] (#19246) [bot] Update authorized users list (2023-08-17) --- .c3i/authorized_users.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index d4bb58861e74d1..fcf61aaa08fd3d 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1215,3 +1215,4 @@ authorized_users: - Arkokat - adattatri - jwfallawuiuc +- tgurriet From 1c43599843bb53254030b06faace72f313c9292f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 18 Aug 2023 08:05:19 +0200 Subject: [PATCH 0278/1140] (#19248) harfbuzz: Bump dependencies, fix glib tool_requires * Bump dependencies, fix glib tool_requires * Fix version check, fix outdated url --- recipes/harfbuzz/all/conanfile.py | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/recipes/harfbuzz/all/conanfile.py b/recipes/harfbuzz/all/conanfile.py index c31c4772cdf26a..ce1aa84efb199e 100644 --- a/recipes/harfbuzz/all/conanfile.py +++ b/recipes/harfbuzz/all/conanfile.py @@ -2,7 +2,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.apple import is_apple_os, fix_apple_shared_install_name from conan.tools.build import can_run, stdcpp_library -from conan.tools.env import Environment, VirtualBuildEnv, VirtualRunEnv +from conan.tools.env import Environment, VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir, replace_in_file from conan.tools.gnu import PkgConfigDeps from conan.tools.layout import basic_layout @@ -12,7 +12,7 @@ import os -required_conan_version = ">=1.54.0" +required_conan_version = ">=1.60.0 <2.0 || >=2.0.6" class HarfbuzzConan(ConanFile): @@ -20,7 +20,7 @@ class HarfbuzzConan(ConanFile): description = "HarfBuzz is an OpenType text shaping engine." topics = ("opentype", "text", "engine") url = "https://github.com/conan-io/conan-center-index" - homepage = "http://harfbuzz.org" + homepage = "https://harfbuzz.github.io/" license = "MIT" package_type = "library" settings = "os", "arch", "compiler", "build_type" @@ -78,9 +78,9 @@ def requirements(self): if self.options.with_freetype: self.requires("freetype/2.13.0") if self.options.with_icu: - self.requires("icu/73.1") + self.requires("icu/73.2") if self.options.with_glib: - self.requires("glib/2.76.3", run=can_run(self)) + self.requires("glib/2.77.0") def validate(self): if self.options.shared and self.options.with_glib and not self.dependencies["glib"].options.shared: @@ -100,8 +100,8 @@ def build_requirements(self): self.tool_requires("meson/1.1.0") if not self.conf.get("tools.gnu:pkg_config", check_type=str): self.tool_requires("pkgconf/1.9.3") - if self.options.with_glib and not can_run(self): - self.tool_requires("glib/2.76.3") + if self.options.with_glib: + self.tool_requires("glib/") if self.settings.os == "Macos": # Ensure that the gettext we use at build time is compatible # with the libiconv that is transitively exposed by glib @@ -125,8 +125,6 @@ def is_vs_2017(): return "ninja", [] VirtualBuildEnv(self).generate() - if self.options.with_glib and can_run(self): - VirtualRunEnv(self).generate(scope="build") # Avoid conflicts with libiconv # see: https://github.com/conan-io/conan-center-index/pull/17046#issuecomment-1554629094 From 6a85defe83b26432983a95f57a8ee60261b5cbdf Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 16:07:43 +0900 Subject: [PATCH 0279/1140] (#18963) streamvbyte: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * streamvbyte: add recipe * fix installation path on windows * remove empty line * Update recipes/streamvbyte/all/test_package/test_package.c --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Rubén Rincón Blanco --- recipes/streamvbyte/all/conandata.yml | 9 +++ recipes/streamvbyte/all/conanfile.py | 63 +++++++++++++++++++ .../all/patches/1.0.0-0001-fix-cmake.patch | 17 +++++ .../all/test_package/CMakeLists.txt | 7 +++ .../streamvbyte/all/test_package/conanfile.py | 26 ++++++++ .../all/test_package/test_package.c | 29 +++++++++ recipes/streamvbyte/config.yml | 3 + 7 files changed, 154 insertions(+) create mode 100644 recipes/streamvbyte/all/conandata.yml create mode 100644 recipes/streamvbyte/all/conanfile.py create mode 100644 recipes/streamvbyte/all/patches/1.0.0-0001-fix-cmake.patch create mode 100644 recipes/streamvbyte/all/test_package/CMakeLists.txt create mode 100644 recipes/streamvbyte/all/test_package/conanfile.py create mode 100644 recipes/streamvbyte/all/test_package/test_package.c create mode 100644 recipes/streamvbyte/config.yml diff --git a/recipes/streamvbyte/all/conandata.yml b/recipes/streamvbyte/all/conandata.yml new file mode 100644 index 00000000000000..a5dd541a0c7806 --- /dev/null +++ b/recipes/streamvbyte/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "1.0.0": + url: "https://github.com/lemire/streamvbyte/archive/refs/tags/v1.0.0.tar.gz" + sha256: "6b1920e9865146ba444cc317aa61cd39cdf760236e354ef7956011a9fe577882" +patches: + "1.0.0": + - patch_file: "patches/1.0.0-0001-fix-cmake.patch" + patch_description: "fix install destination" + patch_type: "conan" diff --git a/recipes/streamvbyte/all/conanfile.py b/recipes/streamvbyte/all/conanfile.py new file mode 100644 index 00000000000000..e296e0b1707999 --- /dev/null +++ b/recipes/streamvbyte/all/conanfile.py @@ -0,0 +1,63 @@ +from conan import ConanFile +from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +import os + +required_conan_version = ">=1.53.0" + +class StreamvbyteConan(ConanFile): + name = "streamvbyte" + description = "Fast integer compression in C using the StreamVByte codec" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/lemire/streamvbyte" + topics = ("compression", "simd") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["STREAMVBYTE_WERROR"] = False + tc.variables["STREAMVBYTE_WALL"] = False + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["streamvbyte"] diff --git a/recipes/streamvbyte/all/patches/1.0.0-0001-fix-cmake.patch b/recipes/streamvbyte/all/patches/1.0.0-0001-fix-cmake.patch new file mode 100644 index 00000000000000..99ab62225b6388 --- /dev/null +++ b/recipes/streamvbyte/all/patches/1.0.0-0001-fix-cmake.patch @@ -0,0 +1,17 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index b6aa73e..547c44d 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -136,7 +136,11 @@ install( + ${PROJECT_SOURCE_DIR}/include/streamvbyte_zigzag.h + DESTINATION include + ) +-install(TARGETS streamvbyte DESTINATION lib) ++install(TARGETS streamvbyte ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} ++ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} ++) + + option(STREAMVBYTE_SANITIZE_UNDEFINED "Sanitize undefined behavior" OFF) + if(STREAMVBYTE_SANITIZE_UNDEFINED) diff --git a/recipes/streamvbyte/all/test_package/CMakeLists.txt b/recipes/streamvbyte/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..531d5c3182e367 --- /dev/null +++ b/recipes/streamvbyte/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) + +find_package(streamvbyte REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE streamvbyte::streamvbyte) diff --git a/recipes/streamvbyte/all/test_package/conanfile.py b/recipes/streamvbyte/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/streamvbyte/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/streamvbyte/all/test_package/test_package.c b/recipes/streamvbyte/all/test_package/test_package.c new file mode 100644 index 00000000000000..bda2ad161f9424 --- /dev/null +++ b/recipes/streamvbyte/all/test_package/test_package.c @@ -0,0 +1,29 @@ +#include +#include +#include + +#include "streamvbyte.h" + +#ifdef __clang__ +#pragma clang diagnostic ignored "-Wdeclaration-after-statement" +#pragma clang diagnostic ignored "-Wunused-variable" +#endif + +int main(void) { + uint32_t N = 100U; + uint32_t * datain = malloc(N * sizeof(uint32_t)); + uint8_t * compressedbuffer = malloc(streamvbyte_max_compressedbytes(N)); + uint32_t * recovdata = malloc(N * sizeof(uint32_t)); + for (uint32_t k = 0; k < N; ++k) + datain[k] = 120; + size_t compsize = streamvbyte_encode(datain, N, compressedbuffer); // encoding + // here the result is stored in compressedbuffer using compsize bytes + size_t compsize2 = streamvbyte_decode(compressedbuffer, recovdata, + N); // decoding (fast) + assert(compsize == compsize2); + free(datain); + free(compressedbuffer); + free(recovdata); + printf("Compressed %d integers down to %d bytes.\n",N,(int) compsize); + return 0; +} diff --git a/recipes/streamvbyte/config.yml b/recipes/streamvbyte/config.yml new file mode 100644 index 00000000000000..40341aa3db6cd3 --- /dev/null +++ b/recipes/streamvbyte/config.yml @@ -0,0 +1,3 @@ +versions: + "1.0.0": + folder: all From e1b937bd3093567402be2f5e9552630aee5e1dfa Mon Sep 17 00:00:00 2001 From: Joris Putcuyps Date: Fri, 18 Aug 2023 09:29:49 +0200 Subject: [PATCH 0280/1140] (#19200) Follow the convention and also provide etl::etl alias. * Follow the convention and also provide etl::etl alias. * Previous property is overwritten * Update recipes/etl/all/conanfile.py Support legacy target Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/etl/all/conanfile.py | 3 ++- recipes/etl/all/test_package/CMakeLists.txt | 2 +- recipes/etl/all/test_v1_package/CMakeLists.txt | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes/etl/all/conanfile.py b/recipes/etl/all/conanfile.py index b0f40f7104e269..a1737588ee9650 100644 --- a/recipes/etl/all/conanfile.py +++ b/recipes/etl/all/conanfile.py @@ -60,7 +60,8 @@ def _module_file_rel_path(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "etl") - self.cpp_info.set_property("cmake_target_name", "etl") + self.cpp_info.set_property("cmake_target_name", "etl::etl") + self.cpp_info.set_property("cmake_target_aliases", ["etl"]) # legacy target before 20.27.2 self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] diff --git a/recipes/etl/all/test_package/CMakeLists.txt b/recipes/etl/all/test_package/CMakeLists.txt index b8e7aee7d94588..abf67a0fae7eec 100644 --- a/recipes/etl/all/test_package/CMakeLists.txt +++ b/recipes/etl/all/test_package/CMakeLists.txt @@ -5,4 +5,4 @@ find_package(etl REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) -target_link_libraries(${PROJECT_NAME} PRIVATE etl) +target_link_libraries(${PROJECT_NAME} PRIVATE etl::etl) diff --git a/recipes/etl/all/test_v1_package/CMakeLists.txt b/recipes/etl/all/test_v1_package/CMakeLists.txt index b8e7ad788b8211..19dd51b438baa7 100644 --- a/recipes/etl/all/test_v1_package/CMakeLists.txt +++ b/recipes/etl/all/test_v1_package/CMakeLists.txt @@ -8,4 +8,4 @@ find_package(etl REQUIRED CONFIG) add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) -target_link_libraries(${PROJECT_NAME} etl) +target_link_libraries(${PROJECT_NAME} etl::etl) From ddc3b9cdd4144623c127ac10ac470f7eb051aca6 Mon Sep 17 00:00:00 2001 From: Raven Szewczyk Date: Fri, 18 Aug 2023 09:13:45 +0100 Subject: [PATCH 0281/1140] (#19223) nodejs: add version 16.20.2 * nodejs: add version 16.20.2 * Add missing config.yml entry --- recipes/nodejs/all/conandata.yml | 22 ++++++++++++++++++++++ recipes/nodejs/config.yml | 2 ++ 2 files changed, 24 insertions(+) diff --git a/recipes/nodejs/all/conandata.yml b/recipes/nodejs/all/conandata.yml index 0681cc81e538a7..56a1be535ef41d 100644 --- a/recipes/nodejs/all/conandata.yml +++ b/recipes/nodejs/all/conandata.yml @@ -47,6 +47,28 @@ sources: "armv8": url: "https://nodejs.org/dist/v16.3.0/node-v16.3.0-darwin-arm64.tar.gz" sha256: "aeac294dbe54a4dfd222eedfbae704b185c40702254810e2c5917f6dbc80e017" + "16.20.2": + Windows: + "x86_64": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-win-x64.zip" + sha256: "f8bb35f6c08dc7bf14ac753509c06ed1a7ebf5b390cd3fbdc8f8c1aedd020ec3" + Linux: + "x86_64": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-linux-x64.tar.xz" + sha256: "874463523f26ed528634580247f403d200ba17a31adf2de98a7b124c6eb33d87" + "armv7": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-linux-armv7l.tar.xz" + sha256: "5f2a2a34d2f19931b8ef39416bde96933e6666f91a2d1a2b92af30627a8e8429" + "armv8": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-linux-arm64.tar.xz" + sha256: "e88d86154d1ce53dc52fd74d79d4bfdf0b05f58c0bb2639adfa36e9378b770c4" + Macos: + "x86_64": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-darwin-x64.tar.gz" + sha256: "d7a46eaf2b57ffddeda16ece0d887feb2e31a91ad33f8774da553da0249dc4a6" + "armv8": + url: "https://nodejs.org/dist/v16.20.2/node-v16.20.2-darwin-arm64.tar.gz" + sha256: "6a5c4108475871362d742b988566f3fe307f6a67ce14634eb3fbceb4f9eea88c" "18.15.0": Windows: "x86_64": diff --git a/recipes/nodejs/config.yml b/recipes/nodejs/config.yml index e973a099243f74..78cc638a90e4df 100644 --- a/recipes/nodejs/config.yml +++ b/recipes/nodejs/config.yml @@ -5,5 +5,7 @@ versions: folder: all "16.3.0": folder: all + "16.20.2": + folder: all "18.15.0": folder: all From 6e0b64abd1e98161b369dead14ac1f2d7cec9392 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 18 Aug 2023 10:43:45 +0200 Subject: [PATCH 0282/1140] (#19265) [arsenalgear] Bump dependencies: Boost 1.82.0 Signed-off-by: Uilian Ries --- recipes/arsenalgear/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/arsenalgear/all/conanfile.py b/recipes/arsenalgear/all/conanfile.py index 94953657bcd46c..2eafb85d1f49a0 100644 --- a/recipes/arsenalgear/all/conanfile.py +++ b/recipes/arsenalgear/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): def requirements(self): if Version(self.version) < "2.0.0": - self.requires("boost/1.81.0") + self.requires("boost/1.82.0") if self.settings.os in ["Linux", "Macos"]: # exprtk is used in public header of arsenalgear # https://github.com/JustWhit3/arsenalgear-cpp/blob/v1.2.2/include/math.hpp From 3e83e67d63982f3360e8d26439fa29eb71f4a470 Mon Sep 17 00:00:00 2001 From: SSE4 Date: Fri, 18 Aug 2023 16:03:44 +0700 Subject: [PATCH 0283/1140] (#17025) - add vvenc 1.8.0 * - add vvenc 1.8.0 Signed-off-by: SSE4 * disable LTO explicitly * disable -Werror --------- Signed-off-by: SSE4 Co-authored-by: Daniel --- recipes/vvenc/all/conandata.yml | 5 + recipes/vvenc/all/conanfile.py | 120 ++++++++++++++++++ recipes/vvenc/all/test_package/CMakeLists.txt | 9 ++ recipes/vvenc/all/test_package/conanfile.py | 26 ++++ recipes/vvenc/all/test_package/src/example.c | 6 + recipes/vvenc/config.yml | 3 + 6 files changed, 169 insertions(+) create mode 100644 recipes/vvenc/all/conandata.yml create mode 100644 recipes/vvenc/all/conanfile.py create mode 100644 recipes/vvenc/all/test_package/CMakeLists.txt create mode 100644 recipes/vvenc/all/test_package/conanfile.py create mode 100644 recipes/vvenc/all/test_package/src/example.c create mode 100644 recipes/vvenc/config.yml diff --git a/recipes/vvenc/all/conandata.yml b/recipes/vvenc/all/conandata.yml new file mode 100644 index 00000000000000..ed507f5b4a2bc7 --- /dev/null +++ b/recipes/vvenc/all/conandata.yml @@ -0,0 +1,5 @@ +sources: + "1.8.0": + url: + - "https://github.com/fraunhoferhhi/vvenc/archive/refs/tags/v1.8.0.tar.gz" + sha256: "119970f1e00667045eb12775db10611fc04f9158348144913c9e233f98664714" diff --git a/recipes/vvenc/all/conanfile.py b/recipes/vvenc/all/conanfile.py new file mode 100644 index 00000000000000..50d169ed09a7fd --- /dev/null +++ b/recipes/vvenc/all/conanfile.py @@ -0,0 +1,120 @@ +import os +import sys + +from conan import ConanFile, conan_version +# FIXME: linter complains, but function is there +# https://docs.conan.io/2.0/reference/tools/build.html?highlight=check_min_cppstd#conan-tools-build-check-max-cppstd +# from conan.tools.build import stdcpp_library, check_min_cppstd, check_max_cppstd +from conan.tools.build import stdcpp_library, check_min_cppstd +from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout, CMakeDeps +from conan.tools.files import get, copy, rmdir, rm + +required_conan_version = ">=1.60.1" + + +class vvencRecipe(ConanFile): + name = "vvenc" + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + description = "Fraunhofer Versatile Video Encoder (VVenC)" + topics = ("video", "encoder", "codec", "vvc", "h266") + homepage = "https://www.hhi.fraunhofer.de/en/departments/vca/technologies-and-solutions/h266-vvc.html" + package_type = "library" + + settings = "os", "compiler", "build_type", "arch" + options = {"shared": [True, False], "fPIC": [True, False]} + default_options = {"shared": False, "fPIC": True} + + def validate_build(self): + if conan_version.major == 2: + self._validate_build2() + elif conan_version.major == 1: + self._validate_build1() + + def _validate_build1(self): + if self.settings.get_safe("compiler.cppstd"): + check_min_cppstd(self, 14) + # compiler.cppstd isn't set! but we still continue here in V1, + # imagining just like compiler.cppstd was set to 14 + # while package_id doesn't reflect that at all, and cppstd_default also + # might be different from 14, we silently force -std=c++14 to be + # specified during the build. it may produce more incompatibilities, + # and break user's expectation + # (like, output binary depends really on C++14 symbols libstdc++.so) + # it's V1 design flaw which isn't going to be addressed here + # (and probably nowhere, because conan V1 is going to be discontinued in CCI) + # once V1 is retired, that code will be removed altogether + self.output.warning("compiler.cppstd is not set, but we assume C++14") + + def _validate_build2(self): + # validates the minimum and maximum C++ standard supported + # currently, the project can only be built with C++14 standard + # it cannot be built with older standard because + # it doesn't have all the C++ features needed + # and it cannot be built with newer C++ standard + # because they have existing C++ features removed + check_min_cppstd(self, 14) + # FIXME: linter complains, but function is there + # https://docs.conan.io/2.0/reference/tools/build.html?highlight=check_min_cppstd#conan-tools-build-check-max-cppstd + check_max_cppstd = getattr(sys.modules['conan.tools.build'], 'check_max_cppstd') + check_max_cppstd(self, 14) + + def package_id(self): + # still important, older binutils cannot recognize + # object files created with newer binutils, + # thus linker cannot find any valid object and therefore symbols + # (fails to find `vvenc_get_version`, which is obviously always there) + # this is not exactly modeled by conan right now, + # so "compiler" setting is closest thing to avoid an issue + # (while technically it's not a compiler, but linker and archiver) + # del self.info.settings.compiler + pass + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def config_options(self): + if self.settings.os == "Windows": + self.options.rm_safe("fPIC") + + def configure(self): + if self.options.shared: + self.options.rm_safe('fPIC') + + def layout(self): + cmake_layout(self, src_folder='src') + + def generate(self): + deps = CMakeDeps(self) + deps.generate() + tc = CMakeToolchain(self) + tc.variables["VVENC_ENABLE_LINK_TIME_OPT"] = False + tc.cache_variables["VVENC_ENABLE_LINK_TIME_OPT"] = False + if self.settings.compiler in ["gcc", 'clang']: + tc.blocks["cmake_flags_init"].template += '\nstring(APPEND CMAKE_C_FLAGS_INIT " -Wno-uninitialized")' + tc.blocks["cmake_flags_init"].template += '\nstring(APPEND CMAKE_CXX_FLAGS_INIT " -Wno-uninitialized")' + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", 'pkgconfig')) + rmdir(self, os.path.join(self.package_folder, 'lib', "cmake")) + rm(self, "*.pdb", os.path.join(self.package_folder, 'bin')) + rm(self, '*.pdb', os.path.join(self.package_folder, "lib")) + + def package_info(self): + self.cpp_info.libs = ["vvenc"] + if self.options.shared: + self.cpp_info.defines.extend(["VVENC_DYN_LINK"]) # vvcencDecl.h + libcxx = stdcpp_library(self) # source code is C++, but interface is pure C + libcxx = [libcxx] if libcxx else [] + libm = ["m"] if self.settings.get_safe("os") == "Linux" else [] + libpthread = ['pthread'] if self.settings.get_safe('os') == 'Linux' else [] + self.cpp_info.system_libs.extend(libcxx + libm + libpthread) diff --git a/recipes/vvenc/all/test_package/CMakeLists.txt b/recipes/vvenc/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..efaabb8094acbb --- /dev/null +++ b/recipes/vvenc/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.15) +project(PackageTest C) + +find_package(vvenc CONFIG REQUIRED) + + + +add_executable(example src/example.c) +target_link_libraries(example vvenc::vvenc) diff --git a/recipes/vvenc/all/test_package/conanfile.py b/recipes/vvenc/all/test_package/conanfile.py new file mode 100644 index 00000000000000..0f4e9c14439cf7 --- /dev/null +++ b/recipes/vvenc/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +import os + +from conan import ConanFile +from conan.tools.cmake import CMake, cmake_layout +from conan.tools.build import can_run + + +class vvencTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "CMakeDeps", 'VirtualRunEnv', "CMakeToolchain" + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def layout(self): + cmake_layout(self) + + def test(self): + if can_run(self): + cmd = os.path.join(self.cpp.build.bindir, "example") + self.run(cmd, env="conanrun") diff --git a/recipes/vvenc/all/test_package/src/example.c b/recipes/vvenc/all/test_package/src/example.c new file mode 100644 index 00000000000000..2a6652d65f4eb1 --- /dev/null +++ b/recipes/vvenc/all/test_package/src/example.c @@ -0,0 +1,6 @@ +#include +#include + +int main() { + printf("vvenc_get_version: %s\n", vvenc_get_version()); +} diff --git a/recipes/vvenc/config.yml b/recipes/vvenc/config.yml new file mode 100644 index 00000000000000..6088e2f9810177 --- /dev/null +++ b/recipes/vvenc/config.yml @@ -0,0 +1,3 @@ +versions: + "1.8.0": + folder: "all" From 1aa3713781b572f85f0dfa97da854a97564a5de7 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 18 Aug 2023 12:27:32 +0300 Subject: [PATCH 0284/1140] (#18209) enhex-strong_type: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * enhex-strong_type: migrate to Conan v2 * enhex-strong_type: restore test_v1_package * Update recipes/enhex-strong_type/all/conanfile.py * enhex-strong_type: restore VirtualRunEnv in test_package --------- Co-authored-by: Rubén Rincón Blanco --- recipes/enhex-strong_type/all/conanfile.py | 74 ++++++++++++------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 22 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 18 +++++ 5 files changed, 91 insertions(+), 38 deletions(-) create mode 100644 recipes/enhex-strong_type/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/enhex-strong_type/all/test_v1_package/conanfile.py diff --git a/recipes/enhex-strong_type/all/conanfile.py b/recipes/enhex-strong_type/all/conanfile.py index 40601c5f9d3e88..8b4ea08eec845b 100644 --- a/recipes/enhex-strong_type/all/conanfile.py +++ b/recipes/enhex-strong_type/all/conanfile.py @@ -1,50 +1,72 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + + class EnhexStrongTypeConan(ConanFile): name = "enhex-strong_type" - license = "MIT" description = "Create new type from existing type without changing the interface." - topics = ("strong_type", "safety") - homepage = "https://github.com/Enhex/strong_type" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Enhex/strong_type" + topics = ("strong_type", "safety", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - settings = ("compiler") @property - def _source_subfolder(self): - return "source_subfolder" - - def validate(self): - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) + def _min_cppstd(self): + return 17 - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "Visual Studio": "15", + "msvc": "191", "gcc": "7", "clang": "5.0", - "apple-clang": "9.1" + "apple-clang": "9.1", } + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + compiler = str(self.settings.compiler) - compiler_version = tools.Version(self.settings.compiler.version) + compiler_version = Version(self.settings.compiler.version) - if compiler not in minimal_version: - self.output.info("{} requires a compiler that supports at least C++17".format(self.name)) + if compiler not in self._compilers_minimum_version: + self.output.info(f"{self.name} requires a compiler that supports at least C++17") return # Exclude compilers not supported - if compiler_version < minimal_version[compiler]: - raise ConanInvalidConfiguration("{} requires a compiler that supports at least C++17. {} {} is not".format( - self.name, compiler, tools.Version(self.settings.compiler.version.value))) + if compiler_version < self._compilers_minimum_version[compiler]: + raise ConanInvalidConfiguration( + f"{self.name} requires a compiler that supports at least C++17. " + f"{compiler} {Version(self.settings.compiler.version.value)} is not" + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE.txt", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, pattern="*", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include")) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/enhex-strong_type/all/test_package/CMakeLists.txt b/recipes/enhex-strong_type/all/test_package/CMakeLists.txt index ee8f5992e5656a..51d45c127f7222 100644 --- a/recipes/enhex-strong_type/all/test_package/CMakeLists.txt +++ b/recipes/enhex-strong_type/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(enhex-strong_type CONFIG REQUIRED) +find_package(enhex-strong_type REQUIRED CONFIG) add_executable(example example.cpp) target_link_libraries(example enhex-strong_type::enhex-strong_type) diff --git a/recipes/enhex-strong_type/all/test_package/conanfile.py b/recipes/enhex-strong_type/all/test_package/conanfile.py index c48d1d23bfccde..8d52b7021efe14 100644 --- a/recipes/enhex-strong_type/all/test_package/conanfile.py +++ b/recipes/enhex-strong_type/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class EnhexStrongTypeTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/enhex-strong_type/all/test_v1_package/CMakeLists.txt b/recipes/enhex-strong_type/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/enhex-strong_type/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/enhex-strong_type/all/test_v1_package/conanfile.py b/recipes/enhex-strong_type/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..c48d1d23bfccde --- /dev/null +++ b/recipes/enhex-strong_type/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class EnhexStrongTypeTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From e9ec7131fc1c1e56b004fdb788cd1da2d9f8a6da Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 18 Aug 2023 12:52:32 +0300 Subject: [PATCH 0285/1140] (#18254) procxx-boost-ext-simd: migrate to Conan v2 * procxx-boost-ext-simd: migrate to Conan v2 * procxx-boost-ext-simd: restore test_v1_package * procxx-boost-ext-simd: add cmake_find_package_multi generator to test_v1_package * procxx-boost-ext-simd: bump boost dependency * procxx-boost-ext-simd: update CMakeLists.txt * procxx-boost-ext-simd: restore VirtualRunEnv in test_package --- .../procxx-boost-ext-simd/all/conanfile.py | 70 +++++++++++-------- .../all/test_package/CMakeLists.txt | 14 ++-- .../all/test_package/conanfile.py | 22 ++++-- .../all/test_package/test_package.cpp | 9 ++- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 16 +++++ 6 files changed, 88 insertions(+), 51 deletions(-) create mode 100644 recipes/procxx-boost-ext-simd/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/procxx-boost-ext-simd/all/test_v1_package/conanfile.py diff --git a/recipes/procxx-boost-ext-simd/all/conanfile.py b/recipes/procxx-boost-ext-simd/all/conanfile.py index beacde69525027..58d22448c3e7e7 100644 --- a/recipes/procxx-boost-ext-simd/all/conanfile.py +++ b/recipes/procxx-boost-ext-simd/all/conanfile.py @@ -1,61 +1,71 @@ -from conans import ConanFile, CMake, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" class ProCxxBoostExSimdConan(ConanFile): name = "procxx-boost-ext-simd" - description = ("Portable SIMD computation library - was proposed as a " - "Boost library" - ) - homepage = "https://github.com/procxx/boost.simd" - topics = ("conan", "boost", "simd") + description = "Portable SIMD computation library - was proposed as a Boost library" license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/procxx/boost.simd" + topics = ("boost", "simd", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package" no_copy_source = True - - @property - def _source_subfolder(self): - return "source_subfolder" + short_paths = True @property def _min_cppstd(self): - return "11" + return 11 + + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.76.0") + self.requires("boost/1.82.0") + + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._min_cppstd) - - def package_id(self): - self.info.header_only() + check_min_cppstd(self, self._min_cppstd) def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_folder = "boost.simd-" + self.version - os.rename(extracted_folder, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="*", dst="include", - src=os.path.join(self._source_subfolder, "include")) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + # this technique was inspired by conan-center's "boost-ex-ut" recipe, # and has been fixed to use the upstream Capitalized `Boost::` # namespace for components - self.cpp_info.names["cmake_find_package"] = "Boost" - self.cpp_info.names["cmake_find_package_multi"] = "Boost" - + self.cpp_info.set_property("cmake_file_name", "Boost.SIMD") + self.cpp_info.set_property("cmake_target_name", "Boost") # The original find_package() name here: + self.cpp_info.components["SIMD"].set_property("cmake_target_name", "Boost::SIMD") + self.cpp_info.components["SIMD"].requires = ["boost::headers"] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "Boost.SIMD" self.cpp_info.filenames["cmake_find_package_multi"] = "Boost.SIMD" + self.cpp_info.names["cmake_find_package"] = "Boost" + self.cpp_info.names["cmake_find_package_multi"] = "Boost" self.cpp_info.components["SIMD"].names["cmake_find_package"] = "SIMD" - self.cpp_info.components["SIMD"].names["cmake_find_package_multi"] = \ - "SIMD" - self.cpp_info.components["SIMD"].requires = ["boost::headers"] + self.cpp_info.components["SIMD"].names["cmake_find_package_multi"] = "SIMD" diff --git a/recipes/procxx-boost-ext-simd/all/test_package/CMakeLists.txt b/recipes/procxx-boost-ext-simd/all/test_package/CMakeLists.txt index 36ff666d5a74f0..f2ca3191917217 100644 --- a/recipes/procxx-boost-ext-simd/all/test_package/CMakeLists.txt +++ b/recipes/procxx-boost-ext-simd/all/test_package/CMakeLists.txt @@ -1,19 +1,13 @@ -cmake_minimum_required(VERSION 3.1.0) -project(test_package) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS) - -find_package(Boost.SIMD REQUIRED) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) # FIXME: components from Boost.SIMD (target Boost::SIMD) don't work. # It should be: # find_package(BOOST REQUIRED COMPONENTS SIMD) # See https://github.com/conan-io/conan-center-index/issues/6682 for details. -find_package(Boost REQUIRED COMPONENTS date_time) # COMPONENTS SIMD) + +find_package(Boost.SIMD REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} Boost::headers Boost::SIMD) -# FIXME: recipe should transitively sets proper minimum cxx standard. -# See https://github.com/conan-io/conan/issues/7772 about revising cxx std model. set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/procxx-boost-ext-simd/all/test_package/conanfile.py b/recipes/procxx-boost-ext-simd/all/test_package/conanfile.py index 3be12b2d6b0c52..ef5d7042163ecc 100644 --- a/recipes/procxx-boost-ext-simd/all/test_package/conanfile.py +++ b/recipes/procxx-boost-ext-simd/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class ProCxxBoostExSimdConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - self.run(os.path.join("bin", "test_package"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/procxx-boost-ext-simd/all/test_package/test_package.cpp b/recipes/procxx-boost-ext-simd/all/test_package/test_package.cpp index ddf7bb1fb383ad..48b397b470c70c 100644 --- a/recipes/procxx-boost-ext-simd/all/test_package/test_package.cpp +++ b/recipes/procxx-boost-ext-simd/all/test_package/test_package.cpp @@ -3,17 +3,16 @@ // or running library tests - just only check that package is properly created. // See docs for details: // https://docs.conan.io/en/latest/creating_packages/getting_started.html#the-test-package-folder -#include #include +#include #include namespace bs = boost::simd; -int main() -{ +int main() { using namespace boost::date_time; - bs::pack p{1.f,2.f,3.f,4.f}; - std::cout << "Boost.SIMD test from README.md : " << p + 10*p << "\n"; + bs::pack p{1.f, 2.f, 3.f, 4.f}; + std::cout << "Boost.SIMD test from README.md : " << p + 10 * p << "\n"; std::cout << "Boost.date_time interop test: " << boost::gregorian::date(2021, Aug, 4) << "\n"; return 0; } diff --git a/recipes/procxx-boost-ext-simd/all/test_v1_package/CMakeLists.txt b/recipes/procxx-boost-ext-simd/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/procxx-boost-ext-simd/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/procxx-boost-ext-simd/all/test_v1_package/conanfile.py b/recipes/procxx-boost-ext-simd/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..70611dabf01ae4 --- /dev/null +++ b/recipes/procxx-boost-ext-simd/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + + +class ProCxxBoostExSimdConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "test_package"), run_environment=True) From 1cd20e60686d8d866bc522ebe0baab1b396537f7 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 19:47:47 +0900 Subject: [PATCH 0286/1140] (#19154) mozjpeg: add version 4.1.3 --- recipes/mozjpeg/all/conandata.yml | 7 ++++ .../all/patches/4.1.3-0001-cmake-fixes.patch | 34 +++++++++++++++++++ recipes/mozjpeg/config.yml | 2 ++ 3 files changed, 43 insertions(+) create mode 100644 recipes/mozjpeg/all/patches/4.1.3-0001-cmake-fixes.patch diff --git a/recipes/mozjpeg/all/conandata.yml b/recipes/mozjpeg/all/conandata.yml index b3cb941ad21ebc..972600a1f5a902 100644 --- a/recipes/mozjpeg/all/conandata.yml +++ b/recipes/mozjpeg/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.1.3": + url: "https://github.com/mozilla/mozjpeg/archive/v4.1.3.tar.gz" + sha256: "f6ce89f616b30c498d1fb3b0f0940914557d8393a79c9e7aafff72032446bca0" "4.1.1": url: "https://github.com/mozilla/mozjpeg/archive/v4.1.1.tar.gz" sha256: "66b1b8d6b55d263f35f27f55acaaa3234df2a401232de99b6d099e2bb0a9d196" @@ -9,6 +12,10 @@ sources: url: "https://github.com/mozilla/mozjpeg/archive/v3.3.1.tar.gz" sha256: "aebbea60ea038a84a2d1ed3de38fdbca34027e2e54ee2b7d08a97578be72599d" patches: + "4.1.3": + - patch_file: "patches/4.1.3-0001-cmake-fixes.patch" + patch_description: "fix install folder and disable /NODEFAULT in MSVC" + patch_type: "conan" "4.1.1": - patch_file: "patches/4.1.1-0001-cmake-fixes.patch" patch_description: "fix install folder and disable /NODEFAULT in MSVC" diff --git a/recipes/mozjpeg/all/patches/4.1.3-0001-cmake-fixes.patch b/recipes/mozjpeg/all/patches/4.1.3-0001-cmake-fixes.patch new file mode 100644 index 00000000000000..b9d6dd16f33f32 --- /dev/null +++ b/recipes/mozjpeg/all/patches/4.1.3-0001-cmake-fixes.patch @@ -0,0 +1,34 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 82ce902..bde4aba 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1492,7 +1492,7 @@ if(WITH_TURBOJPEG) + else() + set(DIR ${CMAKE_CURRENT_BINARY_DIR}) + endif() +- install(PROGRAMS ${DIR}/tjbench-static${EXE} ++ install(PROGRAMS $ + DESTINATION ${CMAKE_INSTALL_BINDIR} RENAME tjbench${EXE}) + endif() + endif() +@@ -1510,16 +1510,16 @@ if(ENABLE_STATIC) + else() + set(DIR ${CMAKE_CURRENT_BINARY_DIR}) + endif() +- install(PROGRAMS ${DIR}/cjpeg-static${EXE} ++ install(PROGRAMS $ + DESTINATION ${CMAKE_INSTALL_BINDIR} RENAME cjpeg${EXE}) +- install(PROGRAMS ${DIR}/djpeg-static${EXE} ++ install(PROGRAMS $ + DESTINATION ${CMAKE_INSTALL_BINDIR} RENAME djpeg${EXE}) +- install(PROGRAMS ${DIR}/jpegtran-static${EXE} ++ install(PROGRAMS $ + DESTINATION ${CMAKE_INSTALL_BINDIR} RENAME jpegtran${EXE}) + endif() + endif() + +-install(TARGETS rdjpgcom wrjpgcom RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) ++install(TARGETS rdjpgcom wrjpgcom DESTINATION ${CMAKE_INSTALL_BINDIR}) + + install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/README.ijg + ${CMAKE_CURRENT_SOURCE_DIR}/README.md ${CMAKE_CURRENT_SOURCE_DIR}/example.txt diff --git a/recipes/mozjpeg/config.yml b/recipes/mozjpeg/config.yml index c5a4dbb215dd32..980a55d043dc8d 100644 --- a/recipes/mozjpeg/config.yml +++ b/recipes/mozjpeg/config.yml @@ -1,4 +1,6 @@ versions: + "4.1.3": + folder: all "4.1.1": folder: all "4.0.0": From fa077ddee415ace91580fc8cab96dde1356f836c Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 20:46:42 +0900 Subject: [PATCH 0287/1140] (#19161) highway: add version 1.0.6, remove older versions * highway: add version 1.0.6, remove older versions * fix condition --------- Co-authored-by: Carlos Zoido --- recipes/highway/all/conandata.yml | 18 ++----- recipes/highway/all/conanfile.py | 8 ++- .../patches/0.11.1-0001-remove-contrib.patch | 12 ----- .../0.16.0-0001-fix-sys-random-h.patch | 50 ------------------- recipes/highway/config.yml | 6 +-- 5 files changed, 11 insertions(+), 83 deletions(-) delete mode 100644 recipes/highway/all/patches/0.11.1-0001-remove-contrib.patch delete mode 100644 recipes/highway/all/patches/0.16.0-0001-fix-sys-random-h.patch diff --git a/recipes/highway/all/conandata.yml b/recipes/highway/all/conandata.yml index b0736b5e173506..0f97a2fe01fc88 100644 --- a/recipes/highway/all/conandata.yml +++ b/recipes/highway/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.6": + url: "https://github.com/google/highway/archive/1.0.6.tar.gz" + sha256: "d89664a045a41d822146e787bceeefbf648cc228ce354f347b18f2b419e57207" "1.0.5": url: "https://github.com/google/highway/archive/1.0.5.tar.gz" sha256: "99b7dad98b8fa088673b720151458fae698ae5df9154016e39de4afdc23bb927" @@ -20,21 +23,6 @@ sources: "0.17.0": url: "https://github.com/google/highway/archive/0.17.0.tar.gz" sha256: "25158fd5c090b70ecea47fc246c860d150f07f801d2434e1e51ec14a6c15822c" - "0.16.0": - url: "https://github.com/google/highway/archive/0.16.0.tar.gz" - sha256: "746c9578446be6c5286e8846c5f0d4118c0c1f04219c401abadcb8a5f2051893" "0.12.2": url: "https://github.com/google/highway/archive/0.12.2.tar.gz" sha256: "e1d47ce510429fdcf31f41697ca74fb0dcd59d933196e531a86d51751a56f4cc" - "0.11.1": - url: "https://github.com/google/highway/archive/0.11.1.tar.gz" - sha256: "4c4bb9501c02b27a0944afde8923aaab554384690d37e5b2a7f97553426ea641" -patches: - "0.16.0": - - patch_file: "patches/0.16.0-0001-fix-sys-random-h.patch" - patch_description: "fix including sys/random.h on several environments" - patch_type: "portability" - "0.11.1": - - patch_file: "patches/0.11.1-0001-remove-contrib.patch" - patch_description: "remove contrib sources" - patch_type: "portability" diff --git a/recipes/highway/all/conanfile.py b/recipes/highway/all/conanfile.py index 0da9b64e6b9f47..70b41b9d07eb43 100644 --- a/recipes/highway/all/conanfile.py +++ b/recipes/highway/all/conanfile.py @@ -21,10 +21,12 @@ class HighwayConan(ConanFile): options = { "shared": [True, False], "fPIC": [True, False], + "with_test": [True, False], } default_options = { "shared": False, "fPIC": True, + "with_test": False, } @property @@ -53,6 +55,8 @@ def configure(self): self.package_type = "static-library" elif self.options.shared: self.options.rm_safe("fPIC") + if Version(self.version) < "1.0.6": + del self.options.with_test def layout(self): cmake_layout(self, src_folder="src") @@ -73,7 +77,7 @@ def generate(self): tc = CMakeToolchain(self) tc.variables["BUILD_TESTING"] = False tc.variables["HWY_ENABLE_EXAMPLES"] = False - tc.variables["HWY_ENABLE_TESTS"] = False + tc.variables["HWY_ENABLE_TESTS"] = self.options.get_safe("with_test", False) tc.generate() def _patch_sources(self): @@ -109,7 +113,7 @@ def package_info(self): self.cpp_info.components["hwy_contrib"].set_property("pkg_config_name", "libhwy-contrib") self.cpp_info.components["hwy_contrib"].libs = ["hwy_contrib"] self.cpp_info.components["hwy_contrib"].requires = ["hwy"] - if Version(self.version) >= "0.15.0": + if "0.15.0" <= Version(self.version) < "1.0.6" or (Version(self.version) >= "1.0.6" and self.options.with_test): self.cpp_info.components["hwy_test"].set_property("pkg_config_name", "libhwy-test") self.cpp_info.components["hwy_test"].libs = ["hwy_test"] self.cpp_info.components["hwy_test"].requires = ["hwy"] diff --git a/recipes/highway/all/patches/0.11.1-0001-remove-contrib.patch b/recipes/highway/all/patches/0.11.1-0001-remove-contrib.patch deleted file mode 100644 index e409cd92d3227f..00000000000000 --- a/recipes/highway/all/patches/0.11.1-0001-remove-contrib.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -52,9 +52,6 @@ check_cxx_source_compiles( - ) - - set(HWY_SOURCES -- contrib/image/image.cc -- contrib/image/image.h -- contrib/math/math-inl.h - hwy/aligned_allocator.cc - hwy/aligned_allocator.h - hwy/base.h diff --git a/recipes/highway/all/patches/0.16.0-0001-fix-sys-random-h.patch b/recipes/highway/all/patches/0.16.0-0001-fix-sys-random-h.patch deleted file mode 100644 index aee3b37dc1e43f..00000000000000 --- a/recipes/highway/all/patches/0.16.0-0001-fix-sys-random-h.patch +++ /dev/null @@ -1,50 +0,0 @@ -diff --git a/hwy/contrib/sort/vqsort.cc b/hwy/contrib/sort/vqsort.cc -index 951a0bd..2009da8 100644 ---- a/hwy/contrib/sort/vqsort.cc -+++ b/hwy/contrib/sort/vqsort.cc -@@ -25,12 +25,43 @@ - // After foreach_target - #include "hwy/contrib/sort/shared-inl.h" - -+// Check if we have sys/random.h. First skip some systems on which the check -+// itself (features.h) might be problematic. -+#if defined(ANDROID) || defined(__ANDROID__) || HWY_ARCH_RVV -+#define VQSORT_GETRANDOM 0 -+#endif -+ -+#if !defined(VQSORT_GETRANDOM) && (defined(linux) || defined(__linux__)) -+#include -+ -+// ---- which libc -+#if defined(__UCLIBC__) -+#define VQSORT_GETRANDOM 1 // added Mar 2015, before uclibc-ng 1.0 -+ -+#elif defined(__GLIBC__) && defined(__GLIBC_PREREQ) -+#if __GLIBC_PREREQ(2, 25) -+#define VQSORT_GETRANDOM 1 -+#else -+#define VQSORT_GETRANDOM 0 -+#endif -+ -+#else -+// Assume MUSL, which has getrandom since 2018. There is no macro to test, see -+// https://www.openwall.com/lists/musl/2013/03/29/13. -+#define VQSORT_GETRANDOM 1 -+ -+#endif // ---- which libc -+#endif // linux -+ -+#if !defined(VQSORT_GETRANDOM) -+#define VQSORT_GETRANDOM 0 -+#endif -+ - // Seed source for SFC generator: 1=getrandom, 2=CryptGenRandom - // (not all Android support the getrandom wrapper) - #ifndef VQSORT_SECURE_SEED - --#if (defined(linux) || defined(__linux__)) && \ -- !(defined(ANDROID) || defined(__ANDROID__) || HWY_ARCH_RVV) -+#if VQSORT_GETRANDOM - #define VQSORT_SECURE_SEED 1 - #elif defined(_WIN32) || defined(_WIN64) - #define VQSORT_SECURE_SEED 2 diff --git a/recipes/highway/config.yml b/recipes/highway/config.yml index 48d515416587a4..e978e314cb0cd2 100644 --- a/recipes/highway/config.yml +++ b/recipes/highway/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.6": + folder: all "1.0.5": folder: all "1.0.4": @@ -13,9 +15,5 @@ versions: folder: all "0.17.0": folder: all - "0.16.0": - folder: all "0.12.2": folder: all - "0.11.1": - folder: all From aaf72e4e04386fcba01fda8da2bc352c606fae3d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 18 Aug 2023 14:43:07 +0200 Subject: [PATCH 0288/1140] (#19269) [bot] Update list of references (prod-v2/ListPackages) Co-authored-by: Uilian Ries --- .c3i/conan_v2_ready_references.yml | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index f8823a111ab285..fec7da6449a4b3 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -78,6 +78,7 @@ required_for_references: - bear - benchmark - bertrand +- bgfx - bigint - bimg - binutils @@ -167,6 +168,7 @@ required_for_references: - concurrentqueue - console_bridge - continuable +- cotila - cpp-httplib - cpp-ipc - cpp-jwt @@ -313,6 +315,7 @@ required_for_references: - foxglove-schemas-protobuf - foxi - fp16 +- fpgen - fpzip - freeglut - freeimage @@ -419,6 +422,7 @@ required_for_references: - imath - imgui - imguizmo +- immer - implot - imutils-cpp - incbin @@ -661,6 +665,7 @@ required_for_references: - lzma_sdk - lzo - m4 +- maddy - magic_enum - mailio - make @@ -743,6 +748,7 @@ required_for_references: - nanosvg - nas - nasm +- neargye-semver - netcdf - nettle - nextsilicon-cpp-subprocess @@ -753,6 +759,7 @@ required_for_references: - nmslib - nng - nodejs +- nodesoup - norm - nsync - ntv2 @@ -803,6 +810,7 @@ required_for_references: - opensubdiv - opentelemetry-cpp - opentelemetry-proto +- opentracing-cpp - openxlsx - optional-lite - opus @@ -814,6 +822,7 @@ required_for_references: - p-ranav-glob - paho-mqtt-c - paho-mqtt-cpp +- panzi-portable-endian - parallel-hashmap - parg - parson @@ -839,6 +848,7 @@ required_for_references: - pixman - pkgconf - platform.delegates +- platform.exceptions - platform.hashing - platform.interfaces - plf_colony @@ -848,6 +858,7 @@ required_for_references: - plf_queue - plf_stack - plog +- plusaes - plutovg - pngpp - poco @@ -895,6 +906,8 @@ required_for_references: - ragel - rang - range-v3 +- rangeless +- rangesnext - rapidcheck - rapidcsv - rapidfuzz @@ -917,6 +930,7 @@ required_for_references: - restbed - restinio - rg-etc1 +- rgbcx - ring-span-lite - rmm - roaring @@ -1052,6 +1066,7 @@ required_for_references: - trantor - tree-sitter - troldal-zippy +- trompeloeil - tsl-hopscotch-map - turtle - type_safe @@ -1109,6 +1124,7 @@ required_for_references: - wt - wtl - xapian-core +- xbyak - xerces-c - xkbcommon - xkeyboard-config @@ -1132,6 +1148,7 @@ required_for_references: - xz_utils - yajl - yaml-cpp +- yas - yasm - yyjson - z3 From 851342aa5e37d7d16be220549fe6bf69bae55c7a Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 18 Aug 2023 22:17:24 +0900 Subject: [PATCH 0289/1140] (#19175) boost: add version 1.83.0 * boost: add version 1.83.0, remove older versions * revert 1.71.0, 1.72.0 * use 1.82.0's patch for 1.83.0 --- recipes/boost/all/conandata.yml | 11 +- .../all/dependencies/dependencies-1.83.0.yml | 280 ++++++++++++++++++ recipes/boost/config.yml | 2 + 3 files changed, 292 insertions(+), 1 deletion(-) create mode 100644 recipes/boost/all/dependencies/dependencies-1.83.0.yml diff --git a/recipes/boost/all/conandata.yml b/recipes/boost/all/conandata.yml index b2ef58c60ab75a..ee7228b61bc726 100644 --- a/recipes/boost/all/conandata.yml +++ b/recipes/boost/all/conandata.yml @@ -1,9 +1,14 @@ sources: + "1.83.0": + url: + - "https://boostorg.jfrog.io/artifactory/main/release/1.83.0/source/boost_1_83_0.tar.bz2" + - "https://sourceforge.net/projects/boost/files/boost/1.83.0/boost_1_83_0.tar.bz2" + sha256: "6478edfe2f3305127cffe8caf73ea0176c53769f4bf1585be237eb30798c3b8e" "1.82.0": url: - "https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.bz2" - "https://sourceforge.net/projects/boost/files/boost/1.82.0/boost_1_82_0.tar.bz2" - sha256: a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6 + sha256: "a6e1ab9b0860e6a2881dd7b21fe9f737a095e5f33a3a874afc6a345228597ee6" "1.81.0": url: - "https://boostorg.jfrog.io/artifactory/main/release/1.81.0/source/boost_1_81_0.tar.bz2" @@ -58,6 +63,10 @@ sources: url: "https://boostorg.jfrog.io/artifactory/main/release/1.71.0/source/boost_1_71_0.tar.bz2" sha256: "d73a8da01e8bf8c7eda40b4c84915071a8c8a0df4a6734537ddde4a8580524ee" patches: + "1.83.0": + - patch_file: "patches/1.82.0-locale-iconv-library-option.patch" + patch_description: "Optional flag to specify iconv from either libc of libiconv" + patch_type: "conan" "1.82.0": - patch_file: "patches/1.82.0-locale-iconv-library-option.patch" patch_description: "Optional flag to specify iconv from either libc of libiconv" diff --git a/recipes/boost/all/dependencies/dependencies-1.83.0.yml b/recipes/boost/all/dependencies/dependencies-1.83.0.yml new file mode 100644 index 00000000000000..e6b009423a409b --- /dev/null +++ b/recipes/boost/all/dependencies/dependencies-1.83.0.yml @@ -0,0 +1,280 @@ +configure_options: +- atomic +- chrono +- container +- context +- contract +- coroutine +- date_time +- exception +- fiber +- filesystem +- graph +- graph_parallel +- iostreams +- json +- locale +- log +- math +- mpi +- nowide +- program_options +- python +- random +- regex +- serialization +- stacktrace +- system +- test +- thread +- timer +- type_erasure +- url +- wave +dependencies: + atomic: [] + chrono: + - system + container: [] + context: [] + contract: + - exception + - thread + coroutine: + - context + - exception + - system + date_time: [] + exception: [] + fiber: + - context + - filesystem + fiber_numa: + - fiber + filesystem: + - atomic + - system + graph: + - math + - random + - regex + - serialization + graph_parallel: + - filesystem + - graph + - mpi + - random + - serialization + iostreams: + - random + - regex + json: + - container + - system + locale: + - thread + log: + - atomic + - container + - date_time + - exception + - filesystem + - random + - regex + - system + - thread + log_setup: + - log + math: [] + math_c99: + - math + math_c99f: + - math + math_c99l: + - math + math_tr1: + - math + math_tr1f: + - math + math_tr1l: + - math + mpi: + - graph + - serialization + mpi_python: + - mpi + - python + nowide: + - filesystem + numpy: + - python + prg_exec_monitor: + - test + program_options: [] + python: [] + random: + - system + regex: [] + serialization: [] + stacktrace: [] + stacktrace_addr2line: + - stacktrace + stacktrace_backtrace: + - stacktrace + stacktrace_basic: + - stacktrace + stacktrace_noop: + - stacktrace + stacktrace_windbg: + - stacktrace + stacktrace_windbg_cached: + - stacktrace + system: [] + test: + - exception + test_exec_monitor: + - test + thread: + - atomic + - chrono + - container + - date_time + - exception + - system + timer: + - chrono + - system + type_erasure: + - thread + unit_test_framework: + - prg_exec_monitor + - test + - test_exec_monitor + url: + - system + wave: + - filesystem + - serialization + wserialization: + - serialization +libs: + atomic: + - boost_atomic + chrono: + - boost_chrono + container: + - boost_container + context: + - boost_context + contract: + - boost_contract + coroutine: + - boost_coroutine + date_time: + - boost_date_time + exception: + - boost_exception + fiber: + - boost_fiber + fiber_numa: + - boost_fiber_numa + filesystem: + - boost_filesystem + graph: + - boost_graph + graph_parallel: + - boost_graph_parallel + iostreams: + - boost_iostreams + json: + - boost_json + locale: + - boost_locale + log: + - boost_log + log_setup: + - boost_log_setup + math: [] + math_c99: + - boost_math_c99 + math_c99f: + - boost_math_c99f + math_c99l: + - boost_math_c99l + math_tr1: + - boost_math_tr1 + math_tr1f: + - boost_math_tr1f + math_tr1l: + - boost_math_tr1l + mpi: + - boost_mpi + mpi_python: + - boost_mpi_python + nowide: + - boost_nowide + numpy: + - boost_numpy{py_major}{py_minor} + prg_exec_monitor: + - boost_prg_exec_monitor + program_options: + - boost_program_options + python: + - boost_python{py_major}{py_minor} + random: + - boost_random + regex: + - boost_regex + serialization: + - boost_serialization + stacktrace: [] + stacktrace_addr2line: + - boost_stacktrace_addr2line + stacktrace_backtrace: + - boost_stacktrace_backtrace + stacktrace_basic: + - boost_stacktrace_basic + stacktrace_noop: + - boost_stacktrace_noop + stacktrace_windbg: + - boost_stacktrace_windbg + stacktrace_windbg_cached: + - boost_stacktrace_windbg_cached + system: + - boost_system + test: [] + test_exec_monitor: + - boost_test_exec_monitor + thread: + - boost_thread + timer: + - boost_timer + type_erasure: + - boost_type_erasure + unit_test_framework: + - boost_unit_test_framework + url: + - boost_url + wave: + - boost_wave + wserialization: + - boost_wserialization +requirements: + iostreams: + - bzip2 + - lzma + - zlib + - zstd + locale: + - iconv + - icu + python: + - python + regex: + - icu + stacktrace: + - backtrace +static_only: +- boost_exception +- boost_test_exec_monitor +version: 1.83.0 diff --git a/recipes/boost/config.yml b/recipes/boost/config.yml index 38ecaf5c73d635..f81f4b5e8e72b0 100644 --- a/recipes/boost/config.yml +++ b/recipes/boost/config.yml @@ -1,4 +1,6 @@ versions: + "1.83.0": + folder: all "1.82.0": folder: all "1.81.0": From cfc4955b0c4910196c8227b08fa777af7eea9cf8 Mon Sep 17 00:00:00 2001 From: Oliver Kuckertz Date: Fri, 18 Aug 2023 16:35:10 +0200 Subject: [PATCH 0290/1140] (#19179) loguru: fix preprocessor definition values Loguru expects 0 or 1, but the recipe would set "False"/"True", which C's preprocessor would always evaluate to false. --- recipes/loguru/all/conanfile.py | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/recipes/loguru/all/conanfile.py b/recipes/loguru/all/conanfile.py index 098d77e4ec8b73..8f740c8665ca64 100644 --- a/recipes/loguru/all/conanfile.py +++ b/recipes/loguru/all/conanfile.py @@ -20,6 +20,7 @@ class LoguruConan(ConanFile): description = "Loguru is a C++11 logging library." package_type = "library" settings = "os", "arch", "compiler", "build_type" + options = { "shared": [True, False], "fPIC": [True, False], @@ -79,16 +80,19 @@ def layout(self): def generate(self): tc = CMakeToolchain(self) + tc.variables["LOGURU_USE_FMTLIB"] = self.options.with_fmt tc.variables["LOGURU_VERBOSE_SCOPE_ENDINGS"] = self.options.verbose_scope_endings tc.variables["LOGURU_REDEFINE_ASSERT"] = self.options.redefine_assert tc.variables["LOGURU_WITH_STREAMS"] = self.options.enable_streams tc.variables["LOGURU_WITH_FILEABS"] = self.options.enable_fileabs tc.variables["LOGURU_REPLACE_GLOG"] = self.options.replace_glog + tc.variables["LOGURU_SCOPE_TEXT_SIZE"] = self.options.scope_text_size tc.variables["LOGURU_SCOPE_TIME_PRECISION"] = self.options.scope_time_precision tc.variables["LOGURU_FILENAME_WIDTH"] = self.options.filename_width tc.variables["LOGURU_THREADNAME_WIDTH"] = self.options.threadname_width + if is_msvc(self) and self.options.shared: tc.preprocessor_definitions["LOGURU_EXPORT"] = "__declspec(dllexport)" tc.generate() @@ -110,7 +114,7 @@ def package(self): save(self, os.path.join(self.package_folder, 'licenses', 'LICENSE'), self._extracted_license) cmake = CMake(self) cmake.install() - + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) rm(self, "*.pdb", os.path.join(self.package_folder, "lib")) @@ -124,16 +128,18 @@ def package_info(self): self.cpp_info.set_property("cmake_file_name", "loguru") self.cpp_info.set_property("cmake_target_name", "loguru::loguru") - self.cpp_info.defines.append(f"LOGURU_USE_FMTLIB={self.options.with_fmt}") + # render each option as either 0 or 1 for loguru's #if preprocessor commands + self.cpp_info.defines.append(f"LOGURU_USE_FMTLIB={bool(self.options.with_fmt)*1}") + self.cpp_info.defines.append(f"LOGURU_VERBOSE_SCOPE_ENDINGS={bool(self.options.verbose_scope_endings)*1}") + self.cpp_info.defines.append(f"LOGURU_REDEFINE_ASSERT={bool(self.options.redefine_assert)*1}") + self.cpp_info.defines.append(f"LOGURU_WITH_STREAMS={bool(self.options.enable_streams)*1}") + self.cpp_info.defines.append(f"LOGURU_WITH_FILEABS={bool(self.options.enable_fileabs)*1}") + self.cpp_info.defines.append(f"LOGURU_REPLACE_GLOG={bool(self.options.replace_glog)*1}") + self.cpp_info.defines.append(f"LOGURU_SCOPE_TEXT_SIZE={self.options.scope_text_size}") self.cpp_info.defines.append(f"LOGURU_SCOPE_TIME_PRECISION={self.options.scope_time_precision}") self.cpp_info.defines.append(f"LOGURU_FILENAME_WIDTH={self.options.filename_width}") self.cpp_info.defines.append(f"LOGURU_THREADNAME_WIDTH={self.options.threadname_width}") - self.cpp_info.defines.append(f"LOGURU_VERBOSE_SCOPE_ENDINGS={self.options.verbose_scope_endings}") - self.cpp_info.defines.append(f"LOGURU_REDEFINE_ASSERT={self.options.redefine_assert}") - self.cpp_info.defines.append(f"LOGURU_WITH_STREAMS={self.options.enable_streams}") - self.cpp_info.defines.append(f"LOGURU_WITH_FILEABS={self.options.enable_fileabs}") - self.cpp_info.defines.append(f"LOGURU_REPLACE_GLOG={self.options.replace_glog}") if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["pthread", "dl", "m"] From d3ad3f126576b4e0134692c4af731a4b5b7527b8 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Fri, 18 Aug 2023 17:10:54 +0200 Subject: [PATCH 0291/1140] (#19203) [libsnd] Update to 1.2.2 * [libsnd] Update to 1.2.2 * apply CMP0091 patch --------- Co-authored-by: czoido --- recipes/libsndfile/all/conandata.yml | 7 +++++++ recipes/libsndfile/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/libsndfile/all/conandata.yml b/recipes/libsndfile/all/conandata.yml index 77ba2985f3b59d..cc9d3fa6bc38cb 100644 --- a/recipes/libsndfile/all/conandata.yml +++ b/recipes/libsndfile/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.2": + url: "https://github.com/libsndfile/libsndfile/releases/download/1.2.2/libsndfile-1.2.2.tar.xz" + sha256: "3799ca9924d3125038880367bf1468e53a1b7e3686a934f098b7e1d286cdb80e" "1.2.0": url: "https://github.com/libsndfile/libsndfile/releases/download/1.2.0/libsndfile-1.2.0.tar.xz" sha256: "0e30e7072f83dc84863e2e55f299175c7e04a5902ae79cfb99d4249ee8f6d60a" @@ -12,6 +15,10 @@ sources: url: "https://github.com/libsndfile/libsndfile/releases/download/v1.0.29/libsndfile-1.0.29.tar.bz2" sha256: "2ba20d44817c8176f097ab25eff44ef0aeec9e00973def5a7174c5ae0764b22f" patches: + "1.2.2": + - patch_file: "patches/1.0.31-0001-fix-msvc-runtime-logic.patch" + patch_description: "always set CMP0091" + patch_type: "portability" "1.2.0": - patch_file: "patches/1.0.31-0001-fix-msvc-runtime-logic.patch" patch_description: "always set CMP0091" diff --git a/recipes/libsndfile/config.yml b/recipes/libsndfile/config.yml index 2248a847a68f02..47a9d6a6d063ea 100644 --- a/recipes/libsndfile/config.yml +++ b/recipes/libsndfile/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.2": + folder: "all" "1.2.0": folder: "all" "1.0.31": From b864d06e5e8627f688d52d07dbd2cd4d56b94a15 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 01:01:38 +0900 Subject: [PATCH 0292/1140] (#19209) libmysqlclient: fix compilation error on RHEL --- recipes/libmysqlclient/all/conanfile.py | 1 - 1 file changed, 1 deletion(-) diff --git a/recipes/libmysqlclient/all/conanfile.py b/recipes/libmysqlclient/all/conanfile.py index ba135f46de785c..80776aaf0f0374 100644 --- a/recipes/libmysqlclient/all/conanfile.py +++ b/recipes/libmysqlclient/all/conanfile.py @@ -133,7 +133,6 @@ def _patch_sources(self): f"# SET({lib.upper()}_WARN_GIVEN)", strict=False) - rmdir(self, os.path.join(self.source_folder, "extra")) for folder in ["client", "man", "mysql-test", "libbinlogstandalone"]: replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), f"ADD_SUBDIRECTORY({folder})\n", From 32b96bb5d37f8d5ea436826efdaa1576335bc0c0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ludwig=20F=C3=BCchsl?= Date: Fri, 18 Aug 2023 18:25:07 +0200 Subject: [PATCH 0293/1140] (#19242) [package] opus/1.4 (Update) * Added version 1.4 * Change opus download location to GitHub --- recipes/opus/all/conandata.yml | 3 +++ recipes/opus/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/opus/all/conandata.yml b/recipes/opus/all/conandata.yml index d7e0ee962c3b21..5ac1b419900e18 100644 --- a/recipes/opus/all/conandata.yml +++ b/recipes/opus/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.4": + url: "https://github.com/xiph/opus/releases/download/v1.4/opus-1.4.tar.gz" + sha256: "c9b32b4253be5ae63d1ff16eea06b94b5f0f2951b7a02aceef58e3a3ce49c51f" "1.3.1": url: "https://archive.mozilla.org/pub/opus/opus-1.3.1.tar.gz" sha256: "65b58e1e25b2a114157014736a3d9dfeaad8d41be1c8179866f144a2fb44ff9d" diff --git a/recipes/opus/config.yml b/recipes/opus/config.yml index 59334d50773685..3360afdd0ecabb 100644 --- a/recipes/opus/config.yml +++ b/recipes/opus/config.yml @@ -1,3 +1,5 @@ versions: + "1.4": + folder: all "1.3.1": folder: all From 8dfe9f93e4617a78a9dc472fd7b06b836addedf5 Mon Sep 17 00:00:00 2001 From: njacquemin1993 Date: Fri, 18 Aug 2023 19:18:56 +0200 Subject: [PATCH 0294/1140] (#19247) [cpuinfo] fix bug when compiling for Android See https://stackoverflow.com/questions/38666609/cant-find-lpthread-when-cross-compile-to-arm: "The android libc, bionic, provides built-in support for pthreads, so no additional linking (-lpthreads) is necessary." --- recipes/cpuinfo/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cpuinfo/all/conanfile.py b/recipes/cpuinfo/all/conanfile.py index 00574928a56f75..d109a4b7e8b2ff 100644 --- a/recipes/cpuinfo/all/conanfile.py +++ b/recipes/cpuinfo/all/conanfile.py @@ -95,5 +95,5 @@ def package_info(self): self.cpp_info.components["cpuinfo"].libs = ["cpuinfo"] if self.version < "cci.20230118": self.cpp_info.components["cpuinfo"].requires = ["clog"] - if self.settings.os in ["Linux", "FreeBSD", "Android"]: + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["cpuinfo"].system_libs.append("pthread") From c7ebb147497ee466a23861c1cec141f50100a9f6 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Fri, 18 Aug 2023 10:53:14 -0700 Subject: [PATCH 0295/1140] (#19259) restinio: add 0.6.19 * restinio: add 0.6.19 * update version for fmt and pcre/pcre2 and switch to version ranges for more flexibility and future compat * revert: update version for fmt and pcre/pcre2 and switch to version ranges for more flexibility and future compat As per https://github.com/conan-io/conan-center-index/blob/master/docs/adding_packages/dependencies.md#version-ranges version ranges are only allowed for CMake/OpenSSL. bump fmt and pcre2's versions manually. * removing 4th oldest revision (to use less resources) See doc here: https://github.com/conan-io/conan-center-index/blob/9436459b4a909c4c533ffe27a95c1f21cbdbbfa8/docs/adding_packages/sources_and_patches.md#removing-old-versions --- recipes/restinio/all/conandata.yml | 6 +++--- recipes/restinio/all/conanfile.py | 4 ++-- recipes/restinio/config.yml | 4 ++-- 3 files changed, 7 insertions(+), 7 deletions(-) diff --git a/recipes/restinio/all/conandata.yml b/recipes/restinio/all/conandata.yml index ad2cb8100089c9..06ced9d2281b30 100644 --- a/recipes/restinio/all/conandata.yml +++ b/recipes/restinio/all/conandata.yml @@ -1,10 +1,10 @@ sources: + "0.6.19": + url: "https://github.com/Stiffstream/restinio/archive/v.0.6.19.tar.gz" + sha256: "5a739cac8f3148e7e94f05bb08f5cf569dd31f6f3ea2b893eddfffb0a155eb52" "0.6.18": url: "https://github.com/Stiffstream/restinio/archive/v.0.6.18.tar.gz" sha256: "16fa041f4603746c6cd0f29ab126d02d220034535e7019c6ca1b8b9f58bfeee0" "0.6.17": url: "https://github.com/Stiffstream/restinio/archive/v.0.6.17.tar.gz" sha256: "0140b23f50bb964f6917d1f99205476eba92203dc586673bdf2ea48d7406f2c4" - "0.6.16": - url: "https://github.com/Stiffstream/restinio/archive/v.0.6.16.tar.gz" - sha256: "b3208d746087ba979f51b3a32e08463718c33d58720247d53ffb5bda99f4f92a" diff --git a/recipes/restinio/all/conanfile.py b/recipes/restinio/all/conanfile.py index e65bd0d3bc7f99..1fec7b581abe4b 100644 --- a/recipes/restinio/all/conanfile.py +++ b/recipes/restinio/all/conanfile.py @@ -38,7 +38,7 @@ def layout(self): def requirements(self): self.requires("http_parser/2.9.4") - self.requires("fmt/10.0.0") + self.requires("fmt/10.1.0") self.requires("expected-lite/0.6.3") self.requires("optional-lite/3.5.0") self.requires("string-view-lite/1.7.0") @@ -58,7 +58,7 @@ def requirements(self): if self.options.with_pcre == 1: self.requires("pcre/8.45") elif self.options.with_pcre == 2: - self.requires("pcre2/10.40") + self.requires("pcre2/10.42") def package_id(self): self.info.clear() diff --git a/recipes/restinio/config.yml b/recipes/restinio/config.yml index 517f51717a3a84..ee5e9f8ed6a0a3 100644 --- a/recipes/restinio/config.yml +++ b/recipes/restinio/config.yml @@ -1,7 +1,7 @@ versions: + "0.6.19": + folder: all "0.6.18": folder: all "0.6.17": folder: all - "0.6.16": - folder: all From 8d107eaf9495c20a05641a9a32bcec9ab95475d6 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 03:32:16 +0900 Subject: [PATCH 0296/1140] (#19260) maddy: add version 1.2.1 with several improvements --- recipes/maddy/all/conandata.yml | 7 ++++-- recipes/maddy/all/conanfile.py | 23 ++++++++++++++++++- recipes/maddy/all/test_package/CMakeLists.txt | 5 +--- recipes/maddy/config.yml | 2 ++ 4 files changed, 30 insertions(+), 7 deletions(-) diff --git a/recipes/maddy/all/conandata.yml b/recipes/maddy/all/conandata.yml index 91359378f20723..dfa40b0be62066 100644 --- a/recipes/maddy/all/conandata.yml +++ b/recipes/maddy/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.1": + url: "https://github.com/progsource/maddy/archive/refs/tags/1.2.1.tar.gz" + sha256: "b6058bce7ca32506969633ee7a4042e75b07464489f1c44be00913543cd687ef" "1.1.2": - sha256: ce66e1ee63bda3a6ab9c814edc0ed818abecca1c2218307ff87fb9ec1fc970fc - url: https://github.com/progsource/maddy/archive/refs/tags/1.1.2.tar.gz + url: "https://github.com/progsource/maddy/archive/refs/tags/1.1.2.tar.gz" + sha256: "ce66e1ee63bda3a6ab9c814edc0ed818abecca1c2218307ff87fb9ec1fc970fc" diff --git a/recipes/maddy/all/conanfile.py b/recipes/maddy/all/conanfile.py index 1cc4a8a062ec26..b023f2456bef00 100644 --- a/recipes/maddy/all/conanfile.py +++ b/recipes/maddy/all/conanfile.py @@ -1,9 +1,11 @@ import os from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout +from conan.tools.scm import Version required_conan_version = ">=1.52.0" @@ -20,6 +22,20 @@ class MaddyConan(ConanFile): settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + return 14 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "6", + "clang": "5", + "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", + } + def layout(self): basic_layout(self, src_folder="src") @@ -28,7 +44,12 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 14) + 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) diff --git a/recipes/maddy/all/test_package/CMakeLists.txt b/recipes/maddy/all/test_package/CMakeLists.txt index 8b3d049ce58f5c..9b4b9a74cb47a8 100755 --- a/recipes/maddy/all/test_package/CMakeLists.txt +++ b/recipes/maddy/all/test_package/CMakeLists.txt @@ -5,7 +5,4 @@ find_package(maddy REQUIRED CONFIG) add_executable(${PROJECT_NAME} example.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE maddy::maddy) -set_target_properties(${PROJECT_NAME} PROPERTIES - CXX_STANDARD 14 - CXX_STANDARD_REQUIRED ON -) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/maddy/config.yml b/recipes/maddy/config.yml index 8d13aefb6b4fbd..12b8a7bf45a5bf 100644 --- a/recipes/maddy/config.yml +++ b/recipes/maddy/config.yml @@ -1,3 +1,5 @@ versions: + "1.2.1": + folder: all "1.1.2": folder: all From cc1e5f0ee43eaf7cbd6f29d24ebdcb120eaf6941 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Fri, 18 Aug 2023 23:50:56 +0300 Subject: [PATCH 0297/1140] (#19276) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index e4f01057df7709..b2befced4887a1 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.10": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.10.tar.gz" + sha256: "efcb7c97999ce2d78aba67041a61dda45feb54113e5b21851b0532fdcbc460a8" "2.0.9": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.9.tar.gz" sha256: "5b00c997eb33e877ca54468a101345e3a9986ce1b61b0919fa8632efabc51b6d" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index c184130e67ed4c..20cb1b119cc183 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.10": + folder: all "2.0.9": folder: all "2.0.8": From 5fb83dcacc9d78b96c5a293e36607897427e2bc5 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 14:35:15 +0900 Subject: [PATCH 0298/1140] (#19282) nudb: update boost/1.83.0 --- recipes/nudb/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/nudb/all/conanfile.py b/recipes/nudb/all/conanfile.py index f02496ac2b32a7..bd9db41da603fc 100644 --- a/recipes/nudb/all/conanfile.py +++ b/recipes/nudb/all/conanfile.py @@ -28,7 +28,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def package_id(self): self.info.clear() From 12ba5cea9abf2f73697eec8910ec2a6df202810f Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sat, 19 Aug 2023 10:03:08 +0200 Subject: [PATCH 0299/1140] (#19038) [yaclib] Fix import for cmake_layout Signed-off-by: Uilian Ries --- recipes/yaclib/all/conanfile.py | 4 +--- recipes/yaclib/all/test_v1_package/conanfile.py | 5 ++--- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/recipes/yaclib/all/conanfile.py b/recipes/yaclib/all/conanfile.py index 4c35bd089113e8..5cd68c33e8af5c 100644 --- a/recipes/yaclib/all/conanfile.py +++ b/recipes/yaclib/all/conanfile.py @@ -1,9 +1,7 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd -from conan.tools.cmake import CMake, CMakeToolchain -from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import copy, get, export_conandata_patches, apply_conandata_patches, save -from conan.tools.layout import cmake_layout from conan.errors import ConanInvalidConfiguration import os import textwrap diff --git a/recipes/yaclib/all/test_v1_package/conanfile.py b/recipes/yaclib/all/test_v1_package/conanfile.py index 20d4d2e28d57e0..22642ac137bfad 100644 --- a/recipes/yaclib/all/test_v1_package/conanfile.py +++ b/recipes/yaclib/all/test_v1_package/conanfile.py @@ -1,5 +1,4 @@ -from conans import ConanFile, CMake -from conan.tools.build import cross_building +from conans import ConanFile, CMake, tools import os class TestPackageV1Conan(ConanFile): @@ -12,6 +11,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): + if not tools.cross_building(self): bin_path = os.path.join("bin", "test_package") self.run(bin_path, run_environment=True) From c23c100cb410789451770d989428f697787291a5 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 17:22:58 +0900 Subject: [PATCH 0300/1140] (#14509) cassandra-cpp-driver: add version 2.16.2, support conan v2 * cassandra-cpp-driver: add version 2.16.2, support conan v2 * fix library name, specify C++11 * add transitive_headers=True * update dependencies * fix compilation error on msvc * update dependencies, improve patch file * enable C++11, include type_traits --------- Co-authored-by: Uilian Ries --- .../cassandra-cpp-driver/all/CMakeLists.txt | 7 - .../cassandra-cpp-driver/all/conandata.yml | 38 +++- recipes/cassandra-cpp-driver/all/conanfile.py | 138 ++++++------ .../all/patches/2.15.3/fix-atomic.patch | 28 +++ .../all/patches/2.15.3/fix-cmake.patch | 148 ++++++++----- .../all/patches/2.15.3/fix-rapidjson.patch | 18 +- .../2.15.3/remove-attribute-for-msvc.patch | 18 ++ .../all/patches/2.16.2/fix-cmake.patch | 201 ++++++++++++++++++ .../all/test_package/CMakeLists.txt | 13 +- .../all/test_package/conanfile.py | 25 ++- .../{main.cpp => test_package.cpp} | 0 .../all/test_v1_package/CMakeLists.txt | 8 + .../all/test_v1_package/conanfile.py | 18 ++ recipes/cassandra-cpp-driver/config.yml | 2 + 14 files changed, 491 insertions(+), 171 deletions(-) delete mode 100644 recipes/cassandra-cpp-driver/all/CMakeLists.txt create mode 100644 recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-atomic.patch create mode 100644 recipes/cassandra-cpp-driver/all/patches/2.15.3/remove-attribute-for-msvc.patch create mode 100644 recipes/cassandra-cpp-driver/all/patches/2.16.2/fix-cmake.patch rename recipes/cassandra-cpp-driver/all/test_package/{main.cpp => test_package.cpp} (100%) create mode 100644 recipes/cassandra-cpp-driver/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cassandra-cpp-driver/all/test_v1_package/conanfile.py diff --git a/recipes/cassandra-cpp-driver/all/CMakeLists.txt b/recipes/cassandra-cpp-driver/all/CMakeLists.txt deleted file mode 100644 index 7f03984bd91495..00000000000000 --- a/recipes/cassandra-cpp-driver/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cassandra C CXX) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/cassandra-cpp-driver/all/conandata.yml b/recipes/cassandra-cpp-driver/all/conandata.yml index 0ca8371b0b30f9..35b0bd34f38b7a 100644 --- a/recipes/cassandra-cpp-driver/all/conandata.yml +++ b/recipes/cassandra-cpp-driver/all/conandata.yml @@ -1,10 +1,36 @@ sources: + "2.16.2": + url: "https://github.com/datastax/cpp-driver/archive/2.16.2.tar.gz" + sha256: "de60751bd575b5364c2c5a17a24a40f3058264ea2ee6fef19de126ae550febc9" "2.15.3": - url: "https://github.com/datastax/cpp-driver/archive/2.15.3.zip" - sha256: "494b35418f1eaa86d80572a4254b7fae88a1341dcda83788ed038ce4f39117cb" + url: "https://github.com/datastax/cpp-driver/archive/2.15.3.tar.gz" + sha256: "eccb53c5151621c3b647fc83781a542cfb93e76687b4178ebce418fc4c817293" patches: + "2.16.2": + - patch_file: "patches/2.16.2/fix-cmake.patch" + patch_description: "use cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-rapidjson.patch" + patch_description: "fix include path for cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-atomic.patch" + patch_description: "Adapt MemoryOrder definition for C++ 20" + patch_type: "portability" + patch_source: "https://github.com/datastax/cpp-driver/pull/533" + - patch_file: "patches/2.15.3/remove-attribute-for-msvc.patch" + patch_description: "remove attribute for msvc" + patch_type: "portability" "2.15.3": - - base_path: "source_subfolder" - patch_file: "patches/2.15.3/fix-cmake.patch" - - base_path: "source_subfolder" - patch_file: "patches/2.15.3/fix-rapidjson.patch" + - patch_file: "patches/2.15.3/fix-cmake.patch" + patch_description: "use cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-rapidjson.patch" + patch_description: "fix include path for cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-atomic.patch" + patch_description: "Adapt MemoryOrder definition for C++ 20" + patch_type: "portability" + patch_source: "https://github.com/datastax/cpp-driver/pull/533" + - patch_file: "patches/2.15.3/remove-attribute-for-msvc.patch" + patch_description: "remove attribute for msvc" + patch_type: "portability" diff --git a/recipes/cassandra-cpp-driver/all/conanfile.py b/recipes/cassandra-cpp-driver/all/conanfile.py index 76b1d99adf12b9..57fdb66f78e3f3 100644 --- a/recipes/cassandra-cpp-driver/all/conanfile.py +++ b/recipes/cassandra-cpp-driver/all/conanfile.py @@ -1,19 +1,20 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, replace_in_file, rm +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.build import check_min_cppstd import os -required_conan_version = ">=1.33.0" - +required_conan_version = ">=1.53.0" class CassandraCppDriverConan(ConanFile): name = "cassandra-cpp-driver" + description = "DataStax C/C++ Driver for Apache Cassandra and DataStax Products" license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://docs.datastax.com/en/developer/cpp-driver/" - description = "DataStax C/C++ Driver for Apache Cassandra and DataStax Products" - topics = ("cassandra", "cpp-driver", "database", "conan-recipe") - - settings = "os", "compiler", "build_type", "arch" + topics = ("cassandra", "cpp-driver", "database",) + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -34,19 +35,14 @@ class CassandraCppDriverConan(ConanFile): "with_kerberos": False, "use_timerfd": True, } - short_paths = True - generators = "cmake" - exports_sources = [ - "CMakeLists.txt", - "patches/*" - ] - - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 + + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -55,24 +51,30 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libuv/1.44.1") + self.requires("libuv/1.46.0") self.requires("http_parser/2.9.4") - self.requires("rapidjson/cci.20211112") + self.requires("rapidjson/cci.20220822") if self.options.with_openssl: - self.requires("openssl/1.1.1q") + self.requires("openssl/[>=1.1 <4]") if self.options.with_zlib: - self.requires("minizip/1.2.12") - self.requires("zlib/1.2.12") + self.requires("minizip/1.2.13") + self.requires("zlib/1.2.13") if self.options.use_atomic == "boost": - self.requires("boost/1.79.0") + self.requires("boost/1.82.0") def validate(self): + if self.info.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + if self.options.use_atomic == "boost": # Compilation error on Linux if self.settings.os == "Linux": @@ -84,69 +86,69 @@ def validate(self): "Kerberos is not supported at the moment") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), - "\"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"Clang\"", - "\"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"Clang\" OR \"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"AppleClang\"") - - def _configure_cmake(self): - if self._cmake: - return self._cmake - - self._cmake = CMake(self) - self._cmake.definitions["VERSION"] = self.version - self._cmake.definitions["CASS_BUILD_EXAMPLES"] = False - self._cmake.definitions["CASS_BUILD_INTEGRATION_TESTS"] = False - self._cmake.definitions["CASS_BUILD_SHARED"] = self.options.shared - self._cmake.definitions["CASS_BUILD_STATIC"] = not self.options.shared - self._cmake.definitions["CASS_BUILD_TESTS"] = False - self._cmake.definitions["CASS_BUILD_UNIT_TESTS"] = False - self._cmake.definitions["CASS_DEBUG_CUSTOM_ALLOC"] = False - self._cmake.definitions["CASS_INSTALL_HEADER_IN_SUBDIR"] = self.options.install_header_in_subdir - self._cmake.definitions["CASS_INSTALL_PKG_CONFIG"] = False + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["VERSION"] = self.version + tc.variables["CASS_BUILD_EXAMPLES"] = False + tc.variables["CASS_BUILD_INTEGRATION_TESTS"] = False + tc.variables["CASS_BUILD_SHARED"] = self.options.shared + tc.variables["CASS_BUILD_STATIC"] = not self.options.shared + tc.variables["CASS_BUILD_TESTS"] = False + tc.variables["CASS_BUILD_UNIT_TESTS"] = False + tc.variables["CASS_DEBUG_CUSTOM_ALLOC"] = False + tc.variables["CASS_INSTALL_HEADER_IN_SUBDIR"] = self.options.install_header_in_subdir + tc.variables["CASS_INSTALL_PKG_CONFIG"] = False if self.options.use_atomic == "boost": - self._cmake.definitions["CASS_USE_BOOST_ATOMIC"] = True - self._cmake.definitions["CASS_USE_STD_ATOMIC"] = False + tc.variables["CASS_USE_BOOST_ATOMIC"] = True + tc.variables["CASS_USE_STD_ATOMIC"] = False elif self.options.use_atomic == "std": - self._cmake.definitions["CASS_USE_BOOST_ATOMIC"] = False - self._cmake.definitions["CASS_USE_STD_ATOMIC"] = True + tc.variables["CASS_USE_BOOST_ATOMIC"] = False + tc.variables["CASS_USE_STD_ATOMIC"] = True else: - self._cmake.definitions["CASS_USE_BOOST_ATOMIC"] = False - self._cmake.definitions["CASS_USE_STD_ATOMIC"] = False + tc.variables["CASS_USE_BOOST_ATOMIC"] = False + tc.variables["CASS_USE_STD_ATOMIC"] = False - self._cmake.definitions["CASS_USE_OPENSSL"] = self.options.with_openssl - self._cmake.definitions["CASS_USE_STATIC_LIBS"] = False - self._cmake.definitions["CASS_USE_ZLIB"] = self.options.with_zlib - self._cmake.definitions["CASS_USE_LIBSSH2"] = False + tc.variables["CASS_USE_OPENSSL"] = self.options.with_openssl + tc.variables["CASS_USE_STATIC_LIBS"] = False + tc.variables["CASS_USE_ZLIB"] = self.options.with_zlib + tc.variables["CASS_USE_LIBSSH2"] = False # FIXME: To use kerberos, its conan package is needed. Uncomment this when kerberos conan package is ready. - # self._cmake.definitions["CASS_USE_KERBEROS"] = self.options.with_kerberos + # tc.variables["CASS_USE_KERBEROS"] = self.options.with_kerberos if self.settings.os == "Linux": - self._cmake.definitions["CASS_USE_TIMERFD"] = self.options.use_timerfd + tc.variables["CASS_USE_TIMERFD"] = self.options.use_timerfd + tc.generate() - self._cmake.configure() - return self._cmake + deps = CMakeDeps(self) + deps.generate() + + def _patch_sources(self): + apply_conandata_patches(self) + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "\"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"Clang\"", + "\"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"Clang\" OR \"${CMAKE_CXX_COMPILER_ID}\" STREQUAL \"AppleClang\"") + rm(self, "Findlibssh2.cmake", os.path.join(self.source_folder, "cmake")) + rm(self, "Findlibuv.cmake", os.path.join(self.source_folder, "cmake")) + rm(self, "FindOpenSSL.cmake", os.path.join(self.source_folder, "cmake")) def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE.txt", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = ["cassandra" if self.options.shared else "cassandra_static"] if self.settings.os == "Windows": self.cpp_info.system_libs.extend(["iphlpapi", "psapi", "wsock32", diff --git a/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-atomic.patch b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-atomic.patch new file mode 100644 index 00000000000000..64a29de126f9f6 --- /dev/null +++ b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-atomic.patch @@ -0,0 +1,28 @@ +diff --git a/src/atomic/atomic_std.hpp b/src/atomic/atomic_std.hpp +index 2ad0103..08418a9 100644 +--- a/src/atomic/atomic_std.hpp ++++ b/src/atomic/atomic_std.hpp +@@ -18,16 +18,17 @@ + #define DATASTAX_INTERNAL_ATOMIC_STD_HPP + + #include ++#include + + namespace datastax { namespace internal { + + enum MemoryOrder { +- MEMORY_ORDER_RELAXED = std::memory_order_relaxed, +- MEMORY_ORDER_CONSUME = std::memory_order_consume, +- MEMORY_ORDER_ACQUIRE = std::memory_order_acquire, +- MEMORY_ORDER_RELEASE = std::memory_order_release, +- MEMORY_ORDER_ACQ_REL = std::memory_order_acq_rel, +- MEMORY_ORDER_SEQ_CST = std::memory_order_seq_cst ++ MEMORY_ORDER_RELAXED = static_cast::type>(std::memory_order_relaxed), ++ MEMORY_ORDER_CONSUME = static_cast::type>(std::memory_order_consume), ++ MEMORY_ORDER_ACQUIRE = static_cast::type>(std::memory_order_acquire), ++ MEMORY_ORDER_RELEASE = static_cast::type>(std::memory_order_release), ++ MEMORY_ORDER_ACQ_REL = static_cast::type>(std::memory_order_acq_rel), ++ MEMORY_ORDER_SEQ_CST = static_cast::type>(std::memory_order_seq_cst) + }; + + template diff --git a/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-cmake.patch b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-cmake.patch index 191d2eb7e8174a..9406ccc60d7aa9 100644 --- a/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-cmake.patch +++ b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-cmake.patch @@ -1,43 +1,87 @@ - CMakeLists.txt | 4 --- - src/CMakeLists.txt | 84 ++++++++++++++++++++++++++++++++++++------------------ - 2 files changed, 57 insertions(+), 31 deletions(-) - diff --git a/CMakeLists.txt b/CMakeLists.txt -index c6150948b..669eb086e 100644 +index c615094..b10d9c9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -1,6 +1,3 @@ --cmake_minimum_required(VERSION 2.8.12) --project(cassandra C CXX) -- - set(CASS_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}) - set(CASS_SRC_DIR "${CASS_ROOT_DIR}/src") - set(CASS_INCLUDE_DIR "${CASS_ROOT_DIR}/include") -@@ -81,7 +78,6 @@ endif() - # Dependencies - #------------------------ +@@ -164,7 +164,7 @@ endif() + if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" OR + "${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") + # Enable C++11 support to use std::atomic +- if(CASS_USE_STD_ATOMIC) ++ if(1) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + endif() + +diff --git a/cmake/Dependencies.cmake b/cmake/Dependencies.cmake +index 9052472..3f65adb 100644 +--- a/cmake/Dependencies.cmake ++++ b/cmake/Dependencies.cmake +@@ -21,28 +21,28 @@ if(NOT LIBUV_ROOT_DIR) + endif() + + # Ensure libuv was found +-find_package(Libuv "1.0.0") +-if(WIN32 AND NOT LIBUV_FOUND) ++find_package(libuv "1.0.0") ++if(WIN32 AND NOT libuv_FOUND) + message(STATUS "Unable to Locate libuv: Third party build step will be performed") + include(ExternalProject-libuv) +-elseif(NOT LIBUV_FOUND) ++elseif(NOT libuv_FOUND) + message(FATAL_ERROR "Unable to Locate libuv: libuv v1.0.0+ is required") + endif() + +-if(LIBUV_VERSION VERSION_LESS "1.0") +- message(FATAL_ERROR "Libuv version ${LIBUV_VERSION} is not " ++if(libuv_VERSION VERSION_LESS "1.0") ++ message(FATAL_ERROR "libuv version ${libuv_VERSION} is not " + " supported. Please updgrade to libuv version 1.0 or greater in order to " + "utilize the driver.") + endif() --include(Dependencies) - include(ClangFormat) +-if(LIBUV_VERSION VERSION_LESS "1.6") +- message(WARNING "Libuv version ${LIBUV_VERSION} does not support custom " ++if(libuv_VERSION VERSION_LESS "1.6") ++ message(WARNING "libuv version ${libuv_VERSION} does not support custom " + "memory allocators (version 1.6 or greater required)") + endif() + + # Assign libuv include and libraries +-set(CASS_INCLUDES ${CASS_INCLUDES} ${LIBUV_INCLUDE_DIRS}) +-set(CASS_LIBS ${CASS_LIBS} ${LIBUV_LIBRARIES}) ++set(CASS_INCLUDES ${CASS_INCLUDES} ${libuv_INCLUDE_DIRS}) ++set(CASS_LIBS ${CASS_LIBS} ${libuv_LIBRARIES}) + + # libuv and gtests require thread library + if(NOT WIN32) +@@ -192,3 +192,20 @@ if(CASS_USE_BOOST_ATOMIC) + endif() + endif() - #------------------------ ++#------------------------ ++# RapidJSON ++#------------------------ ++find_package(RapidJSON REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} rapidjson) ++ ++#------------------------ ++# http_parser ++#------------------------ ++find_package(http_parser REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} http_parser::http_parser) ++ ++#------------------------ ++# minizip ++#------------------------ ++find_package(minizip REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} minizip::minizip) diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 06b84b759..7e81b2a06 100644 +index 06b84b7..41b23f2 100644 --- a/src/CMakeLists.txt +++ b/src/CMakeLists.txt -@@ -1,6 +1,50 @@ +@@ -1,6 +1,41 @@ include(CheckSymbolExists) include(CheckCXXSourceCompiles) -+#------------------------ -+# Windows libraries -+#------------------------ -+ -+if(WIN32) -+ # Assign additional library requirements for Windows -+ set(CASS_LIBS iphlpapi psapi wsock32 crypt32 ws2_32 userenv version) -+endif() -+ +#------------------------ +# Libuv +#------------------------ @@ -76,7 +120,7 @@ index 06b84b759..7e81b2a06 100644 file(GLOB SOURCES *.cpp *.hpp) if(APPLE) -@@ -38,18 +82,14 @@ endif() +@@ -38,18 +73,14 @@ endif() add_subdirectory(third_party/curl) add_subdirectory(third_party/hdr_histogram) @@ -90,16 +134,17 @@ index 06b84b759..7e81b2a06 100644 - third_party/http-parser - third_party/minizip - third_party/mt19937_64 +- third_party/rapidjson/rapidjson +- third_party/sparsehash/src) + third_party/curl # FIXME: Use conan package + third_party/hdr_histogram # FIXME: Use conan package + third_party/mt19937_64 # FIXME: Use conan package -+ third_party/sparsehash/src) # FIXME: Use conan package - third_party/rapidjson/rapidjson -- third_party/sparsehash/src) ++ third_party/sparsehash/src # FIXME: Use conan package ++) list(APPEND INCLUDE_DIRS ${CASS_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) -@@ -69,12 +109,6 @@ if(WIN32) +@@ -69,12 +100,6 @@ if(WIN32) endif() endif() @@ -112,40 +157,27 @@ index 06b84b759..7e81b2a06 100644 #------------------------------ # Build configured header #------------------------------ -@@ -130,11 +164,11 @@ if(CASS_BUILD_SHARED) - add_library(cassandra SHARED +@@ -131,8 +156,7 @@ if(CASS_BUILD_SHARED) ${SOURCES} $ -- $ + $ - $ - $) -+ $) ++ ) target_link_libraries(cassandra ${CASS_LIBS}) -- target_include_directories(cassandra PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) -+ target_include_directories(cassandra PRIVATE ${INCLUDE_DIRS}) -+ -+ conan_target_link_libraries(cassandra) - - set_target_properties(cassandra PROPERTIES OUTPUT_NAME cassandra) - set_target_properties(cassandra PROPERTIES VERSION ${PROJECT_VERSION_STRING} SOVERSION ${PROJECT_VERSION_MAJOR}) -@@ -167,11 +201,12 @@ if(CASS_BUILD_STATIC) - add_library(cassandra_static STATIC + target_include_directories(cassandra PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) + +@@ -168,8 +192,7 @@ if(CASS_BUILD_STATIC) ${SOURCES} $ -- $ + $ - $ - $) -+ $) -+ ++ ) target_link_libraries(cassandra_static ${CASS_LIBS}) -- target_include_directories(cassandra_static PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) -+ target_include_directories(cassandra_static PRIVATE ${INCLUDE_DIRS}) -+ -+ conan_target_link_libraries(cassandra_static) - - set_target_properties(cassandra_static PROPERTIES OUTPUT_NAME cassandra_static) - set_target_properties(cassandra_static PROPERTIES VERSION ${PROJECT_VERSION_STRING} SOVERSION ${PROJECT_VERSION_MAJOR}) -@@ -274,11 +309,6 @@ if(CASS_BUILD_SHARED) + target_include_directories(cassandra_static PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) + +@@ -274,11 +297,6 @@ if(CASS_BUILD_SHARED) endif() endif() endif() diff --git a/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-rapidjson.patch b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-rapidjson.patch index 7c7b5d16994d78..91811710ffbe44 100644 --- a/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-rapidjson.patch +++ b/recipes/cassandra-cpp-driver/all/patches/2.15.3/fix-rapidjson.patch @@ -1,21 +1,5 @@ - src/CMakeLists.txt | 1 - - src/json.hpp | 8 ++++---- - 2 files changed, 4 insertions(+), 5 deletions(-) - -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 7e81b2a06..2f3229292 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -89,7 +89,6 @@ list(APPEND INCLUDE_DIRS - third_party/hdr_histogram # FIXME: Use conan package - third_party/mt19937_64 # FIXME: Use conan package - third_party/sparsehash/src) # FIXME: Use conan package -- third_party/rapidjson/rapidjson - - list(APPEND INCLUDE_DIRS ${CASS_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) - diff --git a/src/json.hpp b/src/json.hpp -index 620536e55..6003f2521 100644 +index 620536e..6003f25 100644 --- a/src/json.hpp +++ b/src/json.hpp @@ -48,13 +48,13 @@ static void delete_(T* ptr) { diff --git a/recipes/cassandra-cpp-driver/all/patches/2.15.3/remove-attribute-for-msvc.patch b/recipes/cassandra-cpp-driver/all/patches/2.15.3/remove-attribute-for-msvc.patch new file mode 100644 index 00000000000000..216ee8df654e9c --- /dev/null +++ b/recipes/cassandra-cpp-driver/all/patches/2.15.3/remove-attribute-for-msvc.patch @@ -0,0 +1,18 @@ +diff --git a/src/third_party/sparsehash/src/sparsehash/internal/hashtable-common.h b/src/third_party/sparsehash/src/sparsehash/internal/hashtable-common.h +index bac2b88..e802b5c 100644 +--- a/src/third_party/sparsehash/src/sparsehash/internal/hashtable-common.h ++++ b/src/third_party/sparsehash/src/sparsehash/internal/hashtable-common.h +@@ -50,8 +50,13 @@ + _START_GOOGLE_NAMESPACE_ + + template struct SparsehashCompileAssert { }; ++#if defined(_MSC_VER) ++#define SPARSEHASH_COMPILE_ASSERT(expr, msg) \ ++ typedef SparsehashCompileAssert<(bool(expr))> msg[bool(expr) ? 1 : -1] ++#else + #define SPARSEHASH_COMPILE_ASSERT(expr, msg) \ + __attribute__((unused)) typedef SparsehashCompileAssert<(bool(expr))> msg[bool(expr) ? 1 : -1] ++#endif + + namespace sparsehash_internal { + diff --git a/recipes/cassandra-cpp-driver/all/patches/2.16.2/fix-cmake.patch b/recipes/cassandra-cpp-driver/all/patches/2.16.2/fix-cmake.patch new file mode 100644 index 00000000000000..5a69b0d7d12b14 --- /dev/null +++ b/recipes/cassandra-cpp-driver/all/patches/2.16.2/fix-cmake.patch @@ -0,0 +1,201 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index c615094..b10d9c9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -164,7 +164,7 @@ endif() + if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang" OR + "${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") + # Enable C++11 support to use std::atomic +- if(CASS_USE_STD_ATOMIC) ++ if(1) + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11") + endif() + +diff --git a/cmake/Dependencies.cmake b/cmake/Dependencies.cmake +index 9052472..4701133 100644 +--- a/cmake/Dependencies.cmake ++++ b/cmake/Dependencies.cmake +@@ -21,28 +21,28 @@ if(NOT LIBUV_ROOT_DIR) + endif() + + # Ensure libuv was found +-find_package(Libuv "1.0.0") +-if(WIN32 AND NOT LIBUV_FOUND) ++find_package(libuv "1.0.0") ++if(WIN32 AND NOT libuv_FOUND) + message(STATUS "Unable to Locate libuv: Third party build step will be performed") + include(ExternalProject-libuv) +-elseif(NOT LIBUV_FOUND) ++elseif(NOT libuv_FOUND) + message(FATAL_ERROR "Unable to Locate libuv: libuv v1.0.0+ is required") + endif() + +-if(LIBUV_VERSION VERSION_LESS "1.0") +- message(FATAL_ERROR "Libuv version ${LIBUV_VERSION} is not " ++if(libuv_VERSION VERSION_LESS "1.0") ++ message(FATAL_ERROR "Libuv version ${libuv_VERSION} is not " + " supported. Please updgrade to libuv version 1.0 or greater in order to " + "utilize the driver.") + endif() + +-if(LIBUV_VERSION VERSION_LESS "1.6") +- message(WARNING "Libuv version ${LIBUV_VERSION} does not support custom " ++if(libuv_VERSION VERSION_LESS "1.6") ++ message(WARNING "Libuv version ${libuv_VERSION} does not support custom " + "memory allocators (version 1.6 or greater required)") + endif() + + # Assign libuv include and libraries +-set(CASS_INCLUDES ${CASS_INCLUDES} ${LIBUV_INCLUDE_DIRS}) +-set(CASS_LIBS ${CASS_LIBS} ${LIBUV_LIBRARIES}) ++set(CASS_INCLUDES ${CASS_INCLUDES} ${libuv_INCLUDE_DIRS}) ++set(CASS_LIBS ${CASS_LIBS} ${libuv_LIBRARIES}) + + # libuv and gtests require thread library + if(NOT WIN32) +@@ -192,3 +192,20 @@ if(CASS_USE_BOOST_ATOMIC) + endif() + endif() + ++#------------------------ ++# RapidJSON ++#------------------------ ++find_package(RapidJSON REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} rapidjson) ++ ++#------------------------ ++# http_parser ++#------------------------ ++find_package(http_parser REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} http_parser::http_parser) ++ ++#------------------------ ++# minizip ++#------------------------ ++find_package(minizip REQUIRED CONFIG) ++set(CASS_LIBS ${CASS_LIBS} minizip::minizip) +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index d662718..088a153 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -1,6 +1,42 @@ + include(CheckSymbolExists) + include(CheckCXXSourceCompiles) + ++#------------------------ ++# Libuv ++#------------------------ ++ ++if(NOT WIN32) ++ set(CMAKE_THREAD_PREFER_PTHREAD 1) ++ set(THREADS_PREFER_PTHREAD_FLAG 1) ++endif() ++ ++find_package(Threads REQUIRED) ++set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_THREAD_LIBS_INIT}") ++set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_THREAD_LIBS_INIT}") ++if(NOT WIN32 AND ${CMAKE_VERSION} VERSION_LESS "3.1.0") ++ # FindThreads in CMake versions < v3.1.0 do not have the THREADS_PREFER_PTHREAD_FLAG to prefer -pthread ++ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pthread") ++ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pthread") ++endif() ++ ++#------------------------ ++# Boost ++#------------------------ ++ ++if(CASS_USE_BOOST_ATOMIC) ++ # Ensure Boost auto linking is disabled (defaults to auto linking on Windows) ++ if(WIN32) ++ add_definitions(-DBOOST_ALL_NO_LIB) ++ endif() ++ ++ # Determine if additional Boost definitions are required for driver/executables ++ if(NOT WIN32) ++ # Handle explicit initialization warning in atomic/details/casts ++ add_definitions(-Wno-missing-field-initializers) ++ endif() ++endif() ++ ++ + file(GLOB SOURCES *.cpp *.hpp) + + if(APPLE) +@@ -38,18 +74,14 @@ endif() + + add_subdirectory(third_party/curl) + add_subdirectory(third_party/hdr_histogram) +-add_subdirectory(third_party/http-parser) +-add_subdirectory(third_party/minizip) + add_subdirectory(third_party/sparsehash) + + list(APPEND INCLUDE_DIRS +- third_party/curl +- third_party/hdr_histogram +- third_party/http-parser +- third_party/minizip +- third_party/mt19937_64 +- third_party/rapidjson/rapidjson +- third_party/sparsehash/src) ++ third_party/curl # FIXME: Use conan package ++ third_party/hdr_histogram # FIXME: Use conan package ++ third_party/mt19937_64 # FIXME: Use conan package ++ third_party/sparsehash/src # FIXME: Use conan package ++) + + list(APPEND INCLUDE_DIRS ${CASS_INCLUDE_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) + +@@ -69,13 +101,6 @@ if(WIN32) + endif() + endif() + +-if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "Clang") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wconversion -Wno-sign-conversion -Wno-shorten-64-to-32 -Wno-undefined-var-template -Werror") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wno-implicit-int-float-conversion") +-elseif("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU") # To many superfluous warnings generated with GCC when using -Wconversion (see: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=40752) +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Werror") +-endif() +- + #------------------------------ + # Build configured header + #------------------------------ +@@ -122,7 +147,6 @@ configure_file( + ${CASS_ROOT_DIR}/driver_config.hpp.in + ${CMAKE_CURRENT_SOURCE_DIR}/driver_config.hpp) + +- + #------------------------------ + # Targets + #------------------------------ +@@ -132,8 +156,7 @@ if(CASS_BUILD_SHARED) + ${SOURCES} + $ + $ +- $ +- $) ++ ) + target_link_libraries(cassandra ${CASS_LIBS}) + target_include_directories(cassandra PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) + +@@ -169,8 +192,7 @@ if(CASS_BUILD_STATIC) + ${SOURCES} + $ + $ +- $ +- $) ++ ) + target_link_libraries(cassandra_static ${CASS_LIBS}) + target_include_directories(cassandra_static PRIVATE ${INCLUDE_DIRS} ${CASS_INCLUDES}) + +@@ -275,11 +297,6 @@ if(CASS_BUILD_SHARED) + endif() + endif() + endif() +- if(WIN32) +- install(FILES $ +- DESTINATION "${INSTALL_DLL_EXE_DIR}" +- OPTIONAL) +- endif() + endif() + + if(CASS_BUILD_STATIC) diff --git a/recipes/cassandra-cpp-driver/all/test_package/CMakeLists.txt b/recipes/cassandra-cpp-driver/all/test_package/CMakeLists.txt index 1a95218e3d7a51..4d590e1005c294 100644 --- a/recipes/cassandra-cpp-driver/all/test_package/CMakeLists.txt +++ b/recipes/cassandra-cpp-driver/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(cassandra-cpp-driver REQUIRED CONFIG) -add_executable(${PROJECT_NAME} main.cpp) - -conan_target_link_libraries(${PROJECT_NAME}) +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE cassandra-cpp-driver::cassandra-cpp-driver) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/cassandra-cpp-driver/all/test_package/conanfile.py b/recipes/cassandra-cpp-driver/all/test_package/conanfile.py index 0399475aec9873..a9fb96656f2039 100644 --- a/recipes/cassandra-cpp-driver/all/test_package/conanfile.py +++ b/recipes/cassandra-cpp-driver/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -import os.path -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os -class CassandraCppDriverTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cassandra-cpp-driver/all/test_package/main.cpp b/recipes/cassandra-cpp-driver/all/test_package/test_package.cpp similarity index 100% rename from recipes/cassandra-cpp-driver/all/test_package/main.cpp rename to recipes/cassandra-cpp-driver/all/test_package/test_package.cpp diff --git a/recipes/cassandra-cpp-driver/all/test_v1_package/CMakeLists.txt b/recipes/cassandra-cpp-driver/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..925ecbe19e448d --- /dev/null +++ b/recipes/cassandra-cpp-driver/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cassandra-cpp-driver/all/test_v1_package/conanfile.py b/recipes/cassandra-cpp-driver/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..5a05af3c2dfd2f --- /dev/null +++ b/recipes/cassandra-cpp-driver/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake +from conan.tools.build import cross_building +import os + + +class TestPackageV1Conan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/cassandra-cpp-driver/config.yml b/recipes/cassandra-cpp-driver/config.yml index 9792bd17fcc93c..fa0680a1da5b55 100644 --- a/recipes/cassandra-cpp-driver/config.yml +++ b/recipes/cassandra-cpp-driver/config.yml @@ -1,3 +1,5 @@ versions: + "2.16.2": + folder: all "2.15.3": folder: all From 244e2cb9434191129a79d3808cf48451b4acfc0c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 11:45:28 +0300 Subject: [PATCH 0301/1140] (#17347) urdfdom: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * urdfdom: add recipe * urdfdom: fix libraries being hard-coded to SHARED * urdfdom: fix building as static library on Windows * urdfdom: remove unused USE_MSVC_RUNTIME_LIBRARY_DLL * urdfdom: simplify patches * urdfdom: improve conanfile.py - Add src_folder="src" to cmake_layout(). - Add minimum cppstd >= 14. - Explicitly set the CMake package and target names. * urdfdom: replace test_requires() -> build_requires() * urdfdom: drop test_v1_package * urdfdom: drop skip_test=False support For a simpler recipe. * urdfdom: rm unnecessary cpp_info properties * urdfdom: drop transitive_libs from tinyxml * urdfdom: remove *.pc, *.cmake and shared/package.xml * Update recipes/urdfdom/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Rubén Rincón Blanco --- recipes/urdfdom/all/conandata.yml | 22 ++++ recipes/urdfdom/all/conanfile.py | 107 ++++++++++++++++++ .../all/patches/001-optional-build-apps.patch | 34 ++++++ .../patches/002-use-conan-dependencies.patch | 83 ++++++++++++++ .../003-use-merged-urdfdom_headers.patch | 21 ++++ .../urdfdom/all/test_package/CMakeLists.txt | 8 ++ recipes/urdfdom/all/test_package/conanfile.py | 26 +++++ .../urdfdom/all/test_package/test_package.cpp | 15 +++ recipes/urdfdom/config.yml | 3 + 9 files changed, 319 insertions(+) create mode 100644 recipes/urdfdom/all/conandata.yml create mode 100644 recipes/urdfdom/all/conanfile.py create mode 100644 recipes/urdfdom/all/patches/001-optional-build-apps.patch create mode 100644 recipes/urdfdom/all/patches/002-use-conan-dependencies.patch create mode 100644 recipes/urdfdom/all/patches/003-use-merged-urdfdom_headers.patch create mode 100644 recipes/urdfdom/all/test_package/CMakeLists.txt create mode 100644 recipes/urdfdom/all/test_package/conanfile.py create mode 100644 recipes/urdfdom/all/test_package/test_package.cpp create mode 100644 recipes/urdfdom/config.yml diff --git a/recipes/urdfdom/all/conandata.yml b/recipes/urdfdom/all/conandata.yml new file mode 100644 index 00000000000000..82a20122324507 --- /dev/null +++ b/recipes/urdfdom/all/conandata.yml @@ -0,0 +1,22 @@ +sources: + "3.1.1": + urdfdom: + url: "https://github.com/ros/urdfdom/archive/refs/tags/3.1.1.tar.gz" + sha256: "dd69b2077b8fc1bd2b67022c1dc861cd896ac882df065aa08cabdf2f945a9ac0" + urdfdom_headers: + # Latest unreleased version from 2023-04-25. + # Identical to the latest v1.0.5 release, except headers have been conveniently moved to include/. + # We merge the headers into the main source tree instead of packaging them separately. + url: "https://github.com/ros/urdfdom_headers/archive/1fd21b64ed78493508a174f98af982605d1e4607.zip" + sha256: "aba42c1c83d6d1fb94e54ec84680a8b9e2417337fbaa85424da0e069d0cc89b6" +patches: + "3.1.1": + - patch_file: "patches/001-optional-build-apps.patch" + patch_type: "conan" + patch_description: "Disable building of apps by default" + - patch_file: "patches/002-use-conan-dependencies.patch" + patch_type: "conan" + patch_description: "Use dependencies (console_bridge, TinyXML, GTest) from Conan" + - patch_file: "patches/003-use-merged-urdfdom_headers.patch" + patch_type: "conan" + patch_description: "Use merged urdfdom_headers instead of a separate package" diff --git a/recipes/urdfdom/all/conanfile.py b/recipes/urdfdom/all/conanfile.py new file mode 100644 index 00000000000000..f7a710e7f7ea76 --- /dev/null +++ b/recipes/urdfdom/all/conanfile.py @@ -0,0 +1,107 @@ +import os + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rm, rmdir + +required_conan_version = ">=1.53.0" + + +class PackageConan(ConanFile): + name = "urdfdom" + description = "Data structures and parsers to access URDF files using the DOM model" + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ros/urdfdom" + topics = ("urdf", "ros", "robotics") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 14 + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("tinyxml/2.6.2", transitive_headers=True) + self.requires("console_bridge/1.0.2") + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + + def source(self): + # urdfdom packages its headers separately as urdfdom_headers. + # There is no obvious benefit of doing the same for the Conan package, + # so we simply merge the headers into the main source tree. + sources = self.conan_data["sources"][self.version] + get(self, **sources["urdfdom_headers"], strip_root=True, + destination=os.path.join(self.source_folder, "urdf_parser")) + get(self, **sources["urdfdom"], strip_root=True, destination=self.source_folder) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["APPEND_PROJECT_NAME_TO_INCLUDEDIR"] = False + tc.variables["BUILD_TESTING"] = False + tc.variables["BUILD_APPS"] = False + if not self.options.shared: + tc.preprocessor_definitions["URDFDOM_STATIC"] = "1" + tc.generate() + CMakeDeps(self).generate() + + def _patch_sources(self): + apply_conandata_patches(self) + # Do not hard-code libraries to SHARED + parser_cmakelists = os.path.join(self.source_folder, "urdf_parser", "CMakeLists.txt") + replace_in_file(self, parser_cmakelists, " SHARED", "") + + def build(self): + self._patch_sources() + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "urdfdom")) + rmdir(self, os.path.join(self.package_folder, "CMake")) + rmdir(self, os.path.join(self.package_folder, "share")) + rm(self, "*.pdb", self.package_folder, recursive=True) + + def package_info(self): + self.cpp_info.libs = [ + "urdfdom_model", + "urdfdom_model_state", + "urdfdom_sensor", + "urdfdom_world", + ] + + if not self.options.shared: + self.cpp_info.defines.append("URDFDOM_STATIC=1") diff --git a/recipes/urdfdom/all/patches/001-optional-build-apps.patch b/recipes/urdfdom/all/patches/001-optional-build-apps.patch new file mode 100644 index 00000000000000..a89c2b010b26ce --- /dev/null +++ b/recipes/urdfdom/all/patches/001-optional-build-apps.patch @@ -0,0 +1,34 @@ +--- a/urdf_parser/CMakeLists.txt ++++ b/urdf_parser/CMakeLists.txt +@@ -80,6 +78,7 @@ + + # -------------------------------- + ++if(BUILD_APPS) + add_executable(check_urdf src/check_urdf.cpp) + target_include_directories(check_urdf PUBLIC include) + target_link_libraries(check_urdf urdfdom_model urdfdom_world) +@@ -96,6 +95,7 @@ + add_executable(urdf_mem_test test/memtest.cpp) + target_include_directories(urdf_mem_test PUBLIC include) + target_link_libraries(urdf_mem_test urdfdom_model) ++endif() + + include(CTest) + if(BUILD_TESTING) +@@ -103,6 +103,7 @@ + add_subdirectory(test) + endif() + ++if(BUILD_APPS) + INSTALL( + TARGETS + check_urdf +@@ -113,6 +114,7 @@ + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + ) ++endif() + INSTALL( + TARGETS + urdfdom_model diff --git a/recipes/urdfdom/all/patches/002-use-conan-dependencies.patch b/recipes/urdfdom/all/patches/002-use-conan-dependencies.patch new file mode 100644 index 00000000000000..cbb6f0fc84fb3f --- /dev/null +++ b/recipes/urdfdom/all/patches/002-use-conan-dependencies.patch @@ -0,0 +1,83 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt (revision 1ed7ca95b917f38feb4ff7bd1aa033baf2cfce0e) ++++ b/CMakeLists.txt (revision 6592c04e28cb59b8e9ac5944e3229c50d706a2ee) +@@ -45,19 +45,9 @@ + + set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") + +-find_package(tinyxml_vendor QUIET) +-find_package(TinyXML) +-# bionic has not cmake module, workaround +-if (NOT TinyXML_FOUND AND UNIX) +- include(FindPkgConfig) +- pkg_check_modules (TinyXML tinyxml) +-else() +- # Make it fail in platforms without pkgconfig +- find_package(TinyXML REQUIRED) # bionic has not cmake module +-endif() ++find_package(tinyxml REQUIRED CONFIG) + find_package(urdfdom_headers 1.0 REQUIRED) +-find_package(console_bridge_vendor QUIET) # Provides console_bridge 0.4.0 on platforms without it. +-find_package(console_bridge REQUIRED) ++find_package(console_bridge REQUIRED CONFIG) + + # Control where libraries and executables are placed during the build + set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_BINARY_DIR}/${CMAKE_INSTALL_BINDIR}") + +diff --git a/urdf_parser/CMakeLists.txt b/urdf_parser/CMakeLists.txt +--- a/urdf_parser/CMakeLists.txt (revision 1ed7ca95b917f38feb4ff7bd1aa033baf2cfce0e) ++++ b/urdf_parser/CMakeLists.txt (revision 6592c04e28cb59b8e9ac5944e3229c50d706a2ee) +@@ -5,8 +5,6 @@ + + add_library(${add_urdfdom_library_LIBNAME} SHARED + ${add_urdfdom_library_SOURCES}) +- target_include_directories(${add_urdfdom_library_LIBNAME} SYSTEM PUBLIC +- ${TinyXML_INCLUDE_DIRS}) + target_include_directories(${add_urdfdom_library_LIBNAME} PUBLIC + "$" + "$") +@@ -14,7 +12,7 @@ + ${add_urdfdom_library_LINK} + ${console_bridge_link_libs} + ${urdfdom_headers_link_libs} +- ${TinyXML_LIBRARIES}) ++ tinyxml::tinyxml) + if(NOT CMAKE_CXX_STANDARD) + target_compile_features(${add_urdfdom_library_LIBNAME} PUBLIC cxx_std_14) + endif() + +diff --git a/urdf_parser/test/CMakeLists.txt b/urdf_parser/test/CMakeLists.txt +--- a/urdf_parser/test/CMakeLists.txt (revision 1ed7ca95b917f38feb4ff7bd1aa033baf2cfce0e) ++++ b/urdf_parser/test/CMakeLists.txt (revision 6592c04e28cb59b8e9ac5944e3229c50d706a2ee) +@@ -1,18 +1,8 @@ +-include_directories( +- ${CMAKE_CURRENT_SOURCE_DIR}/gtest/include +- ${CMAKE_CURRENT_SOURCE_DIR}/gtest +- ${CMAKE_CURRENT_SOURCE_DIR} +-) +- +-# Build gtest +-add_library(gtest STATIC gtest/src/gtest-all.cc) +-add_library(gtest_main STATIC gtest/src/gtest_main.cc) +-target_link_libraries(gtest_main gtest) +-target_compile_features(gtest PUBLIC cxx_std_11) +- + execute_process(COMMAND cmake -E remove_directory ${CMAKE_BINARY_DIR}/test_results) + execute_process(COMMAND cmake -E make_directory ${CMAKE_BINARY_DIR}/test_results) + ++find_package(GTest REQUIRED) ++ + # unit test to fix geometry problems + set(tests + urdf_double_convert.cpp +@@ -27,8 +17,8 @@ + add_executable(${BINARY_NAME} ${GTEST_SOURCE_file}) + + target_link_libraries(${BINARY_NAME} +- gtest_main +- gtest ++ GTest::gtest ++ GTest::gtest_main + urdfdom_model + ) + if (UNIX) diff --git a/recipes/urdfdom/all/patches/003-use-merged-urdfdom_headers.patch b/recipes/urdfdom/all/patches/003-use-merged-urdfdom_headers.patch new file mode 100644 index 00000000000000..b4095fcb7ba42f --- /dev/null +++ b/recipes/urdfdom/all/patches/003-use-merged-urdfdom_headers.patch @@ -0,0 +1,21 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +--- a/CMakeLists.txt (revision 82fb54588f3ba5091d9a73d072559ac7061eccdf) ++++ b/CMakeLists.txt (revision 1de2b88f231fa0f7f83a028e971d4ebaed1b164c) +@@ -46,7 +46,6 @@ + set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") + + find_package(tinyxml REQUIRED CONFIG) +-find_package(urdfdom_headers 1.0 REQUIRED) + find_package(console_bridge REQUIRED CONFIG) + + # Control where libraries and executables are placed during the build + +diff --git a/urdf_parser/CMakeLists.txt b/urdf_parser/CMakeLists.txt +--- a/urdf_parser/CMakeLists.txt (revision 82fb54588f3ba5091d9a73d072559ac7061eccdf) ++++ b/urdf_parser/CMakeLists.txt (revision 1de2b88f231fa0f7f83a028e971d4ebaed1b164c) +@@ -135,4 +135,4 @@ + FILE "urdfdomExport.cmake" + ) + +-INSTALL(DIRECTORY include/urdf_parser DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) ++INSTALL(DIRECTORY include/ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) diff --git a/recipes/urdfdom/all/test_package/CMakeLists.txt b/recipes/urdfdom/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..2d7a881934a294 --- /dev/null +++ b/recipes/urdfdom/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) + +find_package(urdfdom REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE urdfdom::urdfdom) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/urdfdom/all/test_package/conanfile.py b/recipes/urdfdom/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/urdfdom/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/urdfdom/all/test_package/test_package.cpp b/recipes/urdfdom/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..a7e4a0d704e359 --- /dev/null +++ b/recipes/urdfdom/all/test_package/test_package.cpp @@ -0,0 +1,15 @@ +#include +#include +#include + +#include + +int main() { + std::string test_str = + "" + " " + ""; + urdf::ModelInterfaceSharedPtr urdf = urdf::parseURDF(test_str); + std::cout << "urdf::parseURDF() ran successfully" << std::endl; + return EXIT_SUCCESS; +} diff --git a/recipes/urdfdom/config.yml b/recipes/urdfdom/config.yml new file mode 100644 index 00000000000000..fd9669719a7ade --- /dev/null +++ b/recipes/urdfdom/config.yml @@ -0,0 +1,3 @@ +versions: + "3.1.1": + folder: all From 16b4778098a54accf9428a21e67db6f347d2db1a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 12:25:18 +0300 Subject: [PATCH 0302/1140] (#17998) rtklib: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * rtklib: add recipe * rtklib: add undefined extern functions * rtklib: remove use_iers_tide_model option Disabled by default and would require linking with a precompiled library. * rtklib: simplify defs handling * rtklib: add a comment for the default values * rtklib: remove an unsupported compile flag from Clang * rtklib: add an additional reference for the defaults * rtklib: fix build errors on MacOS * rtklib: add '-undefined dynamic_lookup' ldflags on apple-clang * rtklib: fix Windows builds * rtklib: do not add opt flags for Debug, disable compiler warnings --------- Co-authored-by: Rubén Rincón Blanco --- recipes/rtklib/all/CMakeLists.txt | 38 +++++ recipes/rtklib/all/conandata.yml | 9 ++ recipes/rtklib/all/conanfile.py | 138 ++++++++++++++++++ .../fix-dll-export-of-global-vars.patch | 23 +++ .../rtklib/all/test_package/CMakeLists.txt | 7 + recipes/rtklib/all/test_package/conanfile.py | 27 ++++ .../rtklib/all/test_package/test_package.cpp | 18 +++ recipes/rtklib/config.yml | 3 + 8 files changed, 263 insertions(+) create mode 100644 recipes/rtklib/all/CMakeLists.txt create mode 100644 recipes/rtklib/all/conandata.yml create mode 100644 recipes/rtklib/all/conanfile.py create mode 100644 recipes/rtklib/all/patches/fix-dll-export-of-global-vars.patch create mode 100644 recipes/rtklib/all/test_package/CMakeLists.txt create mode 100644 recipes/rtklib/all/test_package/conanfile.py create mode 100644 recipes/rtklib/all/test_package/test_package.cpp create mode 100644 recipes/rtklib/config.yml diff --git a/recipes/rtklib/all/CMakeLists.txt b/recipes/rtklib/all/CMakeLists.txt new file mode 100644 index 00000000000000..6f87c0e328a597 --- /dev/null +++ b/recipes/rtklib/all/CMakeLists.txt @@ -0,0 +1,38 @@ +# Based largely on https://github.com/tomojitakasu/RTKLIB/blob/v2.4.3-b34/app/consapp/rnx2rtkp/gcc/makefile +cmake_minimum_required(VERSION 3.15) +project(rtklib C) + +if (NOT MSVC) + add_compile_options(-ansi $<$>:-O3>) +# add_compile_options(-Wall -pedantic) +# if (GCC) +# add_compile_options(-Wno-unused-but-set-variable) +# endif() +else() + add_compile_options( /D_CRT_SECURE_NO_WARNINGS $<$>:/O2>) +# add_compile_options(/W4) +endif() + +if (APPLE) + # Allow extern functions (showmsg(), settspan() and settime()) to be found at runtime + set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} -undefined dynamic_lookup") +endif() + +file(GLOB_RECURSE RTKLIB_SOURCES "src/*.c") + +find_package(Threads REQUIRED) + +add_library(rtklib ${RTKLIB_SOURCES}) +target_include_directories(rtklib PUBLIC src) +target_link_libraries(rtklib PUBLIC Threads::Threads) + +if (WIN32) + target_link_libraries(rtklib PRIVATE + ws2_32 # sockets + winmm # timeGetTime() + ) +endif() + +include(GNUInstallDirs) +install(TARGETS rtklib) +install(FILES src/rtklib.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) diff --git a/recipes/rtklib/all/conandata.yml b/recipes/rtklib/all/conandata.yml new file mode 100644 index 00000000000000..7dc67f1d1ed6dc --- /dev/null +++ b/recipes/rtklib/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "2.4.3-b34": + url: "https://github.com/tomojitakasu/RTKLIB/archive/refs/tags/v2.4.3-b34.tar.gz" + sha256: "a9ce13293ef71b028036cb98a114b9bba96bdd439a0aeebca8e9c73156e461cf" +patches: + "2.4.3-b34": + - patch_file: "patches/fix-dll-export-of-global-vars.patch" + patch_description: "Fix missing EXPORT attributes on global variables required for shared Windows builds" + patch_type: "portability" diff --git a/recipes/rtklib/all/conanfile.py b/recipes/rtklib/all/conanfile.py new file mode 100644 index 00000000000000..ea091707cc7ee7 --- /dev/null +++ b/recipes/rtklib/all/conanfile.py @@ -0,0 +1,138 @@ +import os + +from conan import ConanFile +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches + +required_conan_version = ">=1.53.0" + + +class RtklibConan(ConanFile): + name = "rtklib" + description = "Library for standard and precise positioning with GNSS" + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/tomojitakasu/RTKLIB" + topics = ("gnss", "rtk", "ppp", "rinex", "rtcm", "ublox", "novatel", "septentrio") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "trace": [True, False], + "enable_glonass": [True, False], + "enable_qzss": [True, False], + "enable_galileo": [True, False], + "enable_beidou": [True, False], + "enable_irnss": [True, False], + "num_frequencies": ["ANY"], + "num_ext_obs_codes": ["ANY"], + } + default_options = { + "shared": False, + "fPIC": True, + "trace": False, + "enable_glonass": True, + "enable_qzss": True, + "enable_galileo": True, + "enable_beidou": True, + "enable_irnss": True, + "num_frequencies": 5, + "num_ext_obs_codes": 3, + } + + def export_sources(self): + copy(self, "CMakeLists.txt", + src=self.recipe_folder, + dst=os.path.join(self.export_sources_folder, "src")) + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + @property + def _public_defines(self): + # Values used in the public header + # https://github.com/tomojitakasu/RTKLIB/blob/v2.4.3-b34/src/rtklib.h#L6-L15 + # Default values are based on + # https://github.com/tomojitakasu/RTKLIB/blob/v2.4.3-b34/app/consapp/rnx2rtkp/gcc/makefile#L5 + # https://github.com/tomojitakasu/RTKLIB/blob/v2.4.3-b34/app/consapp/convbin/gcc/makefile#L10 + defs = {} + defs["ENAGLO"] = self.options.enable_glonass + defs["ENAQZS"] = self.options.enable_qzss + defs["ENAGAL"] = self.options.enable_galileo + defs["ENACMP"] = self.options.enable_beidou + defs["ENAIRN"] = self.options.enable_irnss + defs["NFREQ"] = str(self.options.num_frequencies) + defs["NEXOBS"] = str(self.options.num_ext_obs_codes) + defs["WIN32"] = self.settings.os == "Windows" + defs["WIN_DLL"] = self.settings.os == "Windows" and self.options.shared + return defs + + def generate(self): + tc = CMakeToolchain(self) + defs = self._public_defines + defs["TRACE"] = self.options.trace + # TODO: add as options and set libraries correctly + defs["LAPACK"] = False + defs["MKL"] = False + # Set default values + defs["SVR_REUSEADDR"] = True # reuse tcp server address + defs["NOCALLOC"] = False # use calloc for zero matrix + defs["CPUTIME_IN_GPST"] = False # cputime operated in gpst + defs["RRCENA"] = False # enable rrc correction + defs["OUTSTAT_AMB"] = False # output ambiguity parameters to solution status + defs["IERS_MODEL"] = False # use IERS tide model + if is_apple_os(self): + # Add baud rates missing from termios.h for stream.c + defs["B460800"] = 460800 + defs["B921600"] = 921600 + for k, v in defs.items(): + if type(v) in (str, int): + tc.preprocessor_definitions[k] = v + elif v: + tc.preprocessor_definitions[k] = "" + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["rtklib"] + + for k, v in self._public_defines.items(): + if type(v) in (str, int): + self.cpp_info.defines.append(f"{k}={v}") + elif v: + self.cpp_info.defines.append(k) + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m", "pthread", "rt"] + elif self.settings.os == "Windows": + self.cpp_info.system_libs = ["ws2_32", "winmm"] diff --git a/recipes/rtklib/all/patches/fix-dll-export-of-global-vars.patch b/recipes/rtklib/all/patches/fix-dll-export-of-global-vars.patch new file mode 100644 index 00000000000000..f52bd22d8d75b6 --- /dev/null +++ b/recipes/rtklib/all/patches/fix-dll-export-of-global-vars.patch @@ -0,0 +1,23 @@ +--- src/rtklib.h ++++ src/rtklib.h +@@ -1293,13 +1293,13 @@ + typedef void fatalfunc_t(const char *); /* fatal callback function type */ + + /* global variables ----------------------------------------------------------*/ +-extern const double chisqr[]; /* chi-sqr(n) table (alpha=0.001) */ +-extern const prcopt_t prcopt_default; /* default positioning options */ +-extern const solopt_t solopt_default; /* default solution output options */ +-extern const sbsigpband_t igpband1[9][8]; /* SBAS IGP band 0-8 */ +-extern const sbsigpband_t igpband2[2][5]; /* SBAS IGP band 9-10 */ +-extern const char *formatstrs[]; /* stream format strings */ +-extern opt_t sysopts[]; /* system options table */ ++EXPORT extern const double chisqr[]; /* chi-sqr(n) table (alpha=0.001) */ ++EXPORT extern const prcopt_t prcopt_default; /* default positioning options */ ++EXPORT extern const solopt_t solopt_default; /* default solution output options */ ++EXPORT extern const sbsigpband_t igpband1[9][8]; /* SBAS IGP band 0-8 */ ++EXPORT extern const sbsigpband_t igpband2[2][5]; /* SBAS IGP band 9-10 */ ++EXPORT extern const char *formatstrs[]; /* stream format strings */ ++EXPORT extern opt_t sysopts[]; /* system options table */ + + /* satellites, systems, codes functions --------------------------------------*/ + EXPORT int satno (int sys, int prn); diff --git a/recipes/rtklib/all/test_package/CMakeLists.txt b/recipes/rtklib/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..326ac56093a5ed --- /dev/null +++ b/recipes/rtklib/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(rtklib REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE rtklib::rtklib) diff --git a/recipes/rtklib/all/test_package/conanfile.py b/recipes/rtklib/all/test_package/conanfile.py new file mode 100644 index 00000000000000..02eb5ce439fb40 --- /dev/null +++ b/recipes/rtklib/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +# It will become the standard on Conan 2.x +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rtklib/all/test_package/test_package.cpp b/recipes/rtklib/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..51c8582d96563a --- /dev/null +++ b/recipes/rtklib/all/test_package/test_package.cpp @@ -0,0 +1,18 @@ +#include +#undef lock + +#include +#include + +// Extern functions meant to be defined by the user +extern int showmsg(const char *format, ...) { return 0; } +extern void settspan(gtime_t ts, gtime_t te) {} +extern void settime(gtime_t time) {} + +int main() { + int week = 0; + double sec = time2gpst(timeget(), &week); + std::cout << "Current GPS time: week " << week << ", " << sec << " seconds of week" + << std::endl; + return EXIT_SUCCESS; +} diff --git a/recipes/rtklib/config.yml b/recipes/rtklib/config.yml new file mode 100644 index 00000000000000..8faa0eba5645fc --- /dev/null +++ b/recipes/rtklib/config.yml @@ -0,0 +1,3 @@ +versions: + "2.4.3-b34": + folder: all From 4cd361e70988b1e3b154f88dacef96f6f912b074 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 12:47:34 +0300 Subject: [PATCH 0303/1140] (#18133) easyloggingpp: migrate to Conan v2 --- recipes/easyloggingpp/all/CMakeLists.txt | 67 --------- recipes/easyloggingpp/all/conanfile.py | 130 ++++++++---------- .../all/test_package/CMakeLists.txt | 5 +- .../all/test_package/conanfile.py | 21 ++- .../all/test_package/test_package.cpp | 7 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ 7 files changed, 106 insertions(+), 149 deletions(-) delete mode 100644 recipes/easyloggingpp/all/CMakeLists.txt create mode 100644 recipes/easyloggingpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/easyloggingpp/all/test_v1_package/conanfile.py diff --git a/recipes/easyloggingpp/all/CMakeLists.txt b/recipes/easyloggingpp/all/CMakeLists.txt deleted file mode 100644 index f6fc5c33e69b07..00000000000000 --- a/recipes/easyloggingpp/all/CMakeLists.txt +++ /dev/null @@ -1,67 +0,0 @@ -cmake_minimum_required(VERSION 3.2) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() -option(enable_crash_log "Enable crash log handler" OFF) -option(enable_thread_safe "Enable thread safety for use in multithreaded env" OFF) -option(enable_debug_errors "Enable debug errors in case of configuration issues" OFF) -option(enable_default_logfile "Enable creation of default logfile" ON) -option(disable_logs "Disables all logs" OFF) -option(disable_debug_logs "Disables debug logs" OFF) -option(disable_info_logs "Disables info logs" OFF) -option(disable_warning_logs "Disables warning logs" OFF) -option(disable_error_logs "Disables error logs" OFF) -option(disable_fatal_logs "Disables fatal logs" OFF) -option(disable_verbose_logs "Disables verbose logs" OFF) -option(disable_trace_logs "Disables trace logs" OFF) - -if (enable_crash_log) - add_definitions(-DELPP_FEATURE_CRASH_LOG) -endif() - -if (enable_thread_safe) - add_definitions(-DELPP_THREAD_SAFE) -endif() - -if (enable_debug_errors) - add_definitions(-DELPP_DEBUG_ERRORS) -endif() - -if (NOT enable_default_logfile) - add_definitions(-DELPP_NO_DEFAULT_LOG_FILE) -endif() - -if (disable_logs) - add_definitions(-DELPP_DISABLE_LOGS) -endif() - -if (disable_debug_logs) - add_definitions(-DELPP_DISABLE_DEBUG_LOGS) -endif() - -if (disable_info_logs) - add_definitions(-DELPP_DISABLE_INFO_LOGS) -endif() - -if (disable_warning_logs) - add_definitions(-DELPP_DISABLE_WARNING_LOGS) -endif() - -if (disable_error_logs) - add_definitions(-DELPP_DISABLE_ERROR_LOGS) -endif() - -if (disable_fatal_logs) - add_definitions(-DELPP_DISABLE_FATAL_LOGS) -endif() - -if (disable_verbose_logs) - add_definitions(-DELPP_DISABLE_VERBOSE_LOGS) -endif() - -if (disable_trace_logs) - add_definitions(-DELPP_DISABLE_TRACE_LOGS) -endif() - -add_subdirectory("source_subfolder") diff --git a/recipes/easyloggingpp/all/conanfile.py b/recipes/easyloggingpp/all/conanfile.py index b5d1f9b44e060d..5410892575c4a7 100644 --- a/recipes/easyloggingpp/all/conanfile.py +++ b/recipes/easyloggingpp/all/conanfile.py @@ -1,21 +1,22 @@ import os -from conans import CMake -from conan.tools import files + from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir, replace_in_file +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.33.0" class EasyloggingppConan(ConanFile): name = "easyloggingpp" - license = "The MIT License (MIT)" - homepage = "https://github.com/amrayn/easyloggingpp" + description = "Single-header C++ logging library." + license = "MIT" url = "https://github.com/conan-io/conan-center-index" - description = "Single header C++ logging library." + homepage = "https://github.com/amrayn/easyloggingpp" topics = ("logging", "stacktrace", "efficient-logging") - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" - exports_sources = "CMakeLists.txt", + + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" options = { "enable_crash_log": [True, False], "enable_thread_safe": [True, False], @@ -28,7 +29,8 @@ class EasyloggingppConan(ConanFile): "disable_error_logs": [True, False], "disable_fatal_logs": [True, False], "disable_verbose_logs": [True, False], - "disable_trace_logs": [True, False] + "disable_trace_logs": [True, False], + "lib_utc_datetime": [True, False], } default_options = { "enable_crash_log": False, @@ -42,80 +44,70 @@ class EasyloggingppConan(ConanFile): "disable_error_logs": False, "disable_fatal_logs": False, "disable_verbose_logs": False, - "disable_trace_logs": False + "disable_trace_logs": False, + "lib_utc_datetime": False, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - def _configure_cmake(self): - if self._cmake is not None: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["build_static_lib"] = True - self._cmake.definitions["enable_crash_log"] = self.options.enable_crash_log - self._cmake.definitions["enable_thread_safe"] = self.options.enable_thread_safe - self._cmake.definitions["enable_debug_errors"] = self.options.enable_debug_errors - self._cmake.definitions["enable_default_logfile"] = self.options.enable_default_logfile - self._cmake.definitions["disable_logs"] = self.options.disable_logs - self._cmake.definitions["disable_debug_logs"] = self.options.disable_debug_logs - self._cmake.definitions["disable_info_logs"] = self.options.disable_info_logs - self._cmake.definitions["disable_warning_logs"] = self.options.disable_warning_logs - self._cmake.definitions["disable_error_logs"] = self.options.disable_error_logs - self._cmake.definitions["disable_fatal_logs"] = self.options.disable_fatal_logs - self._cmake.definitions["disable_verbose_logs"] = self.options.disable_verbose_logs - self._cmake.definitions["disable_trace_logs"] = self.options.disable_trace_logs - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - files.get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def build(self): - cmake = self._configure_cmake() - cmake.build() - - def package(self): - cmake = self._configure_cmake() - cmake.install() - files.rmdir(self, os.path.join(self.package_folder, "share")) - self.copy(pattern="LICENSE", - dst="licenses", - src=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def package_info(self): - self.cpp_info.names["cmake_find_package"] = "easyloggingpp" - self.cpp_info.names["cmake_find_package_multi"] = "easyloggingpp" - self.cpp_info.libs = ["easyloggingpp"] + @property + def _public_defines(self): + defines = [] if self.options.enable_crash_log: - self.cpp_info.defines.append("ELPP_FEATURE_CRASH_LOG") + defines.append("ELPP_FEATURE_CRASH_LOG") if self.options.enable_thread_safe: - self.cpp_info.defines.append("ELPP_THREAD_SAFE") + defines.append("ELPP_THREAD_SAFE") if self.options.enable_debug_errors: - self.cpp_info.defines.append("ELPP_DEBUG_ERRORS") + defines.append("ELPP_DEBUG_ERRORS") if self.options.enable_default_logfile: - self.cpp_info.defines.append("ELPP_NO_DEFAULT_LOG_FILE") + defines.append("ELPP_NO_DEFAULT_LOG_FILE") if self.options.disable_logs: - self.cpp_info.defines.append("ELPP_DISABLE_LOGS") + defines.append("ELPP_DISABLE_LOGS") if self.options.disable_debug_logs: - self.cpp_info.defines.append("ELPP_DISABLE_DEBUG_LOGS") + defines.append("ELPP_DISABLE_DEBUG_LOGS") if self.options.disable_info_logs: - self.cpp_info.defines.append("ELPP_DISABLE_INFO_LOGS") + defines.append("ELPP_DISABLE_INFO_LOGS") if self.options.disable_warning_logs: - self.cpp_info.defines.append("ELPP_DISABLE_WARNING_LOGS") + defines.append("ELPP_DISABLE_WARNING_LOGS") if self.options.disable_error_logs: - self.cpp_info.defines.append("ELPP_DISABLE_ERROR_LOGS") + defines.append("ELPP_DISABLE_ERROR_LOGS") if self.options.disable_fatal_logs: - self.cpp_info.defines.append("ELPP_DISABLE_FATAL_LOGS") + defines.append("ELPP_DISABLE_FATAL_LOGS") if self.options.disable_verbose_logs: - self.cpp_info.defines.append("ELPP_DISABLE_VERBOSE_LOGS") + defines.append("ELPP_DISABLE_VERBOSE_LOGS") if self.options.disable_trace_logs: - self.cpp_info.defines.append("ELPP_DISABLE_TRACE_LOGS") + defines.append("lib_utc_datetime") + if self.options.lib_utc_datetime: + defines.append("ELPP_UTC_DATETIME") + return defines + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["build_static_lib"] = True + for d in self._public_defines: + tc.preprocessor_definitions[d] = "1" + tc.generate() + def _patch_sources(self): + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "set_property(TARGET easyloggingpp PROPERTY POSITION_INDEPENDENT_CODE ON)", "") + + def build(self): + self._patch_sources() + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "share")) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + + def package_info(self): + self.cpp_info.libs = ["easyloggingpp"] + self.cpp_info.defines = self._public_defines diff --git a/recipes/easyloggingpp/all/test_package/CMakeLists.txt b/recipes/easyloggingpp/all/test_package/CMakeLists.txt index e515e14d7e6ada..a353807cafd1f8 100644 --- a/recipes/easyloggingpp/all/test_package/CMakeLists.txt +++ b/recipes/easyloggingpp/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(easyloggingpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/easyloggingpp/all/test_package/conanfile.py b/recipes/easyloggingpp/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/easyloggingpp/all/test_package/conanfile.py +++ b/recipes/easyloggingpp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/easyloggingpp/all/test_package/test_package.cpp b/recipes/easyloggingpp/all/test_package/test_package.cpp index 9f1fc4b8dad349..da48715e9c0a26 100644 --- a/recipes/easyloggingpp/all/test_package/test_package.cpp +++ b/recipes/easyloggingpp/all/test_package/test_package.cpp @@ -10,11 +10,12 @@ void myCrashHandler(int sig) { } #endif -int main() { +int main(int argc, char* argv[]) { + START_EASYLOGGINGPP(argc, argv); LOG(INFO) << "My first info log using default logger"; - #ifdef ELPP_FEATURE_CRASH_LOG +#ifdef ELPP_FEATURE_CRASH_LOG LOG(INFO) << "Installed crash handler"; el::Helpers::setCrashHandler(myCrashHandler); - #endif +#endif return 0; } diff --git a/recipes/easyloggingpp/all/test_v1_package/CMakeLists.txt b/recipes/easyloggingpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/easyloggingpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/easyloggingpp/all/test_v1_package/conanfile.py b/recipes/easyloggingpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/easyloggingpp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b4da1b55601395520df343e62a6bcc82379e0c61 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 13:08:08 +0300 Subject: [PATCH 0304/1140] (#18227) deco: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * deco: migrate to Conan v2 * deco: restore test_v1_package * Update recipes/deco/all/conanfile.py * Update recipes/deco/all/conanfile.py * deco: fix v1 test executable * deco: restore VirtualRunEnv in test_package --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Uilian Ries --- recipes/deco/all/conanfile.py | 90 ++++++++++++------- recipes/deco/all/test_package/CMakeLists.txt | 13 ++- recipes/deco/all/test_package/conanfile.py | 22 +++-- .../{example.cpp => test_package.cpp} | 0 .../deco/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/deco/all/test_v1_package/conanfile.py | 18 ++++ 6 files changed, 104 insertions(+), 47 deletions(-) rename recipes/deco/all/test_package/{example.cpp => test_package.cpp} (100%) create mode 100644 recipes/deco/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/deco/all/test_v1_package/conanfile.py diff --git a/recipes/deco/all/conanfile.py b/recipes/deco/all/conanfile.py index 3760e5bb68e075..29a4d2480e3aaa 100644 --- a/recipes/deco/all/conanfile.py +++ b/recipes/deco/all/conanfile.py @@ -1,56 +1,82 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + + class DecoConan(ConanFile): name = "deco" - license = "Apache-2.0-WITH-LLVM-exception" description = "Delimiter Collision Free Format" - topics = ("serialization") - homepage = "https://github.com/Enhex/Deco" + license = "Apache-2.0-WITH-LLVM-exception" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Enhex/Deco" + topics = ("serialization", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - settings = ("compiler", "build_type", "os", "arch") - requires = ( - "enhex-generic_serialization/1.0.0", - "enhex-strong_type/1.0.0", - "boost/1.79.0", - "rang/3.2", - ) @property - def _source_subfolder(self): - return "source_subfolder" - - def validate(self): - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) + def _min_cppstd(self): + return 17 - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "Visual Studio": "15", + "msvc": "191", "gcc": "7", "clang": "5.0", - "apple-clang": "9.1" + "apple-clang": "9.1", } + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("enhex-generic_serialization/1.0.0") + self.requires("enhex-strong_type/1.0.0") + self.requires("boost/1.82.0") + self.requires("rang/3.2") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + compiler = str(self.settings.compiler) - compiler_version = tools.Version(self.settings.compiler.version) + compiler_version = Version(self.settings.compiler.version) - if compiler not in minimal_version: - self.output.info("{} requires a compiler that supports at least C++17".format(self.name)) + if compiler not in self._compilers_minimum_version: + self.output.info(f"{self.name} requires a compiler that supports at least C++17") return # Exclude compilers not supported - if compiler_version < minimal_version[compiler]: - raise ConanInvalidConfiguration("{} requires a compiler that supports at least C++17. {} {} is not".format( - self.name, compiler, tools.Version(self.settings.compiler.version.value))) + if compiler_version < self._compilers_minimum_version[compiler]: + raise ConanInvalidConfiguration( + f"{self.name} requires a compiler that supports at least C++17. " + f"{compiler} {Version(self.settings.compiler.version.value)} is not" + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE.txt", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/deco/all/test_package/CMakeLists.txt b/recipes/deco/all/test_package/CMakeLists.txt index 00c3587be1a635..c3b92714405e83 100644 --- a/recipes/deco/all/test_package/CMakeLists.txt +++ b/recipes/deco/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(PackageTest CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) find_package(deco CONFIG REQUIRED) -add_executable(example example.cpp) -target_link_libraries(example deco::deco) -set_target_properties(example PROPERTIES CXX_STANDARD 17) +add_executable(test_package test_package.cpp) +target_link_libraries(test_package deco::deco) +set_target_properties(test_package PROPERTIES CXX_STANDARD 17) diff --git a/recipes/deco/all/test_package/conanfile.py b/recipes/deco/all/test_package/conanfile.py index f735734fbcfa9b..ef5d7042163ecc 100644 --- a/recipes/deco/all/test_package/conanfile.py +++ b/recipes/deco/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class DecoTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/deco/all/test_package/example.cpp b/recipes/deco/all/test_package/test_package.cpp similarity index 100% rename from recipes/deco/all/test_package/example.cpp rename to recipes/deco/all/test_package/test_package.cpp diff --git a/recipes/deco/all/test_v1_package/CMakeLists.txt b/recipes/deco/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/deco/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/deco/all/test_v1_package/conanfile.py b/recipes/deco/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..f64055b093b4d3 --- /dev/null +++ b/recipes/deco/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class DecoTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b4e9798893e8f6b217cf3e962e94d4f082da0db7 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 13:28:13 +0300 Subject: [PATCH 0305/1140] (#18232) nfrechette-acl: migrate to Conan v2 * nfrechette-acl: migrate to Conan v2 * nfrechette-acl: restore test_v1_package * nfrechette-acl: add cmake_find_package_multi generator to test_v1_package * nfrechette-acl: drop older versions * nfrechette-acl: restore VirtualRunEnv in test_package --- recipes/nfrechette-acl/all/conandata.yml | 12 ---- recipes/nfrechette-acl/all/conanfile.py | 65 ++++++++++++------- .../all/test_package/CMakeLists.txt | 9 ++- .../all/test_package/conanfile.py | 22 +++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 18 +++++ recipes/nfrechette-acl/config.yml | 8 --- 7 files changed, 85 insertions(+), 57 deletions(-) create mode 100644 recipes/nfrechette-acl/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/nfrechette-acl/all/test_v1_package/conanfile.py diff --git a/recipes/nfrechette-acl/all/conandata.yml b/recipes/nfrechette-acl/all/conandata.yml index 0c2e8a5978fd09..dca5b638ad1dc2 100644 --- a/recipes/nfrechette-acl/all/conandata.yml +++ b/recipes/nfrechette-acl/all/conandata.yml @@ -2,18 +2,6 @@ sources: "1.3.5": url: "https://github.com/nfrechette/acl/archive/v1.3.5.tar.gz" sha256: "06112ad5dc6b586124cc7b22ff6979ea1de9b69abefcd94d43556e20617355a1" - "2.0.0": - url: "https://github.com/nfrechette/acl/archive/v2.0.0.tar.gz" - sha256: "c5b44c063efbee6fb5753d0070e37215162d5d47f047fa033024750d9dbb6cdc" - "2.0.1": - url: "https://github.com/nfrechette/acl/archive/v2.0.1.tar.gz" - sha256: "aeab843b03ba15edd886472d96cdbe06e7c7142a0d54f0bf08a4f30693b9dad7" - "2.0.2": - url: "https://github.com/nfrechette/acl/archive/v2.0.2.tar.gz" - sha256: "d91c7942b4cbc6e8123a9964c1a68eec2778c75dc741c10ea9fede382d831649" - "2.0.3": - url: "https://github.com/nfrechette/acl/archive/v2.0.3.tar.gz" - sha256: "2cc0a6fd8f74ba7fee9177f6b7794bfdc22a27f5b00aa684ba52d60f0f8b3460" "2.0.5": url: "https://github.com/nfrechette/acl/archive/v2.0.5.tar.gz" sha256: "edd255a3ffcdb102b960922069d1ec9ae5fed561bca3bb6ee73224562f76fa36" diff --git a/recipes/nfrechette-acl/all/conanfile.py b/recipes/nfrechette-acl/all/conanfile.py index 23d68bbd569f4d..4a590b12eb34ec 100644 --- a/recipes/nfrechette-acl/all/conanfile.py +++ b/recipes/nfrechette-acl/all/conanfile.py @@ -1,44 +1,59 @@ import os + from conan import ConanFile -from conan.tools.files import rename, get -from conans import tools -from conans.errors import ConanInvalidConfiguration +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class AclConan(ConanFile): name = "nfrechette-acl" description = "Animation Compression Library" - topics = ("animation", "compression") license = "MIT" - homepage = "https://github.com/nfrechette/acl" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/nfrechette/acl" + topics = ("animation", "compression", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - settings = "compiler" @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 - def requirements(self): - self.requires("rtm/2.1.4") + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) - def configure(self): - minimal_cpp_standard = "11" - if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, minimal_cpp_standard) + if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "5": + raise ConanInvalidConfiguration( + f"acl can't be compiled by {self.settings.compiler} {self.settings.compiler.version}") - if self.settings.compiler == "gcc" and tools.Version(self.settings.compiler.version) < "5": - raise ConanInvalidConfiguration("acl can't be compiled by {0} {1}".format(self.settings.compiler, - self.settings.compiler.version)) + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("rtm/2.1.5") + + def package_id(self): + self.info.clear() def source(self): - get(self, **self.conan_data["sources"][self.version]) - extracted_dir = "acl-" + self.version - rename(self, extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.h", dst="include", src=os.path.join(self._source_subfolder, "includes")) - - def package_id(self): - self.info.header_only() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "includes")) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/nfrechette-acl/all/test_package/CMakeLists.txt b/recipes/nfrechette-acl/all/test_package/CMakeLists.txt index 33ae887aa6aea3..da2314ef0ec2be 100644 --- a/recipes/nfrechette-acl/all/test_package/CMakeLists.txt +++ b/recipes/nfrechette-acl/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(nfrechette-acl REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE nfrechette-acl::nfrechette-acl) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/nfrechette-acl/all/test_package/conanfile.py b/recipes/nfrechette-acl/all/test_package/conanfile.py index efea4352797165..ef5d7042163ecc 100644 --- a/recipes/nfrechette-acl/all/test_package/conanfile.py +++ b/recipes/nfrechette-acl/all/test_package/conanfile.py @@ -1,11 +1,19 @@ -import os from conan import ConanFile -from conans import CMake, tools +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/nfrechette-acl/all/test_v1_package/CMakeLists.txt b/recipes/nfrechette-acl/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/nfrechette-acl/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/nfrechette-acl/all/test_v1_package/conanfile.py b/recipes/nfrechette-acl/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49ba777923b404 --- /dev/null +++ b/recipes/nfrechette-acl/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os +from conan import ConanFile +from conans import CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/nfrechette-acl/config.yml b/recipes/nfrechette-acl/config.yml index cf68d13e1c6982..00fcf380290718 100644 --- a/recipes/nfrechette-acl/config.yml +++ b/recipes/nfrechette-acl/config.yml @@ -1,14 +1,6 @@ versions: "1.3.5": folder: "all" - "2.0.0": - folder: "all" - "2.0.1": - folder: "all" - "2.0.2": - folder: "all" - "2.0.3": - folder: "all" "2.0.5": folder: "all" "2.0.6": From 963bb7fe1914792d7e4796c68b5d82666b9355b1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 14:27:51 +0300 Subject: [PATCH 0306/1140] (#18257) cpp_project_framework: migrate to Conan v2 * cpp_project_framework: migrate to Conan v2 * cpp_project_framework: restore test_v1_package * cpp_project_framework: add cmake_find_package_multi generator to test_v1_package * cpp_project_framework: fix gtest dependency in test_package * cpp_project_framework: restore VirtualRunEnv in test_package --- .../cpp_project_framework/all/conanfile.py | 66 ++++++++++++------- .../all/test_package/CMakeLists.txt | 14 ++-- .../all/test_package/conanfile.py | 25 ++++--- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 20 ++++++ 5 files changed, 90 insertions(+), 43 deletions(-) create mode 100644 recipes/cpp_project_framework/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cpp_project_framework/all/test_v1_package/conanfile.py diff --git a/recipes/cpp_project_framework/all/conanfile.py b/recipes/cpp_project_framework/all/conanfile.py index 5a2a5fe5679e4b..00ce6a88bd9212 100644 --- a/recipes/cpp_project_framework/all/conanfile.py +++ b/recipes/cpp_project_framework/all/conanfile.py @@ -1,24 +1,26 @@ +import os + from conan import ConanFile -from conan.tools.files import get +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout from conan.tools.scm import Version -from conans.errors import ConanInvalidConfiguration -from conans.tools import check_min_cppstd -import os -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.52.0" class CppProjectFrameworkConan(ConanFile): name = "cpp_project_framework" + description = "C++ Project Framework is a framework for creating C++ projects." license = "AGPL-3.0" + url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/sheepgrass/cpp_project_framework" - url = "https://github.com/conan-io/conan-center-index" # Package recipe repository url here, for issues about the package - description = "C++ Project Framework is a framework for creating C++ project." - topics = ("cpp", "project", "framework") - settings = "os", "compiler", "build_type", "arch" + topics = ("cpp", "project", "framework", "header-only") - def package_id(self): - self.info.header_only() + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _minimum_cpp_standard(self): @@ -28,38 +30,52 @@ def _minimum_cpp_standard(self): def _minimum_compilers_version(self): return { "Visual Studio": "16", + "msvc": "192", "gcc": "7", "clang": "6", "apple-clang": "10", } + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + def validate(self): - if self.settings.os not in ('Linux', 'Windows'): - raise ConanInvalidConfiguration(f"{self.name} is just supported for Linux and Windows") + if self.settings.os not in ("Linux", "FreeBSD", "Windows"): + raise ConanInvalidConfiguration(f"{self.name} is only supported on Linux and Windows") compiler = self.settings.compiler if compiler.get_safe("cppstd"): check_min_cppstd(self, self._minimum_cpp_standard) - if compiler in ('gcc', 'clang'): - if compiler.get_safe("libcxx") != "libstdc++": - raise ConanInvalidConfiguration(f"only supported {compiler} with libstdc++") + if compiler in ("gcc", "clang"): + if not compiler.get_safe("libcxx", "").startswith("libstdc++"): + raise ConanInvalidConfiguration(f"{self.name} is only supported {compiler} with libstdc++") min_version = self._minimum_compilers_version.get(str(compiler)) if not min_version: - self.output.warn(f"{self.name} recipe lacks information about the {compiler} compiler support.") + self.output.warning(f"{self.name} recipe lacks information about the {compiler} compiler support.") else: if Version(compiler.version) < min_version: - raise ConanInvalidConfiguration(f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler {compiler} {compiler.version} does not support it.") - - @property - def _source_subfolder(self): - return "source_subfolder" + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._minimum_cpp_standard} support. " + f"The current compiler {compiler} {compiler.version} does not support it." + ) def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.h", dst=os.path.join("include", self.name), src=os.path.join(self._source_subfolder, self.name)) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include", self.name), + src=os.path.join(self.source_folder, self.name)) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/cpp_project_framework/all/test_package/CMakeLists.txt b/recipes/cpp_project_framework/all/test_package/CMakeLists.txt index d3c22a987a39d2..9edc8bb602af7d 100644 --- a/recipes/cpp_project_framework/all/test_package/CMakeLists.txt +++ b/recipes/cpp_project_framework/all/test_package/CMakeLists.txt @@ -1,18 +1,14 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) set(CMAKE_CXX_STANDARD 14) set(CMAKE_CXX_STANDARD_REQUIRED True) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(cpp_project_framework REQUIRED) -find_package(GTest REQUIRED) +find_package(cpp_project_framework REQUIRED CONFIG) +find_package(GTest REQUIRED CONFIG) add_executable(test_package test_package.cpp) +target_link_libraries(test_package PRIVATE cpp_project_framework::cpp_project_framework GTest::gtest GTest::gtest_main) if(UNIX) - target_link_libraries(test_package cpp_project_framework::cpp_project_framework GTest::gtest GTest::gtest_main stdc++fs) -else() - target_link_libraries(test_package cpp_project_framework::cpp_project_framework GTest::gtest GTest::gtest_main) + target_link_libraries(test_package PRIVATE stdc++fs) endif() diff --git a/recipes/cpp_project_framework/all/test_package/conanfile.py b/recipes/cpp_project_framework/all/test_package/conanfile.py index ed8a4e73713c64..c31dc0dd89d148 100644 --- a/recipes/cpp_project_framework/all/test_package/conanfile.py +++ b/recipes/cpp_project_framework/all/test_package/conanfile.py @@ -1,13 +1,20 @@ from conan import ConanFile -from conan.tools.build import cross_building -from conans import CMake +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class CppProjectFrameworkTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" - requires = "gtest/1.10.0" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + self.requires("gtest/1.13.0") + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -15,6 +22,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cpp_project_framework/all/test_v1_package/CMakeLists.txt b/recipes/cpp_project_framework/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cpp_project_framework/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cpp_project_framework/all/test_v1_package/conanfile.py b/recipes/cpp_project_framework/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..0761aa549fc918 --- /dev/null +++ b/recipes/cpp_project_framework/all/test_v1_package/conanfile.py @@ -0,0 +1,20 @@ +from conan import ConanFile +from conan.tools.build import cross_building +from conans import CMake +import os + + +class CppProjectFrameworkTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + requires = "gtest/1.13.0" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 853fe51f2ae2139cafa24aec91696eb20540a41b Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 20:50:54 +0900 Subject: [PATCH 0307/1140] (#18277) pbtools: add version 0.47.0, support conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * pbtools: add version 0.47.0, support conan v2 * disable C++ feature --------- Co-authored-by: Rubén Rincón Blanco --- recipes/pbtools/all/conandata.yml | 5 ++++- recipes/pbtools/all/conanfile.py | 10 +++++++--- recipes/pbtools/all/test_package/CMakeLists.txt | 7 ++++--- recipes/pbtools/config.yml | 2 ++ 4 files changed, 17 insertions(+), 7 deletions(-) diff --git a/recipes/pbtools/all/conandata.yml b/recipes/pbtools/all/conandata.yml index 529d052902f815..236ef4b15fa0a8 100644 --- a/recipes/pbtools/all/conandata.yml +++ b/recipes/pbtools/all/conandata.yml @@ -1,7 +1,10 @@ sources: + "0.47.0": + url: "https://github.com/eerimoq/pbtools/archive/0.47.0.tar.gz" + sha256: "f53189ad061e4063d7cb5a3863f778221868b820a1dde4e65b217537c3fa0c9e" "0.45.2": url: "https://github.com/eerimoq/pbtools/archive/0.45.2.tar.gz" sha256: "723967fff6e1d51a078ce7328f937cafe0c32b4e9ab19735cf591d15afc281d3" "0.45.0": url: "https://github.com/eerimoq/pbtools/archive/refs/tags/0.45.0.zip" - sha256: 84b17003f1c7b6c62061e93e11abe8729480338f5f106948ebfefa303c163b75 + sha256: "84b17003f1c7b6c62061e93e11abe8729480338f5f106948ebfefa303c163b75" diff --git a/recipes/pbtools/all/conanfile.py b/recipes/pbtools/all/conanfile.py index 98670e16a72dc7..8ae53d392140af 100644 --- a/recipes/pbtools/all/conanfile.py +++ b/recipes/pbtools/all/conanfile.py @@ -5,6 +5,7 @@ from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import copy, get + required_conan_version = ">=1.53.0" @@ -15,7 +16,6 @@ class PbtoolsConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/eerimoq/pbtools" topics = ("protobuf", "serialization", "rpc", "protocol-buffers") - package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -27,6 +27,10 @@ class PbtoolsConan(ConanFile): "fPIC": True, } + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + def configure(self): if self.options.shared: self.options.rm_safe("fPIC") @@ -36,7 +40,7 @@ def layout(self): def validate(self): if self.settings.os == "Windows": - raise ConanInvalidConfiguration("This library is not compatible with Windows") + raise ConanInvalidConfiguration(f"{self.ref} is not compatible with Windows") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -47,7 +51,7 @@ def generate(self): def build(self): cmake = CMake(self) - cmake.configure(build_script_folder="lib") + cmake.configure(build_script_folder=os.path.join(self.source_folder, "lib")) cmake.build() def package(self): diff --git a/recipes/pbtools/all/test_package/CMakeLists.txt b/recipes/pbtools/all/test_package/CMakeLists.txt index cd447f6cc0d278..e01a140f079aa0 100644 --- a/recipes/pbtools/all/test_package/CMakeLists.txt +++ b/recipes/pbtools/all/test_package/CMakeLists.txt @@ -1,7 +1,8 @@ cmake_minimum_required(VERSION 3.15) -project(PackageTest C) +project(test_package LANGUAGES C) + find_package(pbtools REQUIRED CONFIG) -add_executable(test_package test_package.c hello_world.c) -target_link_libraries(test_package pbtools::pbtools) +add_executable(${PROJECT_NAME} test_package.c hello_world.c) +target_link_libraries(${PROJECT_NAME} PRIVATE pbtools::pbtools) diff --git a/recipes/pbtools/config.yml b/recipes/pbtools/config.yml index 81c0b9ecee392a..06df1f3ce62324 100644 --- a/recipes/pbtools/config.yml +++ b/recipes/pbtools/config.yml @@ -1,4 +1,6 @@ versions: + "0.47.0": + folder: "all" "0.45.2": folder: "all" "0.45.0": From a07b155328bf92ff6e1c0cb72eacb120152a6022 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 21:25:42 +0900 Subject: [PATCH 0308/1140] (#18408) clipper2: add recipe * clipper2: add recipe * support conan v1 * fix install * enable CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS * link math lib --------- Co-authored-by: Carlos Zoido --- recipes/clipper2/all/conandata.yml | 9 ++ recipes/clipper2/all/conanfile.py | 107 ++++++++++++++++++ .../all/patches/1.2.2-0001-fix-install.patch | 14 +++ .../clipper2/all/test_package/CMakeLists.txt | 17 +++ .../clipper2/all/test_package/conanfile.py | 35 ++++++ .../all/test_package/test_package.cpp | 45 ++++++++ .../all/test_package/test_package_z.cpp | 46 ++++++++ recipes/clipper2/config.yml | 3 + 8 files changed, 276 insertions(+) create mode 100644 recipes/clipper2/all/conandata.yml create mode 100644 recipes/clipper2/all/conanfile.py create mode 100644 recipes/clipper2/all/patches/1.2.2-0001-fix-install.patch create mode 100644 recipes/clipper2/all/test_package/CMakeLists.txt create mode 100644 recipes/clipper2/all/test_package/conanfile.py create mode 100644 recipes/clipper2/all/test_package/test_package.cpp create mode 100644 recipes/clipper2/all/test_package/test_package_z.cpp create mode 100644 recipes/clipper2/config.yml diff --git a/recipes/clipper2/all/conandata.yml b/recipes/clipper2/all/conandata.yml new file mode 100644 index 00000000000000..a80a428924ce35 --- /dev/null +++ b/recipes/clipper2/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "1.2.2": + url: "https://github.com/AngusJohnson/Clipper2/files/11071418/Clipper2_1.2.2.zip" + sha256: "ec28bc4e05a86cb0be81a872e8d90a4d575b63882ef3ac78f06662358e410f89" +patches: + "1.2.2": + - patch_file: "patches/1.2.2-0001-fix-install.patch" + patch_description: "fix install for windows shared build" + patch_type: "portability" diff --git a/recipes/clipper2/all/conanfile.py b/recipes/clipper2/all/conanfile.py new file mode 100644 index 00000000000000..688144f7992cd0 --- /dev/null +++ b/recipes/clipper2/all/conanfile.py @@ -0,0 +1,107 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import get, copy, rmdir, export_conandata_patches, apply_conandata_patches +from conan.tools.build import check_min_cppstd +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +import os + +required_conan_version = ">=1.53.0" + +class Clipper2Conan(ConanFile): + name = "clipper2" + description = " A Polygon Clipping and Offsetting library in C++" + license = "BSL-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/AngusJohnson/Clipper2" + topics = ("geometry", "polygon", "clipping") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "usingz": ["ON", "OFF", "ONLY"], + } + default_options = { + "shared": False, + "fPIC": True, + "usingz": "ON", + } + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.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]) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True + tc.variables["CLIPPER2_UTILS"] = False + tc.variables["CLIPPER2_EXAMPLES"] = False + tc.variables["CLIPPER2_TESTS"] = False + tc.variables["CLIPPER2_USINGZ"] = self.options.usingz + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, "CPP")) + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + if self.options.usingz != "ONLY": + self.cpp_info.components["clipper2"].set_property("cmake_target_name", "Clipper2::clipper2") + self.cpp_info.components["clipper2"].set_property("pkg_config_name", "Clipper2") + self.cpp_info.components["clipper2"].libs = ["Clipper2"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["clipper2"].system_libs.append("m") + + if self.options.usingz != "OFF": + self.cpp_info.components["clipper2z"].set_property("cmake_target_name", "Clipper2::clipper2z") + self.cpp_info.components["clipper2z"].set_property("pkg_config_name", "Clipper2Z") + self.cpp_info.components["clipper2z"].libs = ["Clipper2Z"] + self.cpp_info.components["clipper2z"].defines.append("USINGZ") + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["clipper2z"].system_libs.append("m") diff --git a/recipes/clipper2/all/patches/1.2.2-0001-fix-install.patch b/recipes/clipper2/all/patches/1.2.2-0001-fix-install.patch new file mode 100644 index 00000000000000..4f4848313e0763 --- /dev/null +++ b/recipes/clipper2/all/patches/1.2.2-0001-fix-install.patch @@ -0,0 +1,14 @@ +diff --git a/CPP/CMakeLists.txt b/CPP/CMakeLists.txt +index 58b41c2..cd2f96b 100644 +--- a/CPP/CMakeLists.txt ++++ b/CPP/CMakeLists.txt +@@ -245,6 +245,9 @@ endforeach() + + install(TARGETS ${CLIPPER2_LIBS} + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/clipper2 ++ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} ++ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} ++ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + ) + install(FILES ${CLIPPER2_PCFILES} DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + diff --git a/recipes/clipper2/all/test_package/CMakeLists.txt b/recipes/clipper2/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..6b344661830838 --- /dev/null +++ b/recipes/clipper2/all/test_package/CMakeLists.txt @@ -0,0 +1,17 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(clipper2 REQUIRED CONFIG) + +if(TARGET Clipper2::clipper2) + add_executable(${PROJECT_NAME} test_package.cpp) + target_link_libraries(${PROJECT_NAME} PRIVATE Clipper2::clipper2) + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +endif() + +if(TARGET Clipper2::clipper2z) + add_executable(${PROJECT_NAME}_z test_package_z.cpp) + target_link_libraries(${PROJECT_NAME}_z PRIVATE Clipper2::clipper2z) + target_compile_features(${PROJECT_NAME}_z PRIVATE cxx_std_17) +endif() + diff --git a/recipes/clipper2/all/test_package/conanfile.py b/recipes/clipper2/all/test_package/conanfile.py new file mode 100644 index 00000000000000..87531c64cc6a25 --- /dev/null +++ b/recipes/clipper2/all/test_package/conanfile.py @@ -0,0 +1,35 @@ +from conan import ConanFile, conan_version +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + if conan_version.major >= 2: + usingz = self.dependencies["clipper2"].options.usingz + else: + usingz = self.options["clipper2"].usingz + + if usingz != "ONLY": + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") + if usingz != "OFF": + bin_path = os.path.join(self.cpp.build.bindir, "test_package_z") + self.run(bin_path, env="conanrun") diff --git a/recipes/clipper2/all/test_package/test_package.cpp b/recipes/clipper2/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..f8b893dade24d6 --- /dev/null +++ b/recipes/clipper2/all/test_package/test_package.cpp @@ -0,0 +1,45 @@ +#include +#include + +#include "clipper2/clipper.h" + +using namespace Clipper2Lib; + +void DoSimpleTest(bool show_solution_coords = false); +Path64 MakeRandomPoly(int width, int height, unsigned vertCnt); + +int main() +{ + DoSimpleTest(); +} + +inline Path64 MakeStar(const Point64& center, int radius, int points) +{ + if (!(points % 2)) --points; + if (points < 5) points = 5; + Path64 tmp = Ellipse(center, radius, radius, points); + Path64 result; + result.reserve(points); + result.push_back(tmp[0]); + for (int i = points - 1, j = i / 2; j;) + { + result.push_back(tmp[j--]); + result.push_back(tmp[i--]); + } + return result; +} + +void DoSimpleTest(bool show_solution_coords) +{ + Paths64 tmp, solution; + FillRule fr = FillRule::NonZero; + + Paths64 subject, clip; + subject.push_back(MakeStar(Point64(225, 225), 220, 9)); + clip.push_back(Ellipse(Point64(225,225), 150, 150)); + + //Intersect both shapes and then 'inflate' result -10 (ie deflate) + solution = Intersect(subject, clip, fr); + solution = InflatePaths(solution, -10, JoinType::Round, EndType::Polygon); +} + diff --git a/recipes/clipper2/all/test_package/test_package_z.cpp b/recipes/clipper2/all/test_package/test_package_z.cpp new file mode 100644 index 00000000000000..3713bf124619af --- /dev/null +++ b/recipes/clipper2/all/test_package/test_package_z.cpp @@ -0,0 +1,46 @@ +#include +#include "clipper2/clipper.h" + +using namespace std; +using namespace Clipper2Lib; + +void TestingZ_Double(); + +// use the Z callback to flag intersections by setting z = 1; + +class MyClass { +public: + + // Point64 callback - see TestingZ_Int64() + void myZCB(const Point64& e1bot, const Point64& e1top, + const Point64& e2bot, const Point64& e2top, Point64& pt) + { + pt.z = 1; + } + + // PointD callback - see TestingZ_Double() + void myZCBD(const PointD& e1bot, const PointD& e1top, + const PointD& e2bot, const PointD& e2top, PointD& pt) + { + pt.z = 1; + } +}; + +int main(int argc, char* argv[]) +{ + TestingZ_Double(); +} +void TestingZ_Double() +{ + PathsD subject, solution; + MyClass mc; + ClipperD c; + + subject.push_back(MakePathD({ 100, 50, 10, 79, 65, 2, 65, 98, 10, 21 })); + c.AddSubject(subject); + c.SetZCallback( + std::bind(&MyClass::myZCBD, mc, std::placeholders::_1, + std::placeholders::_2, std::placeholders::_3, + std::placeholders::_4, std::placeholders::_5)); + c.Execute(ClipType::Union, FillRule::NonZero, solution); +} diff --git a/recipes/clipper2/config.yml b/recipes/clipper2/config.yml new file mode 100644 index 00000000000000..af40d9653a3783 --- /dev/null +++ b/recipes/clipper2/config.yml @@ -0,0 +1,3 @@ +versions: + "1.2.2": + folder: all From be941c5e0c4f66303965931ccacba8e7add702ee Mon Sep 17 00:00:00 2001 From: Marian Klymov Date: Sat, 19 Aug 2023 16:04:32 +0300 Subject: [PATCH 0309/1140] (#17957) gdcm: use charls from conan instead of internal one * gdcm: use charls from conan * gdcm: cosmetic change for test_package * gdcm: suppress warning about deprecated method usage * gdcm: suppress deprecation warning from OpenSSL 3.0 * charls requires at least C++14 * Update charls to 2.4.2 --- recipes/gdcm/all/conandata.yml | 15 +++++--- recipes/gdcm/all/conanfile.py | 18 ++++++--- .../all/patches/0001-3.0.20-find-charls.patch | 28 ++++++++++++++ .../all/patches/0001-3.0.9-find-charls.patch | 28 ++++++++++++++ .../all/patches/0001-charls-linking.patch | 38 ------------------- recipes/gdcm/all/test_package/CMakeLists.txt | 2 +- recipes/gdcm/all/test_package/conanfile.py | 2 +- .../gdcm/all/test_v1_package/CMakeLists.txt | 2 +- 8 files changed, 81 insertions(+), 52 deletions(-) create mode 100644 recipes/gdcm/all/patches/0001-3.0.20-find-charls.patch create mode 100644 recipes/gdcm/all/patches/0001-3.0.9-find-charls.patch delete mode 100644 recipes/gdcm/all/patches/0001-charls-linking.patch diff --git a/recipes/gdcm/all/conandata.yml b/recipes/gdcm/all/conandata.yml index 330dc8dd2483cb..2a53250fc718cd 100644 --- a/recipes/gdcm/all/conandata.yml +++ b/recipes/gdcm/all/conandata.yml @@ -10,9 +10,10 @@ sources: sha256: "1d518b0e4709cecfb7330c9bd9b3a73cfd01ffe70d1c178f36a4c847283c4672" patches: "3.0.21": - - patch_file: "patches/0001-charls-linking.patch" - patch_description: "fix symbol export for gdcmcharls" + - patch_file: "patches/0001-3.0.20-find-charls.patch" + patch_description: "allow using charls >= 2.2.0" patch_type: "portability" + patch_source: "https://github.com/malaterre/GDCM/pull/157" - patch_file: "patches/0002-3.0.20-openjpeg.patch" patch_description: "fix variable names for openjpeg" patch_type: "conan" @@ -32,9 +33,10 @@ patches: patch_description: "fix find_package for libuuid" patch_type: "conan" "3.0.20": - - patch_file: "patches/0001-charls-linking.patch" - patch_description: "fix symbol export for gdcmcharls" + - patch_file: "patches/0001-3.0.20-find-charls.patch" + patch_description: "allow using charls >= 2.2.0" patch_type: "portability" + patch_source: "https://github.com/malaterre/GDCM/pull/157" - patch_file: "patches/0002-3.0.20-openjpeg.patch" patch_description: "fix variable names for openjpeg" patch_type: "conan" @@ -54,9 +56,10 @@ patches: patch_description: "fix find_package for libuuid" patch_type: "conan" "3.0.9": - - patch_file: "patches/0001-charls-linking.patch" - patch_description: "fix symbol export for gdcmcharls" + - patch_file: "patches/0001-3.0.9-find-charls.patch" + patch_description: "allow using charls >= 2.2.0" patch_type: "portability" + patch_source: "https://github.com/malaterre/GDCM/pull/157" - patch_file: "patches/0002-3.0.9-openjpeg.patch" patch_description: "fix variable names for openjpeg" patch_type: "conan" diff --git a/recipes/gdcm/all/conanfile.py b/recipes/gdcm/all/conanfile.py index 8a628f7457e273..bccb6132bf5678 100644 --- a/recipes/gdcm/all/conanfile.py +++ b/recipes/gdcm/all/conanfile.py @@ -39,7 +39,7 @@ class GDCMConan(ConanFile): @property def _min_cppstd(self): - return 11 + return 14 def export_sources(self): export_conandata_patches(self) @@ -56,6 +56,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): + self.requires("charls/2.4.2") self.requires("expat/2.5.0") self.requires("openjpeg/2.5.0") if self.options.with_zlibng: @@ -89,6 +90,7 @@ def generate(self): tc.variables["GDCM_BUILD_DOCBOOK_MANPAGES"] = False tc.variables["GDCM_BUILD_SHARED_LIBS"] = bool(self.options.shared) # FIXME: unvendor deps https://github.com/conan-io/conan-center-index/pull/5705#discussion_r647224146 + tc.variables["GDCM_USE_SYSTEM_CHARLS"] = True tc.variables["GDCM_USE_SYSTEM_EXPAT"] = True tc.variables["GDCM_USE_SYSTEM_JSON"] = self.options.with_json tc.variables["GDCM_USE_SYSTEM_OPENJPEG"] = True @@ -98,6 +100,13 @@ def generate(self): if not valid_min_cppstd(self, self._min_cppstd): tc.variables["CMAKE_CXX_STANDARD"] = self._min_cppstd + + # https://sourceforge.net/p/gdcm/bugs/548/ + tc.preprocessor_definitions["CHARLS_NO_DEPRECATED_WARNING"] = "1" + + #gdcm currently uses functionality that is deprecated since OpenSSL 3.0 + tc.preprocessor_definitions["OPENSSL_API_COMPAT"] = "0x10101000L" + tc.generate() deps = CMakeDeps(self) deps.generate() @@ -194,8 +203,7 @@ def _gdcm_build_modules(self): @property def _gdcm_libraries(self): - gdcm_libs = ["gdcmcharls", - "gdcmCommon", + gdcm_libs = ["gdcmCommon", "gdcmDICT", "gdcmDSED", "gdcmIOD", @@ -237,7 +245,7 @@ def zlib(): self.cpp_info.components["gdcmDSED"].requires.extend(["gdcmCommon", zlib()]) self.cpp_info.components["gdcmIOD"].requires.extend(["gdcmDSED", "gdcmCommon", "expat::expat"]) - self.cpp_info.components["gdcmMSFF"].requires.extend(["gdcmIOD", "gdcmDSED", "gdcmDICT", "openjpeg::openjpeg"]) + self.cpp_info.components["gdcmMSFF"].requires.extend(["gdcmIOD", "gdcmDSED", "gdcmDICT", "charls::charls", "openjpeg::openjpeg"]) if self.options.with_json: self.cpp_info.components["gdcmMSFF"].requires.append("json-c::json-c") if self.settings.os != "Windows": @@ -247,7 +255,7 @@ def zlib(): if not self.options.shared: self.cpp_info.components["gdcmDICT"].requires.extend(["gdcmDSED", "gdcmIOD"]) self.cpp_info.components["gdcmMEXD"].requires.extend(["gdcmMSFF", "gdcmDICT", "gdcmDSED", "gdcmIOD", "socketxx"]) - self.cpp_info.components["gdcmMSFF"].requires.extend(["gdcmjpeg8", "gdcmjpeg12", "gdcmjpeg16", "gdcmcharls"]) + self.cpp_info.components["gdcmMSFF"].requires.extend(["gdcmjpeg8", "gdcmjpeg12", "gdcmjpeg16"]) if self.settings.os == "Windows": self.cpp_info.components["gdcmCommon"].system_libs = ["ws2_32", "crypt32"] diff --git a/recipes/gdcm/all/patches/0001-3.0.20-find-charls.patch b/recipes/gdcm/all/patches/0001-3.0.20-find-charls.patch new file mode 100644 index 00000000000000..c30995e540d0b3 --- /dev/null +++ b/recipes/gdcm/all/patches/0001-3.0.20-find-charls.patch @@ -0,0 +1,28 @@ +Allow using charls >= 2.2.0 +https://github.com/malaterre/GDCM/pull/157 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -352,8 +352,8 @@ else() + endif() + + if(GDCM_USE_SYSTEM_CHARLS) +- find_package(CharLS 2.0.0 REQUIRED) +- set(GDCM_CHARLS_LIBRARIES ${CHARLS_LIBRARIES}) ++ find_package(charls 2.2.0 REQUIRED) ++ set(GDCM_CHARLS_LIBRARIES charls) + else() + set(GDCM_CHARLS_LIBRARIES gdcmcharls) + endif() +--- a/Utilities/gdcm_charls.h ++++ b/Utilities/gdcm_charls.h +@@ -17,8 +17,8 @@ + /* Use the charls library configured for gdcm. */ + #include "gdcmTypes.h" + #ifdef GDCM_USE_SYSTEM_CHARLS +-// It is expected that version 2.0.0 is used +-# include ++// It is expected that version >= 2.2.0 is used ++# include + #else + #include "gdcmcharls/charls.h" + #endif diff --git a/recipes/gdcm/all/patches/0001-3.0.9-find-charls.patch b/recipes/gdcm/all/patches/0001-3.0.9-find-charls.patch new file mode 100644 index 00000000000000..c4dfe79c815248 --- /dev/null +++ b/recipes/gdcm/all/patches/0001-3.0.9-find-charls.patch @@ -0,0 +1,28 @@ +Allow using charls >= 2.2.0 +https://github.com/malaterre/GDCM/pull/157 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -356,8 +356,8 @@ else() + endif() + + if(GDCM_USE_SYSTEM_CHARLS) +- find_package(CharLS 2.0.0 REQUIRED) +- set(GDCM_CHARLS_LIBRARIES ${CHARLS_LIBRARIES}) ++ find_package(charls 2.2.0 REQUIRED) ++ set(GDCM_CHARLS_LIBRARIES charls) + else() + set(GDCM_CHARLS_LIBRARIES gdcmcharls) + endif() +--- a/Utilities/gdcm_charls.h ++++ b/Utilities/gdcm_charls.h +@@ -17,8 +17,8 @@ + /* Use the charls library configured for gdcm. */ + #include "gdcmTypes.h" + #ifdef GDCM_USE_SYSTEM_CHARLS +-// It is expected that version 2.0.0 is used +-# include ++// It is expected that version >= 2.2.0 is used ++# include + #else + #include "gdcmcharls/charls.h" + #endif diff --git a/recipes/gdcm/all/patches/0001-charls-linking.patch b/recipes/gdcm/all/patches/0001-charls-linking.patch deleted file mode 100644 index 57df8966f04baa..00000000000000 --- a/recipes/gdcm/all/patches/0001-charls-linking.patch +++ /dev/null @@ -1,38 +0,0 @@ ---- a/Utilities/gdcmcharls/CMakeLists.txt -+++ b/Utilities/gdcmcharls/CMakeLists.txt -@@ -61,12 +61,10 @@ endif() - #option(charls_BUILD_SHARED_LIBS "Build CharLS with shared libraries." OFF) - #set(BUILD_SHARED_LIBS ${charls_BUILD_SHARED_LIBS}) - --if(WIN32) -- if(BUILD_SHARED_LIBS) -- add_definitions(-DCHARLS_DLL_BUILD) -- else() -- add_definitions(-DCHARLS_STATIC) -- endif() -+if(BUILD_SHARED_LIBS) -+ add_definitions(-DCHARLS_DLL_BUILD) -+else() -+ add_definitions(-DCHARLS_STATIC) - endif() - - add_library(${CHARLS_LIBRARY_NAME} ---- a/Utilities/gdcmcharls/charls.h -+++ b/Utilities/gdcmcharls/charls.h -@@ -13,12 +13,12 @@ - #define CHARLS_IMEXPORT(returntype) __declspec(dllexport) returntype __stdcall - #endif - --// Non-windows (static linking) --#if !defined(CHARLS_IMEXPORT) && !defined(_WIN32) --# define CHARLS_IMEXPORT(returntype) returntype -+// Non-windows (dynamic linking) -+#if !defined(WIN32) && (defined(CHARLS_DLL) || defined(CHARLS_DLL_BUILD)) -+#define CHARLS_IMEXPORT(returntype) __attribute__((visibility("default"))) returntype - #endif - --// Windows static linking -+// Static linking - #if !defined(CHARLS_IMEXPORT) && defined(CHARLS_STATIC) - # define CHARLS_IMEXPORT(returntype) returntype - #endif diff --git a/recipes/gdcm/all/test_package/CMakeLists.txt b/recipes/gdcm/all/test_package/CMakeLists.txt index 5465ea8e54b6d9..b8df0da5056db7 100644 --- a/recipes/gdcm/all/test_package/CMakeLists.txt +++ b/recipes/gdcm/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) find_package(GDCM REQUIRED CONFIG) diff --git a/recipes/gdcm/all/test_package/conanfile.py b/recipes/gdcm/all/test_package/conanfile.py index 1f94130dd62ec8..68791e0d3201c0 100644 --- a/recipes/gdcm/all/test_package/conanfile.py +++ b/recipes/gdcm/all/test_package/conanfile.py @@ -22,7 +22,7 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") input_file = os.path.join(self.source_folder, "DCMTK_JPEGExt_12Bits.dcm") test_dir = "test_dir" mkdir(self, test_dir) diff --git a/recipes/gdcm/all/test_v1_package/CMakeLists.txt b/recipes/gdcm/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/gdcm/all/test_v1_package/CMakeLists.txt +++ b/recipes/gdcm/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) From 22876f868798e6bf7c1237391c578ff87ee12153 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 22:44:57 +0900 Subject: [PATCH 0310/1140] (#18464) xlsxio: add libs and requires definitions * xlsxio: add libs and requires definitions * update dependencies * add system_libs for each components * make test_package.cpp to test_package.c * support static build on msvc * fix package name for minizip-ng * apply @czoido patch --- recipes/xlsxio/all/conanfile.py | 48 ++++++++++++++---- .../xlsxio/all/test_package/CMakeLists.txt | 4 +- .../xlsxio/all/test_package/test_package.c | 49 +++++++++++++++++++ .../xlsxio/all/test_package/test_package.cpp | 13 ----- 4 files changed, 90 insertions(+), 24 deletions(-) create mode 100644 recipes/xlsxio/all/test_package/test_package.c delete mode 100644 recipes/xlsxio/all/test_package/test_package.cpp diff --git a/recipes/xlsxio/all/conanfile.py b/recipes/xlsxio/all/conanfile.py index f1cc40e63d655d..55de1430b90bda 100644 --- a/recipes/xlsxio/all/conanfile.py +++ b/recipes/xlsxio/all/conanfile.py @@ -1,4 +1,5 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout, CMakeDeps from conan.tools.env import VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir @@ -47,19 +48,27 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + if self.options.with_wide: + self.options["expat"].char_type = "ushort" + if self.options.get_safe("with_minizip_ng"): + self.options["minizip-ng"].mz_compatibility = True + def layout(self): cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_libzip: - self.requires("libzip/1.7.3") + self.requires("libzip/1.9.2") elif Version(self.version) >= "0.2.34" and self.options.with_minizip_ng : self.requires("minizip-ng/3.0.8") else: - self.requires("minizip/1.2.12") - self.requires("expat/2.4.9") - if self.options.with_wide: - self.options["expat"].char_type="ushort" + self.requires("minizip/1.2.13") + self.requires("expat/2.5.0") + + def validate(self): + if Version(self.version) >= "0.2.34": + if self.options.with_libzip and self.options.with_minizip_ng: + raise ConanInvalidConfiguration("with_libzip and with_minizip_ng are mutually exclusive") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -104,20 +113,41 @@ def package_info(self): self.cpp_info.set_property("cmake_module_file_name", "xlsxio") self.cpp_info.set_property("pkg_config_name", "xlsxio") + ziplib = "minizip::minizip" + if self.options.with_libzip: + ziplib = "libzip::libzip" + elif self.options.get_safe("with_minizip_ng"): + ziplib = "minizip-ng::minizip-ng" + + xlsxio_macro = "BUILD_XLSXIO_SHARED" if self.options.shared else "BUILD_XLSXIO_STATIC" + self.cpp_info.components["xlsxio_read"].set_property("cmake_target_name", "xlsxio::xlsxio_read") self.cpp_info.components["xlsxio_read"].set_property("cmake_module_target_name", "xlsxio::xlsxio_read") self.cpp_info.components["xlsxio_read"].set_property("pkg_config_name", "libxlsxio_read") + self.cpp_info.components["xlsxio_read"].libs = ["xlsxio_read"] + self.cpp_info.components["xlsxio_read"].requires = ["expat::expat", ziplib] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["xlsxio_read"].system_libs.append("pthread") + self.cpp_info.components["xlsxio_read"].defines.append(xlsxio_macro) + self.cpp_info.components["xlsxio_write"].set_property("cmake_target_name", "xlsxio::xlsxio_write") self.cpp_info.components["xlsxio_write"].set_property("cmake_module_target_name", "xlsxio::xlsxio_write") self.cpp_info.components["xlsxio_write"].set_property("pkg_config_name", "libxlsxio_write") + self.cpp_info.components["xlsxio_write"].libs = ["xlsxio_write"] + self.cpp_info.components["xlsxio_write"].requires = ["expat::expat", ziplib] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["xlsxio_write"].system_libs.append("pthread") + self.cpp_info.components["xlsxio_write"].defines.append(xlsxio_macro) + if self.options.with_wide: self.cpp_info.components["xlsxio_readw"].set_property("cmake_target_name", "xlsxio::xlsxio_readw") self.cpp_info.components["xlsxio_readw"].set_property("cmake_module_target_name", "xlsxio::xlsxio_readw") self.cpp_info.components["xlsxio_readw"].set_property("pkg_config_name", "libxlsxio_readw") - - - if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["pthread"] + self.cpp_info.components["xlsxio_readw"].libs = ["xlsxio_readw"] + self.cpp_info.components["xlsxio_readw"].requires = ["expat::expat", ziplib] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["xlsxio_readw"].system_libs.append("pthread") + self.cpp_info.components["xlsxio_readw"].defines.append(xlsxio_macro) # TODO: to remove in conan v2 self.cpp_info.names["cmake_find_package"] = "xlsxio" diff --git a/recipes/xlsxio/all/test_package/CMakeLists.txt b/recipes/xlsxio/all/test_package/CMakeLists.txt index 67d6a295ac9dce..a6b2c7649a0c8e 100644 --- a/recipes/xlsxio/all/test_package/CMakeLists.txt +++ b/recipes/xlsxio/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES CXX) +project(test_package LANGUAGES C) find_package(xlsxio REQUIRED CONFIG) -add_executable(${PROJECT_NAME} test_package.cpp) +add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} PRIVATE xlsxio::xlsxio_read) target_link_libraries(${PROJECT_NAME} PRIVATE xlsxio::xlsxio_write) diff --git a/recipes/xlsxio/all/test_package/test_package.c b/recipes/xlsxio/all/test_package/test_package.c new file mode 100644 index 00000000000000..097bd99e0a65d5 --- /dev/null +++ b/recipes/xlsxio/all/test_package/test_package.c @@ -0,0 +1,49 @@ +#include +#include +#include + +int main(int argc, char** argv) { + xlsxiowriter xlsxwrite; + int i; + xlsxioreader xlsxioread; + + // open .xlsx file for writing (will overwrite if it already exists) + if ((xlsxwrite = xlsxiowrite_open("test_package.xlsx", "MySheet")) == NULL) { + fprintf(stderr, "Error creating .xlsx file\n"); + return 1; + } + // set row height + xlsxiowrite_set_row_height(xlsxwrite, 1); + // how many rows to buffer to detect column widths + xlsxiowrite_set_detection_rows(xlsxwrite, 10); + // write column names + xlsxiowrite_add_column(xlsxwrite, "Col1", 0); + xlsxiowrite_add_column(xlsxwrite, "Col2", 21); + xlsxiowrite_add_column(xlsxwrite, "Col3", 0); + xlsxiowrite_add_column(xlsxwrite, "Col4", 2); + xlsxiowrite_add_column(xlsxwrite, "Col5", 0); + xlsxiowrite_add_column(xlsxwrite, "Col6", 0); + xlsxiowrite_add_column(xlsxwrite, "Col7", 0); + xlsxiowrite_next_row(xlsxwrite); + // write data + for (i = 0; i < 1000; i++) { + xlsxiowrite_add_cell_string(xlsxwrite, "Test"); + xlsxiowrite_add_cell_string(xlsxwrite, "A b c d e f\nnew line"); + xlsxiowrite_add_cell_string(xlsxwrite, "&% \"'"); + xlsxiowrite_add_cell_string(xlsxwrite, NULL); + xlsxiowrite_add_cell_int(xlsxwrite, i); + xlsxiowrite_add_cell_datetime(xlsxwrite, time(NULL)); + xlsxiowrite_add_cell_float(xlsxwrite, 3.1415926); + xlsxiowrite_next_row(xlsxwrite); + } + // close .xlsx file + xlsxiowrite_close(xlsxwrite); + + // read .xlsx file + xlsxioread = xlsxioread_open("test_package.xlsx"); + + // close .xlsx file + xlsxioread_close(xlsxioread); + + return 0; +} diff --git a/recipes/xlsxio/all/test_package/test_package.cpp b/recipes/xlsxio/all/test_package/test_package.cpp deleted file mode 100644 index e7ee13469ca6e8..00000000000000 --- a/recipes/xlsxio/all/test_package/test_package.cpp +++ /dev/null @@ -1,13 +0,0 @@ -#include -#include -#include - -int main(int argc, char** argv) { - xlsxioreader xlsxioread; - xlsxiowriter xlsxiowrite; - xlsxioreadersheet sheet; - (void)xlsxioread; - (void)sheet; - (void)xlsxiowrite; - return 0; -} From 29a11c38757d4a5bc78a94a027ae01e4fd3e56d4 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 19 Aug 2023 23:05:39 +0900 Subject: [PATCH 0311/1140] (#18512) wasm-micro-runtime: add recipe * wasm-micro-runtime: add recipe * support MSVC * link ws2_32 * simplify test_package.cpp --------- Co-authored-by: Carlos Zoido --- recipes/wasm-micro-runtime/all/conandata.yml | 9 ++ recipes/wasm-micro-runtime/all/conanfile.py | 138 ++++++++++++++++++ .../all/patches/1.2.2-0001-fix-cmake.patch | 57 ++++++++ .../all/test_package/CMakeLists.txt | 12 ++ .../all/test_package/conanfile.py | 33 +++++ .../all/test_package/test_package.cpp | 65 +++++++++ .../all/test_package/test_package.wasm | Bin 0 -> 71 bytes .../test_package/test_package_no_interp.cpp | 64 ++++++++ recipes/wasm-micro-runtime/config.yml | 3 + 9 files changed, 381 insertions(+) create mode 100644 recipes/wasm-micro-runtime/all/conandata.yml create mode 100644 recipes/wasm-micro-runtime/all/conanfile.py create mode 100644 recipes/wasm-micro-runtime/all/patches/1.2.2-0001-fix-cmake.patch create mode 100644 recipes/wasm-micro-runtime/all/test_package/CMakeLists.txt create mode 100644 recipes/wasm-micro-runtime/all/test_package/conanfile.py create mode 100644 recipes/wasm-micro-runtime/all/test_package/test_package.cpp create mode 100644 recipes/wasm-micro-runtime/all/test_package/test_package.wasm create mode 100644 recipes/wasm-micro-runtime/all/test_package/test_package_no_interp.cpp create mode 100644 recipes/wasm-micro-runtime/config.yml diff --git a/recipes/wasm-micro-runtime/all/conandata.yml b/recipes/wasm-micro-runtime/all/conandata.yml new file mode 100644 index 00000000000000..e6acc345307822 --- /dev/null +++ b/recipes/wasm-micro-runtime/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "1.2.2": + url: "https://github.com/bytecodealliance/wasm-micro-runtime/archive/refs/tags/WAMR-1.2.2.tar.gz" + sha256: "d328fc1e19c54cfdb4248b861de54b62977b9b85c0a40eaaeb9cd9b628c0c788" +patches: + "1.2.2": + - patch_file: "patches/1.2.2-0001-fix-cmake.patch" + patch_description: "separate static and shasred build" + patch_type: "conan" diff --git a/recipes/wasm-micro-runtime/all/conanfile.py b/recipes/wasm-micro-runtime/all/conanfile.py new file mode 100644 index 00000000000000..4cd796f406c9c8 --- /dev/null +++ b/recipes/wasm-micro-runtime/all/conanfile.py @@ -0,0 +1,138 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.microsoft import is_msvc +import os + +required_conan_version = ">=1.53.0" + +class WasmMicroRuntimeConan(ConanFile): + name = "wasm-micro-runtime" + description = "WebAssembly Micro Runtime (WAMR)" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://bytecodealliance.github.io/wamr.dev/" + topics = ("wasm", "embedded", "webassembly", "runtime") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_interp": [False, "fast", "classic"], + "with_aot": [True, False], + "with_jit": [True, False], + "with_fast_jit": [True, False], + "libc": ["builtin", "wasi", "uvwasi"], + "with_multi_module": [True, False], + "with_mini_loader": [True, False], + "with_pthread": [True, False], + "with_wasi_threads": [True, False], + "with_tail_call": [True, False], + "with_simd": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + "with_interp": "fast", + "with_aot": True, + "with_jit": False, + "with_fast_jit": False, + "libc": "builtin", + "with_multi_module": False, + "with_mini_loader": False, + "with_pthread": False, + "with_wasi_threads": False, + "with_tail_call": False, + "with_simd": True, + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + # When with_fast_jit is True, C++ is required. + if not self.options.with_fast_jit: + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + # When with_fast_jit is True, C++ is required. + if not self.options.with_fast_jit: + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + if not self.options.with_interp and not self.options.with_aot: + raise ConanInvalidConfiguration(f"{self.ref} requires with_interp and with_aot at least one.") + if self.options.with_jit: + raise ConanInvalidConfiguration(f"{self.ref} doesn't support with_jit(yet).") + if self.options.with_multi_module and self.options.with_mini_loader: + raise ConanInvalidConfiguration(f"{self.ref} doesn't support both with_multi_module and with_mini_loader.") + if self.options.libc == "wasi" and self.settings.os == "Windows": + raise ConanInvalidConfiguration(f"{self.ref} doesn't support libc=wasi on Windows.") + if self.options.libc == "uvwasi": + raise ConanInvalidConfiguration(f"{self.ref} doesn't support libc=uvwasi(yet).") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + def is_enabled(value): + return 1 if value else 0 + + tc = CMakeToolchain(self) + # FIXME: it should use assembler code instead of C++ on MSVC + if is_msvc(self): + tc.variables["WAMR_BUILD_INVOKE_NATIVE_GENERAL"] = 1 + + # interpreters + tc.variables["WAMR_BUILD_INTERP"] = is_enabled(self.options.with_interp) + if self.options.with_interp: + tc.variables["WAMR_BUILD_FAST_INTERP"] = is_enabled(self.options.with_interp == "fast") + # AOT and JITs + tc.variables["WAMR_BUILD_AOT"] = is_enabled(self.options.with_aot) + tc.variables["WAMR_BUILD_JIT"] = is_enabled(self.options.with_jit) + tc.variables["WAMR_BUILD_FAST_JIT"] = is_enabled(self.options.with_fast_jit) + # LIBC + tc.variables["WAMR_BUILD_LIBC_BUILTIN"] = is_enabled(self.options.libc == "builtin") + tc.variables["WAMR_BUILD_LIBC_WASI"] = is_enabled(self.options.libc == "wasi") + tc.variables["WAMR_BUILD_LIBC_UVWASI"] = is_enabled(self.options.libc == "uvwasi") + # others + tc.variables["WAMR_BUILD_MULTI_MODULE"] = is_enabled(self.options.with_multi_module) + tc.variables["WAMR_BUILD_MINI_LOADER"] = is_enabled(self.options.with_mini_loader) + tc.variables["WAMR_BUILD_LIB_PTHREAD"] = is_enabled(self.options.with_pthread) + tc.variables["WAMR_BUILD_LIB_WASI_THREADS"] = is_enabled(self.options.with_wasi_threads) + tc.variables["WAMR_BUILD_TAIL_CALL"] = is_enabled(self.options.with_tail_call) + tc.variables["WAMR_BUILD_SIMD"] = is_enabled(self.options.with_simd) + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["iwasm" if self.options.shared else "vmlib"] + if self.settings.os == "Windows" and not self.options.shared: + self.cpp_info.defines.append("COMPILING_WASM_RUNTIME_API=0") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") + self.cpp_info.system_libs.append("pthread") + if self.settings.os == "Windows": + self.cpp_info.system_libs.append("ws2_32") diff --git a/recipes/wasm-micro-runtime/all/patches/1.2.2-0001-fix-cmake.patch b/recipes/wasm-micro-runtime/all/patches/1.2.2-0001-fix-cmake.patch new file mode 100644 index 00000000000000..baf12ba1a1b627 --- /dev/null +++ b/recipes/wasm-micro-runtime/all/patches/1.2.2-0001-fix-cmake.patch @@ -0,0 +1,57 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 1c87994..bbcb2fd 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -109,11 +109,6 @@ set (WAMR_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}) + + include (${WAMR_ROOT_DIR}/build-scripts/runtime_lib.cmake) + +-set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wformat -Wformat-security -Wshadow -Wno-unused-parameter") +-# set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wconversion -Wsign-conversion") +- +-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wformat -Wformat-security -Wno-unused") +- + if (WAMR_BUILD_TARGET MATCHES "X86_.*" OR WAMR_BUILD_TARGET STREQUAL "AMD_64") + if (NOT (CMAKE_C_COMPILER MATCHES ".*clang.*" OR CMAKE_C_COMPILER_ID MATCHES ".*Clang")) + set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mindirect-branch-register") +@@ -130,22 +125,29 @@ endif () + + include (${SHARED_DIR}/utils/uncommon/shared_uncommon.cmake) + ++if (NOT BUILD_SHARED_LIBS) + # STATIC LIBRARY + add_library(iwasm_static STATIC ${WAMR_RUNTIME_LIB_SOURCE}) + set_target_properties (iwasm_static PROPERTIES OUTPUT_NAME vmlib) + target_include_directories(iwasm_static INTERFACE ${WAMR_ROOT_DIR}/core/iwasm/include) +-target_link_libraries (iwasm_static INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS} -lm -ldl -lpthread) ++target_link_libraries (iwasm_static INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS}) ++if(NOT MSVC) ++target_link_libraries (iwasm_static INTERFACE -lm -ldl -lpthread) ++endif() + if (WAMR_BUILD_WASM_CACHE EQUAL 1) + target_link_libraries(iwasm_static INTERFACE boringssl_crypto) + endif () + + install (TARGETS iwasm_static ARCHIVE DESTINATION lib) +- ++else() + # SHARED LIBRARY + add_library (iwasm_shared SHARED ${WAMR_RUNTIME_LIB_SOURCE}) + set_target_properties (iwasm_shared PROPERTIES OUTPUT_NAME iwasm) + target_include_directories(iwasm_shared INTERFACE ${WAMR_ROOT_DIR}/core/iwasm/include) +-target_link_libraries (iwasm_shared INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS} -lm -ldl -lpthread) ++target_link_libraries (iwasm_shared INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS}) ++if(NOT MSVC) ++target_link_libraries (iwasm_shared INTERFACE -lm -ldl -lpthread) ++endif() + if (WAMR_BUILD_WASM_CACHE EQUAL 1) + target_link_libraries(iwasm_shared INTERFACE boringssl_crypto) + endif () +@@ -155,6 +157,7 @@ if (MINGW) + endif () + + install (TARGETS iwasm_shared LIBRARY DESTINATION lib) ++endif() + + # HEADERS + install (FILES diff --git a/recipes/wasm-micro-runtime/all/test_package/CMakeLists.txt b/recipes/wasm-micro-runtime/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..3cf7f573410ea6 --- /dev/null +++ b/recipes/wasm-micro-runtime/all/test_package/CMakeLists.txt @@ -0,0 +1,12 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(wasm-micro-runtime REQUIRED CONFIG) + +if(WAMR_NO_INTERP) +add_executable(${PROJECT_NAME} test_package_no_interp.cpp) +else() +add_executable(${PROJECT_NAME} test_package.cpp) +endif() + +target_link_libraries(${PROJECT_NAME} PRIVATE wasm-micro-runtime::wasm-micro-runtime) diff --git a/recipes/wasm-micro-runtime/all/test_package/conanfile.py b/recipes/wasm-micro-runtime/all/test_package/conanfile.py new file mode 100644 index 00000000000000..d56a8c50a887ae --- /dev/null +++ b/recipes/wasm-micro-runtime/all/test_package/conanfile.py @@ -0,0 +1,33 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake, CMakeToolchain + +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def generate(self): + tc = CMakeToolchain(self) + if not self.dependencies["wasm-micro-runtime"].options.with_interp: + tc.variables["WAMR_NO_INTERP"] = True + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + wat_path = os.path.join(self.source_folder, "test_package.wasm") + self.run(f"{bin_path} {wat_path}", env="conanrun") diff --git a/recipes/wasm-micro-runtime/all/test_package/test_package.cpp b/recipes/wasm-micro-runtime/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..6e413e2d402fcb --- /dev/null +++ b/recipes/wasm-micro-runtime/all/test_package/test_package.cpp @@ -0,0 +1,65 @@ +#include +#include +#include +#include + +#include "wasm_c_api.h" + +#define own + +int main(int argc, const char* argv[]) { + // Initialize. + printf("Initializing...\n"); + wasm_engine_t* engine = wasm_engine_new(); + wasm_store_t* store = wasm_store_new(engine); + + // Load binary. + printf("Loading binary...\n"); + FILE* file = fopen(argv[1], "rb"); + if (!file) { + printf("> Error loading module!\n"); + return 1; + } + + int ret = fseek(file, 0L, SEEK_END); + if (ret == -1) { + printf("> Error loading module!\n"); + fclose(file); + return 1; + } + + long file_size = ftell(file); + if (file_size == -1) { + printf("> Error loading module!\n"); + fclose(file); + return 1; + } + + ret = fseek(file, 0L, SEEK_SET); + if (ret == -1) { + printf("> Error loading module!\n"); + fclose(file); + return 1; + } + + wasm_byte_vec_t binary; + wasm_byte_vec_new_uninitialized(&binary, file_size); + if (fread(binary.data, file_size, 1, file) != 1) { + printf("> Error loading module!\n"); + fclose(file); + return 1; + } + fclose(file); + + // Compile. + printf("Compiling module...\n"); + own wasm_module_t* module = wasm_module_new(store, &binary); + if (!module) { + printf("> Error compiling module!\n"); + return 1; + } + + wasm_byte_vec_delete(&binary); + + return 0; +} diff --git a/recipes/wasm-micro-runtime/all/test_package/test_package.wasm b/recipes/wasm-micro-runtime/all/test_package/test_package.wasm new file mode 100644 index 0000000000000000000000000000000000000000..18ac7653b03011ec07329a1b12166d0e53061b33 GIT binary patch literal 71 zcmXxbF%Ezr5JkcFmqiRVR-R7^5(~gY +#include +#include +#include + +#include "wasm_c_api.h" + +#define own + +// A function to be called from Wasm code. +own wasm_trap_t* hello_callback( + const wasm_val_vec_t* args, wasm_val_vec_t* results +) { + printf("Calling back...\n"); + printf("> Hello World!\n"); + return NULL; +} + +int main(int argc, const char* argv[]) { + // Initialize. + printf("Initializing...\n"); + wasm_engine_t* engine = wasm_engine_new(); + wasm_store_t* store = wasm_store_new(engine); + + // Load binary. + printf("Loading binary...\n"); + FILE* file = fopen(argv[1], "rb"); + if (!file) { + printf("> Error loading module!\n"); + return 1; + } + + long file_size = 10240; + + wasm_byte_vec_t binary; + wasm_byte_vec_new_uninitialized(&binary, file_size); + + // Compile. + printf("Compiling module...\n"); + own wasm_module_t* module = wasm_module_new(store, &binary); + + wasm_byte_vec_delete(&binary); + + // Create external print functions. + printf("Creating callback...\n"); + own wasm_functype_t* hello_type = wasm_functype_new_0_0(); + own wasm_func_t* hello_func = + wasm_func_new(store, hello_type, hello_callback); + + wasm_functype_delete(hello_type); + + wasm_func_delete(hello_func); + + wasm_module_delete(module); + + // Shut down. + printf("Shutting down...\n"); + wasm_store_delete(store); + wasm_engine_delete(engine); + + // All done. + printf("Done.\n"); + return 0; +} diff --git a/recipes/wasm-micro-runtime/config.yml b/recipes/wasm-micro-runtime/config.yml new file mode 100644 index 00000000000000..af40d9653a3783 --- /dev/null +++ b/recipes/wasm-micro-runtime/config.yml @@ -0,0 +1,3 @@ +versions: + "1.2.2": + folder: all From 8ae35ee449b9b5270e252c6867f1037dfcc10051 Mon Sep 17 00:00:00 2001 From: Pavel Geler <53797155+pgeler@users.noreply.github.com> Date: Sat, 19 Aug 2023 10:25:52 -0400 Subject: [PATCH 0312/1140] (#18544) add grpc package version 1.54.3 and 1.48.4 * add grpc version 1.56.1 * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * add grpc version 1.56.1 * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * fix * update 1.54.2 to the latest 1.54.3 * fix * abseil * fix --------- Co-authored-by: neureal-dev <17104352+neureal-dev@users.noreply.github.com> --- recipes/grpc/all/conandata.yml | 30 ++++++------------ recipes/grpc/all/conanfile.py | 17 +++++----- .../v1.46.x/001-disable-cppstd-override.patch | 26 ---------------- .../v1.47.x/001-disable-cppstd-override.patch | 31 ------------------- .../v1.48.x/001-disable-cppstd-override.patch | 15 ++++++++- .../v1.50.x/001-disable-cppstd-override.patch | 26 ---------------- recipes/grpc/config.yml | 8 ++--- 7 files changed, 35 insertions(+), 118 deletions(-) delete mode 100644 recipes/grpc/all/patches/v1.46.x/001-disable-cppstd-override.patch delete mode 100644 recipes/grpc/all/patches/v1.47.x/001-disable-cppstd-override.patch delete mode 100644 recipes/grpc/all/patches/v1.50.x/001-disable-cppstd-override.patch diff --git a/recipes/grpc/all/conandata.yml b/recipes/grpc/all/conandata.yml index afbe96ebd2a5ea..e714373e94d62c 100644 --- a/recipes/grpc/all/conandata.yml +++ b/recipes/grpc/all/conandata.yml @@ -1,24 +1,12 @@ sources: - "1.50.1": - url: "https://github.com/grpc/grpc/archive/v1.50.1.tar.gz" - sha256: "fb1ed98eb3555877d55eb2b948caca44bc8601c6704896594de81558639709ef" - "1.50.0": - url: "https://github.com/grpc/grpc/archive/v1.50.0.tar.gz" - sha256: "76900ab068da86378395a8e125b5cc43dfae671e09ff6462ddfef18676e2165a" - "1.47.1": - url: "https://github.com/grpc/grpc/archive/v1.47.1.tar.gz" - sha256: "ba7c36989ad8a52c813adeebb0c65869283448f496dbb2868c75f69941dec6a9" - "1.46.3": - url: "https://github.com/grpc/grpc/archive/refs/tags/v1.46.3.tar.gz" - sha256: "d6cbf22cb5007af71b61c6be316a79397469c58c82a942552a62e708bce60964" + "1.54.3": + url: "https://github.com/grpc/grpc/archive/v1.54.3.tar.gz" + sha256: "17e4e1b100657b88027721220cbfb694d86c4b807e9257eaf2fb2d273b41b1b1" + "1.48.4": + url: "https://github.com/grpc/grpc/archive/v1.48.4.tar.gz" + sha256: "0c3faa83e39d4f1ab55fe1476362b9ac3b81632a46dce7fd4d50271bce816b53" patches: - "1.50.1": - - patch_file: "patches/v1.50.x/001-disable-cppstd-override.patch" - "1.50.0": - - patch_file: "patches/v1.50.x/001-disable-cppstd-override.patch" - "1.48.0": + "1.48.4": - patch_file: "patches/v1.48.x/001-disable-cppstd-override.patch" - "1.47.1": - - patch_file: "patches/v1.47.x/001-disable-cppstd-override.patch" - "1.46.3": - - patch_file: "patches/v1.46.x/001-disable-cppstd-override.patch" + patch_description: "disable cpp std override" + patch_type: "portability" diff --git a/recipes/grpc/all/conanfile.py b/recipes/grpc/all/conanfile.py index 3187b094b35594..2278045abf6b97 100644 --- a/recipes/grpc/all/conanfile.py +++ b/recipes/grpc/all/conanfile.py @@ -1,5 +1,4 @@ import os -import shutil from conan import ConanFile from conan.errors import ConanInvalidConfiguration @@ -86,15 +85,18 @@ def layout(self): def requirements(self): # abseil is public. See https://github.com/conan-io/conan-center-index/pull/17284#issuecomment-1526082638 - if is_msvc(self) and Version(self.version) < "1.47": - self.requires("abseil/20211102.0", transitive_headers=True, transitive_libs=True) + if Version(self.version) < "1.47": + if is_msvc(self): + self.requires("abseil/20211102.0", transitive_headers=True, transitive_libs=True) + else: + self.requires("abseil/20220623.1", transitive_headers=True, transitive_libs=True) else: - self.requires("abseil/20220623.0", transitive_headers=True, transitive_libs=True) - self.requires("c-ares/1.19.0") + self.requires("abseil/20230125.3", transitive_headers=True, transitive_libs=True) + self.requires("c-ares/1.19.1") self.requires("openssl/[>=1.1 <4]") self.requires("re2/20230301") self.requires("zlib/1.2.13") - self.requires("protobuf/3.21.9", transitive_headers=True, transitive_libs=True, run=can_run(self)) + self.requires("protobuf/3.21.12", transitive_headers=True, transitive_libs=True, run=can_run(self)) def package_id(self): del self.info.options.secure @@ -119,7 +121,7 @@ def validate(self): def build_requirements(self): if not can_run(self): - self.tool_requires("protobuf/3.21.9") + self.tool_requires("protobuf/3.21.12") if cross_building(self): # when cross compiling we need pre compiled grpc plugins for protoc self.tool_requires(f"grpc/{self.version}") @@ -309,6 +311,7 @@ def corefoundation(): "abseil::absl_status", "abseil::absl_str_format", "abseil::absl_strings", "abseil::absl_synchronization", "abseil::absl_time", "abseil::absl_optional", + "abseil::absl_flags", ], "system_libs": libm() + pthread() + crypt32() + ws2_32() + wsock32(), }, diff --git a/recipes/grpc/all/patches/v1.46.x/001-disable-cppstd-override.patch b/recipes/grpc/all/patches/v1.46.x/001-disable-cppstd-override.patch deleted file mode 100644 index a2601246759471..00000000000000 --- a/recipes/grpc/all/patches/v1.46.x/001-disable-cppstd-override.patch +++ /dev/null @@ -1,26 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 7a97604b75..7ae815042f 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -222,21 +222,6 @@ if (NOT DEFINED CMAKE_C_STANDARD) - set(CMAKE_C_STANDARD 99) - endif() - --# Add c++11 flags --if (NOT DEFINED CMAKE_CXX_STANDARD) -- set(CMAKE_CXX_STANDARD 11) --else() -- if (CMAKE_CXX_STANDARD LESS 11) -- message(FATAL_ERROR "CMAKE_CXX_STANDARD is less than 11, please specify at least SET(CMAKE_CXX_STANDARD 11)") -- endif() --endif() --if (NOT DEFINED CMAKE_CXX_STANDARD_REQUIRED) -- set(CMAKE_CXX_STANDARD_REQUIRED ON) --endif() --if (NOT DEFINED CMAKE_CXX_EXTENSIONS) -- set(CMAKE_CXX_EXTENSIONS OFF) --endif() -- - if (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE) - set(CMAKE_POSITION_INDEPENDENT_CODE TRUE) - endif() diff --git a/recipes/grpc/all/patches/v1.47.x/001-disable-cppstd-override.patch b/recipes/grpc/all/patches/v1.47.x/001-disable-cppstd-override.patch deleted file mode 100644 index 0ba329e6480bcc..00000000000000 --- a/recipes/grpc/all/patches/v1.47.x/001-disable-cppstd-override.patch +++ /dev/null @@ -1,31 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index db075cbe4a..289cc52215 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -220,26 +220,6 @@ if(WIN32) - set(_gRPC_PLATFORM_WINDOWS ON) - endif() - -- # Use C11 standard --if (NOT DEFINED CMAKE_C_STANDARD) -- set(CMAKE_C_STANDARD 11) --endif() -- --# Add c++14 flags --if (NOT DEFINED CMAKE_CXX_STANDARD) -- set(CMAKE_CXX_STANDARD 14) --else() -- if (CMAKE_CXX_STANDARD LESS 14) -- message(FATAL_ERROR "CMAKE_CXX_STANDARD is less than 14, please specify at least SET(CMAKE_CXX_STANDARD 14)") -- endif() --endif() --if (NOT DEFINED CMAKE_CXX_STANDARD_REQUIRED) -- set(CMAKE_CXX_STANDARD_REQUIRED ON) --endif() --if (NOT DEFINED CMAKE_CXX_EXTENSIONS) -- set(CMAKE_CXX_EXTENSIONS OFF) --endif() -- - if (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE) - set(CMAKE_POSITION_INDEPENDENT_CODE TRUE) - endif() diff --git a/recipes/grpc/all/patches/v1.48.x/001-disable-cppstd-override.patch b/recipes/grpc/all/patches/v1.48.x/001-disable-cppstd-override.patch index 65b655ba1f8b59..dee7836ac518bd 100644 --- a/recipes/grpc/all/patches/v1.48.x/001-disable-cppstd-override.patch +++ b/recipes/grpc/all/patches/v1.48.x/001-disable-cppstd-override.patch @@ -1,5 +1,5 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 25990a5..f37849c 100644 +index 1ecaea8eb7..0788b88177 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -226,21 +226,6 @@ if (NOT DEFINED CMAKE_C_STANDARD) @@ -24,3 +24,16 @@ index 25990a5..f37849c 100644 if (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE) set(CMAKE_POSITION_INDEPENDENT_CODE TRUE) endif() +diff --git a/src/core/ext/xds/xds_http_fault_filter.cc b/src/core/ext/xds/xds_http_fault_filter.cc +index 2a10d2fd27..0900fedf61 100644 +--- a/src/core/ext/xds/xds_http_fault_filter.cc ++++ b/src/core/ext/xds/xds_http_fault_filter.cc +@@ -109,7 +109,7 @@ absl::StatusOr ParseHttpFaultIntoJson( + int abort_http_status_code = + envoy_extensions_filters_http_fault_v3_FaultAbort_http_status( + fault_abort); +- if (abort_http_status_code != 0 and abort_http_status_code != 200) { ++ if (abort_http_status_code != 0 && abort_http_status_code != 200) { + abort_grpc_status_code = + grpc_http2_status_to_grpc_status(abort_http_status_code); + } diff --git a/recipes/grpc/all/patches/v1.50.x/001-disable-cppstd-override.patch b/recipes/grpc/all/patches/v1.50.x/001-disable-cppstd-override.patch deleted file mode 100644 index a9339dbcc896b4..00000000000000 --- a/recipes/grpc/all/patches/v1.50.x/001-disable-cppstd-override.patch +++ /dev/null @@ -1,26 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 7052846..259fa93 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -227,21 +227,6 @@ if (NOT DEFINED CMAKE_C_STANDARD) - set(CMAKE_C_STANDARD 11) - endif() - --# Add c++14 flags --if (NOT DEFINED CMAKE_CXX_STANDARD) -- set(CMAKE_CXX_STANDARD 14) --else() -- if (CMAKE_CXX_STANDARD LESS 14) -- message(FATAL_ERROR "CMAKE_CXX_STANDARD is less than 14, please specify at least SET(CMAKE_CXX_STANDARD 14)") -- endif() --endif() --if (NOT DEFINED CMAKE_CXX_STANDARD_REQUIRED) -- set(CMAKE_CXX_STANDARD_REQUIRED ON) --endif() --if (NOT DEFINED CMAKE_CXX_EXTENSIONS) -- set(CMAKE_CXX_EXTENSIONS OFF) --endif() -- - if (NOT DEFINED CMAKE_POSITION_INDEPENDENT_CODE) - set(CMAKE_POSITION_INDEPENDENT_CODE TRUE) - endif() diff --git a/recipes/grpc/config.yml b/recipes/grpc/config.yml index d36f53e1f178cb..471303e99a287d 100644 --- a/recipes/grpc/config.yml +++ b/recipes/grpc/config.yml @@ -1,9 +1,5 @@ versions: - "1.50.1": + "1.54.3": folder: "all" - "1.50.0": - folder: "all" - "1.47.1": - folder: "all" - "1.46.3": + "1.48.4": folder: "all" From 75230bff154ac8b7c12e7bb4742b55e674f014c1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 17:46:56 +0300 Subject: [PATCH 0313/1140] (#18625) onetbb/2020.x: migrate to Conan v2, add v2020.3.3 * onetbb/2020.x: migrate to Conan v2 * onetbb/2020.x: fix linker error * onetbb: improve os detection * onetbb: further cleanup * onetbb: fix duplicate arch flag issue * onetbb: fix LDFLAGS getting incorrectly applied to ar command * onetbb: add m to system_libs * onetbb: add v2020.3.3 * onetbb: fix a typo --- recipes/onetbb/2020.x/conandata.yml | 3 + recipes/onetbb/2020.x/conanfile.py | 294 +++++++++--------- .../onetbb/2020.x/test_package/CMakeLists.txt | 5 +- .../onetbb/2020.x/test_package/conanfile.py | 19 +- .../2020.x/test_v1_package/CMakeLists.txt | 8 + .../2020.x/test_v1_package/conanfile.py | 17 + .../onetbb/all/test_package/CMakeLists.txt | 2 +- .../onetbb/all/test_v1_package/CMakeLists.txt | 2 +- recipes/onetbb/config.yml | 2 + 9 files changed, 198 insertions(+), 154 deletions(-) create mode 100644 recipes/onetbb/2020.x/test_v1_package/CMakeLists.txt create mode 100644 recipes/onetbb/2020.x/test_v1_package/conanfile.py diff --git a/recipes/onetbb/2020.x/conandata.yml b/recipes/onetbb/2020.x/conandata.yml index de98a3aa2d71de..bca751ad9a8a8d 100644 --- a/recipes/onetbb/2020.x/conandata.yml +++ b/recipes/onetbb/2020.x/conandata.yml @@ -1,4 +1,7 @@ sources: + "2020.3.3": + url: "https://github.com/oneapi-src/oneTBB/archive/v2020.3.3.tar.gz" + sha256: "494ac15f60e91d95ed7aec04f4e1d389b8a55bffc581d0fe9116b99336401963" "2020.3": url: "https://github.com/oneapi-src/oneTBB/archive/v2020.3.tar.gz" sha256: "ebc4f6aa47972daed1f7bf71d100ae5bf6931c2e3144cf299c8cc7d041dca2f3" diff --git a/recipes/onetbb/2020.x/conanfile.py b/recipes/onetbb/2020.x/conanfile.py index 0fd823e9ffd157..3975cf2c1c8b6b 100644 --- a/recipes/onetbb/2020.x/conanfile.py +++ b/recipes/onetbb/2020.x/conanfile.py @@ -1,27 +1,34 @@ -from conan import ConanFile -from conan.errors import ConanInvalidConfiguration, ConanException -from conan.tools.files import get, replace_in_file, save, chdir, copy -from conan.tools.microsoft import msvc_runtime_flag, is_msvc -from conan.tools.scm import Version -from conans import tools as legacy_tools import os +import re import textwrap +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.build import check_min_cppstd +from conan.tools.files import chdir, copy, get, replace_in_file, save +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.intel import IntelCC +from conan.tools.layout import basic_layout +from conan.tools.microsoft import VCVars, msvs_toolset, msvc_runtime_flag, is_msvc +from conan.tools.scm import Version + required_conan_version = ">=1.53.0" class OneTBBConan(ConanFile): name = "onetbb" - license = "Apache-2.0" - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://github.com/oneapi-src/oneTBB" description = ( "oneAPI Threading Building Blocks (oneTBB) lets you easily write parallel " "C++ programs that take full advantage of multicore performance, that " "are portable, composable and have future-proof scalability." ) + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/oneapi-src/oneTBB" topics = ("tbb", "threading", "parallelism", "tbbmalloc") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -36,18 +43,10 @@ class OneTBBConan(ConanFile): "tbbproxy": False, } - @property - def _source_subfolder(self): - return "source_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) - @property - def _is_clanglc(self): - return self.settings.os == "Windows" and self.settings.compiler == "clang" - @property def _base_compiler(self): base = self.settings.get_safe("compiler.base") @@ -55,6 +54,14 @@ def _base_compiler(self): return self.settings.compiler.base return self.settings.compiler + @property + def _is_msvc(self): + return str(self._base_compiler) in ["Visual Studio", "msvc"] + + @property + def _is_clang_cl(self): + return self.settings.os == "Windows" and self.settings.compiler == "clang" + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -63,51 +70,42 @@ def configure(self): if self.options.shared: self.options.rm_safe("fPIC") - def validate(self): - if self.settings.os == "Macos": - if self.settings.compiler == "apple-clang" and Version(self.settings.compiler.version) < "8.0": - raise ConanInvalidConfiguration("%s %s couldn't be built by apple-clang < 8.0" % (self.name, self.version)) - if not self.options.shared: - self.output.warn("oneTBB strongly discourages usage of static linkage") - if self.options.tbbproxy and \ - (not self.options.shared or \ - not self.options.tbbmalloc): - raise ConanInvalidConfiguration("tbbproxy needs tbbmaloc and shared options") + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): del self.info.options.tbbmalloc del self.info.options.tbbproxy + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + if is_apple_os(self): + if self.settings.compiler == "apple-clang" and Version(self.settings.compiler.version) < "8.0": + raise ConanInvalidConfiguration(f"{self.name} {self.version} couldn't be built by apple-clang < 8.0") + if not self.options.shared: + self.output.warning("oneTBB strongly discourages usage of static linkage") + if self.options.tbbproxy and (not self.options.shared or not self.options.tbbmalloc): + raise ConanInvalidConfiguration("tbbproxy needs tbbmaloc and shared options") + def build_requirements(self): if self._settings_build.os == "Windows": - if "CONAN_MAKE_PROGRAM" not in os.environ and not legacy_tools.which("make"): - self.tool_requires("make/4.2.1") + if not self.conf_info.get("tools.gnu:make_program", check_type=str): + self.tool_requires("make/4.3") def source(self): - get(self, **self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) - - def build(self): - def add_flag(name, value): - if name in os.environ: - os.environ[name] += " " + value - else: - os.environ[name] = value - - # Get the version of the current compiler instead of gcc - linux_include = os.path.join(self._source_subfolder, "build", "linux.inc") - replace_in_file(self, linux_include, "shell gcc", "shell $(CC)") - replace_in_file(self, linux_include, "= gcc", "= $(CC)") - - if self.version != "2019_u9" and self.settings.build_type == "Debug": - replace_in_file(self, os.path.join(self._source_subfolder, "Makefile"), "release", "debug") - - if str(self._base_compiler) in ["Visual Studio", "msvc"]: - save(self, - os.path.join(self._source_subfolder, "build", "big_iron_msvc.inc"), + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + if self._is_msvc: + link_cmd = "xilib" if self.settings.compiler == "intel-cc" else "lib" + save( + self, + os.path.join(self.source_folder, "build", "big_iron_msvc.inc"), # copy of big_iron.inc adapted for MSVC - textwrap.dedent("""\ - LIB_LINK_CMD = {}.exe + textwrap.dedent(f"""\ + LIB_LINK_CMD = {link_cmd}.exe LIB_OUTPUT_KEY = /OUT: LIB_LINK_FLAGS = LIB_LINK_LIBS = @@ -128,39 +126,39 @@ def add_flag(name, value): MALLOC_NO_VERSION.DLL = MALLOCPROXY.DLL = MALLOCPROXY.DEF = - """.format("xilib" if self.settings.compiler == "intel" else "lib")) + """), ) - extra = "" if self.options.shared else "extra_inc=big_iron_msvc.inc" + if not self.options.shared: + tc.make_args.append("extra_inc=big_iron_msvc.inc") else: - extra = "" if self.options.shared else "extra_inc=big_iron.inc" + if not self.options.shared: + tc.make_args.append("extra_inc=big_iron.inc") arch = { "x86": "ia32", "x86_64": "intel64", "armv7": "armv7", - "armv8": "arm64" - if (self.settings.os == "iOS" or self.settings.os == "Macos") - else "aarch64", + "armv8": "arm64" if is_apple_os(self) else "aarch64", }[str(self.settings.arch)] - extra += " arch=%s" % arch + tc.make_args.append(f"arch={arch}") if self.settings.os == "iOS": - extra += " target=ios" + tc.make_args.append("target=ios") if str(self._base_compiler) in ("gcc", "clang", "apple-clang"): if str(self._base_compiler.libcxx) in ("libstdc++", "libstdc++11"): - extra += " stdlib=libstdc++" + tc.make_args.append("stdlib=libstdc++") elif str(self._base_compiler.libcxx) == "libc++": - extra += " stdlib=libc++" + tc.make_args.append("stdlib=libc++") - if str(self.settings.compiler) == "intel": - extra += " compiler=icc" + if str(self.settings.compiler) == "intel-cc": + tc.make_args.append("compiler=icc") elif str(self.settings.compiler) in ("clang", "apple-clang"): - extra += " compiler=clang" + tc.make_args.append("compiler=clang") else: - extra += " compiler=gcc" + tc.make_args.append("compiler=gcc") - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: # runtime is supposed to track the version of the c++ stdlib, # the version of glibc, and the version of the linux kernel. # However, it isn't actually used anywhere other than for @@ -168,113 +166,123 @@ def add_flag(name, value): # TBB computes the value of this variable using gcc, which we # don't necessarily want to require when building this recipe. # Setting it to a dummy value prevents TBB from calling gcc. - extra += " runtime=gnu" - elif str(self._base_compiler) in ["Visual Studio", "msvc"]: + tc.make_args.append("runtime=gnu") + elif self._is_msvc: if "MT" in msvc_runtime_flag(self): runtime = "vc_mt" else: - if self.settings.compiler == "Visual Studio": - runtime = { - "8": "vc8", - "9": "vc9", - "10": "vc10", - "11": "vc11", - "12": "vc12", - "14": "vc14", - "15": "vc14.1", - "16": "vc14.2" - }.get(str(self._base_compiler.version), "vc14.2") + # Convert MSVC toolset to TBB runtime id + # v140 -> vc14, v141 -> vc14.1, etc + toolset = msvs_toolset(self) + m = re.fullmatch(r"v(\d+)(\d)", toolset) + if m: + runtime = f"vc{m[1]}" + (f".{m[2]}" if m[2] != "0" else "") else: - runtime = { - "190": "vc14", - "191": "vc14.1", - "192": "vc14.2" - }.get(str(self._base_compiler.version), "vc14.2") - extra += " runtime=%s" % runtime - - if self.settings.compiler == "intel": - extra += " compiler=icl" + self.output.warning(f"Unknown MSVC toolset: {toolset}") + runtime = "vc14.2" + tc.make_args.append(f"runtime={runtime}") + + if self.settings.compiler == "intel-cc": + tc.make_args.append("compiler=icl") else: - extra += " compiler=cl" - cxx_std_flag = legacy_tools.cppstd_flag(self.settings) - if cxx_std_flag: - cxx_std_value = ( - cxx_std_flag.split("=")[1] - if "=" in cxx_std_flag - else cxx_std_flag.split(":")[1] - if ":" in cxx_std_flag - else None - ) - if cxx_std_value: - extra += f" stdver={cxx_std_value}" - - make = legacy_tools.get_env("CONAN_MAKE_PROGRAM", legacy_tools.which("make") or legacy_tools.which("mingw32-make")) - if not make: - raise ConanException("This package needs 'make' in the path to build") - - with chdir(self, self._source_subfolder): - # intentionally not using AutoToolsBuildEnvironment for now - it's broken for clang-cl - if self._is_clanglc: - add_flag("CFLAGS", "-mrtm") - add_flag("CXXFLAGS", "-mrtm") - - targets = ["tbb", "tbbmalloc", "tbbproxy"] - context = legacy_tools.no_op() - if self.settings.compiler == "intel": - context = legacy_tools.intel_compilervars(self) - elif is_msvc(self): - # intentionally not using vcvars for clang-cl yet - context = legacy_tools.vcvars(self) - with context: - self.run("%s %s %s" % (make, extra, " ".join(targets))) + tc.make_args.append("compiler=cl") + elif self._is_clang_cl: + tc.extra_cflags.append("-mrtm") + tc.extra_cxxflags.append("-mrtm") + + tc.generate() + + if self.settings.compiler == "intel-cc": + intelcc = IntelCC(self) + intelcc.generate() + elif is_msvc(self): + # intentionally not using vcvars for clang-cl yet + vcvars = VCVars(self) + vcvars.generate() + + def _patch_sources(self): + # Fix LDFLAGS getting incorrectly applied to ar command + linux_include = os.path.join(self.source_folder, "build", "common_rules.inc") + replace_in_file(self, linux_include, "LIB_LINK_FLAGS += $(LDFLAGS)", "") + # Get the version of the current compiler instead of gcc + linux_include = os.path.join(self.source_folder, "build", "linux.inc") + replace_in_file(self, linux_include, "shell gcc", "shell $(CC)") + replace_in_file(self, linux_include, "= gcc", "= $(CC)") + if self.version != "2019_u9" and self.settings.build_type == "Debug": + replace_in_file(self, os.path.join(self.source_folder, "Makefile"), "release", "debug") + + def build(self): + self._patch_sources() + with chdir(self, self.source_folder): + autotools = Autotools(self) + for target in ["tbb", "tbbmalloc", "tbbproxy"]: + autotools.make(target) def package(self): - copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self._source_subfolder) - copy(self, pattern="*.h", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self._source_subfolder, "include")) - copy(self, pattern="*", dst=os.path.join(self.package_folder, "include", "tbb", "compat"), src=os.path.join(self._source_subfolder, "include", "tbb", "compat")) - build_folder = os.path.join(self._source_subfolder, "build") + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) + copy(self, "*", + dst=os.path.join(self.package_folder, "include", "tbb", "compat"), + src=os.path.join(self.source_folder, "include", "tbb", "compat")) + + build_folder = os.path.join(self.source_folder, "build") build_type = "debug" if self.settings.build_type == "Debug" else "release" - copy(self, pattern=f"*{build_type}*.lib", dst=os.path.join(self.package_folder, "lib"), src=build_folder, keep_path=False) - copy(self, pattern=f"*{build_type}*.a", dst=os.path.join(self.package_folder, "lib"), src=build_folder, keep_path=False) - copy(self, pattern=f"*{build_type}*.dll", dst=os.path.join(self.package_folder, "bin"), src=build_folder, keep_path=False) - copy(self, pattern=f"*{build_type}*.dylib", dst=os.path.join(self.package_folder, "lib"), src=build_folder, keep_path=False) + for extension in ["lib", "a", "dylib"]: + copy(self, f"*{build_type}*.{extension}", + dst=os.path.join(self.package_folder, "lib"), + src=build_folder, keep_path=False) + copy(self, f"*{build_type}*.dll", + dst=os.path.join(self.package_folder, "bin"), + src=build_folder, keep_path=False) + # Copy also .dlls to lib folder so consumers can link against them directly when using MinGW if self.settings.os == "Windows" and self.settings.compiler == "gcc": - copy(self, f"*{build_type}*.dll", dst=os.path.join(self.package_folder, "lib"), src=build_folder, keep_path=False) + copy(self, f"*{build_type}*.dll", + dst=os.path.join(self.package_folder, "lib"), + src=build_folder, keep_path=False) - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"] and self.options.shared: extension = "so" - if self.options.shared: - copy(self, f"*{build_type}*.{extension}.*", dst=os.path.join(self.package_folder, "lib"), src=build_folder, keep_path=False) - outputlibdir = os.path.join(self.package_folder, "lib") - with chdir(self, outputlibdir): - for fpath in os.listdir(outputlibdir): - filepath = fpath[0:fpath.rfind("." + extension) + len(extension) + 1] - self.run(f'ln -s "{fpath}" "{filepath}"', run_environment=True) + copy(self, f"*{build_type}*.{extension}.*", + dst=os.path.join(self.package_folder, "lib"), + src=build_folder, keep_path=False) + # Create libtbb.so.2 -> libtbb.so, etc symlinks + with chdir(self, os.path.join(self.package_folder, "lib")): + for fname in os.listdir("."): + fname_without_version = fname.split(f".{extension}", 1)[0] + f".{extension}" + self.run(f'ln -s "{fname}" "{fname_without_version}"') def package_info(self): self.cpp_info.set_property("cmake_file_name", "TBB") + self.cpp_info.set_property("cmake_target_name", "TBB::TBB") suffix = "_debug" if self.settings.build_type == "Debug" else "" # tbb self.cpp_info.components["libtbb"].set_property("cmake_target_name", "TBB::tbb") - self.cpp_info.components["libtbb"].libs = ["tbb{}".format(suffix)] + self.cpp_info.components["libtbb"].libs = [f"tbb{suffix}"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["libtbb"].system_libs = ["dl", "rt", "pthread"] + self.cpp_info.components["libtbb"].system_libs = ["m", "dl", "rt", "pthread"] # tbbmalloc if self.options.tbbmalloc: self.cpp_info.components["tbbmalloc"].set_property("cmake_target_name", "TBB::tbbmalloc") - self.cpp_info.components["tbbmalloc"].libs = ["tbbmalloc{}".format(suffix)] + self.cpp_info.components["tbbmalloc"].libs = [f"tbbmalloc{suffix}"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["tbbmalloc"].system_libs = ["dl", "pthread"] + self.cpp_info.components["tbbmalloc"].system_libs = ["m", "dl", "pthread"] # tbbmalloc_proxy if self.options.tbbproxy: self.cpp_info.components["tbbmalloc_proxy"].set_property("cmake_target_name", "TBB::tbbmalloc_proxy") - self.cpp_info.components["tbbmalloc_proxy"].libs = ["tbbmalloc_proxy{}".format(suffix)] + self.cpp_info.components["tbbmalloc_proxy"].libs = [f"tbbmalloc_proxy{suffix}"] self.cpp_info.components["tbbmalloc_proxy"].requires = ["tbbmalloc"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["tbbmalloc_proxy"].system_libs = ["m"] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.names["cmake_find_package"] = "TBB" diff --git a/recipes/onetbb/2020.x/test_package/CMakeLists.txt b/recipes/onetbb/2020.x/test_package/CMakeLists.txt index d5a40167452f4f..2dd759c70dd114 100644 --- a/recipes/onetbb/2020.x/test_package/CMakeLists.txt +++ b/recipes/onetbb/2020.x/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(TBB REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/onetbb/2020.x/test_package/conanfile.py b/recipes/onetbb/2020.x/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/onetbb/2020.x/test_package/conanfile.py +++ b/recipes/onetbb/2020.x/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/onetbb/2020.x/test_v1_package/CMakeLists.txt b/recipes/onetbb/2020.x/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/onetbb/2020.x/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/onetbb/2020.x/test_v1_package/conanfile.py b/recipes/onetbb/2020.x/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/onetbb/2020.x/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/onetbb/all/test_package/CMakeLists.txt b/recipes/onetbb/all/test_package/CMakeLists.txt index f510136a26a978..fbae62535650c2 100644 --- a/recipes/onetbb/all/test_package/CMakeLists.txt +++ b/recipes/onetbb/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) find_package(TBB REQUIRED CONFIG) diff --git a/recipes/onetbb/all/test_v1_package/CMakeLists.txt b/recipes/onetbb/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/onetbb/all/test_v1_package/CMakeLists.txt +++ b/recipes/onetbb/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) diff --git a/recipes/onetbb/config.yml b/recipes/onetbb/config.yml index 7995868f434adb..7a33bda288759f 100644 --- a/recipes/onetbb/config.yml +++ b/recipes/onetbb/config.yml @@ -9,6 +9,8 @@ versions: folder: all "2021.3.0": folder: all + "2020.3.3": + folder: "2020.x" "2020.3": folder: "2020.x" "2020.2": From 6a5fee9b18f66cd840da22bb0c334f6f5c28cfb4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 19 Aug 2023 18:26:24 +0300 Subject: [PATCH 0314/1140] (#18756) quickfix: migrate to Conan v2 * quickfix: migrate to Conan v2 * quickfix: revert to collect_libs() for Windows on v1 * quickfix: restore VirtualRunEnv in test_package * quickfix: bump deps --------- Co-authored-by: Carlos Zoido --- recipes/quickfix/all/conandata.yml | 9 -- recipes/quickfix/all/conanfile.py | 138 ++++++++++-------- ...ake-version-add-conan-basic-setup-an.patch | 4 +- .../quickfix/all/test_package/CMakeLists.txt | 7 +- .../quickfix/all/test_package/conanfile.py | 22 ++- .../all/test_v1_package/CMakeLists.txt | 8 + .../quickfix/all/test_v1_package/conanfile.py | 18 +++ 7 files changed, 124 insertions(+), 82 deletions(-) create mode 100644 recipes/quickfix/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/quickfix/all/test_v1_package/conanfile.py diff --git a/recipes/quickfix/all/conandata.yml b/recipes/quickfix/all/conandata.yml index 863c20f1e79d63..bec3ce0e03d95e 100644 --- a/recipes/quickfix/all/conandata.yml +++ b/recipes/quickfix/all/conandata.yml @@ -5,20 +5,11 @@ sources: patches: "1.15.1": - patch_file: "patches/0001-Fix-build-for-C-17-replace-throw-.-with-EXCEPT.patch" - base_path: "source_subfolder" - patch_file: "patches/0002-except-copy.patch" - base_path: "source_subfolder" - patch_file: "patches/0003-fix-condition-for-using-tr1-namespace.patch" - base_path: "source_subfolder" - patch_file: "patches/0004-remove-tests-from-compilatin-unit-performance-and-ac.patch" - base_path: "source_subfolder" - patch_file: "patches/0005-inc.-required-CMake-version-add-conan-basic-setup-an.patch" - base_path: "source_subfolder" - patch_file: "patches/0006-manage-postgres-through-conan.patch" - base_path: "source_subfolder" - patch_file: "patches/0007-add-support-to-static-libraries-for-non-windows-buil.patch" - base_path: "source_subfolder" - patch_file: "patches/0008-manage-mysql-through-conan.patch" - base_path: "source_subfolder" - patch_file: "patches/0009-downgrade-cmake-minimum-required.patch" - base_path: "source_subfolder" diff --git a/recipes/quickfix/all/conanfile.py b/recipes/quickfix/all/conanfile.py index c5c614561ff611..adfbbac153de52 100644 --- a/recipes/quickfix/all/conanfile.py +++ b/recipes/quickfix/all/conanfile.py @@ -1,48 +1,42 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, collect_libs + +required_conan_version = ">=1.53.0" + class QuickfixConan(ConanFile): name = "quickfix" + description = "QuickFIX is a free and open source implementation of the FIX protocol" license = "The QuickFIX Software License, Version 1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "http://www.quickfixengine.org" - description = "QuickFIX is a free and open source implementation of the FIX protocol" - topics = ("conan", "QuickFIX", "FIX", "Financial Information Exchange", "libraries", "cpp") - settings = "os", "compiler", "build_type", "arch" - options = {"fPIC": [True, False], - "shared": [True, False], - "with_ssl": [True, False], - "with_postgres": [True, False], - "with_mysql": [None, "libmysqlclient"]} - default_options = {"fPIC": True, - "shared": False, - "with_ssl": False, - "with_postgres": False, - "with_mysql": None} - generators = "cmake" - exports_sources = "patches/**" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - - def requirements(self): - if self.options.with_ssl: - self.requires("openssl/1.1.1q") - - if self.options.with_postgres: - self.requires("libpq/14.2") - - if self.options.with_mysql == "libmysqlclient": - self.requires("libmysqlclient/8.0.29") + topics = ("FIX", "Financial Information Exchange", "libraries", "cpp") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_ssl": [True, False], + "with_postgres": [True, False], + "with_mysql": [None, "libmysqlclient"], + } + default_options = { + "shared": False, + "fPIC": True, + "with_ssl": False, + "with_postgres": False, + "with_mysql": None, + } + + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -50,43 +44,67 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + if self.options.with_ssl: + self.requires("openssl/[>=1.1 <4]") + + if self.options.with_postgres: + self.requires("libpq/15.3") + + if self.options.with_mysql == "libmysqlclient": + self.requires("libmysqlclient/8.0.31") def validate(self): if self.settings.os == "Windows" and self.options.shared: raise ConanInvalidConfiguration("QuickFIX cannot be built as shared lib on Windows") - if self.settings.os == "Macos" and self.settings.arch == "armv8": - raise ConanInvalidConfiguration("QuickFIX doesn't support ARM compilation") # See issue: https://github.com/quickfix/quickfix/issues/206 + if is_apple_os(self) and self.settings.arch == "armv8": + # See issue: https://github.com/quickfix/quickfix/issues/206 + raise ConanInvalidConfiguration("QuickFIX doesn't support ARM compilation") - def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") - def _configure_cmake(self): - if not self._cmake: - self._cmake = CMake(self) - self._cmake.definitions["HAVE_SSL"] = self.options.with_ssl - self._cmake.definitions["HAVE_POSTGRESQL"] = self.options.with_postgres - self._cmake.definitions["HAVE_MYSQL"] = bool(self.options.with_mysql) - self._cmake.configure(source_folder=self._source_subfolder, build_folder=self._build_subfolder) - return self._cmake + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + tc = CMakeToolchain(self) + tc.variables["HAVE_SSL"] = self.options.with_ssl + tc.variables["HAVE_POSTGRESQL"] = self.options.with_postgres + tc.variables["HAVE_MYSQL"] = bool(self.options.with_mysql) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) - - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build(target="quickfix") def package(self): - cmake = self._configure_cmake() + cmake = CMake(self) cmake.install() - self.copy("config.h", dst=os.path.join("include", "quickfix"), src=self._build_subfolder) - self.copy("Except.h", dst="include", src=os.path.join(self._source_subfolder, "src", "C++")) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - tools.rmdir(os.path.join(self.package_folder, "share")) + copy(self, "config.h", + dst=os.path.join(self.package_folder, "include", "quickfix"), + src=self.build_folder) + copy(self, "Except.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "src", "C++")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) + self.cpp_info.libs = collect_libs(self) if self.options.with_ssl: self.cpp_info.defines.append("HAVE_SSL=1") diff --git a/recipes/quickfix/all/patches/0005-inc.-required-CMake-version-add-conan-basic-setup-an.patch b/recipes/quickfix/all/patches/0005-inc.-required-CMake-version-add-conan-basic-setup-an.patch index 3480935d8cd0e9..fbea88ec0b6c1a 100644 --- a/recipes/quickfix/all/patches/0005-inc.-required-CMake-version-add-conan-basic-setup-an.patch +++ b/recipes/quickfix/all/patches/0005-inc.-required-CMake-version-add-conan-basic-setup-an.patch @@ -25,8 +25,8 @@ index 48908ead..8789432c 100644 endif() project(${quickfix_PROJECT_NAME} VERSION 0.1 LANGUAGES CXX C) -+include(${PROJECT_BINARY_DIR}/../conanbuildinfo.cmake) -+conan_basic_setup() ++ ++ message("-- Project name ${CMAKE_PROJECT_NAME}") set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/") diff --git a/recipes/quickfix/all/test_package/CMakeLists.txt b/recipes/quickfix/all/test_package/CMakeLists.txt index 57cf0bfd3debb2..59fa2d07ab926b 100644 --- a/recipes/quickfix/all/test_package/CMakeLists.txt +++ b/recipes/quickfix/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(quickfix REQUIRED CONFIG) add_executable(executor ${PROJECT_SOURCE_DIR}/executor.cpp) -target_link_libraries(executor ${CONAN_LIBS}) +target_link_libraries(executor PRIVATE quickfix::quickfix) diff --git a/recipes/quickfix/all/test_package/conanfile.py b/recipes/quickfix/all/test_package/conanfile.py index a68d648c5c5b56..bf3ebab04211e7 100644 --- a/recipes/quickfix/all/test_package/conanfile.py +++ b/recipes/quickfix/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class QuickfixTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "executor") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "executor") + self.run(bin_path, env="conanrun") diff --git a/recipes/quickfix/all/test_v1_package/CMakeLists.txt b/recipes/quickfix/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/quickfix/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/quickfix/all/test_v1_package/conanfile.py b/recipes/quickfix/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..3148dc9605e6c1 --- /dev/null +++ b/recipes/quickfix/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class QuickfixTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "executor") + self.run(bin_path, run_environment=True) From a55a137d76b14f3f1693df04af7d780bdb3e5825 Mon Sep 17 00:00:00 2001 From: tt4g <45120617+tt4g@users.noreply.github.com> Date: Sun, 20 Aug 2023 00:48:30 +0900 Subject: [PATCH 0315/1140] (#18857) libpqxx: add version 7.8.0 * libpqxx: add version 7.8.0 * libpqxx: fix build on C++17 * libpqxx: fix conandata.yml format * libpqxx: build only static or shared library * libpqxx: Fix MSVC 2022 compile error An older version could not be built by MSVC 2022. Since the compile error was avoided by a change made in another task, only the relevant change is imported in the patch. --- recipes/libpqxx/all/conandata.yml | 75 +++++++++++++++++++ recipes/libpqxx/all/conanfile.py | 6 ++ ...fix-alternative-operator-error-7.8.0.patch | 24 ++++++ .../patches/stop-using-strnlen-7.2.1.patch | 28 +++++++ .../patches/stop-using-strnlen-7.3.2.patch | 28 +++++++ .../patches/stop-using-strnlen-7.4.2.patch | 28 +++++++ recipes/libpqxx/config.yml | 2 + 7 files changed, 191 insertions(+) create mode 100644 recipes/libpqxx/all/patches/fix-alternative-operator-error-7.8.0.patch create mode 100644 recipes/libpqxx/all/patches/stop-using-strnlen-7.2.1.patch create mode 100644 recipes/libpqxx/all/patches/stop-using-strnlen-7.3.2.patch create mode 100644 recipes/libpqxx/all/patches/stop-using-strnlen-7.4.2.patch diff --git a/recipes/libpqxx/all/conandata.yml b/recipes/libpqxx/all/conandata.yml index a8a8be54d6643c..9d9a75993b0261 100644 --- a/recipes/libpqxx/all/conandata.yml +++ b/recipes/libpqxx/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "7.8.0": + url: "https://github.com/jtv/libpqxx/archive/refs/tags/7.8.0.tar.gz" + sha256: "bc471d8d34588f820f38e19e1cc217f399212eef900416cf12f90fab293628af" "7.7.5": url: "https://github.com/jtv/libpqxx/archive/refs/tags/7.7.5.tar.gz" sha256: "c7dc3e8fa2eee656f2b6a8179d72f15db10e97a80dc4f173f806e615ea990973" @@ -42,39 +45,111 @@ sources: url: "https://github.com/jtv/libpqxx/archive/6.4.8.tar.gz" sha256: "3f7aba951822e01f1b9f9f353702954773323dd9f9dc376ffb57cb6bbd9a7a2f" patches: + "7.8.0": + - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" + - patch_file: "patches/fix-alternative-operator-error-7.8.0.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/714" + patch_description: "Fix a bug undeclared identifier alternative operator." + patch_type: "bugfix" "7.7.5": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.7.4": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.7.3": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.7.2": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-install-library-symlink-7.7.2.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/552" + patch_description: "Fix install library symlink error." + patch_type: "bugfix" "7.7.0": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-clang-compilation-7.7.0.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/519" + patch_description: "Fix clang compile error." + patch_type: "bugfix" "7.6.1": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-inline-constexpr-local-variable-problem-7.6.0.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/468" + patch_description: "Fixed a problem that some compilers did not allow `inline constexpr` local variable declarations." + patch_type: "bugfix" - patch_file: "patches/fix-remove-unlikely-annotation-before-return-7.6.0_to_7.6.1.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/476" + patch_description: "fix: Remove `unlikely` annotation before `return`" + patch_type: "bugfix" "7.6.0": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-inline-constexpr-local-variable-problem-7.6.0.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/468" + patch_description: "Fixed a problem that some compilers did not allow `inline constexpr` local variable declarations." + patch_type: "bugfix" - patch_file: "patches/fix-remove-unlikely-annotation-before-return-7.6.0_to_7.6.1.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/476" + patch_description: "fix: Remove `unlikely` annotation before `return`" + patch_type: "bugfix" "7.5.3": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.4.2": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" + - patch_file: "patches/stop-using-strnlen-7.4.2.patch" + patch_source: "https://github.com/jtv/libpqxx/commit/df30e186e148acb031244ed0ab1151731d3501a4" + patch_description: "Fix MSVC 2022 compile error: '<': no operator found which takes a right-hand operand of type 'std::_String_view_iterator<_Traits>'" + patch_type: "bugfix" "7.3.2": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-msvc-compilation-7.3.1.patch" + patch_source: "https://github.com/jtv/libpqxx/pull/406" + patch_description: "Fix a bug that syntax error on Visual Studio 2017" + patch_type: "bugfix" + - patch_file: "patches/stop-using-strnlen-7.3.2.patch" + patch_source: "https://github.com/jtv/libpqxx/commit/df30e186e148acb031244ed0ab1151731d3501a4" + patch_description: "Fix MSVC 2022 compile error: '<': no operator found which takes a right-hand operand of type 'std::_String_view_iterator<_Traits>'" + patch_type: "bugfix" "7.2.1": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" + - patch_file: "patches/stop-using-strnlen-7.2.1.patch" + patch_source: "https://github.com/jtv/libpqxx/commit/df30e186e148acb031244ed0ab1151731d3501a4" + patch_description: "Fix MSVC 2022 compile error: '<': no operator found which takes a right-hand operand of type 'std::_String_view_iterator<_Traits>'" + patch_type: "bugfix" "7.1.2": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.0.7": - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" - patch_file: "patches/fix-not-declared-dumb_stringstream-7.0.6_to_7.0.7.patch" + patch_source: "https://github.com/jtv/libpqxx/commit/0e81d36f522093d7215b3792f1c62dcd06a34ad1" + patch_description: "Fix 'dumb_stringstream' was not declared." + patch_type: "bugfix" "6.4.8": - patch_file: "patches/0001-cmake-fix-module-6.4.8.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" diff --git a/recipes/libpqxx/all/conanfile.py b/recipes/libpqxx/all/conanfile.py index ef9bfe326bc0ae..2c06284a7d4d74 100644 --- a/recipes/libpqxx/all/conanfile.py +++ b/recipes/libpqxx/all/conanfile.py @@ -104,6 +104,12 @@ def generate(self): tc.variables["BUILD_TEST"] = False # Set `-mmacosx-version-min` to enable C++17 standard library support. tc.variables["CMAKE_OSX_DEPLOYMENT_TARGET"] = self._mac_os_minimum_required_version + if Version(self.version) < "7.0": + if self.options.shared: + tc.variables["SKIP_PQXX_STATIC"] = True + else: + tc.variables["SKIP_PQXX_SHARED"] = True + tc.generate() deps = CMakeDeps(self) diff --git a/recipes/libpqxx/all/patches/fix-alternative-operator-error-7.8.0.patch b/recipes/libpqxx/all/patches/fix-alternative-operator-error-7.8.0.patch new file mode 100644 index 00000000000000..9a792a2cc015e3 --- /dev/null +++ b/recipes/libpqxx/all/patches/fix-alternative-operator-error-7.8.0.patch @@ -0,0 +1,24 @@ +Fix a bug undeclared identifier alternative operator (https://github.com/jtv/libpqxx/pull/714) +diff --git a/include/pqxx/internal/header-pre.hxx b/include/pqxx/internal/header-pre.hxx +index 595a53b4..9d4c60e7 100644 +--- a/include/pqxx/internal/header-pre.hxx ++++ b/include/pqxx/internal/header-pre.hxx +@@ -58,6 +58,18 @@ + // Workarounds & definitions that need to be included even in library's headers + #include "pqxx/config-public-compiler.h" + ++#if defined(_MSC_VER) ++# define PQXX_CPLUSPLUS _MSVC_LANG ++#else ++# define PQXX_CPLUSPLUS __cplusplus ++#endif ++ ++// C++20: No longer needed. ++// Enable ISO-646 alternative operaotr representations: "and" instead of "&&" ++// etc. on older compilers. C++20 removes this header. ++#if PQXX_CPLUSPLUS <= 201703L && __has_include() ++# include ++#endif + + #if defined(PQXX_HAVE_GCC_PURE) + /// Declare function "pure": no side effects, only reads globals and its args. diff --git a/recipes/libpqxx/all/patches/stop-using-strnlen-7.2.1.patch b/recipes/libpqxx/all/patches/stop-using-strnlen-7.2.1.patch new file mode 100644 index 00000000000000..39e7b4ab81e4ed --- /dev/null +++ b/recipes/libpqxx/all/patches/stop-using-strnlen-7.2.1.patch @@ -0,0 +1,28 @@ +diff --git a/src/strconv.cxx b/src/strconv.cxx +index 4339625e..200b416a 100644 +--- a/src/strconv.cxx ++++ b/src/strconv.cxx +@@ -265,18 +265,18 @@ namespace + template + [[maybe_unused]] inline TYPE from_string_arithmetic(std::string_view in) + { +- char const *begin; ++ char const *here; ++ auto const end{in.data() + std::size(in)}; + + // Skip whitespace. This is not the proper way to do it, but I see no way + // that any of the supported encodings could ever produce a valid character + // whose byte sequence would confuse this code. +- for (begin = in.data(); +- begin < std::end(in) and (*begin == ' ' or *begin == '\t'); ++begin) ++ for (here = in.data(); ++ here < end and (*here == ' ' or *here == '\t'); ++here) + ; + +- auto const end{in.data() + std::size(in)}; + TYPE out; +- auto const res{std::from_chars(begin, end, out)}; ++ auto const res{std::from_chars(here, end, out)}; + if (res.ec == std::errc() and res.ptr == end) + return out; + diff --git a/recipes/libpqxx/all/patches/stop-using-strnlen-7.3.2.patch b/recipes/libpqxx/all/patches/stop-using-strnlen-7.3.2.patch new file mode 100644 index 00000000000000..5602c77e030c69 --- /dev/null +++ b/recipes/libpqxx/all/patches/stop-using-strnlen-7.3.2.patch @@ -0,0 +1,28 @@ +diff --git a/src/strconv.cxx b/src/strconv.cxx +index d82e5c53..ee1628ff 100644 +--- a/src/strconv.cxx ++++ b/src/strconv.cxx +@@ -264,18 +264,18 @@ namespace + template + [[maybe_unused]] inline TYPE from_string_arithmetic(std::string_view in) + { +- char const *begin; ++ char const *here; ++ auto const end{in.data() + std::size(in)}; + + // Skip whitespace. This is not the proper way to do it, but I see no way + // that any of the supported encodings could ever produce a valid character + // whose byte sequence would confuse this code. +- for (begin = in.data(); +- begin < std::end(in) and (*begin == ' ' or *begin == '\t'); ++begin) ++ for (here = in.data(); ++ here < end and (*here == ' ' or *here == '\t'); ++here) + ; + +- auto const end{in.data() + std::size(in)}; + TYPE out; +- auto const res{std::from_chars(begin, end, out)}; ++ auto const res{std::from_chars(here, end, out)}; + if (res.ec == std::errc() and res.ptr == end) + return out; + diff --git a/recipes/libpqxx/all/patches/stop-using-strnlen-7.4.2.patch b/recipes/libpqxx/all/patches/stop-using-strnlen-7.4.2.patch new file mode 100644 index 00000000000000..0c628fb55fdff3 --- /dev/null +++ b/recipes/libpqxx/all/patches/stop-using-strnlen-7.4.2.patch @@ -0,0 +1,28 @@ +diff --git a/src/strconv.cxx b/src/strconv.cxx +index ea4d3c82..08d645eb 100644 +--- a/src/strconv.cxx ++++ b/src/strconv.cxx +@@ -264,18 +264,18 @@ namespace + template + [[maybe_unused]] inline TYPE from_string_arithmetic(std::string_view in) + { +- char const *begin; ++ char const *here; ++ auto const end{in.data() + std::size(in)}; + + // Skip whitespace. This is not the proper way to do it, but I see no way + // that any of the supported encodings could ever produce a valid character + // whose byte sequence would confuse this code. +- for (begin = in.data(); +- begin < std::end(in) and (*begin == ' ' or *begin == '\t'); ++begin) ++ for (here = in.data(); ++ here < end and (*here == ' ' or *here == '\t'); ++here) + ; + +- auto const end{in.data() + std::size(in)}; + TYPE out; +- auto const res{std::from_chars(begin, end, out)}; ++ auto const res{std::from_chars(here, end, out)}; + if (res.ec == std::errc() and res.ptr == end) + return out; + diff --git a/recipes/libpqxx/config.yml b/recipes/libpqxx/config.yml index 96d5c5cc009569..9ea1691e885020 100644 --- a/recipes/libpqxx/config.yml +++ b/recipes/libpqxx/config.yml @@ -1,4 +1,6 @@ versions: + "7.8.0": + folder: all "7.7.5": folder: all "7.7.4": From 003f526787e31440b1ac9b8b92f6e3d2a47d54a6 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 19 Aug 2023 18:46:02 +0200 Subject: [PATCH 0316/1140] (#18498) gdal/pre_3.5.0: bump deps, remove old versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gdal/pre_3.5.0: bump deps * gdal: remove old versions * fix test_package * gdal/pre_3.5.0: bump deps * bump deps --------- Co-authored-by: Rubén Rincón Blanco --- recipes/gdal/config.yml | 4 - recipes/gdal/pre_3.5.0/conandata.yml | 20 -- recipes/gdal/pre_3.5.0/conanfile.py | 24 +- .../patches/3.1.x/fix-autotools-3.1.4.patch | 283 ---------------- .../patches/3.1.x/fix-import-dll-msvc.patch | 15 - .../patches/3.1.x/fix-include-jsonc.patch | 104 ------ .../patches/3.1.x/fix-include-podofo.patch | 11 - .../3.1.x/fix-include-xerces-3.1.2.patch | 63 ---- .../patches/3.1.x/fix-nmake-common.patch | 165 ---------- .../patches/3.1.x/fix-nmake-opt-3.1.2.patch | 14 - .../patches/3.2.x/fix-autotools.patch | 304 ------------------ .../patches/3.2.x/fix-include-jsonc.patch | 104 ------ .../patches/3.2.x/fix-include-podofo.patch | 11 - .../patches/3.2.x/fix-include-xerces.patch | 63 ---- .../pre_3.5.0/patches/3.2.x/fix-nmake.patch | 179 ----------- .../gdal/pre_3.5.0/test_package/conanfile.py | 5 +- 16 files changed, 15 insertions(+), 1354 deletions(-) delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-autotools-3.1.4.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-import-dll-msvc.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-jsonc.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-podofo.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-xerces-3.1.2.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-nmake-common.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.1.x/fix-nmake-opt-3.1.2.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.2.x/fix-autotools.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-jsonc.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-podofo.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-xerces.patch delete mode 100644 recipes/gdal/pre_3.5.0/patches/3.2.x/fix-nmake.patch diff --git a/recipes/gdal/config.yml b/recipes/gdal/config.yml index da2f4dc3a9cabb..a2ce278d929656 100644 --- a/recipes/gdal/config.yml +++ b/recipes/gdal/config.yml @@ -11,7 +11,3 @@ versions: folder: "pre_3.5.0" "3.3.3": folder: "pre_3.5.0" - "3.2.3": - folder: "pre_3.5.0" - "3.1.4": - folder: "pre_3.5.0" diff --git a/recipes/gdal/pre_3.5.0/conandata.yml b/recipes/gdal/pre_3.5.0/conandata.yml index 4ca595dd102568..49983edc62730c 100644 --- a/recipes/gdal/pre_3.5.0/conandata.yml +++ b/recipes/gdal/pre_3.5.0/conandata.yml @@ -8,12 +8,6 @@ sources: "3.3.3": url: "https://github.com/OSGeo/gdal/releases/download/v3.3.3/gdal-3.3.3.tar.gz" sha256: "28925ea4717b02185ee208bfc121a94fa0bc1dfe9cb862fd3868c2a0394d605a" - "3.2.3": - url: "https://github.com/OSGeo/gdal/releases/download/v3.2.3/gdal-3.2.3.tar.gz" - sha256: "86a35aad60a1eb87c2c0c145f9bccd83a47c4781254544ed5246f64d55ee1f18" - "3.1.4": - url: "https://github.com/OSGeo/gdal/releases/download/v3.1.4/gdal-3.1.4.tar.gz" - sha256: "5f09ea6ca797e296b608d261e08e18ffa43a12fa28d460ae139d2a026ee2b0c0" patches: "3.4.3": - patch_file: "patches/3.4.x/fix-autotools-3.4.3.patch" @@ -33,17 +27,3 @@ patches: - patch_file: "patches/3.3.x/fix-include-jsonc.patch" - patch_file: "patches/3.3.x/fix-include-xerces.patch" - patch_file: "patches/3.3.x/fix-include-podofo.patch" - "3.2.3": - - patch_file: "patches/3.2.x/fix-autotools.patch" - - patch_file: "patches/3.2.x/fix-nmake.patch" - - patch_file: "patches/3.2.x/fix-include-jsonc.patch" - - patch_file: "patches/3.2.x/fix-include-xerces.patch" - - patch_file: "patches/3.2.x/fix-include-podofo.patch" - "3.1.4": - - patch_file: "patches/3.1.x/fix-autotools-3.1.4.patch" - - patch_file: "patches/3.1.x/fix-nmake-common.patch" - - patch_file: "patches/3.1.x/fix-nmake-opt-3.1.2.patch" - - patch_file: "patches/3.1.x/fix-import-dll-msvc.patch" - - patch_file: "patches/3.1.x/fix-include-jsonc.patch" - - patch_file: "patches/3.1.x/fix-include-xerces-3.1.2.patch" - - patch_file: "patches/3.1.x/fix-include-podofo.patch" diff --git a/recipes/gdal/pre_3.5.0/conanfile.py b/recipes/gdal/pre_3.5.0/conanfile.py index 7ecdfb6713c6ab..65bbd7d92d812a 100644 --- a/recipes/gdal/pre_3.5.0/conanfile.py +++ b/recipes/gdal/pre_3.5.0/conanfile.py @@ -246,21 +246,21 @@ def layout(self): self.folders.build = self.folders.source def requirements(self): - self.requires("json-c/0.16") + self.requires("json-c/0.17") self.requires("libgeotiff/1.7.1") # self.requires("libopencad/0.0.2") # TODO: use conan recipe when available instead of internal one - self.requires("libtiff/4.4.0") - self.requires("proj/9.1.1") + self.requires("libtiff/4.5.1") + self.requires("proj/9.2.1") if Version(self.version) >= "3.1.0": self.requires("flatbuffers/2.0.5") if self.options.get_safe("with_zlib", True): self.requires("zlib/1.2.13") if self.options.get_safe("with_libdeflate"): - self.requires("libdeflate/1.17") + self.requires("libdeflate/1.18") if self.options.with_libiconv: self.requires("libiconv/1.17") if self.options.get_safe("with_zstd"): - self.requires("zstd/1.5.2") + self.requires("zstd/1.5.5") if self.options.get_safe("with_blosc"): self.requires("c-blosc/1.21.3") if self.options.get_safe("with_lz4"): @@ -274,7 +274,7 @@ def requirements(self): # if self.options.with_pcraster: # self.requires("pcraster-rasterformat/1.3.2") if self.options.get_safe("with_png", True): - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") if self.options.with_dds: self.requires("crunch/cci.20190615") if self.options.with_gta: @@ -284,7 +284,7 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.4") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") if self.options.with_charls: @@ -326,13 +326,13 @@ def requirements(self): # if self.options.with_dods_root: # self.requires("libdap/3.20.6") if self.options.with_curl: - self.requires("libcurl/7.87.0") + self.requires("libcurl/8.2.1") if self.options.with_xml2: self.requires("libxml2/2.10.3") # if self.options.with_spatialite: # self.requires("libspatialite/4.3.0a") if self.options.get_safe("with_sqlite3"): - self.requires("sqlite3/3.40.1") + self.requires("sqlite3/3.42.0") # if self.options.with_rasterlite2: # self.requires("rasterlite2/x.x.x") if self.options.get_safe("with_pcre"): @@ -340,7 +340,7 @@ def requirements(self): if self.options.get_safe("with_pcre2"): self.requires("pcre2/10.42") if self.options.with_webp: - self.requires("libwebp/1.3.0") + self.requires("libwebp/1.3.1") if self.options.with_geos: self.requires("geos/3.11.1") # if self.options.with_sfcgal: @@ -367,11 +367,11 @@ def requirements(self): if self.options.with_cryptopp: self.requires("cryptopp/8.7.0") if self.options.with_crypto: - self.requires("openssl/1.1.1s") + self.requires("openssl/1.1.1u") # if not self.options.without_lerc: # self.requires("lerc/2.1") # TODO: use conan recipe (not possible yet because lerc API is broken for GDAL) if self.options.get_safe("with_exr"): - self.requires("openexr/3.1.5") + self.requires("openexr/3.1.9") if self.options.get_safe("with_heif"): self.requires("libheif/1.13.0") diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-autotools-3.1.4.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-autotools-3.1.4.patch deleted file mode 100644 index 974146f6a3f7ad..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-autotools-3.1.4.patch +++ /dev/null @@ -1,283 +0,0 @@ ---- a/GDALmake.opt.in -+++ b/GDALmake.opt.in -@@ -601,7 +601,7 @@ endif - - ifeq ($(HAVE_LIBTOOL), yes) - --CONFIG_LIBS = $(GDAL_ROOT)/$(LIBGDAL) -+CONFIG_LIBS = $(GDAL_ROOT)/$(LIBGDAL) $(LIBS) - ifeq ($(MACOSX_FRAMEWORK),yes) - CONFIG_LIBS_INS = -L$(INST_LIB)/unix/lib -lgdal - else ---- a/configure.ac -+++ b/configure.ac -@@ -1214,6 +1214,7 @@ dnl --------------------------------------------------------------------------- - dnl PROJ.6 related stuff - dnl --------------------------------------------------------------------------- - -+PKG_PROG_PKG_CONFIG([0.21]) - AC_MSG_CHECKING([for PROJ >= 6 library]) - - AC_ARG_WITH(proj,[ --with-proj=ARG Compile with PROJ.x (ARG=yes or path)],,) -@@ -1229,11 +1230,7 @@ if test "x$with_proj" = "xno" ; then - else - - if test "x$with_proj" = "xyes" -o "x$with_proj" = "x"; then -- ORIG_LIBS="$LIBS" -- LIBS="-lproj $ORIG_LIBS" -- AC_LANG_PUSH([C++]) -- AC_CHECK_LIB(proj,proj_create_from_wkt,PROJ_FOUND=yes,PROJ_FOUND=no,) -- AC_LANG_POP([C++]) -+ PROJ_FOUND=yes - if test "$PROJ_FOUND" = "no"; then - AC_LANG_PUSH([C++]) - AC_CHECK_LIB(proj,internal_proj_create_from_wkt,PROJ_FOUND=yes,PROJ_FOUND=no,) -@@ -1876,7 +1873,6 @@ else - - DDS_SETTING=yes - CRUNCHDIR="$with_dds" -- LIBS="-L$with_dds/lib/ -lcrunch $LIBS" - echo "using libcrunch from $with_dds." - - fi -@@ -2012,7 +2008,7 @@ else - AC_MSG_RESULT([using libtiff from ${with_libtiff}.]) - - dnl Check for the BigTIFF enabled library (libtiff >= 4.0) -- AC_CHECK_LIB(tiff,TIFFScanlineSize64,HAVE_BIGTIFF=yes,HAVE_BIGTIFF=no,) -+ AC_CHECK_LIB(tiff,TIFFScanlineSize64,HAVE_BIGTIFF=yes,HAVE_BIGTIFF=no,$LIBS) - - fi - -@@ -2082,7 +2078,6 @@ else - - dnl We now require libgeotiff 1.5.0 - dnl first check if $with_geotiff/lib has the library: -- AC_CHECK_LIB(geotiff,GTIFAttachPROJContext,GEOTIFF_SETTING=external,GEOTIFF_SETTING=not_found,-L$with_geotiff/lib) - - if test $GEOTIFF_SETTING = "external" ; then - LIBS="-L$with_geotiff/lib -lgeotiff $LIBS" -@@ -2650,6 +2645,10 @@ if test x"$with_hdf4" = x"no" ; then - - echo "hdf4 support disabled." - -+elif test x"$with_hdf4" = x"yes" ; then -+ PKG_CHECK_MODULES([HDF4], [hdf], [HAVE_HDF4=yes], [AC_MSG_ERROR([hdf4 not found...])]) -+ PKG_CHECK_MODULES([HDF4], [hdf >= 4.2.5], [HDF4_HAS_MAXOPENFILES=yes], [HDF4_HAS_MAXOPENFILES=no]) -+ HDF4_INCLUDE="$HDF4_CFLAGS" - else - - if test x"$with_hdf4" = x"yes" -o x"$with_hdf4" = x"" ; then -@@ -2780,7 +2779,6 @@ elif test "$with_hdf5" = "yes" -o "$with_hdf5" = "" ; then - # Test that the package found is for the right architecture - saved_LIBS="$LIBS" - LIBS="$HDF5_LIBS" -- AC_CHECK_LIB(hdf5,H5Fopen, [HAVE_HDF5=yes], [HAVE_HDF5=no]) - LIBS="$saved_LIBS" - - if test "$HAVE_HDF5" = "yes"; then -@@ -2849,21 +2847,21 @@ KEA_CONFIG=no - - AC_ARG_WITH(kea,[ --with-kea[=ARG] Include kealib (ARG=path to kea-config) [[default=yes]]],,) - -+AC_MSG_CHECKING([for kea]) - if test "$with_kea" = "yes" -o "x$with_kea" = "x" ; then -- AC_PATH_PROG(KEA_CONFIG, kea-config, no) -+ HAVE_KEA=yes -+ AC_MSG_RESULT([yes]) - else -- KEA_CONFIG=$with_kea -+ HAVE_KEA=no -+ AC_MSG_RESULT([no]) - fi - --AC_MSG_CHECKING([for kea]) - - if test "$KEA_CONFIG" = "no" ; then - -- HAVE_KEA=no - KEA_LIB= - KEA_INC= - -- AC_MSG_RESULT([no]) - - else - if test -d $KEA_CONFIG ; then -@@ -3715,18 +3713,15 @@ MYSQL_CONFIG=no - AC_ARG_WITH(mysql,[ --with-mysql[=ARG] Include MySQL (ARG=path to mysql_config) [[default=no]]],,) - - if test "$with_mysql" = "yes" ; then -- AC_PATH_PROG(MYSQL_CONFIG, mysql_config, no) -+ HAVE_MYSQL=yes - else -- if test "x$with_mysql" != "x" ; then -- MYSQL_CONFIG=$with_mysql -- fi -+ HAVE_MYSQL=no - fi - - AC_MSG_CHECKING([for MySQL]) - - if test "$MYSQL_CONFIG" = "no" ; then - -- HAVE_MYSQL=no - MYSQL_LIB= - MYSQL_INC= - -@@ -3820,8 +3815,11 @@ dnl Check for Expat configuration. - dnl --------------------------------------------------------------------------- - - dnl Expat 1.95.0 released in 2000-09-28 --EXPAT_REQ_VERSION="1.95.0" --AX_LIB_EXPAT($EXPAT_REQ_VERSION) -+# AX_LIB_EXPAT is too fragile, it doesn't properly handle debug expat on Windows -+HAVE_EXPAT=no -+AC_ARG_WITH([expat], AS_HELP_STRING([--with-expat[=ARG]], [use Expat library (ARG=yes or no)]),,) -+if test x"$with_expat" = x"yes" ; then -+PKG_CHECK_MODULES([EXPAT], [expat >= 1.95.0], [HAVE_EXPAT=yes], [AC_MSG_ERROR([expat not found...])]) - - if test "$HAVE_EXPAT" = "yes"; then - LIBS="$EXPAT_LDFLAGS $LIBS" -@@ -3834,6 +3832,7 @@ m4_foreach_w([frmt],EXPAT_DRIVERS,[ - fi - ]) - -+fi - fi - - AC_SUBST([HAVE_EXPAT], $HAVE_EXPAT) -@@ -4059,29 +4058,17 @@ AC_ARG_WITH(curl, - dnl Clear some cache variables - unset ac_cv_path_LIBCURL - --if test "`basename xx/$with_curl`" = "curl-config" ; then -- LIBCURL_CONFIG="$with_curl" --elif test "$with_curl" = "no" ; then -- LIBCURL_CONFIG=no --else -- AC_PATH_PROG(LIBCURL_CONFIG, curl-config, no) --fi -- --if test "$LIBCURL_CONFIG" != "no" ; then -- -- CURL_VERNUM=`$LIBCURL_CONFIG --vernum` -- CURL_VER=`$LIBCURL_CONFIG --version | awk '{print $2}'` -- -- AC_MSG_RESULT([ found libcurl version $CURL_VER]) -- -- AC_CHECK_LIB(curl,curl_global_init,CURL_SETTING=yes,CURL_SETTING=no,`$LIBCURL_CONFIG --libs`) - -+if test "$with_curl" = "yes" ; then -+ PKG_CHECK_MODULES([CURL], [libcurl], [CURL_SETTING=yes], [AC_MSG_ERROR([libcurl not found...])]) -+else -+ CURL_SETTING=no - fi - - if test "$CURL_SETTING" = "yes" ; then - -- CURL_INC=`$LIBCURL_CONFIG --cflags` -- CURL_LIB=`$LIBCURL_CONFIG --libs` -+ CURL_INC="$CURL_CFLAGS" -+ CURL_LIB="$CURL_LIBS" - m4_foreach_w([frmt],CURL_FORMATS,[ - driver_enabled=m4_join([_],[$INTERNAL_FORMAT],frmt,[ENABLED]) - if test "x$driver_enabled" = "xyes"; then -@@ -4121,7 +4108,6 @@ if test "x$with_xml2" = "xyes" -o "x$with_xml2" = "x" ; then - if test "${HAVE_LIBXML2}" = "yes"; then - SAVED_LIBS="${LIBS}" - LIBS="${LIBXML2_LIBS}" -- AC_CHECK_LIB(xml2,xmlParseDoc,HAVE_LIBXML2=yes,HAVE_LIBXML2=no) - LIBS="${SAVED_LIBS}" - fi - -@@ -4242,9 +4228,12 @@ dnl --------------------------------------------------------------------------- - dnl Check for SQLite (only if SpatiaLite is not detected) - dnl --------------------------------------------------------------------------- - -+HAVE_SQLITE3=no -+AC_ARG_WITH(sqlite3, AS_HELP_STRING([--with-sqlite3[=ARG]], [use SQLite 3 library (ARG=yes or no)]),,) - if test "${HAVE_SPATIALITE}" = "no" -o "${HAVE_SPATIALITE}" = "dlopen" ; then -- SQLITE3_REQ_VERSION="3.0.0" -- AX_LIB_SQLITE3($SQLITE3_REQ_VERSION) -+ if test x"$with_sqlite3" = x"yes" ; then -+ PKG_CHECK_MODULES([SQLITE3], [sqlite3 >= 3.0.0], [HAVE_SQLITE3=yes], [AC_MSG_ERROR([sqlite3 not found...])]) -+ fi - - if test "$HAVE_SQLITE3" = "yes"; then - LIBS="$SQLITE3_LDFLAGS $LIBS" -@@ -4597,8 +4586,13 @@ dnl --------------------------------------------------------------------------- - dnl Check if geos library is available. - dnl --------------------------------------------------------------------------- - --GEOS_INIT(3.1.0) -+AC_ARG_WITH(geos, AS_HELP_STRING([--with-geos[=ARG]], [Include GEOS support (ARG=yes or no)]),,) - HAVE_GEOS_RESULT="no" -+HAVE_GEOS=no -+if test x"$with_geos" = x"no" ; then -+ AC_MSG_RESULT([GEOS support disabled]) -+else -+ PKG_CHECK_MODULES([GEOS], [geos >= 3.1.0], [HAVE_GEOS=yes], [AC_MSG_ERROR([geos not found...])]) - if test "${HAVE_GEOS}" = "yes" ; then - - AC_MSG_NOTICE([Using C API from GEOS $GEOS_VERSION]) -@@ -4607,6 +4601,8 @@ if test "${HAVE_GEOS}" = "yes" ; then - LIBS="${GEOS_LIBS} ${LIBS}" - HAVE_GEOS_RESULT="yes" - fi -+fi -+AC_SUBST(HAVE_GEOS, $HAVE_GEOS) - - dnl --------------------------------------------------------------------------- - dnl Check if SFCGAL library is available. -@@ -4641,20 +4637,18 @@ elif test "$with_qhull" = "yes" -o "$with_qhull" = "" ; then - # qhull/qhull.h - AC_CHECK_HEADERS([qhull/libqhull.h]) - if test "$ac_cv_header_qhull_libqhull_h" = "yes"; then -- AC_CHECK_LIB(qhull,qh_new_qhull,QHULL_SETTING=yes,QHULL_SETTING=no,) -+ QHULL_SETTING=yes - if test "$QHULL_SETTING" = "yes"; then - QHULL_SETTING=external - QHULL_INCLUDE_SUBDIR_IS_LIBQHULL=0 -- LIBS="-lqhull $LIBS" - fi - fi - AC_CHECK_HEADERS([libqhull/libqhull.h]) - if test "$ac_cv_header_libqhull_libqhull_h" = "yes"; then -- AC_CHECK_LIB(qhull,qh_new_qhull,QHULL_SETTING=yes,QHULL_SETTING=no,) -+ QHULL_SETTING=yes - if test "$QHULL_SETTING" = "yes"; then - QHULL_SETTING=external - QHULL_INCLUDE_SUBDIR_IS_LIBQHULL=1 -- LIBS="-lqhull $LIBS" - fi - fi - -@@ -4741,7 +4735,9 @@ AC_MSG_CHECKING([for FreeXL support]) - HAVE_FREEXL=no - FREEXL_INCLUDE= - --if test "$with_freexl" = "" -o "$with_freexl" = "yes" ; then -+if test "$with_freexl" = "yes"; then -+ PKG_CHECK_MODULES([FREEXL], [freexl >= 1.0.0], [HAVE_FREEXL=yes], [AC_MSG_ERROR([freexl not found...])]) -+elif test "$with_freexl" = ""; then - AC_CHECK_HEADERS(freexl.h) - AC_CHECK_LIB(freexl,freexl_open,FREEXL_LIBS="-lfreexl",FREEXL_LIBS=missing) - -@@ -4847,8 +4843,7 @@ if test "$with_libjson_c" = "external" -o "$with_libjson_c" = "" -o "$with_libjs - elif test "$with_libjson_c" = "internal" ; then - LIBJSONC_SETTING=internal - elif test "$with_libjson_c" != "no"; then -- LIBS="-L$with_libjson_c/lib $LIBS" -- AC_CHECK_LIB(json-c,json_object_set_serializer,LIBJSONC_SETTING=external,LIBJSONC_SETTING=internal,-L$with_libjson_c/lib) -+ LIBJSONC_SETTING=external - else - AC_MSG_ERROR([libjson-c (internal or external) is required]) - fi -@@ -5952,7 +5947,6 @@ else - # Test that the package found is for the right architecture - saved_LIBS="$LIBS" - LIBS="$EXR_LIBS" -- AC_CHECK_LIB(IlmImf,ImfTiledInputReadTile, [HAVE_EXR=yes], [HAVE_EXR=no]) - LIBS="$saved_LIBS" - - if test "$HAVE_EXR" = "yes"; then diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-import-dll-msvc.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-import-dll-msvc.patch deleted file mode 100644 index 308c1bca0a4c0f..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-import-dll-msvc.patch +++ /dev/null @@ -1,15 +0,0 @@ ---- a/port/cpl_port.h -+++ b/port/cpl_port.h -@@ -344,7 +344,11 @@ typedef unsigned int GUIntptr_t; - - #ifndef CPL_DLL - #if defined(_MSC_VER) && !defined(CPL_DISABLE_DLL) --# define CPL_DLL __declspec(dllexport) -+# ifdef GDAL_COMPILATION -+# define CPL_DLL __declspec(dllexport) -+# else -+# define CPL_DLL -+# endif - # define CPL_INTERNAL - #else - # if defined(USE_GCC_VISIBILITY_FLAG) diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-jsonc.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-jsonc.patch deleted file mode 100644 index c52f9dff533821..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-jsonc.patch +++ /dev/null @@ -1,104 +0,0 @@ ---- a/gcore/gdal_rat.cpp -+++ b/gcore/gdal_rat.cpp -@@ -50,7 +50,7 @@ - #pragma clang diagnostic ignored "-Wunknown-pragmas" - #pragma clang diagnostic ignored "-Wdocumentation" - #endif --#include "json.h" -+#include - #ifdef __clang__ - #pragma clang diagnostic pop - #endif ---- a/ogr/ogrsf_frmts/geojson/ogresrijsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogresrijsonreader.cpp -@@ -37,7 +37,7 @@ - - #include "cpl_conv.h" - #include "cpl_error.h" --#include "json.h" -+#include - // #include "json_object.h" - // #include "json_tokener.h" - #include "ogr_api.h" ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsondatasource.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsondatasource.cpp -@@ -41,7 +41,7 @@ - #include "cpl_string.h" - #include "cpl_vsi.h" - #include "cpl_vsi_error.h" --#include "json.h" -+#include - // #include "json_object.h" - #include "gdal_utils.h" - #include "gdal.h" ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonlayer.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonlayer.cpp -@@ -37,7 +37,7 @@ - # endif - #endif // !DEBUG_VERBOSE - --#include -+#include - - #if !DEBUG_JSON - # ifdef __clang ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonreader.cpp -@@ -32,7 +32,7 @@ - #include "ogrgeojsonreader.h" - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" --#include // JSON-C -+#include // JSON-C - - #if (!defined(JSON_C_VERSION_NUM)) || (JSON_C_VERSION_NUM < JSON_C_VER_013) - #include // just for sizeof(struct json_object) ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonutils.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonutils.cpp -@@ -31,7 +31,7 @@ - #include - #include - #include --#include // JSON-C -+#include // JSON-C - - #include - #include ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonwriter.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonwriter.cpp -@@ -33,13 +33,13 @@ - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" - #include "ogrgeojsonreader.h" --#include // JSON-C -+#include // JSON-C - - #if (!defined(JSON_C_VERSION_NUM)) || (JSON_C_VERSION_NUM < JSON_C_VER_013) - #include - #endif - --#include -+#include - #include - #include - ---- a/ogr/ogrsf_frmts/geojson/ogrtopojsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrtopojsonreader.cpp -@@ -30,5 +30,5 @@ - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" --#include // JSON-C -+#include // JSON-C - #include - ---- a/port/cpl_json_header.h -+++ b/port/cpl_json_header.h -@@ -33,7 +33,7 @@ - #pragma GCC system_header - #endif - --#include -+#include - - #undef json_object_object_foreachC - #define json_object_object_foreachC(obj,iter) \ diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-podofo.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-podofo.patch deleted file mode 100644 index aa86489f0296ba..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-podofo.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/frmts/pdf/pdfsdk_headers.h -+++ b/frmts/pdf/pdfsdk_headers.h -@@ -103,7 +103,7 @@ typedef unsigned char Guchar; - #undef GetObject - #endif - --#include "podofo.h" -+#include - #endif // HAVE_PODOFO - - #ifdef HAVE_PDFIUM diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-xerces-3.1.2.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-xerces-3.1.2.patch deleted file mode 100644 index 8b08760381794f..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-include-xerces-3.1.2.patch +++ /dev/null @@ -1,63 +0,0 @@ ---- a/ogr/ogr_xerces_headers.h -+++ b/ogr/ogr_xerces_headers.h -@@ -33,9 +33,9 @@ - #pragma GCC system_header - #endif - --#include --#include --#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE ---- a/ogr/ogrsf_frmts/gml/xercesc_headers.h -+++ b/ogr/ogrsf_frmts/gml/xercesc_headers.h -@@ -33,13 +33,13 @@ - #pragma GCC system_header - #endif - --#include --#include --#include --#include --#include --#include --#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE ---- a/ogr/ogrsf_frmts/ili/xercesc_headers.h -+++ b/ogr/ogrsf_frmts/ili/xercesc_headers.h -@@ -33,14 +33,14 @@ - #pragma GCC system_header - #endif - --#include --#include --#include --#include --#include --#include --#include --#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE diff --git a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-nmake-common.patch b/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-nmake-common.patch deleted file mode 100644 index c0201f8dc9cd8c..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.1.x/fix-nmake-common.patch +++ /dev/null @@ -1,165 +0,0 @@ ---- a/alg/makefile.vc -+++ b/alg/makefile.vc -@@ -14,7 +14,7 @@ EXTRAFLAGS = -I../frmts/vrt -I../ogr/ogrsf_frmts $(GEOS_CFLAGS) $(PROJ_FLAGS) $( - EXTRAFLAGS = $(EXTRAFLAGS) -DINTERNAL_QHULL - !ELSE - !IF "$(QHULL_SETTING)" == "EXTERNAL" --EXTRAFLAGS = $(EXTRAFLAGS) -DEXTERNAL_QHULL $(QHULL_INC) -+EXTRAFLAGS = $(EXTRAFLAGS) -DEXTERNAL_QHULL -DQHULL_INCLUDE_SUBDIR_IS_LIBQHULL=1 $(QHULL_INC) - !ENDIF - !ENDIF - !ENDIF ---- a/apps/makefile.vc -+++ b/apps/makefile.vc -@@ -8,6 +8,9 @@ EXTRAFLAGS = -I..\frmts\vrt -I..\ogr\ogrsf_frmts\geojson\libjson -I..\ogr\ogrsf_ - !INCLUDE ..\nmake.opt - - LIBS = $(GDALLIB) -+!IF "$(DLLBUILD)" != "1" -+LIBS = $(LIBS) $(EXTERNAL_LIBS) -+!ENDIF - - !IFDEF INCLUDE_OGR_FRMTS - OGR_PROGRAMS = gdal_contour.exe gdaltindex.exe gdal_rasterize.exe \ ---- a/frmts/gif/makefile.vc -+++ b/frmts/gif/makefile.vc -@@ -10,14 +10,8 @@ EXTRAFLAGS = -Igiflib - - default: $(OBJ) - xcopy /D /Y *.obj ..\o -- cd giflib -- $(MAKE) /f makefile.vc -- cd .. - - clean: - -del *.obj -- cd giflib -- $(MAKE) /f makefile.vc clean -- cd .. - - ---- a/frmts/jpeg/makefile.vc -+++ b/frmts/jpeg/makefile.vc -@@ -29,12 +29,16 @@ default: $(EXTRA_DEP) $(OBJ) - - clean: - -del *.obj -+!IFNDEF JPEG_EXTERNAL_LIB - cd libjpeg - $(MAKE) /f makefile.vc clean - cd .. -+!ENDIF -+!IFDEF JPEG12_SUPPORTED - cd libjpeg12 - $(MAKE) /f makefile.vc clean - cd .. -+!ENDIF - - libjpeg12src: - cd libjpeg12 ---- a/frmts/kea/makefile.vc -+++ b/frmts/kea/makefile.vc -@@ -1,7 +1,7 @@ - - OBJ = keaband.obj keacopy.obj keadataset.obj keadriver.obj keamaskband.obj keaoverview.obj kearat.obj - --EXTRAFLAGS = $(KEA_CFLAGS) -DH5_BUILT_AS_DYNAMIC_LIB -+EXTRAFLAGS = $(KEA_CFLAGS) - - GDAL_ROOT = ..\.. - ---- a/frmts/makefile.vc -+++ b/frmts/makefile.vc -@@ -3,11 +3,11 @@ GDAL_ROOT = .. - - EXTRAFLAGS = -DFRMT_ceos -DFRMT_aigrid -DFRMT_elas -DFRMT_hfa -DFRMT_gtiff\ - -DFRMT_sdts -DFRMT_raw -DFRMT_gxf -DFRMT_ceos2 -DFRMT_png \ -- -DFRMT_dted -DFRMT_mem -DFRMT_jdem -DFRMT_gif \ -+ -DFRMT_dted -DFRMT_mem -DFRMT_jdem \ - -DFRMT_envisat -DFRMT_aaigrid -DFRMT_usgsdem -DFRMT_l1b \ - -DFRMT_fit -DFRMT_vrt -DFRMT_xpm -DFRMT_bmp -DFRMT_rmf \ -- -DFRMT_nitf -DFRMT_pcidsk -DFRMT_airsar -DFRMT_rs2 \ -- -DFRMT_ilwis -DFRMT_msgn -DFRMT_rik -DFRMT_pcraster \ -+ -DFRMT_nitf -DFRMT_airsar -DFRMT_rs2 \ -+ -DFRMT_ilwis -DFRMT_msgn -DFRMT_rik \ - -DFRMT_leveller -DFRMT_sgi -DFRMT_srtmhgt -DFRMT_idrisi \ - -DFRMT_jaxapalsar -DFRMT_ers -DFRMT_ingr -DFRMT_dimap \ - -DFRMT_gff -DFRMT_terragen -DFRMT_gsg -DFRMT_cosar -DFRMT_pds \ -@@ -32,6 +32,22 @@ PLUGINDIRLIST = $(PLUGINFLAGS:-DFRMT_=) - EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_postgisraster - !ENDIF - -+!IFDEF GIF_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_gif -+!ENDIF -+ -+!IFDEF PCIDSK_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_pcidsk -+!ENDIF -+ -+!IFDEF PCRASTER_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_pcraster -+!ENDIF -+ -+!IFDEF EXR_INC -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_exr -+!ENDIF -+ - !IFDEF JPEG_SUPPORTED - EXTRAFLAGS = -DFRMT_jpeg $(EXTRAFLAGS) - !ENDIF ---- a/frmts/pcidsk/makefile.vc -+++ b/frmts/pcidsk/makefile.vc -@@ -14,7 +14,11 @@ OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj - !ENDIF - - !IF "$(PCIDSK_SETTING)" == "INTERNAL" -+!IFDEF JPEG_SUPPORTED - PCIDSKFLAGS = -Isdk -DPCIDSK_INTERNAL -DHAVE_LIBJPEG -+!ELSE -+PCIDSKFLAGS = -Isdk -DPCIDSK_INTERNAL -+!ENDIF - - OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj \ - sdk\channel\cbandinterleavedchannel.obj \ -@@ -57,11 +61,13 @@ OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj \ - - !ENDIF - -+!IFDEF JPEG_SUPPORTED - !IFDEF JPEG_EXTERNAL_LIB - JPEGFLAGS = -I$(JPEGDIR) - !ELSE - JPEGFLAGS = -I..\jpeg\libjpeg - !ENDIF -+!ENDIF - - .cpp.obj: - $(CC) $(CFLAGS) $(PCIDSKFLAGS) $(JPEGFLAGS) /c $*.cpp /Fo$*.obj ---- a/makefile.vc -+++ b/makefile.vc -@@ -84,7 +84,7 @@ staticlib: $(LIB_DEPENDS) - call <= 4.0) -- AC_CHECK_LIB(tiff,TIFFScanlineSize64,HAVE_BIGTIFF=yes,HAVE_BIGTIFF=no,) -+ AC_CHECK_LIB(tiff,TIFFScanlineSize64,HAVE_BIGTIFF=yes,HAVE_BIGTIFF=no,$LIBS) - - fi - -@@ -1333,23 +1337,11 @@ AC_ARG_WITH(curl, - dnl Clear some cache variables - unset ac_cv_path_LIBCURL - --if test "`basename xx/$with_curl`" = "curl-config" ; then -- LIBCURL_CONFIG="$with_curl" --elif test "$with_curl" = "no" ; then -- LIBCURL_CONFIG=no -+PKG_PROG_PKG_CONFIG([0.21]) -+if test "$with_curl" = "yes" ; then -+ PKG_CHECK_MODULES([CURL], [libcurl], [CURL_SETTING=yes], [AC_MSG_ERROR([libcurl not found...])]) - else -- AC_PATH_PROG(LIBCURL_CONFIG, curl-config, no) --fi -- --if test "$LIBCURL_CONFIG" != "no" ; then -- -- CURL_VERNUM=`$LIBCURL_CONFIG --vernum` -- CURL_VER=`$LIBCURL_CONFIG --version | awk '{print $2}'` -- -- AC_MSG_RESULT([ found libcurl version $CURL_VER]) -- -- AC_CHECK_LIB(curl,curl_global_init,CURL_SETTING=yes,CURL_SETTING=no,`$LIBCURL_CONFIG --libs`) -- -+ CURL_SETTING=no - fi - - AC_SUBST(CURL_SETTING,$CURL_SETTING) -@@ -1361,8 +1353,11 @@ dnl Check for SQLite - dnl Proj depends on it so it must appear before. - dnl --------------------------------------------------------------------------- - --SQLITE3_REQ_VERSION="3.0.0" --AX_LIB_SQLITE3($SQLITE3_REQ_VERSION) -+HAVE_SQLITE3=no -+AC_ARG_WITH(sqlite3, AS_HELP_STRING([--with-sqlite3[=ARG]], [use SQLite 3 library (ARG=yes or no)]),,) -+if test x"$with_sqlite3" = x"yes" ; then -+ PKG_CHECK_MODULES([SQLITE3], [sqlite3 >= 3.0.0], [HAVE_SQLITE3=yes], [AC_MSG_ERROR([sqlite3 not found...])]) -+fi - - if test "$HAVE_SQLITE3" = "yes"; then - LIBS="$SQLITE3_LDFLAGS $LIBS" -@@ -1393,11 +1388,7 @@ if test "x$with_proj" = "xno" ; then - else - - if test "x$with_proj" = "xyes" -o "x$with_proj" = "x"; then -- ORIG_LIBS="$LIBS" -- LIBS="-lproj $with_proj_extra_lib_for_test $ORIG_LIBS" -- AC_LANG_PUSH([C++]) -- AC_CHECK_LIB(proj,proj_create_from_wkt,PROJ_FOUND=yes,PROJ_FOUND=no,) -- AC_LANG_POP([C++]) -+ PROJ_FOUND=yes - if test "$PROJ_FOUND" = "no"; then - AC_LANG_PUSH([C++]) - AC_CHECK_LIB(proj,internal_proj_create_from_wkt,PROJ_FOUND=yes,PROJ_FOUND=no,) -@@ -1820,8 +1811,8 @@ fi - - if test "$CURL_SETTING" = "yes" ; then - -- CURL_INC=`$LIBCURL_CONFIG --cflags` -- CURL_LIB=`$LIBCURL_CONFIG --libs` -+ CURL_INC="$CURL_CFLAGS" -+ CURL_LIB="$CURL_LIBS" - m4_foreach_w([frmt],CURL_FORMATS,[ - driver_enabled=m4_join([_],[$INTERNAL_FORMAT],frmt,[ENABLED]) - if test "x$driver_enabled" = "xyes"; then -@@ -2153,7 +2144,6 @@ else - - DDS_SETTING=yes - CRUNCHDIR="$with_dds" -- LIBS="-L$with_dds/lib/ -lcrunch $LIBS" - echo "using libcrunch from $with_dds." - - fi -@@ -2304,7 +2294,6 @@ else - - dnl We now require libgeotiff 1.5.0 - dnl first check if $with_geotiff/lib has the library: -- AC_CHECK_LIB(geotiff,GTIFAttachPROJContext,GEOTIFF_SETTING=external,GEOTIFF_SETTING=not_found,-L$with_geotiff/lib) - - if test $GEOTIFF_SETTING = "external" ; then - LIBS="-L$with_geotiff/lib -lgeotiff $LIBS" -@@ -2872,6 +2861,10 @@ if test x"$with_hdf4" = x"no" ; then - - echo "hdf4 support disabled." - -+elif test x"$with_hdf4" = x"yes" ; then -+ PKG_CHECK_MODULES([HDF4], [hdf], [HAVE_HDF4=yes], [AC_MSG_ERROR([hdf4 not found...])]) -+ PKG_CHECK_MODULES([HDF4], [hdf >= 4.2.5], [HDF4_HAS_MAXOPENFILES=yes], [HDF4_HAS_MAXOPENFILES=no]) -+ HDF4_INCLUDE="$HDF4_CFLAGS" - else - - if test x"$with_hdf4" = x"yes" -o x"$with_hdf4" = x"" ; then -@@ -3002,7 +2995,6 @@ elif test "$with_hdf5" = "yes" -o "$with_hdf5" = "" ; then - # Test that the package found is for the right architecture - saved_LIBS="$LIBS" - LIBS="$HDF5_LIBS" -- AC_CHECK_LIB(hdf5,H5Fopen, [HAVE_HDF5=yes], [HAVE_HDF5=no]) - LIBS="$saved_LIBS" - - if test "$HAVE_HDF5" = "yes"; then -@@ -3071,21 +3063,21 @@ KEA_CONFIG=no - - AC_ARG_WITH(kea,[ --with-kea[=ARG] Include kealib (ARG=path to kea-config) [[default=yes]]],,) - -+AC_MSG_CHECKING([for kea]) - if test "$with_kea" = "yes" -o "x$with_kea" = "x" ; then -- AC_PATH_PROG(KEA_CONFIG, kea-config, no) -+ HAVE_KEA=yes -+ AC_MSG_RESULT([yes]) - else -- KEA_CONFIG=$with_kea -+ HAVE_KEA=no -+ AC_MSG_RESULT([no]) - fi - --AC_MSG_CHECKING([for kea]) - - if test "$KEA_CONFIG" = "no" ; then - -- HAVE_KEA=no - KEA_LIB= - KEA_INC= - -- AC_MSG_RESULT([no]) - - else - if test -d $KEA_CONFIG ; then -@@ -3937,18 +3929,15 @@ MYSQL_CONFIG=no - AC_ARG_WITH(mysql,[ --with-mysql[=ARG] Include MySQL (ARG=path to mysql_config) [[default=no]]],,) - - if test "$with_mysql" = "yes" ; then -- AC_PATH_PROG(MYSQL_CONFIG, mysql_config, no) -+ HAVE_MYSQL=yes - else -- if test "x$with_mysql" != "x" ; then -- MYSQL_CONFIG=$with_mysql -- fi -+ HAVE_MYSQL=no - fi - - AC_MSG_CHECKING([for MySQL]) - - if test "$MYSQL_CONFIG" = "no" ; then - -- HAVE_MYSQL=no - MYSQL_LIB= - MYSQL_INC= - -@@ -4042,8 +4031,11 @@ dnl Check for Expat configuration. - dnl --------------------------------------------------------------------------- - - dnl Expat 1.95.0 released in 2000-09-28 --EXPAT_REQ_VERSION="1.95.0" --AX_LIB_EXPAT($EXPAT_REQ_VERSION) -+# AX_LIB_EXPAT is too fragile, it doesn't properly handle debug expat on Windows -+HAVE_EXPAT=no -+AC_ARG_WITH([expat], AS_HELP_STRING([--with-expat[=ARG]], [use Expat library (ARG=yes or no)]),,) -+if test x"$with_expat" = x"yes" ; then -+PKG_CHECK_MODULES([EXPAT], [expat >= 1.95.0], [HAVE_EXPAT=yes], [AC_MSG_ERROR([expat not found...])]) - - if test "$HAVE_EXPAT" = "yes"; then - LIBS="$EXPAT_LDFLAGS $LIBS" -@@ -4056,6 +4048,7 @@ m4_foreach_w([frmt],EXPAT_DRIVERS,[ - fi - ]) - -+fi - fi - - AC_SUBST([HAVE_EXPAT], $HAVE_EXPAT) -@@ -4287,7 +4280,6 @@ if test "x$with_xml2" = "xyes" -o "x$with_xml2" = "x" ; then - if test "${HAVE_LIBXML2}" = "yes"; then - SAVED_LIBS="${LIBS}" - LIBS="${LIBXML2_LIBS}" -- AC_CHECK_LIB(xml2,xmlParseDoc,HAVE_LIBXML2=yes,HAVE_LIBXML2=no) - LIBS="${SAVED_LIBS}" - fi - -@@ -4567,8 +4559,13 @@ dnl --------------------------------------------------------------------------- - dnl Check if geos library is available. - dnl --------------------------------------------------------------------------- - --GEOS_INIT(3.1.0) -+AC_ARG_WITH(geos, AS_HELP_STRING([--with-geos[=ARG]], [Include GEOS support (ARG=yes or no)]),,) - HAVE_GEOS_RESULT="no" -+HAVE_GEOS=no -+if test x"$with_geos" = x"no" ; then -+ AC_MSG_RESULT([GEOS support disabled]) -+else -+ PKG_CHECK_MODULES([GEOS], [geos >= 3.1.0], [HAVE_GEOS=yes], [AC_MSG_ERROR([geos not found...])]) - if test "${HAVE_GEOS}" = "yes" ; then - - AC_MSG_NOTICE([Using C API from GEOS $GEOS_VERSION]) -@@ -4577,6 +4574,8 @@ if test "${HAVE_GEOS}" = "yes" ; then - LIBS="${GEOS_LIBS} ${LIBS}" - HAVE_GEOS_RESULT="yes" - fi -+fi -+AC_SUBST(HAVE_GEOS, $HAVE_GEOS) - - dnl --------------------------------------------------------------------------- - dnl Check if SFCGAL library is available. -@@ -4611,20 +4610,18 @@ elif test "$with_qhull" = "yes" -o "$with_qhull" = "" ; then - # qhull/qhull.h - AC_CHECK_HEADERS([qhull/libqhull.h]) - if test "$ac_cv_header_qhull_libqhull_h" = "yes"; then -- AC_CHECK_LIB(qhull,qh_new_qhull,QHULL_SETTING=yes,QHULL_SETTING=no,) -+ QHULL_SETTING=yes - if test "$QHULL_SETTING" = "yes"; then - QHULL_SETTING=external - QHULL_INCLUDE_SUBDIR_IS_LIBQHULL=0 -- LIBS="-lqhull $LIBS" - fi - fi - AC_CHECK_HEADERS([libqhull/libqhull.h]) - if test "$ac_cv_header_libqhull_libqhull_h" = "yes"; then -- AC_CHECK_LIB(qhull,qh_new_qhull,QHULL_SETTING=yes,QHULL_SETTING=no,) -+ QHULL_SETTING=yes - if test "$QHULL_SETTING" = "yes"; then - QHULL_SETTING=external - QHULL_INCLUDE_SUBDIR_IS_LIBQHULL=1 -- LIBS="-lqhull $LIBS" - fi - fi - -@@ -4711,7 +4708,9 @@ AC_MSG_CHECKING([for FreeXL support]) - HAVE_FREEXL=no - FREEXL_INCLUDE= - --if test "$with_freexl" = "" -o "$with_freexl" = "yes" ; then -+if test "$with_freexl" = "yes"; then -+ PKG_CHECK_MODULES([FREEXL], [freexl >= 1.0.0], [HAVE_FREEXL=yes], [AC_MSG_ERROR([freexl not found...])]) -+elif test "$with_freexl" = ""; then - AC_CHECK_HEADERS(freexl.h) - AC_CHECK_LIB(freexl,freexl_open,FREEXL_LIBS="-lfreexl",FREEXL_LIBS=missing) - -@@ -4817,8 +4816,7 @@ if test "$with_libjson_c" = "external" -o "$with_libjson_c" = "" -o "$with_libjs - elif test "$with_libjson_c" = "internal" ; then - LIBJSONC_SETTING=internal - elif test "$with_libjson_c" != "no"; then -- LIBS="-L$with_libjson_c/lib $LIBS" -- AC_CHECK_LIB(json-c,json_object_set_serializer,LIBJSONC_SETTING=external,LIBJSONC_SETTING=internal,-L$with_libjson_c/lib) -+ LIBJSONC_SETTING=external - else - AC_MSG_ERROR([libjson-c (internal or external) is required]) - fi -@@ -5928,7 +5926,6 @@ else - # Test that the package found is for the right architecture - saved_LIBS="$LIBS" - LIBS="$EXR_LIBS" -- AC_CHECK_LIB(IlmImf,ImfTiledInputReadTile, [HAVE_EXR=yes], [HAVE_EXR=no]) - LIBS="$saved_LIBS" - - if test "$HAVE_EXR" = "yes"; then diff --git a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-jsonc.patch b/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-jsonc.patch deleted file mode 100644 index e88043df4189f5..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-jsonc.patch +++ /dev/null @@ -1,104 +0,0 @@ ---- a/gcore/gdal_rat.cpp -+++ b/gcore/gdal_rat.cpp -@@ -50,7 +50,7 @@ - #pragma clang diagnostic ignored "-Wunknown-pragmas" - #pragma clang diagnostic ignored "-Wdocumentation" - #endif --#include "json.h" -+#include - #ifdef __clang__ - #pragma clang diagnostic pop - #endif ---- a/ogr/ogrsf_frmts/geojson/ogresrijsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogresrijsonreader.cpp -@@ -37,7 +37,7 @@ - - #include "cpl_conv.h" - #include "cpl_error.h" --#include "json.h" -+#include - // #include "json_object.h" - // #include "json_tokener.h" - #include "ogr_api.h" ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsondatasource.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsondatasource.cpp -@@ -41,7 +41,7 @@ - #include "cpl_string.h" - #include "cpl_vsi.h" - #include "cpl_vsi_error.h" --#include "json.h" -+#include - // #include "json_object.h" - #include "gdal_utils.h" - #include "gdal.h" ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonlayer.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonlayer.cpp -@@ -37,7 +37,7 @@ - # endif - #endif // !DEBUG_VERBOSE - --#include -+#include - - #if !DEBUG_JSON - # ifdef __clang ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonreader.cpp -@@ -32,7 +32,7 @@ - #include "ogrgeojsonreader.h" - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" --#include // JSON-C -+#include - - #if (!defined(JSON_C_VERSION_NUM)) || (JSON_C_VERSION_NUM < JSON_C_VER_013) - #include // just for sizeof(struct json_object) ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonutils.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonutils.cpp -@@ -32,7 +32,7 @@ - #include - #include - #include --#include // JSON-C -+#include - - #include - #include ---- a/ogr/ogrsf_frmts/geojson/ogrgeojsonwriter.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrgeojsonwriter.cpp -@@ -33,13 +33,13 @@ - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" - #include "ogrgeojsonreader.h" --#include // JSON-C -+#include - - #if (!defined(JSON_C_VERSION_NUM)) || (JSON_C_VERSION_NUM < JSON_C_VER_013) - #include - #endif - --#include -+#include - #include - #include - ---- a/ogr/ogrsf_frmts/geojson/ogrtopojsonreader.cpp -+++ b/ogr/ogrsf_frmts/geojson/ogrtopojsonreader.cpp -@@ -30,5 +30,5 @@ - #include "ogrgeojsonutils.h" - #include "ogr_geojson.h" --#include // JSON-C -+#include - #include - ---- a/port/cpl_json_header.h -+++ b/port/cpl_json_header.h -@@ -33,7 +33,7 @@ - #pragma GCC system_header - #endif - --#include -+#include - - #undef json_object_object_foreachC - #define json_object_object_foreachC(obj,iter) \ diff --git a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-podofo.patch b/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-podofo.patch deleted file mode 100644 index aa86489f0296ba..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-podofo.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/frmts/pdf/pdfsdk_headers.h -+++ b/frmts/pdf/pdfsdk_headers.h -@@ -103,7 +103,7 @@ typedef unsigned char Guchar; - #undef GetObject - #endif - --#include "podofo.h" -+#include - #endif // HAVE_PODOFO - - #ifdef HAVE_PDFIUM diff --git a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-xerces.patch b/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-xerces.patch deleted file mode 100644 index 8b08760381794f..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-include-xerces.patch +++ /dev/null @@ -1,63 +0,0 @@ ---- a/ogr/ogr_xerces_headers.h -+++ b/ogr/ogr_xerces_headers.h -@@ -33,9 +33,9 @@ - #pragma GCC system_header - #endif - --#include --#include --#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE ---- a/ogr/ogrsf_frmts/gml/xercesc_headers.h -+++ b/ogr/ogrsf_frmts/gml/xercesc_headers.h -@@ -33,13 +33,13 @@ - #pragma GCC system_header - #endif - --#include --#include --#include --#include --#include --#include --#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE ---- a/ogr/ogrsf_frmts/ili/xercesc_headers.h -+++ b/ogr/ogrsf_frmts/ili/xercesc_headers.h -@@ -33,14 +33,14 @@ - #pragma GCC system_header - #endif - --#include --#include --#include --#include --#include --#include --#include --#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include -+#include - - #ifdef XERCES_CPP_NAMESPACE_USE - XERCES_CPP_NAMESPACE_USE diff --git a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-nmake.patch b/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-nmake.patch deleted file mode 100644 index e23b85d35a16a1..00000000000000 --- a/recipes/gdal/pre_3.5.0/patches/3.2.x/fix-nmake.patch +++ /dev/null @@ -1,179 +0,0 @@ ---- a/alg/makefile.vc -+++ b/alg/makefile.vc -@@ -14,7 +14,7 @@ EXTRAFLAGS = -I../frmts/vrt -I../ogr/ogrsf_frmts $(GEOS_CFLAGS) $(PROJ_FLAGS) $( - EXTRAFLAGS = $(EXTRAFLAGS) -DINTERNAL_QHULL - !ELSE - !IF "$(QHULL_SETTING)" == "EXTERNAL" --EXTRAFLAGS = $(EXTRAFLAGS) -DEXTERNAL_QHULL $(QHULL_INC) -+EXTRAFLAGS = $(EXTRAFLAGS) -DEXTERNAL_QHULL -DQHULL_INCLUDE_SUBDIR_IS_LIBQHULL=1 $(QHULL_INC) - !ENDIF - !ENDIF - !ENDIF ---- a/apps/makefile.vc -+++ b/apps/makefile.vc -@@ -8,6 +8,9 @@ EXTRAFLAGS = -I..\frmts\vrt -I..\ogr\ogrsf_frmts\geojson\libjson -I..\ogr\ogrsf_ - !INCLUDE ..\nmake.opt - - LIBS = $(GDALLIB) -+!IF "$(DLLBUILD)" != "1" -+LIBS = $(LIBS) $(EXTERNAL_LIBS) -+!ENDIF - - !IFDEF INCLUDE_OGR_FRMTS - OGR_PROGRAMS = gdal_contour.exe gdaltindex.exe gdal_rasterize.exe \ ---- a/frmts/gif/makefile.vc -+++ b/frmts/gif/makefile.vc -@@ -10,14 +10,8 @@ EXTRAFLAGS = -Igiflib - - default: $(OBJ) - xcopy /D /Y *.obj ..\o -- cd giflib -- $(MAKE) /f makefile.vc -- cd .. - - clean: - -del *.obj -- cd giflib -- $(MAKE) /f makefile.vc clean -- cd .. - - ---- a/frmts/jpeg/makefile.vc -+++ b/frmts/jpeg/makefile.vc -@@ -29,12 +29,16 @@ default: $(EXTRA_DEP) $(OBJ) - - clean: - -del *.obj -+!IFNDEF JPEG_EXTERNAL_LIB - cd libjpeg - $(MAKE) /f makefile.vc clean - cd .. -+!ENDIF -+!IFDEF JPEG12_SUPPORTED - cd libjpeg12 - $(MAKE) /f makefile.vc clean - cd .. -+!ENDIF - - libjpeg12src: - cd libjpeg12 ---- a/frmts/kea/makefile.vc -+++ b/frmts/kea/makefile.vc -@@ -1,7 +1,7 @@ - - OBJ = keaband.obj keacopy.obj keadataset.obj keadriver.obj keamaskband.obj keaoverview.obj kearat.obj - --EXTRAFLAGS = $(KEA_CFLAGS) -DH5_BUILT_AS_DYNAMIC_LIB -+EXTRAFLAGS = $(KEA_CFLAGS) - - GDAL_ROOT = ..\.. - ---- a/frmts/makefile.vc -+++ b/frmts/makefile.vc -@@ -3,11 +3,11 @@ GDAL_ROOT = .. - - EXTRAFLAGS = -DFRMT_ceos -DFRMT_aigrid -DFRMT_elas -DFRMT_hfa -DFRMT_gtiff\ - -DFRMT_sdts -DFRMT_raw -DFRMT_gxf -DFRMT_ceos2 -DFRMT_png \ -- -DFRMT_dted -DFRMT_mem -DFRMT_jdem -DFRMT_gif -DFRMT_esric \ -+ -DFRMT_dted -DFRMT_mem -DFRMT_jdem -DFRMT_esric \ - -DFRMT_envisat -DFRMT_aaigrid -DFRMT_usgsdem -DFRMT_l1b \ - -DFRMT_fit -DFRMT_vrt -DFRMT_xpm -DFRMT_bmp -DFRMT_rmf \ -- -DFRMT_nitf -DFRMT_pcidsk -DFRMT_airsar -DFRMT_rs2 \ -- -DFRMT_ilwis -DFRMT_msgn -DFRMT_rik -DFRMT_pcraster \ -+ -DFRMT_nitf -DFRMT_airsar -DFRMT_rs2 \ -+ -DFRMT_ilwis -DFRMT_msgn -DFRMT_rik \ - -DFRMT_leveller -DFRMT_sgi -DFRMT_srtmhgt -DFRMT_idrisi \ - -DFRMT_jaxapalsar -DFRMT_ers -DFRMT_ingr -DFRMT_dimap \ - -DFRMT_gff -DFRMT_terragen -DFRMT_gsg -DFRMT_cosar -DFRMT_pds \ -@@ -32,6 +32,22 @@ PLUGINDIRLIST = $(PLUGINFLAGS:-DFRMT_=) - EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_postgisraster - !ENDIF - -+!IFDEF GIF_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_gif -+!ENDIF -+ -+!IFDEF PCIDSK_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_pcidsk -+!ENDIF -+ -+!IFDEF PCRASTER_SETTING -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_pcraster -+!ENDIF -+ -+!IFDEF EXR_INC -+EXTRAFLAGS = $(EXTRAFLAGS) -DFRMT_exr -+!ENDIF -+ - !IFDEF JPEG_SUPPORTED - EXTRAFLAGS = -DFRMT_jpeg $(EXTRAFLAGS) - !ENDIF ---- a/frmts/pcidsk/makefile.vc -+++ b/frmts/pcidsk/makefile.vc -@@ -14,7 +14,11 @@ OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj - !ENDIF - - !IF "$(PCIDSK_SETTING)" == "INTERNAL" -+!IFDEF JPEG_SUPPORTED - PCIDSKFLAGS = -Isdk -DPCIDSK_INTERNAL -DHAVE_LIBJPEG -+!ELSE -+PCIDSKFLAGS = -Isdk -DPCIDSK_INTERNAL -+!ENDIF - - OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj \ - sdk\channel\cbandinterleavedchannel.obj \ -@@ -57,11 +61,13 @@ OBJ = pcidskdataset2.obj ogrpcidsklayer.obj vsi_pcidsk_io.obj gdal_edb.obj \ - - !ENDIF - -+!IFDEF JPEG_SUPPORTED - !IFDEF JPEG_EXTERNAL_LIB - JPEGFLAGS = -I$(JPEGDIR) - !ELSE - JPEGFLAGS = -I..\jpeg\libjpeg - !ENDIF -+!ENDIF - - .cpp.obj: - $(CC) $(CFLAGS) $(PCIDSKFLAGS) $(JPEGFLAGS) /c $*.cpp /Fo$*.obj ---- a/makefile.vc -+++ b/makefile.vc -@@ -84,7 +84,7 @@ staticlib: $(LIB_DEPENDS) - call < Date: Sat, 19 Aug 2023 20:09:45 +0300 Subject: [PATCH 0317/1140] (#18940) objectbox-generator: migrate to Conan v2 * objectbox-generator: migrate to Conan v2 * objectbox-generator: apply PR suggestions --- recipes/objectbox-generator/all/conanfile.py | 54 +++++++++++-------- .../all/test_package/conanfile.py | 14 +++-- .../all/test_v1_package/conanfile.py | 11 ++++ 3 files changed, 52 insertions(+), 27 deletions(-) create mode 100644 recipes/objectbox-generator/all/test_v1_package/conanfile.py diff --git a/recipes/objectbox-generator/all/conanfile.py b/recipes/objectbox-generator/all/conanfile.py index 5493b25252fde2..b6b2defa46e0e0 100644 --- a/recipes/objectbox-generator/all/conanfile.py +++ b/recipes/objectbox-generator/all/conanfile.py @@ -1,8 +1,12 @@ -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, download, get +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.47.0" + class PackageConan(ConanFile): name = "objectbox-generator" @@ -10,39 +14,45 @@ class PackageConan(ConanFile): license = "GPL-3.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/objectbox/objectbox-generator" - topics = ("database", "code-generator", "objectbox") + topics = ("database", "code-generator", "objectbox", "pre-built") + + package_type = "application" settings = "os", "arch", "compiler", "build_type" - @property - def _source_subfolder(self): - return "source_subfolder" - - def validate(self): - if self.settings.os not in ["Linux", "Windows", "Macos"] or self.settings.arch != "x86_64": - raise ConanInvalidConfiguration("{} doesn't support current environment".format(self.name)) + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): del self.info.settings.compiler del self.info.settings.build_type - def source(self): - tools.get(**self.conan_data["sources"][self.version][str(self.settings.os)], - destination=self.source_folder) - tools.download(**self.conan_data["sources"][self.version]["License"], filename="LICENSE.txt") + def validate(self): + if self.settings.os not in ["Linux", "FreeBSD", "Windows", "Macos"] or self.settings.arch != "x86_64": + raise ConanInvalidConfiguration(f"{self.name} doesn't support current environment") + + def build(self): + get(self, **self.conan_data["sources"][self.version][str(self.info.settings.os)]) + download(self, **self.conan_data["sources"][self.version]["License"], filename="LICENSE.txt") def package(self): if self.settings.os != "Windows": - bin_path = os.path.join(self.source_folder, "objectbox-generator") + bin_path = os.path.join(self.build_folder, "objectbox-generator") os.chmod(bin_path, os.stat(bin_path).st_mode | 0o111) - self.copy("objectbox-generator*", src=self.source_folder, dst="bin", keep_path=False) - self.copy("LICENSE.txt", dst="licenses", src=self.source_folder) + copy(self, "objectbox-generator*", + src=self.build_folder, + dst=os.path.join(self.package_folder, "bin"), + keep_path=False) + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.build_folder) def package_info(self): - binpath = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH env var: {}".format(binpath)) - self.env_info.PATH.append(binpath) - self.cpp_info.includedirs = [] self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] self.cpp_info.resdirs = [] + + # TODO: Legacy, to be removed on Conan 2.0 + binpath = os.path.join(self.package_folder, "bin") + self.output.info(f"Appending PATH env var: {binpath}") + self.env_info.PATH.append(binpath) diff --git a/recipes/objectbox-generator/all/test_package/conanfile.py b/recipes/objectbox-generator/all/test_package/conanfile.py index c605339e388af3..42f9cfb1d7ca26 100644 --- a/recipes/objectbox-generator/all/test_package/conanfile.py +++ b/recipes/objectbox-generator/all/test_package/conanfile.py @@ -1,11 +1,15 @@ -from conans import ConanFile, CMake, tools -import os +from conan import ConanFile +from conan.tools.build import can_run class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" + generators = "VirtualBuildEnv" + test_type = "explicit" + + def build_requirements(self): + self.tool_requires(self.tested_reference_str) def test(self): - if not tools.cross_building(self): - bin_path = os.path.join(self.deps_cpp_info["objectbox-generator"].rootpath, "bin", "objectbox-generator") - self.run(bin_path + " -help", run_environment=True) + if can_run(self): + self.run("objectbox-generator -help") diff --git a/recipes/objectbox-generator/all/test_v1_package/conanfile.py b/recipes/objectbox-generator/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..c605339e388af3 --- /dev/null +++ b/recipes/objectbox-generator/all/test_v1_package/conanfile.py @@ -0,0 +1,11 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join(self.deps_cpp_info["objectbox-generator"].rootpath, "bin", "objectbox-generator") + self.run(bin_path + " -help", run_environment=True) From e6dd93bc3b4f4388f579319d12aad6fb0faf7837 Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Sat, 19 Aug 2023 19:51:26 +0200 Subject: [PATCH 0318/1140] (#19120) Add library SCIP++ * Add library SCIP++ * Add license * Add url and homepage * Output version in test * Set CMake version variable which derived from git in upstream * Update SCIP++ to v1.0.1 * Fix version in config.yml * Also package license file * Update to SCIP++ 1.0.2 --- recipes/scippp/all/conandata.yml | 4 + recipes/scippp/all/conanfile.py | 90 +++++++++++++++++++ .../scippp/all/test_package/CMakeLists.txt | 7 ++ recipes/scippp/all/test_package/conanfile.py | 26 ++++++ .../scippp/all/test_package/test_package.cpp | 13 +++ recipes/scippp/config.yml | 3 + 6 files changed, 143 insertions(+) create mode 100644 recipes/scippp/all/conandata.yml create mode 100644 recipes/scippp/all/conanfile.py create mode 100644 recipes/scippp/all/test_package/CMakeLists.txt create mode 100644 recipes/scippp/all/test_package/conanfile.py create mode 100644 recipes/scippp/all/test_package/test_package.cpp create mode 100644 recipes/scippp/config.yml diff --git a/recipes/scippp/all/conandata.yml b/recipes/scippp/all/conandata.yml new file mode 100644 index 00000000000000..ce0a80569e788d --- /dev/null +++ b/recipes/scippp/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.0.2": + url: "https://github.com/scipopt/SCIPpp/archive/refs/tags/1.0.2.tar.gz" + sha256: "d51dfd0f1ca1b57619f7c82e32d5390d99d5cdaee98ae1ace99ec05a394dcee3" diff --git a/recipes/scippp/all/conanfile.py b/recipes/scippp/all/conanfile.py new file mode 100644 index 00000000000000..72d7e95e14f56e --- /dev/null +++ b/recipes/scippp/all/conanfile.py @@ -0,0 +1,90 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.scm import Version +from os.path import join + + +class ScipPlusPlus(ConanFile): + name = "scippp" + settings = "os", "compiler", "build_type", "arch" + generators = "CMakeDeps" + exports_sources = "CMakeLists.txt", "source/*", "include/*" + description = "SCIP++ is a C++ wrapper for SCIP's C interface" + package_type = "library" + topics = ("mip", "solver", "linear", "programming") + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/scipopt/SCIPpp" + options = { + "shared": [True, False], + "fPIC": [True, False] + } + default_options = { + "shared": False, + "fPIC": True + } + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "7", + "clang": "7", + "apple-clang": "10", + "msvc": "192" + } + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 192) + if not is_msvc(self): + 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) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def requirements(self): + # see https://github.com/scipopt/SCIPpp/blob/1.0.0/conanfile.py#L25 + self.requires("scip/8.0.3", transitive_headers=True) + + def generate(self): + tc = CMakeToolchain(self) + # In upstream, the version is injected into CMake via git. + tc.variables["scippp_version"] = self.version + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["ScipPP"] diff --git a/recipes/scippp/all/test_package/CMakeLists.txt b/recipes/scippp/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..877c0c21bd3c0b --- /dev/null +++ b/recipes/scippp/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package CXX) +set(CMAKE_CXX_STANDARD 17) + +find_package(scippp REQUIRED CONFIG) +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE scippp::scippp) diff --git a/recipes/scippp/all/test_package/conanfile.py b/recipes/scippp/all/test_package/conanfile.py new file mode 100644 index 00000000000000..8a5bb47f50c4ce --- /dev/null +++ b/recipes/scippp/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/scippp/all/test_package/test_package.cpp b/recipes/scippp/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..5244632b87e16b --- /dev/null +++ b/recipes/scippp/all/test_package/test_package.cpp @@ -0,0 +1,13 @@ +#include +#include +#include +using namespace scippp; +int main() { + std::cout << "This is SCIP++ version " << scippp::getVersion() << std::endl; + Model model("Simple"); + auto x1 = model.addVar("x_1", 1); + auto x2 = model.addVar("x_2", 1); + model.addConstr(3 * x1 + 2 * x2 <= 1, "capacity"); + model.setObjsense(Sense::MAXIMIZE); + model.solve(); +} diff --git a/recipes/scippp/config.yml b/recipes/scippp/config.yml new file mode 100644 index 00000000000000..8457ca9a4a8cd8 --- /dev/null +++ b/recipes/scippp/config.yml @@ -0,0 +1,3 @@ +versions: + "1.0.2": + folder: all From 1e6d79cc9dbac2fe5512151f5ff3f2cf05f092e7 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 19 Aug 2023 20:30:12 +0200 Subject: [PATCH 0319/1140] (#19127) re2: add version 20230801 --- recipes/re2/all/conandata.yml | 3 +++ recipes/re2/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/re2/all/conandata.yml b/recipes/re2/all/conandata.yml index 6705ed6ddc2fa4..9b52a871bf2616 100644 --- a/recipes/re2/all/conandata.yml +++ b/recipes/re2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20230801": + url: "https://github.com/google/re2/releases/download/2023-08-01/re2-2023-08-01.tar.gz" + sha256: "d82d0efe2389949244445e7a6ac9a10fccc3d6a3d267ec4652991a51291647b0" "20230701": url: "https://github.com/google/re2/releases/download/2023-07-01/re2-2023-07-01.tar.gz" sha256: "18cf85922e27fad3ed9c96a27733037da445f35eb1a2744c306a37c6d11e95c4" diff --git a/recipes/re2/config.yml b/recipes/re2/config.yml index 4d4c9dcf9a641c..fb1f7527256cf1 100644 --- a/recipes/re2/config.yml +++ b/recipes/re2/config.yml @@ -1,4 +1,6 @@ versions: + "20230801": + folder: all "20230701": folder: all "20230602": From 2a0d3dca6edd772e06da6ab867d8188bc35ac68d Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 04:11:01 +0900 Subject: [PATCH 0320/1140] (#19190) cpp-sort: add version 1.15.0, remove older versions --- recipes/cpp-sort/all/conandata.yml | 21 +++------------------ recipes/cpp-sort/all/conanfile.py | 16 ++++++++-------- recipes/cpp-sort/config.yml | 14 ++------------ 3 files changed, 13 insertions(+), 38 deletions(-) diff --git a/recipes/cpp-sort/all/conandata.yml b/recipes/cpp-sort/all/conandata.yml index 092fe59db4a196..48e52896326749 100644 --- a/recipes/cpp-sort/all/conandata.yml +++ b/recipes/cpp-sort/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.15.0": + url: "https://github.com/Morwenn/cpp-sort/archive/1.15.0.tar.gz" + sha256: "886e813a4b87c6361e9b50c0a66c73b3b812f0ce0b7039ff3991eddce77e0dc7" "1.14.0": url: "https://github.com/Morwenn/cpp-sort/archive/1.14.0.tar.gz" sha256: "3b85cd4580f54ae3f171777d0630b4f7c89c33cf96e9ae24a1dbebbf200c3195" @@ -23,21 +26,3 @@ sources: "1.10.0": url: "https://github.com/Morwenn/cpp-sort/archive/1.10.0.tar.gz" sha256: "48951cac0051d48fee286c3bc02804975f9d83269d80c10dfc5589e76a542765" - "1.9.0": - url: "https://github.com/Morwenn/cpp-sort/archive/1.9.0.tar.gz" - sha256: "e83f3daad30bd91fed668bdb56ad379c4aeea39d7dc640484fdcc55149b6d0e4" - "1.8.1": - url: "https://github.com/Morwenn/cpp-sort/archive/1.8.1.tar.gz" - sha256: "04d518dabb422614fcb4a2b4e258c515f31dd01d51c26e9eaaec76e77c4d3d40" - "1.8.0": - sha256: a3de426a66cffbe9f8865feb7518ff4f4d1b3aadf3725161b8e118dcbf6fe9b9 - url: https://github.com/Morwenn/cpp-sort/archive/1.8.0.tar.gz - "1.7.0": - sha256: 4a8230be2c63a92395e140cb7e6593171638a41c46f4cd14d6ffc354ba830e2b - url: https://github.com/Morwenn/cpp-sort/archive/1.7.0.tar.gz - "1.6.0": - sha256: df048d15ff555030eb90d3c96f560a75bbec8baee256f2ced647f359c892c9c8 - url: https://github.com/Morwenn/cpp-sort/archive/1.6.0.tar.gz - "1.5.1": - sha256: 39925958dbd773f15d36d74d4ded48f075c05feef7fe604c7c5c4bfae2a4ec55 - url: https://github.com/Morwenn/cpp-sort/archive/1.5.1.tar.gz diff --git a/recipes/cpp-sort/all/conanfile.py b/recipes/cpp-sort/all/conanfile.py index cfda199bf6a781..e0e093c1fa1654 100644 --- a/recipes/cpp-sort/all/conanfile.py +++ b/recipes/cpp-sort/all/conanfile.py @@ -1,5 +1,3 @@ -import os.path - from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd @@ -7,6 +5,7 @@ from conan.tools.files import copy, get, rmdir from conan.tools.microsoft import is_msvc from conan.tools.scm import Version +import os required_conan_version = ">=1.50.0" @@ -17,12 +16,13 @@ class CppSortConan(ConanFile): license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/Morwenn/cpp-sort" - topics = "cpp-sort", "sorting", "algorithms" + topics = ("sorting", "algorithms", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _minimum_cpp_standard(self): + def _min_cppstd(self): return 14 @property @@ -43,7 +43,7 @@ def package_id(self): def validate(self): if self.settings.get_safe("compiler.cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._min_cppstd) if is_msvc(self) and Version(self.version) < "1.10.0": raise ConanInvalidConfiguration(f"{self.ref} versions older than 1.10.0 do not support MSVC") @@ -60,19 +60,19 @@ def loose_lt_semver(v1, v2): minimum_version = self._compilers_minimum_version[str(compiler)] if minimum_version and loose_lt_semver(version, minimum_version): msg = ( - f"{self.ref} requires C++{self._minimum_cpp_standard} features " + f"{self.ref} requires C++{self._min_cppstd} features " f"which are not supported by compiler {compiler} {version}." ) raise ConanInvalidConfiguration(msg) except KeyError: msg = ( f"{self.ref} recipe lacks information about the {compiler} compiler, " - f"support for the required C++{self._minimum_cpp_standard} features is assumed" + f"support for the required C++{self._min_cppstd} features is assumed" ) self.output.warn(msg) def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/cpp-sort/config.yml b/recipes/cpp-sort/config.yml index c097db627e4151..acbaa54fefe9ca 100644 --- a/recipes/cpp-sort/config.yml +++ b/recipes/cpp-sort/config.yml @@ -1,4 +1,6 @@ versions: + "1.15.0": + folder: all "1.14.0": folder: all "1.13.2": @@ -15,15 +17,3 @@ versions: folder: all "1.10.0": folder: all - "1.9.0": - folder: all - "1.8.1": - folder: all - "1.8.0": - folder: all - "1.7.0": - folder: all - "1.6.0": - folder: all - "1.5.1": - folder: all From 996236ee01bb0b9b267bb5486fbfdfc4ba555219 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Sat, 19 Aug 2023 14:48:30 -0500 Subject: [PATCH 0321/1140] (#19263) libgettext/*: Set license as LGPL instead of GPL * libgettext/*: Set license as LGPL instead of GPL The portions of libgettext that we package are licensed under the LGPL, not the GPL. We only package the libgnuintl portion of the libgettext package, which is under the LGPL. This can easily be confirmed by checking the packaged libintl.h header file. This is also documented explicitly by the project here: https://www.gnu.org/software/gettext/manual/gettext.html#Licenses. * Add comment about the licensing --------- Co-authored-by: Carlos Zoido --- recipes/libgettext/all/conanfile.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/recipes/libgettext/all/conanfile.py b/recipes/libgettext/all/conanfile.py index 30249cef99da1b..a3d65fe027cb3d 100644 --- a/recipes/libgettext/all/conanfile.py +++ b/recipes/libgettext/all/conanfile.py @@ -26,7 +26,11 @@ class GetTextConan(ConanFile): topics = ("gettext", "intl", "libintl", "i18n") url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.gnu.org/software/gettext" - license = "GPL-3.0-or-later" + # Some parts of the project are GPL-3.0-or-later and some are LGPL-2.1-or-later. + # At this time, only libintl is packaged, which is licensed under the LGPL-2.1-or-later. + # If you modify this package to include other portions of the library, please configure the license accordingly. + # The licensing of the project is documented here: https://www.gnu.org/software/gettext/manual/gettext.html#Licenses + license = "LGPL-2.1-or-later" package_type = "library" settings = "os", "arch", "compiler", "build_type" From 9619c12ffe8340643464e7e53a1395c1d12fe9be Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Sat, 19 Aug 2023 13:29:58 -0700 Subject: [PATCH 0322/1140] (#19287) restinio: bump boost & asio deps --- recipes/restinio/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/restinio/all/conanfile.py b/recipes/restinio/all/conanfile.py index 1fec7b581abe4b..076732d0bd175c 100644 --- a/recipes/restinio/all/conanfile.py +++ b/recipes/restinio/all/conanfile.py @@ -45,9 +45,9 @@ def requirements(self): self.requires("variant-lite/2.0.0") if self.options.asio == "standalone": - self.requires("asio/1.28.0") + self.requires("asio/1.28.1") else: - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") From 6ebc920a20c12fc326e204cdbebf033d2d463562 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 05:49:06 +0900 Subject: [PATCH 0323/1140] (#19288) asio-grpc: update boost/1.83.0 --- recipes/asio-grpc/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/asio-grpc/all/conanfile.py b/recipes/asio-grpc/all/conanfile.py index b49ad78283c25d..cccd69684782dd 100644 --- a/recipes/asio-grpc/all/conanfile.py +++ b/recipes/asio-grpc/all/conanfile.py @@ -58,7 +58,7 @@ def configure(self): def requirements(self): self.requires("grpc/1.50.1") if self._local_allocator_option == "boost_container" or self.options.backend == "boost": - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") if self.options.backend == "asio": self.requires("asio/1.28.1") if self.options.backend == "unifex": From 145004db525be971b4e3664e1ca24a628ff5a671 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 06:33:43 +0900 Subject: [PATCH 0324/1140] (#19289) asyncly: update dependencies --- recipes/asyncly/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/asyncly/all/conanfile.py b/recipes/asyncly/all/conanfile.py index 1f48e267d577a4..bed73f009ac53d 100644 --- a/recipes/asyncly/all/conanfile.py +++ b/recipes/asyncly/all/conanfile.py @@ -52,8 +52,8 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.81.0", transitive_headers=True) - self.requires("function2/4.2.2", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) + self.requires("function2/4.2.3", transitive_headers=True) self.requires("prometheus-cpp/1.1.0", transitive_headers=True) def validate(self): From 91f258b8ebfd01c3e93c1081b6fe2a5640159a24 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 20 Aug 2023 00:08:55 +0200 Subject: [PATCH 0325/1140] (#19293) tcl: add version 8.6.13 --- recipes/tcl/all/conandata.yml | 5 +++++ recipes/tcl/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/tcl/all/conandata.yml b/recipes/tcl/all/conandata.yml index ddecf77805a4ca..027d30d480cf09 100644 --- a/recipes/tcl/all/conandata.yml +++ b/recipes/tcl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.6.13": + url: "https://downloads.sourceforge.net/project/tcl/Tcl/8.6.13/tcl8.6.13-src.tar.gz" + sha256: "43a1fae7412f61ff11de2cfd05d28cfc3a73762f354a417c62370a54e2caf066" "8.6.11": url: "https://downloads.sourceforge.net/project/tcl/Tcl/8.6.11/tcl8.6.11-src.tar.gz" sha256: "8c0486668586672c5693d7d95817cb05a18c5ecca2f40e2836b9578064088258" @@ -6,6 +9,8 @@ sources: url: "https://downloads.sourceforge.net/project/tcl/Tcl/8.6.10/tcl8.6.10-src.tar.gz" sha256: "5196dbf6638e3df8d5c87b5815c8c2b758496eb6f0e41446596c9a4e638d87ed" patches: + "8.6.13": + - patch_file: "patches/0001-8.6.11-no-read-only-data.patch" "8.6.11": - patch_file: "patches/0001-8.6.11-no-read-only-data.patch" "8.6.10": diff --git a/recipes/tcl/config.yml b/recipes/tcl/config.yml index 9e60b9c9066766..108b4ab57b9c6b 100644 --- a/recipes/tcl/config.yml +++ b/recipes/tcl/config.yml @@ -1,4 +1,6 @@ versions: + "8.6.13": + folder: "all" "8.6.11": folder: "all" "8.6.10": From 66d1f88625742e8cf16e4a3fcb54a2f9e32b14f4 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 07:31:12 +0900 Subject: [PATCH 0326/1140] (#19295) boost-leaf: add version 1.83.0 --- recipes/boost-leaf/all/conandata.yml | 3 +++ recipes/boost-leaf/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/boost-leaf/all/conandata.yml b/recipes/boost-leaf/all/conandata.yml index 7ea0efeaa464d5..593e982ab983b3 100644 --- a/recipes/boost-leaf/all/conandata.yml +++ b/recipes/boost-leaf/all/conandata.yml @@ -5,3 +5,6 @@ sources: "1.82.0": url: "https://github.com/boostorg/leaf/archive/refs/tags/boost-1.82.0.tar.gz" sha256: "0917b22b60a2980bf5e33a393a8545dc6a4a7006c8ca8b78280d1cdb965d75f3" + "1.83.0": + url: "https://github.com/boostorg/leaf/archive/refs/tags/boost-1.83.0.tar.gz" + sha256: "559b16ac2cd287885104f6d2b93cc777f136d98e89e3b9915013561d893f5128" diff --git a/recipes/boost-leaf/config.yml b/recipes/boost-leaf/config.yml index e86af291ae99fb..7468e5b2998336 100644 --- a/recipes/boost-leaf/config.yml +++ b/recipes/boost-leaf/config.yml @@ -3,3 +3,5 @@ versions: folder: "all" "1.82.0": folder: "all" + "1.83.0": + folder: "all" From 5183d1be3429c0557cc74d02d8232cf0d68f349a Mon Sep 17 00:00:00 2001 From: tt4g <45120617+tt4g@users.noreply.github.com> Date: Sun, 20 Aug 2023 12:09:16 +0900 Subject: [PATCH 0327/1140] (#19299) libpqxx: add version 7.8.1 --- recipes/libpqxx/all/conandata.yml | 7 +++++++ recipes/libpqxx/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/libpqxx/all/conandata.yml b/recipes/libpqxx/all/conandata.yml index 9d9a75993b0261..be515b537e23b8 100644 --- a/recipes/libpqxx/all/conandata.yml +++ b/recipes/libpqxx/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "7.8.1": + url: "https://github.com/jtv/libpqxx/archive/refs/tags/7.8.1.tar.gz" + sha256: "0f4c0762de45a415c9fd7357ce508666fa88b9a4a463f5fb76c235bc80dd6a84" "7.8.0": url: "https://github.com/jtv/libpqxx/archive/refs/tags/7.8.0.tar.gz" sha256: "bc471d8d34588f820f38e19e1cc217f399212eef900416cf12f90fab293628af" @@ -45,6 +48,10 @@ sources: url: "https://github.com/jtv/libpqxx/archive/6.4.8.tar.gz" sha256: "3f7aba951822e01f1b9f9f353702954773323dd9f9dc376ffb57cb6bbd9a7a2f" patches: + "7.8.1": + - patch_file: "patches/0001-cmake-fix-module.patch" + patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." + patch_type: "conan" "7.8.0": - patch_file: "patches/0001-cmake-fix-module.patch" patch_description: "Keep `CMAKE_MODULE_PATH` to be changed by conan." diff --git a/recipes/libpqxx/config.yml b/recipes/libpqxx/config.yml index 9ea1691e885020..e221557dc8d32d 100644 --- a/recipes/libpqxx/config.yml +++ b/recipes/libpqxx/config.yml @@ -1,4 +1,6 @@ versions: + "7.8.1": + folder: all "7.8.0": folder: all "7.7.5": From b41c9dc55232f4730c500415f1c77050d676bff5 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 12:48:32 +0900 Subject: [PATCH 0328/1140] (#19300) ftxui: add version 5.0.0 --- recipes/ftxui/all/conandata.yml | 3 +++ recipes/ftxui/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ftxui/all/conandata.yml b/recipes/ftxui/all/conandata.yml index 9093a5522f932e..56009c498942c4 100644 --- a/recipes/ftxui/all/conandata.yml +++ b/recipes/ftxui/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "5.0.0": + url: "https://github.com/ArthurSonzogni/FTXUI/archive/refs/tags/v5.0.0.tar.gz" + sha256: "a2991cb222c944aee14397965d9f6b050245da849d8c5da7c72d112de2786b5b" "4.1.1": url: "https://github.com/ArthurSonzogni/FTXUI/archive/refs/tags/v4.1.1.tar.gz" sha256: "9009d093e48b3189487d67fc3e375a57c7b354c0e43fc554ad31bec74a4bc2dd" diff --git a/recipes/ftxui/config.yml b/recipes/ftxui/config.yml index 727707c7ea7212..7747269b92a0d1 100644 --- a/recipes/ftxui/config.yml +++ b/recipes/ftxui/config.yml @@ -1,4 +1,6 @@ versions: + "5.0.0": + folder: all "4.1.1": folder: all "4.1.0": From 01f4a35ff2a7b5593b9ed5ed237401524223d96b Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 15:29:06 +0900 Subject: [PATCH 0329/1140] (#19303) docopt.cpp: update boost/1.83.0 --- recipes/docopt.cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/docopt.cpp/all/conanfile.py b/recipes/docopt.cpp/all/conanfile.py index 0745cc959331b1..f91d97fba08924 100644 --- a/recipes/docopt.cpp/all/conanfile.py +++ b/recipes/docopt.cpp/all/conanfile.py @@ -48,7 +48,7 @@ def layout(self): def requirements(self): if self.options.boost_regex: - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") def validate(self): if self.settings.compiler.get_safe("cppstd"): From 1f74b2326ba1db92454486dd53b06e11fb5746d2 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 16:10:12 +0900 Subject: [PATCH 0330/1140] (#19302) numcpp: update boost/1.83.0 --- recipes/numcpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/numcpp/all/conanfile.py b/recipes/numcpp/all/conanfile.py index 9f1e7ec1b42e93..a142a263b77044 100644 --- a/recipes/numcpp/all/conanfile.py +++ b/recipes/numcpp/all/conanfile.py @@ -62,7 +62,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_boost", True): - self.requires("boost/1.82.0", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) def package_id(self): self.info.clear() From a1af7a97b2d97197741c4c541a95a5c534b9d41e Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 20 Aug 2023 18:31:28 +0900 Subject: [PATCH 0331/1140] (#19304) wt: update dependencies --- recipes/wt/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/wt/all/conanfile.py b/recipes/wt/all/conanfile.py index 86da6cd03dedb4..630f87115fd109 100644 --- a/recipes/wt/all/conanfile.py +++ b/recipes/wt/all/conanfile.py @@ -96,7 +96,7 @@ def requirements(self): if Version(self.version) < "4.9.0": self.requires("boost/1.80.0", transitive_headers = True) else: - self.requires("boost/1.82.0", transitive_headers = True) + self.requires("boost/1.83.0", transitive_headers = True) if self.options.connector_http: self.requires("zlib/1.2.13") if self.options.with_ssl: @@ -104,13 +104,13 @@ def requirements(self): if self.options.get_safe("with_sqlite"): self.requires("sqlite3/3.42.0") if self.options.get_safe("with_mysql"): - self.requires("libmysqlclient/8.0.31", transitive_headers=True, transitive_libs=True) + self.requires("libmysqlclient/8.0.34", transitive_headers=True, transitive_libs=True) if self.options.get_safe("with_postgres"): - self.requires("libpq/15.3", transitive_headers=True, transitive_libs=True) + self.requires("libpq/15.4", transitive_headers=True, transitive_libs=True) if self.options.get_safe("with_mssql") and self.settings.os != "Windows": self.requires("odbc/2.3.11") if self.options.get_safe("with_unwind"): - self.requires("libunwind/1.7.0") + self.requires("libunwind/1.7.2") def validate(self): miss_boost_required_comp = any(self.dependencies["boost"].options.get_safe(f"without_{boost_comp}", True) From e62b499f6692b095655aa6c2fc1a0b3be6982eb1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 20 Aug 2023 18:12:01 +0300 Subject: [PATCH 0332/1140] (#19308) proj: bump libcurl to v8.2.1 --- recipes/proj/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/proj/all/conanfile.py b/recipes/proj/all/conanfile.py index 9afbca02d3ff6b..38d4022e8f8569 100644 --- a/recipes/proj/all/conanfile.py +++ b/recipes/proj/all/conanfile.py @@ -61,7 +61,7 @@ def requirements(self): if self.options.get_safe("with_tiff"): self.requires("libtiff/4.5.1") if self.options.get_safe("with_curl"): - self.requires("libcurl/8.2.0") + self.requires("libcurl/8.2.1") def build_requirements(self): if not can_run(self): From affcf551748a57ed3c1791a35a097a015696a1ac Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 08:09:22 +0900 Subject: [PATCH 0333/1140] (#19314) unordered_dense: add version 4.1.0 --- recipes/unordered_dense/all/conandata.yml | 3 +++ recipes/unordered_dense/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/unordered_dense/all/conandata.yml b/recipes/unordered_dense/all/conandata.yml index 5002689bc73b04..9666412e076d67 100644 --- a/recipes/unordered_dense/all/conandata.yml +++ b/recipes/unordered_dense/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.1.0": + url: "https://github.com/martinus/unordered_dense/archive/v4.1.0.tar.gz" + sha256: "0f594cb3b08fc657db3843139000005b6827e5c69d00f5c8d74c1239bd21746f" "4.0.4": url: "https://github.com/martinus/unordered_dense/archive/v4.0.4.tar.gz" sha256: "b34a8c942963e3a647f1bbc192a6391cd56d7ae615b2ddc1601c1779b5792206" diff --git a/recipes/unordered_dense/config.yml b/recipes/unordered_dense/config.yml index f99a8339fb5703..11719a7c946232 100644 --- a/recipes/unordered_dense/config.yml +++ b/recipes/unordered_dense/config.yml @@ -1,4 +1,6 @@ versions: + "4.1.0": + folder: all "4.0.4": folder: all "4.0.1": From 1e15e5fa1e44d034959ce7c81b16dcdc1dd3dd2c Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 08:30:52 +0900 Subject: [PATCH 0334/1140] (#19315) daw_utf_range: update daw_header_libraries --- recipes/daw_utf_range/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/daw_utf_range/all/conanfile.py b/recipes/daw_utf_range/all/conanfile.py index 98739a79d16226..77684e08bfd01d 100644 --- a/recipes/daw_utf_range/all/conanfile.py +++ b/recipes/daw_utf_range/all/conanfile.py @@ -38,7 +38,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("daw_header_libraries/2.93.1") + self.requires("daw_header_libraries/2.95.0") def package_id(self): self.info.clear() From 518b2b1f539bf305e777dfa654d90e85415bb3f6 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 08:53:13 +0900 Subject: [PATCH 0335/1140] (#19317) mp-units: update dependencies --- recipes/mp-units/0.8.0/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/mp-units/0.8.0/conanfile.py b/recipes/mp-units/0.8.0/conanfile.py index b662aae02b390f..360e81be61b3df 100644 --- a/recipes/mp-units/0.8.0/conanfile.py +++ b/recipes/mp-units/0.8.0/conanfile.py @@ -59,9 +59,9 @@ def _use_range_v3(self): def requirements(self): self.requires("gsl-lite/0.40.0") if self._use_libfmt: - self.requires("fmt/8.1.1") + self.requires("fmt/10.1.0") if self._use_range_v3: - self.requires("range-v3/0.11.0") + self.requires("range-v3/0.12.0") def validate(self): if self.settings.get_safe("compiler.cppstd"): From 8835eb11fa848825700b3a70fb24b7248130e27d Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 10:50:18 +0900 Subject: [PATCH 0336/1140] (#19319) mbits-diags: update fmt/10.1.0 --- recipes/mbits-diags/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mbits-diags/all/conanfile.py b/recipes/mbits-diags/all/conanfile.py index f6c4c3381f0e0e..204bf4ed9c3fae 100644 --- a/recipes/mbits-diags/all/conanfile.py +++ b/recipes/mbits-diags/all/conanfile.py @@ -51,7 +51,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fmt/9.1.0") + self.requires("fmt/10.1.0") self.requires("mbits-semver/0.1.1") def validate(self): From c935340e1971dc74dfce281f5be279b24b742ac0 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 12:48:57 +0900 Subject: [PATCH 0337/1140] (#19321) mbits-lngs: update fmt/10.1.0 --- recipes/mbits-lngs/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mbits-lngs/all/conanfile.py b/recipes/mbits-lngs/all/conanfile.py index 2db7f9f7b6cca7..49f97626d1e47d 100644 --- a/recipes/mbits-lngs/all/conanfile.py +++ b/recipes/mbits-lngs/all/conanfile.py @@ -50,7 +50,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fmt/9.1.0") + self.requires("fmt/10.1.0") self.requires("mbits-utfconv/1.0.3") self.requires("mbits-diags/0.9.6") self.requires("mbits-mstch/1.0.4") From 822a120ae1fb9224acf757be4b68963e29823c7b Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 17:29:32 +0900 Subject: [PATCH 0338/1140] (#18895) wasmer: add version 4.1.1 * wasmer: add version 4.1.0 * update 4.1.1 * fix checksum for 4.1.1 --------- Co-authored-by: Carlos Zoido --- recipes/wasmer/all/conandata.yml | 27 +++++++++++++++++++++++++++ recipes/wasmer/config.yml | 2 ++ 2 files changed, 29 insertions(+) diff --git a/recipes/wasmer/all/conandata.yml b/recipes/wasmer/all/conandata.yml index 55462c58cc4d03..9f36767ca9925e 100644 --- a/recipes/wasmer/all/conandata.yml +++ b/recipes/wasmer/all/conandata.yml @@ -1,4 +1,31 @@ sources: + "4.1.1": + Windows: + "x86_64": + "Visual Studio": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-windows-amd64.tar.gz" + sha256: "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855" + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-windows-gnu64.tar.gz" + sha256: "47fb2d9563995fe180fc2a56255f8eb2ffe19de6ee9d512920a7823bc12e66c5" + Linux: + "x86_64": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-linux-amd64.tar.gz" + sha256: "778e87bb62748f2899bb06fe1d07ca3038705b996c93e0c28db12ccc032c0c4e" + "armv8": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-linux-aarch64.tar.gz" + sha256: "74cc40fcfe4108c0240137a47704d4f6ade8895c70da25358b471fe32ce47a50" + Macos: + "x86_64": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-darwin-amd64.tar.gz" + sha256: "113f58b1560c21607f0011ec6a835bdf109efc2f3be6f200ff8bc8b9591d021e" + "armv8": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.1.1/wasmer-darwin-arm64.tar.gz" + sha256: "5eaf3a3b5a2607dd29f70bf21008140a079662bddf42e75e97da71355a29d961" "4.0.0": Windows: "x86_64": diff --git a/recipes/wasmer/config.yml b/recipes/wasmer/config.yml index 23eb21bb556fff..bac9dd3778328e 100644 --- a/recipes/wasmer/config.yml +++ b/recipes/wasmer/config.yml @@ -1,4 +1,6 @@ versions: + "4.1.1": + folder: "all" "4.0.0": folder: "all" "3.2.1": From 2d286525197c33b16cd284a7cd39a422d36caebc Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 21 Aug 2023 11:42:08 +0200 Subject: [PATCH 0339/1140] (#19313) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index fec7da6449a4b3..09348eebe130c7 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -123,6 +123,7 @@ required_for_references: - capnproto - capstone - cargs +- cassandra-cpp-driver - catch2 - ccache - cccl @@ -152,6 +153,7 @@ required_for_references: - cli11 - clickhouse-cpp - clipper +- clipper2 - clove-unit - cmake - cmocka @@ -176,6 +178,7 @@ required_for_references: - cpp-optparse - cpp-peglib - cpp-sort +- cpp_project_framework - cppbenchmark - cppcheck - cppcmd @@ -231,6 +234,7 @@ required_for_references: - dbus - debug_assert - decimal_for_cpp +- deco - di - dice-template-library - dirent @@ -255,6 +259,7 @@ required_for_references: - eastl - easy_profiler - easyhttpcpp +- easyloggingpp - ecos - editline - edlib @@ -269,6 +274,7 @@ required_for_references: - emio - enet - enhex-generic_serialization +- enhex-strong_type - entityx - entt - enum-flags @@ -464,6 +470,7 @@ required_for_references: - kainjow-mustache - kaitai_struct_cpp_stl_runtime - kangaru +- kdbindings - keychain - khrplatform - kickcat @@ -752,6 +759,7 @@ required_for_references: - netcdf - nettle - nextsilicon-cpp-subprocess +- nfrechette-acl - ninja - nlohmann_json - nlopt @@ -771,6 +779,7 @@ required_for_references: - nvtx - oatpp - objectbox +- objectbox-generator - observer-ptr-lite - octomap - odbc @@ -872,6 +881,7 @@ required_for_references: - pprint - pranav-csv2 - pretty-name +- procxx-boost-ext-simd - proj - prometheus-cpp - proposal @@ -898,6 +908,7 @@ required_for_references: - qt - quantlib - quaternions +- quickfix - quickjs - quill - quirc @@ -936,6 +947,7 @@ required_for_references: - roaring - robin-hood-hashing - rply +- rtklib - rtm - rtmidi - rttr @@ -949,6 +961,7 @@ required_for_references: - sbepp - sbp - scip +- scippp - scnlib - scons - scope-lite @@ -1015,6 +1028,7 @@ required_for_references: - stduuid - stlab - strawberryperl +- streamvbyte - string-view-lite - stringtoolbox - strong_type @@ -1079,6 +1093,7 @@ required_for_references: - unordered_dense - unqlite - upx +- urdfdom - uriparser - usockets - usrsctp @@ -1103,6 +1118,8 @@ required_for_references: - vulkan-loader - vulkan-memory-allocator - vulkan-validationlayers +- vvenc +- wasm-micro-runtime - wasmer - wasmtime - wasmtime-cpp @@ -1146,6 +1163,7 @@ required_for_references: - xxhash - xxsds-sdsl-lite - xz_utils +- yaclib - yajl - yaml-cpp - yas From 4de58a354a00f6c647f7ed1d0a846954873ad413 Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Mon, 21 Aug 2023 12:08:33 +0200 Subject: [PATCH 0340/1140] (#19124) [cgal] add cgal/5.6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/cgal/all/conandata.yml | 3 +++ recipes/cgal/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cgal/all/conandata.yml b/recipes/cgal/all/conandata.yml index 74b2b15e01e387..eda02a9fb3ec44 100644 --- a/recipes/cgal/all/conandata.yml +++ b/recipes/cgal/all/conandata.yml @@ -14,6 +14,9 @@ sources: "5.5.3": sha256: 0a04f662693256328b05babfabb5e3a5b7db2f5a58d52e3c520df9d0828ddd73 url: https://github.com/CGAL/cgal/releases/download/v5.5.3/CGAL-5.5.3.tar.xz + "5.6": + sha256: dcab9b08a50a06a7cc2cc69a8a12200f8d8f391b9b8013ae476965c10b45161f + url: https://github.com/CGAL/cgal/releases/download/v5.6/CGAL-5.6.tar.xz patches: "5.3.2": - patch_file: "patches/0001-fix-for-conan.patch" diff --git a/recipes/cgal/config.yml b/recipes/cgal/config.yml index e8e1391dbacd37..3d807cdb944c78 100644 --- a/recipes/cgal/config.yml +++ b/recipes/cgal/config.yml @@ -9,3 +9,5 @@ versions: folder: all "5.5.3": folder: all + "5.6": + folder: all From 0e747bf17947be9ffcab34f55e9c483647d8dc37 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 21:48:22 +0900 Subject: [PATCH 0341/1140] (#18870) ada: add version 2.6.0 * ada: add version 2.6.0 * support rpath, link mathlib * fix rpath issue with proper way --- recipes/ada/all/conandata.yml | 3 +++ recipes/ada/all/conanfile.py | 14 +++++++++++--- recipes/ada/config.yml | 2 ++ 3 files changed, 16 insertions(+), 3 deletions(-) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index 377c8fab6dad4f..97acb278526f59 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.0": + url: "https://github.com/ada-url/ada/archive/v2.6.0.tar.gz" + sha256: "09551bfbd92853e59d731e5f44a88a690425fd2906977ad03a6a1059615a02a5" "2.5.1": url: "https://github.com/ada-url/ada/archive/v2.5.1.tar.gz" sha256: "a7591d771822c3f16e6665311b0c6b4de7dd7615333183f35d89c7573be7f7fa" diff --git a/recipes/ada/all/conanfile.py b/recipes/ada/all/conanfile.py index dcb06ed03de1ae..76d787b5a14b7d 100644 --- a/recipes/ada/all/conanfile.py +++ b/recipes/ada/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import get, copy, rmdir +from conan.tools.files import get, copy, rmdir, replace_in_file from conan.tools.build import check_min_cppstd from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout @@ -69,8 +69,7 @@ def validate(self): ) def build_requirements(self): - if Version(self.version) >= "0.6.0": - self.tool_requires("cmake/[>=3.16 <4]") + self.tool_requires("cmake/[>=3.16 <4]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -78,12 +77,19 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["BUILD_TESTING"] = False + if Version(self.version) >= "2.4.2": + tc.variables["ADA_TOOLS"] = False tc.generate() deps = CMakeDeps(self) deps.generate() + def _patch_sources(self): + # solve APPLE RELOCATABLE SHARED LIBS (KB-H077) + replace_in_file(self, os.path.join(self.source_folder, "cmake", "ada-flags.cmake"), "set(CMAKE_MACOSX_RPATH OFF)", "") + def build(self): + self._patch_sources() cmake = CMake(self) cmake.configure() cmake.build() @@ -97,3 +103,5 @@ def package(self): def package_info(self): self.cpp_info.libs = ["ada"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index 7612786acc48cd..aa9794668e5459 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.0": + folder: all "2.5.1": folder: all "2.5.0": From bfb41d731aa030b9b1ddc3d2b840c6682834bec1 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 21 Aug 2023 22:53:27 +0900 Subject: [PATCH 0342/1140] (#19318) sbepp: update dependencies * sbepp: update dependencies * separate requires recipe's versions * add comment --- recipes/sbepp/all/conanfile.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/recipes/sbepp/all/conanfile.py b/recipes/sbepp/all/conanfile.py index a444e6edb4d52c..550f0466dea48c 100644 --- a/recipes/sbepp/all/conanfile.py +++ b/recipes/sbepp/all/conanfile.py @@ -64,8 +64,13 @@ def package_id(self): def requirements(self): if self.options.with_sbeppc: - self.requires("fmt/9.1.0") - self.requires("pugixml/1.12.1") + # sbepp/<1.1.0 requires fmt and pugixml with hardcoded versions + if Version(self.version) < "1.1.0": + self.requires("fmt/9.1.0") + self.requires("pugixml/1.12.1") + else: + self.requires("fmt/10.1.0") + self.requires("pugixml/1.13") def validate(self): if self.settings.compiler.cppstd: From b25ae2c58cace7f85dd31b27750a1e99fbcb7837 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Mon, 21 Aug 2023 07:32:03 -0700 Subject: [PATCH 0343/1140] (#19320) lyra: make sure libdirs is empty for this header-only library --- recipes/lyra/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/lyra/all/conanfile.py b/recipes/lyra/all/conanfile.py index 184573a6e3fe94..f549011151d40e 100644 --- a/recipes/lyra/all/conanfile.py +++ b/recipes/lyra/all/conanfile.py @@ -57,3 +57,4 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "bfg" self.cpp_info.components["_lyra"].names["cmake_find_package"] = "lyra" self.cpp_info.components["_lyra"].names["cmake_find_package_multi"] = "lyra" + self.cpp_info.components["_lyra"].libdirs = [] From 25e198edb46e55355ec35958f69f92e952f41a5c Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 21 Aug 2023 17:11:03 +0200 Subject: [PATCH 0344/1140] (#19233) rtmidi: fix sha256 of 6.0.0 --- recipes/rtmidi/all/conandata.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/rtmidi/all/conandata.yml b/recipes/rtmidi/all/conandata.yml index 4359539b48015b..9413bb8e982462 100644 --- a/recipes/rtmidi/all/conandata.yml +++ b/recipes/rtmidi/all/conandata.yml @@ -1,7 +1,7 @@ sources: "6.0.0": url: "https://www.music.mcgill.ca/~gary/rtmidi/release/rtmidi-6.0.0.tar.gz" - sha256: "3336248e8c1f054ea5e51a4449558490dca51edd324fcde0eea27df33b80a9ed" + sha256: "5960ccf64b42c23400720ccc880e2f205677ce9457f747ef758b598acd64db5b" "5.0.0": url: "https://www.music.mcgill.ca/~gary/rtmidi/release/rtmidi-5.0.0.tar.gz" sha256: "48db0ed58c8c0e207b5d7327a0210b5bcaeb50e26387935d02829239b0f3c2b9" From 12ba07d07fb0e6694ee611adf49cbab129f212d6 Mon Sep 17 00:00:00 2001 From: Sergey Avseyev Date: Mon, 21 Aug 2023 18:50:58 +0300 Subject: [PATCH 0345/1140] (#19294) Bump Taocpp JSON to 1.0.0-beta.14 --- recipes/taocpp-json/all/conandata.yml | 3 +++ recipes/taocpp-json/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/taocpp-json/all/conandata.yml b/recipes/taocpp-json/all/conandata.yml index 732888cb32c08d..08a817ecfe94bf 100644 --- a/recipes/taocpp-json/all/conandata.yml +++ b/recipes/taocpp-json/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.0-beta.14": + sha256: f9e44a1d6a70a6d39b9e45df76eac928e69f5318e5a957fd5c0efdf45dacaf5e + url: https://github.com/taocpp/json/archive/1.0.0-beta.14.tar.gz "1.0.0-beta.13": sha256: 2513b32d1883277f78071ff1cc55d4f35a979fffdaddf6412d3cb67852ce68b5 url: https://github.com/taocpp/json/archive/1.0.0-beta.13.tar.gz diff --git a/recipes/taocpp-json/config.yml b/recipes/taocpp-json/config.yml index 1c4b5480a0dce2..fb0ab49d5fd2c4 100644 --- a/recipes/taocpp-json/config.yml +++ b/recipes/taocpp-json/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.0-beta.14": + folder: all "1.0.0-beta.13": folder: all "1.0.0-beta.12": From bbb3bc4e48cd9c57b3ed9a159428fdda98b78e78 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 22 Aug 2023 01:11:19 +0900 Subject: [PATCH 0346/1140] (#19306) trantor: add version 1.5.12 * trantor: add version 1.5.12 * support gcc5 --- recipes/trantor/all/conandata.yml | 7 +++++++ recipes/trantor/all/conanfile.py | 2 +- .../all/patches/1.5.12-0001-disable-werror.patch | 13 +++++++++++++ recipes/trantor/config.yml | 2 ++ 4 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 recipes/trantor/all/patches/1.5.12-0001-disable-werror.patch diff --git a/recipes/trantor/all/conandata.yml b/recipes/trantor/all/conandata.yml index 22a2a702c41db2..336360051b220b 100644 --- a/recipes/trantor/all/conandata.yml +++ b/recipes/trantor/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.12": + url: "https://github.com/an-tao/trantor/archive/v1.5.12.tar.gz" + sha256: "3389a2ace83fdc0df7e3e7f9cd9fa9b774f8054889a13a73777c71e2d8e2f364" "1.5.11": url: "https://github.com/an-tao/trantor/archive/v1.5.11.tar.gz" sha256: "3cff9653380f65acaa6ffa191620a2783e866a4552c3408a6919759ce4cfc1dc" @@ -18,6 +21,10 @@ sources: url: "https://github.com/an-tao/trantor/archive/refs/tags/v1.5.5.tar.gz" sha256: "5a549c6efebe7ecba73a944cfba4a9713130704d4ccc82af534a2e108b9a0e71" patches: + "1.5.12": + - patch_file: "patches/1.5.12-0001-disable-werror.patch" + patch_description: "disable -Werror for gcc5" + patch_type: "portability" "1.5.11": - patch_file: "patches/1.5.6-0001-include-cstdint.patch" patch_description: "include cstdint for uint8_t, intmax_t" diff --git a/recipes/trantor/all/conanfile.py b/recipes/trantor/all/conanfile.py index eae8498e374147..8d8c3bbf7e46e1 100644 --- a/recipes/trantor/all/conanfile.py +++ b/recipes/trantor/all/conanfile.py @@ -61,7 +61,7 @@ def layout(self): def requirements(self): self.requires("openssl/[>=1.1 <4]") if self.options.with_c_ares: - self.requires("c-ares/1.19.0") + self.requires("c-ares/1.19.1") def validate(self): if self.info.settings.compiler.get_safe("cppstd"): diff --git a/recipes/trantor/all/patches/1.5.12-0001-disable-werror.patch b/recipes/trantor/all/patches/1.5.12-0001-disable-werror.patch new file mode 100644 index 00000000000000..ac4b2f2545dceb --- /dev/null +++ b/recipes/trantor/all/patches/1.5.12-0001-disable-werror.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 810c2c1..a4f375d 100755 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -46,7 +46,7 @@ if(BUILD_SHARED_LIBS) + endif(BUILD_SHARED_LIBS) + + if (NOT ${CMAKE_SYSTEM_NAME} STREQUAL "Windows" AND CMAKE_CXX_COMPILER_ID MATCHES Clang|GNU) +- target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wextra -Werror) ++ target_compile_options(${PROJECT_NAME} PRIVATE -Wall -Wextra) + endif() + + if(${CMAKE_SYSTEM_NAME} STREQUAL "Haiku") diff --git a/recipes/trantor/config.yml b/recipes/trantor/config.yml index 57e22ce3a2fae2..ceb70d24170866 100644 --- a/recipes/trantor/config.yml +++ b/recipes/trantor/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.12": + folder: "all" "1.5.11": folder: "all" "1.5.10": From bcc21d29665f76caa1a901a1ce7ed9b6eef98d58 Mon Sep 17 00:00:00 2001 From: Gregor Jasny Date: Mon, 21 Aug 2023 19:17:38 +0200 Subject: [PATCH 0347/1140] (#19311) binutils: add version 2.41 --- recipes/binutils/all/conandata.yml | 7 +++ .../all/patches/2.41-0001-no-texinfo.patch | 57 +++++++++++++++++++ recipes/binutils/config.yml | 2 + 3 files changed, 66 insertions(+) create mode 100644 recipes/binutils/all/patches/2.41-0001-no-texinfo.patch diff --git a/recipes/binutils/all/conandata.yml b/recipes/binutils/all/conandata.yml index 24c6d4be967982..92a40425b25909 100644 --- a/recipes/binutils/all/conandata.yml +++ b/recipes/binutils/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.41": + url: "https://ftp.gnu.org/gnu/binutils/binutils-2.41.tar.gz" + sha256: "48d00a8dc73aa7d2394a7dc069b96191d95e8de8f0da6dc91da5cce655c20e45" "2.40": url: "https://ftp.gnu.org/gnu/binutils/binutils-2.40.tar.gz" sha256: "d7f82c4047decf43a6f769ac32456a92ddb6932409a585c633cdd4e9df23d956" @@ -9,6 +12,10 @@ sources: url: "https://ftp.gnu.org/gnu/binutils/binutils-2.37.tar.gz" sha256: "c44968b97cd86499efbc4b4ab7d98471f673e5414c554ef54afa930062dbbfcb" patches: + "2.41": + - patch_file: "patches/2.41-0001-no-texinfo.patch" + patch_type: conan + patch_description: "disable texinfo" "2.40": - patch_file: "patches/2.40-0001-no-texinfo.patch" patch_type: conan diff --git a/recipes/binutils/all/patches/2.41-0001-no-texinfo.patch b/recipes/binutils/all/patches/2.41-0001-no-texinfo.patch new file mode 100644 index 00000000000000..f6d719e75f24ea --- /dev/null +++ b/recipes/binutils/all/patches/2.41-0001-no-texinfo.patch @@ -0,0 +1,57 @@ +diff --git a/bfd/Makefile.in b/bfd/Makefile.in +index 4edfedee..47c7de53 100644 +--- a/bfd/Makefile.in ++++ b/bfd/Makefile.in +@@ -253,7 +253,7 @@ am__v_texidevnull_ = $(am__v_texidevnull_@AM_DEFAULT_V@) + am__v_texidevnull_0 = > /dev/null + am__v_texidevnull_1 = + am__dirstamp = $(am__leading_dot)dirstamp +-INFO_DEPS = doc/bfd.info ++INFO_DEPS = + am__TEXINFO_TEX_DIR = $(srcdir) + DVIS = doc/bfd.dvi + PDFS = doc/bfd.pdf +@@ -2022,7 +2022,7 @@ distclean-tags: + check-am: all-am + check: $(BUILT_SOURCES) + $(MAKE) $(AM_MAKEFLAGS) check-recursive +-all-am: Makefile $(INFO_DEPS) $(LTLIBRARIES) $(HEADERS) config.h ++all-am: Makefile $(LTLIBRARIES) $(HEADERS) config.h + installdirs: installdirs-recursive + installdirs-am: + for dir in "$(DESTDIR)$(bfdlibdir)" "$(DESTDIR)$(infodir)" "$(DESTDIR)$(bfdincludedir)"; do \ +@@ -2089,8 +2089,7 @@ info: info-recursive + + info-am: $(INFO_DEPS) + +-install-data-am: install-bfdincludeHEADERS install-bfdlibLTLIBRARIES \ +- install-info-am ++install-data-am: install-bfdincludeHEADERS install-bfdlibLTLIBRARIES + + install-dvi: install-dvi-recursive + +diff --git a/gas/Makefile.in b/gas/Makefile.in +index 427f42df..535ad3f3 100644 +--- a/gas/Makefile.in ++++ b/gas/Makefile.in +@@ -1793,7 +1793,7 @@ distclean-DEJAGNU: + check-am: all-am + $(MAKE) $(AM_MAKEFLAGS) check-DEJAGNU + check: check-recursive +-all-am: Makefile $(INFO_DEPS) $(PROGRAMS) $(SCRIPTS) $(MANS) config.h ++all-am: Makefile $(PROGRAMS) $(SCRIPTS) $(MANS) config.h + installdirs: installdirs-recursive + installdirs-am: + for dir in "$(DESTDIR)$(infodir)" "$(DESTDIR)$(man1dir)"; do \ +@@ -1869,7 +1869,7 @@ info: info-recursive + + info-am: $(INFO_DEPS) info-local + +-install-data-am: install-info-am install-man ++install-data-am: install-man + + install-dvi: install-dvi-recursive + +-- +2.34.1 + diff --git a/recipes/binutils/config.yml b/recipes/binutils/config.yml index 8d19abd9678f78..97d0d2ecab157c 100644 --- a/recipes/binutils/config.yml +++ b/recipes/binutils/config.yml @@ -1,4 +1,6 @@ versions: + "2.41": + folder: all "2.40": folder: all "2.38": From 85a0eeb3950b0037da2ee074537408a999700bc8 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 22 Aug 2023 02:54:09 +0900 Subject: [PATCH 0348/1140] (#19316) svgwrite: update fmt/10.1.0 --- recipes/svgwrite/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/svgwrite/all/conanfile.py b/recipes/svgwrite/all/conanfile.py index cac9b7b0b66e8f..9c1c80b182559b 100644 --- a/recipes/svgwrite/all/conanfile.py +++ b/recipes/svgwrite/all/conanfile.py @@ -56,7 +56,7 @@ def layout(self): def requirements(self): self.requires("span-lite/0.10.3", transitive_headers=True) - self.requires("fmt/10.0.0") + self.requires("fmt/10.1.0") def validate(self): if self.settings.compiler.cppstd: From 9db4817d600f2513905dcf7df800a2d5e1c949af Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 21 Aug 2023 21:25:12 +0300 Subject: [PATCH 0349/1140] (#18090) boostdep: migrate to Conan v2, add v1.82.0 * boostdep: migrate to Conan v2 * boostdep: restore test_v1_package * boostdep: fix permanent redirect in URL Was highlighted by https://repology.org/repository/conancenter/problems --------- Co-authored-by: Daniel --- recipes/boostdep/all/CMakeLists.txt | 7 -- recipes/boostdep/all/conandata.yml | 7 +- recipes/boostdep/all/conanfile.py | 74 +++++++++++-------- .../boostdep/all/test_package/conanfile.py | 27 ++++--- .../boostdep/all/test_v1_package/conanfile.py | 17 +++++ recipes/boostdep/config.yml | 2 + 6 files changed, 82 insertions(+), 52 deletions(-) delete mode 100644 recipes/boostdep/all/CMakeLists.txt create mode 100644 recipes/boostdep/all/test_v1_package/conanfile.py diff --git a/recipes/boostdep/all/CMakeLists.txt b/recipes/boostdep/all/CMakeLists.txt deleted file mode 100644 index 5e53cb70bdf381..00000000000000 --- a/recipes/boostdep/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(source_subfolder) diff --git a/recipes/boostdep/all/conandata.yml b/recipes/boostdep/all/conandata.yml index 3831a32bc89c95..943785c9b1d4a5 100644 --- a/recipes/boostdep/all/conandata.yml +++ b/recipes/boostdep/all/conandata.yml @@ -1,6 +1,11 @@ sources: + 1.82.0: + - url: "https://github.com/boostorg/boostdep/archive/refs/tags/boost-1.82.0.tar.gz" + sha256: "b3bffa292709ad74bf2fa50831890161ad7b9ef33f9f4ffa83d474da4482a452" + - url: "https://www.boost.org/LICENSE_1_0.txt" + sha256: "c9bff75738922193e67fa726fa225535870d2aa1059f91452c411736284ad566" 1.75.0: - url: "https://github.com/boostorg/boostdep/archive/boost-1.75.0.tar.gz" sha256: "7eecd835eb5b0fd602ff3615a6b663b45917689386d11073d961b86710f428af" - - url: "http://www.boost.org/LICENSE_1_0.txt" + - url: "https://www.boost.org/LICENSE_1_0.txt" sha256: "c9bff75738922193e67fa726fa225535870d2aa1059f91452c411736284ad566" diff --git a/recipes/boostdep/all/conanfile.py b/recipes/boostdep/all/conanfile.py index 01a84ccc90d698..bd8dd57eb93dc9 100644 --- a/recipes/boostdep/all/conanfile.py +++ b/recipes/boostdep/all/conanfile.py @@ -1,58 +1,68 @@ -from conans import CMake, ConanFile, tools import os +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, download, get + +required_conan_version = ">=1.52.0" + class BoostDepConan(ConanFile): name = "boostdep" - settings = "os", "arch", "compiler", "build_type" description = "A tool to create Boost module dependency reports" + license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/boostorg/boostdep" - license = "BSL-1.0" - topics = ("conan", "boostdep", "dependency", "tree") - exports_sources = "CMakeLists.txt" - generators = "cmake", "cmake_find_package" + topics = ("dependency", "tree") - _cmake = None + package_type = "application" + settings = "os", "arch", "compiler", "build_type" - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) - @property - def _build_subfolder(self): - return "build_subfolder" + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.75.0") + self.requires(f"boost/{self.version}") def package_id(self): del self.info.settings.compiler def source(self): - tools.get(**self.conan_data["sources"][self.version][0]) - os.rename("boostdep-boost-{}".format(self.version), self._source_subfolder) - license_info = self.conan_data["sources"][self.version][1] - tools.download(filename=os.path.basename(license_info["url"]), **license_info) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["Boost_USE_STATIC_LIBS"] = not self.options["boost"].shared - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + sources_info, license_info = self.conan_data["sources"][self.version] + get(self, **sources_info, strip_root=True) + download(self, **license_info, filename=os.path.basename(license_info["url"])) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["Boost_USE_STATIC_LIBS"] = not self.dependencies["boost"].options.shared + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE*", dst="licenses") - cmake = self._configure_cmake() + copy( + self, + "LICENSE*", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder, + ) + cmake = CMake(self) cmake.install() def package_info(self): - bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_path)) - self.deps_env_info.PATH.append(bin_path) + self.cpp_info.frameworkdirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = [] + self.cpp_info.includedirs = [] + + # TODO: Legacy, to be removed on Conan 2.0 + bin_folder = os.path.join(self.package_folder, "bin") + self.env_info.PATH.append(bin_folder) diff --git a/recipes/boostdep/all/test_package/conanfile.py b/recipes/boostdep/all/test_package/conanfile.py index 190cc18502e119..2b15ef763d620a 100644 --- a/recipes/boostdep/all/test_package/conanfile.py +++ b/recipes/boostdep/all/test_package/conanfile.py @@ -1,17 +1,20 @@ -from conans import ConanFile, tools -import os +from conan import ConanFile +from conan.tools.env import Environment +from conan.tools.files import mkdir, save -class DefaultNameConan(ConanFile): - settings = "os", "compiler", "arch", "build_type" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "VirtualBuildEnv" + test_type = "explicit" - def build(self): - pass + def build_requirements(self): + self.tool_requires(self.tested_reference_str) def test(self): - if tools.cross_building(self.settings): - return - tools.mkdir("libs") - tools.save("Jamroot", "") - with tools.environment_append({"BOOST_ROOT": self.build_folder}): - self.run("boostdep --list-modules", run_environment=True) + mkdir(self, "libs") + save(self, "Jamroot", "") + env = Environment() + env.define("BOOST_ROOT", self.build_folder) + with env.vars(self).apply(): + self.run("boostdep --list-modules") diff --git a/recipes/boostdep/all/test_v1_package/conanfile.py b/recipes/boostdep/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..190cc18502e119 --- /dev/null +++ b/recipes/boostdep/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, tools +import os + + +class DefaultNameConan(ConanFile): + settings = "os", "compiler", "arch", "build_type" + + def build(self): + pass + + def test(self): + if tools.cross_building(self.settings): + return + tools.mkdir("libs") + tools.save("Jamroot", "") + with tools.environment_append({"BOOST_ROOT": self.build_folder}): + self.run("boostdep --list-modules", run_environment=True) diff --git a/recipes/boostdep/config.yml b/recipes/boostdep/config.yml index 640761587c2aee..1cbe5a69a954fc 100644 --- a/recipes/boostdep/config.yml +++ b/recipes/boostdep/config.yml @@ -1,3 +1,5 @@ versions: + "1.82.0": + folder: "all" "1.75.0": folder: "all" From bbb7def8d09c938fcd90d4a905c9b8a87880a4f6 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 21 Aug 2023 21:51:46 +0300 Subject: [PATCH 0350/1140] (#19245) fpgen: use lazy_lt_semver() in validate() * fpgen: use lazy_lt_semver() in validate() * fpgen: remove unused imports --- recipes/fpgen/all/conanfile.py | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/recipes/fpgen/all/conanfile.py b/recipes/fpgen/all/conanfile.py index 46fc8ca2ceba0b..5d2f0cf538ac50 100644 --- a/recipes/fpgen/all/conanfile.py +++ b/recipes/fpgen/all/conanfile.py @@ -3,9 +3,8 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import copy, get, replace_in_file +from conan.tools.files import copy, get from conan.tools.layout import basic_layout -from conan.tools.scm import Version required_conan_version = ">=1.52.0" @@ -49,8 +48,12 @@ def validate(self): if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) + def lazy_lt_semver(v1, v2): + # Needed to allow version "13" >= "13.1" for apple-clang + return all(int(p1) < int(p2) for p1, p2 in zip(v1.split("."), v2.split("."))) + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version and Version(self.settings.compiler.version) < minimum_version: + if minimum_version and lazy_lt_semver(str(self.settings.compiler.version), minimum_version): raise ConanInvalidConfiguration( f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) From 428a749939c50f63a85ac846db447d38007303b7 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 21 Aug 2023 22:05:43 +0300 Subject: [PATCH 0351/1140] (#18260) pipes: migrate to Conan v2 * pipes: migrate to Conan v2 * pipes: restore test_v1_package * pipes: restore VirtualRunEnv in test_package * pipes: dont add test_v1_package --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/pipes/all/conanfile.py | 55 ++++++++++++------- recipes/pipes/all/test_package/CMakeLists.txt | 5 +- recipes/pipes/all/test_package/conanfile.py | 22 ++++++-- .../pipes/all/test_package/test_package.cpp | 6 +- 4 files changed, 56 insertions(+), 32 deletions(-) diff --git a/recipes/pipes/all/conanfile.py b/recipes/pipes/all/conanfile.py index 70bc84cbc789fc..c2e8937d21d4a5 100644 --- a/recipes/pipes/all/conanfile.py +++ b/recipes/pipes/all/conanfile.py @@ -1,20 +1,26 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + + class PipesConan(ConanFile): name = "pipes" description = "Pipelines for expressive code on collections in C++" license = "MIT" - topics = ("pipes", "functional-programming") - homepage = "https://github.com/joboccara/pipes" url = "https://github.com/conan-io/conan-center-index" - settings = "compiler" - no_copy_source = True + homepage = "https://github.com/joboccara/pipes" + topics = ("functional-programming", "header-only") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _minimum_cpp_standard(self): @@ -31,23 +37,30 @@ def _minimum_compilers_version(self): def configure(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._minimum_cpp_standard) min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) if not min_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") else: - if tools.Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration("{} requires C++{} support. The current compiler {} {} does not support it.".format( - self.name, self._minimum_cpp_standard, self.settings.compiler, self.settings.compiler.version)) + if Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" + f" {self.settings.compiler} {self.settings.compiler.version} does not support it." + ) + + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() - + self.info.clear() + def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename("pipes-{}".format(self.version), self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.hpp", dst="include", src=os.path.join(self._source_subfolder, "include"), keep_path=True) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, "*.hpp", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include"), keep_path=True) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/pipes/all/test_package/CMakeLists.txt b/recipes/pipes/all/test_package/CMakeLists.txt index f24c18a1bb2e16..39ba4f454e712f 100644 --- a/recipes/pipes/all/test_package/CMakeLists.txt +++ b/recipes/pipes/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(pipes REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/pipes/all/test_package/conanfile.py b/recipes/pipes/all/test_package/conanfile.py index 910ae60d104386..ef5d7042163ecc 100644 --- a/recipes/pipes/all/test_package/conanfile.py +++ b/recipes/pipes/all/test_package/conanfile.py @@ -1,9 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pipes/all/test_package/test_package.cpp b/recipes/pipes/all/test_package/test_package.cpp index 5279bc00ec63cc..2050756e502b31 100644 --- a/recipes/pipes/all/test_package/test_package.cpp +++ b/recipes/pipes/all/test_package/test_package.cpp @@ -1,6 +1,10 @@ -#include +// Workaround for pipes not finding size_t +#include + #include +#include + int main() { auto source = std::vector{0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; auto destination = std::vector{}; From d6de8f71f77ceff8cd3851de97737f8a9b20378c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 21 Aug 2023 22:48:12 +0300 Subject: [PATCH 0352/1140] (#18789) libxft: migrate to Conan v2, add v2.3.8 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libxft: migrate to Conan v2 * libxft: add 2.3.8 * libxft: restore VirtualRunEnv in test_package * libxft: bump deps --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libxft/all/conandata.yml | 4 +- recipes/libxft/all/conanfile.py | 96 ++++++++++--------- .../libxft/all/test_package/CMakeLists.txt | 5 +- recipes/libxft/all/test_package/conanfile.py | 21 ++-- .../libxft/all/test_v1_package/CMakeLists.txt | 8 ++ .../libxft/all/test_v1_package/conanfile.py | 17 ++++ recipes/libxft/config.yml | 2 + 7 files changed, 98 insertions(+), 55 deletions(-) create mode 100644 recipes/libxft/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libxft/all/test_v1_package/conanfile.py diff --git a/recipes/libxft/all/conandata.yml b/recipes/libxft/all/conandata.yml index e56e888b5fdb6d..83115b8c226aad 100644 --- a/recipes/libxft/all/conandata.yml +++ b/recipes/libxft/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.3.8": + url: "https://www.x.org/archive/individual/lib/libXft-2.3.8.tar.xz" + sha256: "5e8c3c4bc2d4c0a40aef6b4b38ed2fb74301640da29f6528154b5009b1c6dd49" "2.3.6": url: "https://www.x.org/archive/individual/lib/libXft-2.3.6.tar.gz" sha256: "b7e59f69e0bbabe9438088775f7e5a7c16a572e58b11f9722519385d38192df5" @@ -11,4 +14,3 @@ patches: patch_description: "fix gcc 5 and gcc 11 compilation" patch_type: "portability" patch_source: "https://gitlab.freedesktop.org/xorg/lib/libxft/-/merge_requests/17" - base_path: "source_subfolder" diff --git a/recipes/libxft/all/conanfile.py b/recipes/libxft/all/conanfile.py index c237fe2cfea9c4..6029ce556514a6 100644 --- a/recipes/libxft/all/conanfile.py +++ b/recipes/libxft/all/conanfile.py @@ -1,78 +1,86 @@ +import os + from conan import ConanFile -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, chdir, rm, rmdir -from conans import AutoToolsBuildEnvironment -import functools +from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain, PkgConfigDeps +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.52.0" class libxftConan(ConanFile): name = "libxft" - description = 'X FreeType library' - topics = ("libxft", "x11", "xorg") + description = "X FreeType library" + license = "X11" url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.x.org/wiki/" - license = "X11" + topics = ("x11", "xorg") + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - generators = "pkg_config" - - @property - def _source_subfolder(self): - return "source_subfolder" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def export_sources(self): export_conandata_patches(self) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + basic_layout(self, src_folder="src") + def requirements(self): self.requires("xorg/system") - self.requires("freetype/2.13.0") - self.requires("fontconfig/2.14.2") + self.requires("freetype/2.13.0", transitive_headers=True) + self.requires("fontconfig/2.14.2", transitive_headers=True) def build_requirements(self): - self.build_requires("pkgconf/1.9.3") - self.build_requires("xorg-macros/1.19.3") - self.build_requires("libtool/2.4.7") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") + self.tool_requires("xorg-macros/1.19.3") + self.tool_requires("libtool/2.4.7") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd - if self.options.shared: - del self.options.fPIC + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_autotools(self): - args = ["--disable-dependency-tracking"] - if self.options.shared: - args.extend(["--disable-static", "--enable-shared"]) - else: - args.extend(["--disable-shared", "--enable-static"]) - autotools = AutoToolsBuildEnvironment(self) - autotools.configure(args=args, pkg_config_paths=self.build_folder) - return autotools + def generate(self): + tc = AutotoolsToolchain(self) + tc.configure_args.append("--disable-dependency-tracking") + tc.generate() + tc = PkgConfigDeps(self) + tc.generate() def build(self): apply_conandata_patches(self) - with chdir(self, self._source_subfolder): - autotools = self._configure_autotools() + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) - with chdir(self, self._source_subfolder): - autotools = self._configure_autotools() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, pattern="COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + with chdir(self, self.source_folder): + autotools = Autotools(self) autotools.install(args=["-j1"]) rm(self, "*.la", f"{self.package_folder}/lib", recursive=True) rmdir(self, f"{self.package_folder}/lib/pkgconfig") rmdir(self, f"{self.package_folder}/share") def package_info(self): - self.cpp_info.names['pkg_config'] = "Xft" self.cpp_info.set_property("pkg_config_name", "xft") self.cpp_info.libs = ["Xft"] diff --git a/recipes/libxft/all/test_package/CMakeLists.txt b/recipes/libxft/all/test_package/CMakeLists.txt index e55ad61e844f5c..71362aacc231af 100644 --- a/recipes/libxft/all/test_package/CMakeLists.txt +++ b/recipes/libxft/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(libxft REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/libxft/all/test_package/conanfile.py b/recipes/libxft/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/libxft/all/test_package/conanfile.py +++ b/recipes/libxft/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libxft/all/test_v1_package/CMakeLists.txt b/recipes/libxft/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libxft/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libxft/all/test_v1_package/conanfile.py b/recipes/libxft/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/libxft/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/libxft/config.yml b/recipes/libxft/config.yml index 6caf25620b5dc3..d3f36d4632aefc 100644 --- a/recipes/libxft/config.yml +++ b/recipes/libxft/config.yml @@ -1,4 +1,6 @@ versions: + "2.3.8": + folder: all "2.3.6": folder: all "2.3.4": From a69ce31763e8eb90654b740ed6c3f3f5c47d486d Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Mon, 21 Aug 2023 15:50:13 -0700 Subject: [PATCH 0353/1140] (#19284) fmt: make sure libdirs is empty when header_only=True --- recipes/fmt/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/fmt/all/conanfile.py b/recipes/fmt/all/conanfile.py index 862834c3580478..ab898ea9914110 100644 --- a/recipes/fmt/all/conanfile.py +++ b/recipes/fmt/all/conanfile.py @@ -118,9 +118,9 @@ def package_info(self): if self.options.header_only: self.cpp_info.components["_fmt"].defines.append("FMT_HEADER_ONLY=1") + self.cpp_info.components["_fmt"].libdirs = [] + self.cpp_info.components["_fmt"].bindirs = [] - self.cpp_info.libdirs = [] - self.cpp_info.bindirs = [] else: postfix = "d" if self.settings.build_type == "Debug" else "" libname = "fmt" + postfix From 663bf81b7c803d8a8d340158353ba59a5e4393e6 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Mon, 21 Aug 2023 16:50:33 -0700 Subject: [PATCH 0354/1140] (#19285) boost: make sure libdirs is empty when header_only=True --- recipes/boost/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/boost/all/conanfile.py b/recipes/boost/all/conanfile.py index d845fca4e54daf..d6c700ab42217f 100644 --- a/recipes/boost/all/conanfile.py +++ b/recipes/boost/all/conanfile.py @@ -1444,6 +1444,7 @@ def package_info(self): # - Use '_libboost' component to attach extra system_libs, ... self.cpp_info.components["headers"].libs = [] + self.cpp_info.components["headers"].libdirs = [] self.cpp_info.components["headers"].set_property("cmake_target_name", "Boost::headers") self.cpp_info.components["headers"].names["cmake_find_package"] = "headers" self.cpp_info.components["headers"].names["cmake_find_package_multi"] = "headers" From a43316eea703d954294cc6140bcaf24505ee7245 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 22 Aug 2023 10:29:59 +0200 Subject: [PATCH 0355/1140] (#19307) onnxruntime: bump deps --- recipes/onnxruntime/all/conandata.yml | 4 ++ recipes/onnxruntime/all/conanfile.py | 4 +- .../all/patches/1.14.1-0005-re2-compat.patch | 41 +++++++++++++++++++ 3 files changed, 47 insertions(+), 2 deletions(-) create mode 100644 recipes/onnxruntime/all/patches/1.14.1-0005-re2-compat.patch diff --git a/recipes/onnxruntime/all/conandata.yml b/recipes/onnxruntime/all/conandata.yml index 4a029ad509a2be..c1f4ac489cb97c 100644 --- a/recipes/onnxruntime/all/conandata.yml +++ b/recipes/onnxruntime/all/conandata.yml @@ -28,3 +28,7 @@ patches: - patch_file: "patches/1.14.1-0004-abseil-no-string-view.patch" patch_description: "allow to build with abseil built without c++17 support" patch_type: "portability" + - patch_file: "patches/1.14.1-0005-re2-compat.patch" + patch_description: "Ensures the forward compatibility with the newest versions of re2 library." + patch_type: "portability" + patch_source: "https://github.com/microsoft/onnxruntime/commit/126e7bf15fa4af8621814b82a3f7bd0d786f0239.patch" diff --git a/recipes/onnxruntime/all/conanfile.py b/recipes/onnxruntime/all/conanfile.py index f8951c6e253746..d9a55a421eb6f4 100644 --- a/recipes/onnxruntime/all/conanfile.py +++ b/recipes/onnxruntime/all/conanfile.py @@ -75,10 +75,10 @@ def requirements(self): self.requires("abseil/20230125.3") self.requires("protobuf/3.21.9") self.requires("date/3.0.1") - self.requires("re2/20230301") + self.requires("re2/20230801") self.requires(f"onnx/{self._onnx_version}") self.requires("flatbuffers/1.12.0") - self.requires("boost/1.82.0", headers=True, libs=False, run=False) # for mp11, header only, no need for libraries to link/run + self.requires("boost/1.83.0", headers=True, libs=False, run=False) # for mp11, header only, no need for libraries to link/run self.requires("safeint/3.0.28") self.requires("nlohmann_json/3.11.2") self.requires("eigen/3.4.0") diff --git a/recipes/onnxruntime/all/patches/1.14.1-0005-re2-compat.patch b/recipes/onnxruntime/all/patches/1.14.1-0005-re2-compat.patch new file mode 100644 index 00000000000000..c8e0cc9d9a48eb --- /dev/null +++ b/recipes/onnxruntime/all/patches/1.14.1-0005-re2-compat.patch @@ -0,0 +1,41 @@ +From a3a443c80431c390cbf8855e9c7b2a95d413cd54 Mon Sep 17 00:00:00 2001 +From: Yuriy Chernyshov +Date: Thu, 8 Jun 2023 20:26:26 +0200 +Subject: [PATCH] Support re2 == 2023-06-02 (#16257) + +### Description + +google/re2 [was +switched](https://github.com/google/re2/commit/49d776b9d29d79b6e2876d5f091d2207d8123dfa) +to absl::string_view in version 2023-06-02. + +As `absl::string_view` is a drop-in replacement for `std::string_view` +it does not have `as_string()` method. +This PR ensures the forward compatibility with the newest versions of +re2 library. +--- + onnxruntime/contrib_ops/cpu/tokenizer.cc | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/onnxruntime/contrib_ops/cpu/tokenizer.cc b/onnxruntime/contrib_ops/cpu/tokenizer.cc +index 45998b6d8310..1787fb9b3c4a 100644 +--- a/onnxruntime/contrib_ops/cpu/tokenizer.cc ++++ b/onnxruntime/contrib_ops/cpu/tokenizer.cc +@@ -242,7 +242,7 @@ Status Tokenizer::SeparatorExpressionTokenizer(OpKernelContext* ctx, + token_len, utf8_chars); + if (!valid) { + return Status(common::ONNXRUNTIME, common::INVALID_ARGUMENT, +- "Match contains invalid utf8 chars: " + submatch.as_string()); ++ "Match contains invalid utf8 chars: " + std::string{submatch}); + } + if (utf8_chars >= size_t(mincharnum_)) { + tokens.emplace_back(text.data() + start_pos, token_len); +@@ -384,7 +384,7 @@ Status Tokenizer::TokenExpression(OpKernelContext* ctx, + utf8_chars = 0; + if (!utf8_len(reinterpret_cast(submatch.data()), token_len, utf8_chars)) { + return Status(common::ONNXRUNTIME, common::INVALID_ARGUMENT, +- "Match contains invalid utf8 chars: " + submatch.as_string()); ++ "Match contains invalid utf8 chars: " + std::string{submatch}); + } + if (utf8_chars >= size_t(mincharnum_)) { + row.push_back(submatch); From 370c77465cdfe3d4424dd0cef126c45aaabb21cc Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 22 Aug 2023 12:08:49 +0300 Subject: [PATCH 0356/1140] (#18832) opentdf-client: migrate to Conan v2 * opentdf-client: migrate to Conan v2 * opentdf-client: restore VirtualRunEnv in test_package * opentdf-client: resolve conflicts and remove old versions * opentdf-client fix config.yml * opentdf fixes for Conan 2.0 * opentdf client: remove test_v1_package * opentdf-client: fix patches for install location --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/opentdf-client/all/CMakeLists.txt | 9 - .../all/conan_cmake_project_include.cmake | 11 ++ recipes/opentdf-client/all/conandata.yml | 48 +++--- recipes/opentdf-client/all/conanfile.py | 154 +++++++++++------- .../all/patches/1.1.6-0001-cmake-fixes.patch | 51 ++++++ .../all/patches/1.3.10-0001-cmake-fixes.patch | 51 ++++++ .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 22 ++- recipes/opentdf-client/config.yml | 18 -- 9 files changed, 246 insertions(+), 127 deletions(-) delete mode 100644 recipes/opentdf-client/all/CMakeLists.txt create mode 100644 recipes/opentdf-client/all/conan_cmake_project_include.cmake create mode 100644 recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch create mode 100644 recipes/opentdf-client/all/patches/1.3.10-0001-cmake-fixes.patch diff --git a/recipes/opentdf-client/all/CMakeLists.txt b/recipes/opentdf-client/all/CMakeLists.txt deleted file mode 100644 index 93dc9e86f93f9e..00000000000000 --- a/recipes/opentdf-client/all/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(opentdf-client) - -set(CMAKE_CXX_STANDARD 17) - -include(${CMAKE_SOURCE_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/opentdf-client/all/conan_cmake_project_include.cmake b/recipes/opentdf-client/all/conan_cmake_project_include.cmake new file mode 100644 index 00000000000000..795904b844ae40 --- /dev/null +++ b/recipes/opentdf-client/all/conan_cmake_project_include.cmake @@ -0,0 +1,11 @@ +find_package(Boost REQUIRED) +find_package(OpenSSL REQUIRED) +find_package(Microsoft.GSL REQUIRED) +find_package(nlohmann_json REQUIRED) +find_package(libxml2 REQUIRED) +find_package(jwt-cpp REQUIRED) +find_package(ZLIB REQUIRED) +if(opentdf_VERSION VERSION_GREATER_EQUAL "1.4.0") + find_package(magic_enum REQUIRED) +endif() +link_libraries(Boost::boost OpenSSL::SSL Microsoft.GSL::GSL nlohmann_json::nlohmann_json LibXml2::LibXml2 jwt-cpp::jwt-cpp $ ZLIB::ZLIB) diff --git a/recipes/opentdf-client/all/conandata.yml b/recipes/opentdf-client/all/conandata.yml index 382304e4f3de03..ead069b25a72d5 100644 --- a/recipes/opentdf-client/all/conandata.yml +++ b/recipes/opentdf-client/all/conandata.yml @@ -8,36 +8,30 @@ sources: "1.3.10": url: "https://github.com/opentdf/client-cpp/archive/1.3.10.tar.gz" sha256: "539bd5e64bceb86f63b3f7db75de470d5ea1d52ae6436a6a2d6789f7d0710dd4" - "1.3.9": - url: "https://github.com/opentdf/client-cpp/archive/1.3.9.tar.gz" - sha256: "8fdd88d90afe865ca86261c26abd1ca5e9895261490252199b7f9d4910ca0b49" - "1.3.8": - url: "https://github.com/opentdf/client-cpp/archive/1.3.8.tar.gz" - sha256: "0d73bd17f6d211c04136239e1db630e1ab320a6e41bd5c18533c44381519842c" - "1.3.6": - url: "https://github.com/opentdf/client-cpp/archive/1.3.6.tar.gz" - sha256: "e0d4cf1d0b1824d903a2b0ec1da528acb42623e32f3ca36aa28b2e950c3cc7a0" - "1.3.4": - url: "https://github.com/opentdf/client-cpp/archive/1.3.4.tar.gz" - sha256: "4b9836bff368249b709fc40e67c3a8664fed85a5d8247475ca1f741486210409" - "1.3.3": - url: "https://github.com/opentdf/client-cpp/archive/1.3.3.tar.gz" - sha256: "7949e662dc55a425771e5ecf2d96e25295d1e2394e805608aed72d1131896948" - "1.3.2": - url: "https://github.com/opentdf/client-cpp/archive/1.3.2.tar.gz" - sha256: "d9a38d3aa6114159c90e0c254c78ddda921e2d520851e4def57f3cd26c564b16" "1.2.0": url: "https://github.com/opentdf/client-cpp/archive/1.2.0.tar.gz" sha256: "15828038809ed291ff7881206a675abc5162e1175c8b515363b9c584aebb08f7" "1.1.6": url: "https://github.com/opentdf/client-cpp/archive/1.1.6.tar.gz" sha256: "83992c37c9a58ae2152660a4ffbf1784fe63d7a9e7b8466d10ca1074697b3d3a" - "1.1.5": - url: "https://github.com/opentdf/client-cpp/archive/1.1.5.tar.gz" - sha256: "8fd5b22b36b19cd58a18f63cbffe3d538263ef3aecde4802059951c4eb5ce044" - "1.1.3": - url: "https://github.com/opentdf/client-cpp/archive/1.1.3.tar.gz" - sha256: "67855999010f9c1496e170ad885f73b854f91eb1539e3c20d74b162295d5c732" - "1.1.2": - url: "https://github.com/opentdf/client-cpp/archive/1.1.2.tar.gz" - sha256: "4e41a18ef9d47aa9f964beffa78fdd4290a5f50336c6e4dc3c9bf2dd4b075d10" +patches: + "1.1.6": + - patch_file: "patches/1.1.6-0001-cmake-fixes.patch" + patch_description: "CMake build fixes for Conan 2.0-compatible recipe" + patch_type: "conan" + "1.2.0": + - patch_file: "patches/1.1.6-0001-cmake-fixes.patch" + patch_description: "CMake build fixes for Conan 2.0-compatible recipe" + patch_type: "conan" + "1.3.10": + - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" + patch_description: "CMake build fixes for Conan 2.0-compatible recipe" + patch_type: "conan" + "1.4.0": + - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" + patch_description: "CMake build fixes for Conan 2.0-compatible recipe" + patch_type: "conan" + "1.5.0": + - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" + patch_description: "CMake build fixes for Conan 2.0-compatible recipe" + patch_type: "conan" diff --git a/recipes/opentdf-client/all/conanfile.py b/recipes/opentdf-client/all/conanfile.py index 1c4773399329ba..e22c9867361c73 100644 --- a/recipes/opentdf-client/all/conanfile.py +++ b/recipes/opentdf-client/all/conanfile.py @@ -1,35 +1,38 @@ -from conans import CMake +import os + from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import get, copy, patch from conan.tools.build import check_min_cppstd -from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, export_conandata_patches, replace_in_file, get, copy from conan.tools.microsoft import is_msvc_static_runtime -import functools -import os +from conan.tools.scm import Version -required_conan_version = ">=1.51.3" +required_conan_version = ">=1.53.0" class OpenTDFConan(ConanFile): name = "opentdf-client" - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://www.virtru.com" - topics = ("opentdf", "opentdf-client", "tdf", "virtru") description = "openTDF core c++ client library for creating and accessing TDF protected data" license = "BSD-3-Clause-Clear" - generators = "cmake", "cmake_find_package" - settings = "os", "arch", "compiler", "build_type" - options = {"fPIC": [True, False]} - default_options = {"fPIC": True} + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.virtru.com" + topics = ("opentdf", "tdf", "virtru") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + copy(self, "conan_cmake_project_include.cmake", self.recipe_folder, os.path.join(self.export_sources_folder, "src")) + export_conandata_patches(self) @property def _minimum_cpp_standard(self): @@ -45,25 +48,16 @@ def _minimum_compilers_version(self): "apple-clang": "12.0.0", } - def export_sources(self): - self.copy("CMakeLists.txt") - for data in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(data["patch_file"]) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC - def validate(self): - # check minimum cpp standard supported by compiler - if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) - # check minimum version of compiler - min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) - if not min_version: - self.output.warn(f'{self.name} recipe lacks information about the {self.settings.compiler} compiler support.') - else: - if Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration(f'{self.name} requires {self.settings.compiler} {self.settings.compiler.version} but found {min_version}') - # Disallow MT and MTd - if is_msvc_static_runtime(self): - raise ConanInvalidConfiguration(f'{self.name} can not be built with MT or MTd at this time') + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): # Uses openssl 3.x for 1.5.0 and newer @@ -77,55 +71,95 @@ def requirements(self): self.requires("ms-gsl/2.1.0") self.requires("nlohmann_json/3.11.1") self.requires("jwt-cpp/0.4.0") + self.requires("zlib/1.2.13") # Use newer boost+libxml2 after 1.3.6 if Version(self.version) <= "1.3.6": self.requires("boost/1.79.0") self.requires("libxml2/2.9.14") else: - self.requires("boost/1.81.0") - self.requires("libxml2/2.10.3") + self.requires("boost/1.82.0") + self.requires("libxml2/2.11.4") - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._minimum_cpp_standard) + # check minimum version of compiler + min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) + if not min_version: + self.output.warning( + f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support." + ) + else: + if Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} requires {self.settings.compiler} {self.settings.compiler.version} " + f"but found {min_version}" + ) + # Disallow MT and MTd + if is_msvc_static_runtime(self): + raise ConanInvalidConfiguration(f"{self.name} can not be built with MT or MTd at this time") + + if self.options.shared and self.settings.os == "Windows": + raise ConanInvalidConfiguration(f"{self.name} does not currently support shared library on Windows") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _patch_sources(self): - for data in self.conan_data.get("patches", {}).get(self.version, []): - patch(self, **data) + def generate(self): + tc = CMakeToolchain(self) + if not self.settings.get_safe("compiler.cppstd"): + tc.variables["CMAKE_CXX_STANDARD"] = 17 + tc.cache_variables["CMAKE_PROJECT_opentdf_INCLUDE"] = os.path.join(self.source_folder, "conan_cmake_project_include.cmake") + tc.generate() + tc = CMakeDeps(self) + tc.generate() - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure(build_folder=self._build_subfolder) - return cmake + def _patch_sources(self): + apply_conandata_patches(self) def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - cmake = self._configure_cmake() + cmake = CMake(self) cmake.install() - copy(self, "*", dst=os.path.join(self.package_folder, "lib"), src=os.path.join(os.path.join(self._source_subfolder,"tdf-lib-cpp"), "lib"), keep_path=False) - copy(self, "*", dst=os.path.join(self.package_folder, "include"), src=os.path.join(os.path.join(self._source_subfolder,"tdf-lib-cpp"), "include"), keep_path=False) - copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self._source_subfolder, ignore_case=True, keep_path=False) + copy(self, "*", + dst=os.path.join(self.package_folder, "lib"), + src=os.path.join(os.path.join(self.source_folder, "tdf-lib-cpp"), "lib"), + keep_path=False) + copy(self, "*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(os.path.join(self.source_folder, "tdf-lib-cpp"), "include"), + keep_path=False) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder, + ignore_case=True, + keep_path=False) - # TODO - this only advertises the static lib, add dynamic lib also def package_info(self): self.cpp_info.set_property("cmake_file_name", "opentdf-client") self.cpp_info.set_property("cmake_target_name", "opentdf-client::opentdf-client") self.cpp_info.set_property("pkg_config_name", "opentdf-client") - self.cpp_info.components["libopentdf"].libs = ["opentdf_static"] + self.cpp_info.components["libopentdf"].libs = ["opentdf_static"] if not self.options.shared else ["opentdf"] self.cpp_info.components["libopentdf"].set_property("cmake_target_name", "copentdf-client::opentdf-client") self.cpp_info.components["libopentdf"].names["cmake_find_package"] = "opentdf-client" self.cpp_info.components["libopentdf"].names["cmake_find_package_multi"] = "opentdf-client" - self.cpp_info.components["libopentdf"].names["pkg_config"] = "opentdf-client" - self.cpp_info.components["libopentdf"].requires = ["openssl::openssl", "boost::boost", "ms-gsl::ms-gsl", "libxml2::libxml2", "jwt-cpp::jwt-cpp", "nlohmann_json::nlohmann_json"] + self.cpp_info.components["libopentdf"].requires = [ + "openssl::openssl", + "boost::boost", + "ms-gsl::ms-gsl", + "libxml2::libxml2", + "jwt-cpp::jwt-cpp", + "nlohmann_json::nlohmann_json", + "zlib::zlib" + ] + if Version(self.version) >= "1.4.0": + self.cpp_info.components["libopentdf"].requires.append("magic_enum::magic_enum") if Version(self.version) < "1.1.0": self.cpp_info.components["libopentdf"].requires.append("libarchive::libarchive") if Version(self.version) >= "1.4.0": diff --git a/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch b/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch new file mode 100644 index 00000000000000..7b784e35e922b3 --- /dev/null +++ b/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch @@ -0,0 +1,51 @@ +diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt +index f1ef646..2414ffc 100644 +--- a/src/lib/CMakeLists.txt ++++ b/src/lib/CMakeLists.txt +@@ -99,7 +99,9 @@ set(TDF_COMBINED_LIB_FULL_PATH ${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME}) + message(STATUS "Combined full path: ${TDF_COMBINED_LIB_FULL_PATH}") + + #TODO: Also need to handle iOS and Android(arm64). +-if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") ++if(TRUE) ++ message(STATUS "Skipping generation of combined static library") ++elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") + + FOREACH (LDIR ${CONAN_LIB_DIRS}) + set(V_COMBINED_LIB_DIRS ${V_COMBINED_LIB_DIRS} -L${LDIR}) +@@ -154,8 +156,6 @@ elseif (${CMAKE_SYSTEM_NAME} MATCHES "Windows") + lib -out:${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME} ${TDF_LIB_DIR}/${TDF_STATIC_LIB_FILENAME} ${V_COMBINED_LIB_DIRS} ${V_COMBINED_LIB_NAMES} + ) + ) +-else() +- message(STATUS "${CMAKE_SYSTEM_NAME} - unknown system FIXME........") + endif() + + # generate the shared library from the library sources +@@ -186,16 +186,19 @@ install(DIRECTORY DESTINATION ${TDF_LIB_INSTALL_LOCATION}) + # move the headers(to include) and tdf(to lib) directory under tdf-lib-cpp + install(DIRECTORY ${PROJECT_SOURCE_DIR}/include/ + DESTINATION ${TDF_LIB_INSTALL_LOCATION}/include) +- +-install(FILES ${TDF_STATIC_LIB_FULL_PATH} +- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + +-install(FILES ${TDF_COMBINED_LIB_FULL_PATH} +- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) ++if(NOT BUILD_SHARED_LIBS) ++ install(FILES $ ++ DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) ++endif() ++ ++# Skip combined static library for Conan Center Index package ++# install(FILES ${TDF_COMBINED_LIB_FULL_PATH} ++# DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + + if(${CMAKE_SYSTEM_NAME} MATCHES "Windows") + message(STATUS "Skipping shared lib on windows") +-else() +- install(FILES ${TDF_SHARED_LIB_FULL_PATH} ++elseif(BUILD_SHARED_LIBS) ++ install(FILES $ + DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + endif() diff --git a/recipes/opentdf-client/all/patches/1.3.10-0001-cmake-fixes.patch b/recipes/opentdf-client/all/patches/1.3.10-0001-cmake-fixes.patch new file mode 100644 index 00000000000000..9901f248faf037 --- /dev/null +++ b/recipes/opentdf-client/all/patches/1.3.10-0001-cmake-fixes.patch @@ -0,0 +1,51 @@ +diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt +index d7e1dc1..aeb3b2c 100644 +--- a/src/lib/CMakeLists.txt ++++ b/src/lib/CMakeLists.txt +@@ -99,7 +99,9 @@ set(TDF_COMBINED_LIB_FULL_PATH ${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME}) + message(STATUS "Combined full path: ${TDF_COMBINED_LIB_FULL_PATH}") + + #TODO: Also need to handle iOS and Android(arm64). +-if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") ++if(TRUE) ++ message(STATUS "Skipping generation of combined static library") ++elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") + + FOREACH (LDIR ${CONAN_LIB_DIRS}) + set(V_COMBINED_LIB_DIRS ${V_COMBINED_LIB_DIRS} -L${LDIR}) +@@ -155,8 +157,6 @@ elseif (${CMAKE_SYSTEM_NAME} MATCHES "Windows") + lib -out:${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME} ${TDF_LIB_DIR}/${TDF_STATIC_LIB_FILENAME} ${V_COMBINED_LIB_DIRS} ${V_COMBINED_LIB_NAMES} + ) + ) +-else() +- message(STATUS "${CMAKE_SYSTEM_NAME} - unknown system FIXME........") + endif() + + # generate the shared library from the library sources +@@ -187,16 +187,19 @@ install(DIRECTORY DESTINATION ${TDF_LIB_INSTALL_LOCATION}) + # move the headers(to include) and tdf(to lib) directory under tdf-lib-cpp + install(DIRECTORY ${PROJECT_SOURCE_DIR}/include/ + DESTINATION ${TDF_LIB_INSTALL_LOCATION}/include) +- +-install(FILES ${TDF_STATIC_LIB_FULL_PATH} +- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + +-install(FILES ${TDF_COMBINED_LIB_FULL_PATH} +- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) ++if(NOT BUILD_SHARED_LIBS) ++ install(FILES $ ++ DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) ++endif() ++ ++# Skip combined static library for Conan Center Index package ++# install(FILES ${TDF_COMBINED_LIB_FULL_PATH} ++# DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + + if(${CMAKE_SYSTEM_NAME} MATCHES "Windows") + message(STATUS "Skipping shared lib on windows") +-else() +- install(FILES ${TDF_SHARED_LIB_FULL_PATH} ++elseif(BUILD_SHARED_LIBS) ++ install(FILES $ + DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) + endif() diff --git a/recipes/opentdf-client/all/test_package/CMakeLists.txt b/recipes/opentdf-client/all/test_package/CMakeLists.txt index 90a74a2912fcb2..d73e39aaa8604c 100644 --- a/recipes/opentdf-client/all/test_package/CMakeLists.txt +++ b/recipes/opentdf-client/all/test_package/CMakeLists.txt @@ -1,12 +1,9 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) set(CMAKE_CXX_STANDARD 17) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(opentdf-client CONFIG REQUIRED) +find_package(opentdf-client REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} opentdf-client::opentdf-client) diff --git a/recipes/opentdf-client/all/test_package/conanfile.py b/recipes/opentdf-client/all/test_package/conanfile.py index cffa32351d9695..ef5d7042163ecc 100644 --- a/recipes/opentdf-client/all/test_package/conanfile.py +++ b/recipes/opentdf-client/all/test_package/conanfile.py @@ -1,11 +1,19 @@ -from conans import CMake from conan import ConanFile -from conan.tools.build import cross_building +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/opentdf-client/config.yml b/recipes/opentdf-client/config.yml index 109b67265732eb..ab5feb490bdb88 100644 --- a/recipes/opentdf-client/config.yml +++ b/recipes/opentdf-client/config.yml @@ -5,25 +5,7 @@ versions: folder: all "1.3.10": folder: all - "1.3.9": - folder: all - "1.3.8": - folder: all - "1.3.6": - folder: all - "1.3.4": - folder: all - "1.3.3": - folder: all - "1.3.2": - folder: all "1.2.0": folder: all "1.1.6": folder: all - "1.1.5": - folder: all - "1.1.3": - folder: all - "1.1.2": - folder: all From e5c85578a8420ce861e3e15b1ca5cdd270970185 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Tue, 22 Aug 2023 12:03:38 +0200 Subject: [PATCH 0357/1140] (#18588) [dlib] Port to Conan 2.x * dlib - port to Conan 2.x Signed-off-by: Uilian Ries * fix scm import Signed-off-by: Uilian Ries * fix file import Signed-off-by: Uilian Ries * fix layout Signed-off-by: Uilian Ries * fix copy license Signed-off-by: Uilian Ries * Update recipes/dlib/all/conanfile.py * Update recipes/dlib/all/conanfile.py * Update recipes/dlib/all/conanfile.py * fix windows build Signed-off-by: Uilian Ries * add nsl as system library Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries --- recipes/dlib/all/CMakeLists.txt | 8 - recipes/dlib/all/conanfile.py | 143 +++++++++--------- recipes/dlib/all/test_package/CMakeLists.txt | 11 +- recipes/dlib/all/test_package/conanfile.py | 19 ++- .../dlib/all/test_v1_package/CMakeLists.txt | 8 + recipes/dlib/all/test_v1_package/conanfile.py | 15 ++ 6 files changed, 109 insertions(+), 95 deletions(-) delete mode 100644 recipes/dlib/all/CMakeLists.txt create mode 100644 recipes/dlib/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/dlib/all/test_v1_package/conanfile.py diff --git a/recipes/dlib/all/CMakeLists.txt b/recipes/dlib/all/CMakeLists.txt deleted file mode 100644 index 1c22f049379454..00000000000000 --- a/recipes/dlib/all/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -# Include the dlib subdirectory to skip a check -add_subdirectory(source_subfolder/dlib) diff --git a/recipes/dlib/all/conanfile.py b/recipes/dlib/all/conanfile.py index b6ccf5c0b9123d..fc668dbc311da2 100644 --- a/recipes/dlib/all/conanfile.py +++ b/recipes/dlib/all/conanfile.py @@ -1,13 +1,14 @@ from conan import ConanFile -from conan.errors import ConanInvalidConfiguration -from conan.tools.files import get, rmdir +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import get, replace_in_file, copy, rmdir, collect_libs, rm +from conan.tools.build import check_min_cppstd from conan.tools.microsoft import is_msvc from conan.tools.scm import Version -from conans import CMake, tools -import functools +from conan.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.45.0" + +required_conan_version = ">=1.53.0" class DlibConan(ConanFile): @@ -17,7 +18,7 @@ class DlibConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "http://dlib.net" license = "BSL-1.0" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -46,34 +47,26 @@ class DlibConan(ConanFile): "with_openblas": True, } - exports_sources = "CMakeLists.txt" - generators = "cmake", "cmake_find_package" - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - @property def _has_with_webp_option(self): return Version(self.version) >= "19.24" def config_options(self): if self.settings.os == "Windows": - del self.options.fPIC + self.options.rm_safe("fPIC") if self.settings.arch not in ["x86", "x86_64"]: - del self.options.with_sse2 - del self.options.with_sse4 - del self.options.with_avx + self.options.rm_safe("with_sse2") + self.options.rm_safe("with_sse4") + self.options.rm_safe("with_avx") if not self._has_with_webp_option: - del self.options.with_webp + self.options.rm_safe("with_webp") def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_gif: @@ -90,91 +83,91 @@ def requirements(self): self.requires("openblas/0.3.20") def validate(self): + if self.settings.get_safe("compiler.cppstd"): + check_min_cppstd(self, "11") if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration("dlib can not be built as a shared library with Visual Studio") - if self.settings.os == "Macos" and self.settings.arch == "armv8": - raise ConanInvalidConfiguration("dlib doesn't support macOS M1") + raise ConanInvalidConfiguration(f"{self.ref} does not support shared on Windows. See https://github.com/davisking/dlib/issues/1483.") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def _patch_sources(self): - dlib_cmakelists = os.path.join(self._source_subfolder, "dlib", "CMakeLists.txt") + dlib_cmakelists = os.path.join(self.source_folder, "dlib", "CMakeLists.txt") # robust giflib injection - tools.replace_in_file(dlib_cmakelists, "${GIF_LIBRARY}", "GIF::GIF") + replace_in_file(self, dlib_cmakelists, "${GIF_LIBRARY}", "GIF::GIF") # robust libjpeg injection for cmake_file in [ dlib_cmakelists, - os.path.join(self._source_subfolder, "dlib", "cmake_utils", "find_libjpeg.cmake"), - os.path.join(self._source_subfolder, "dlib", "cmake_utils", "test_for_libjpeg", "CMakeLists.txt"), + os.path.join(self.source_folder, "dlib", "cmake_utils", "find_libjpeg.cmake"), + os.path.join(self.source_folder, "dlib", "cmake_utils", "test_for_libjpeg", "CMakeLists.txt"), ]: - tools.replace_in_file(cmake_file, "${JPEG_LIBRARY}", "JPEG::JPEG") + replace_in_file(self, cmake_file, "${JPEG_LIBRARY}", "JPEG::JPEG") # robust libpng injection for cmake_file in [ dlib_cmakelists, - os.path.join(self._source_subfolder, "dlib", "cmake_utils", "find_libpng.cmake"), - os.path.join(self._source_subfolder, "dlib", "cmake_utils", "test_for_libpng", "CMakeLists.txt"), + os.path.join(self.source_folder, "dlib", "cmake_utils", "find_libpng.cmake"), + os.path.join(self.source_folder, "dlib", "cmake_utils", "test_for_libpng", "CMakeLists.txt"), ]: - tools.replace_in_file(cmake_file, "${PNG_LIBRARIES}", "PNG::PNG") + replace_in_file(self, cmake_file, "${PNG_LIBRARIES}", "PNG::PNG") # robust sqlite3 injection - tools.replace_in_file(dlib_cmakelists, "find_library(sqlite sqlite3)", "find_package(SQLite3 REQUIRED)") - tools.replace_in_file(dlib_cmakelists, "find_path(sqlite_path sqlite3.h)", "") - tools.replace_in_file(dlib_cmakelists, "if (sqlite AND sqlite_path)", "if(1)") - tools.replace_in_file(dlib_cmakelists, "${sqlite}", "SQLite::SQLite3") + if self.options.with_sqlite3: + replace_in_file(self, dlib_cmakelists, "find_library(sqlite sqlite3)", "find_package(SQLite3 REQUIRED)") + replace_in_file(self, dlib_cmakelists, "find_path(sqlite_path sqlite3.h)", "") + replace_in_file(self, dlib_cmakelists, "if (sqlite AND sqlite_path)", "if(1)") + replace_in_file(self, dlib_cmakelists, "${sqlite}", "SQLite::SQLite3") # robust libwebp injection if self._has_with_webp_option: - tools.replace_in_file(dlib_cmakelists, "include(cmake_utils/find_libwebp.cmake)", "find_package(WebP REQUIRED)") - tools.replace_in_file(dlib_cmakelists, "if (WEBP_FOUND)", "if(1)") - tools.replace_in_file(dlib_cmakelists, "${WEBP_LIBRARY}", "WebP::webp") + replace_in_file(self, dlib_cmakelists, "include(cmake_utils/find_libwebp.cmake)", "find_package(WebP REQUIRED)") + replace_in_file(self, dlib_cmakelists, "if (WEBP_FOUND)", "if(1)") + replace_in_file(self, dlib_cmakelists, "${WEBP_LIBRARY}", "WebP::webp") + if self.options.with_png: + replace_in_file(self, dlib_cmakelists, "include(cmake_utils/find_libpng.cmake)", "find_package(PNG REQUIRED)") + if self.options.with_jpeg: + replace_in_file(self, dlib_cmakelists, "include(cmake_utils/find_libjpeg.cmake)", "find_package(JPEG REQUIRED)") - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) + def generate(self): + tc = CMakeToolchain(self) # With in-project builds dlib is always built as a static library, # we want to be able to build it as a shared library too - cmake.definitions["DLIB_IN_PROJECT_BUILD"] = False - - cmake.definitions["DLIB_ISO_CPP_ONLY"] = False - cmake.definitions["DLIB_NO_GUI_SUPPORT"] = True + tc.variables["DLIB_IN_PROJECT_BUILD"] = False + tc.variables["DLIB_ISO_CPP_ONLY"] = False + tc.variables["DLIB_NO_GUI_SUPPORT"] = True # Configure external dependencies - cmake.definitions["DLIB_JPEG_SUPPORT"] = self.options.with_jpeg + tc.variables["DLIB_JPEG_SUPPORT"] = self.options.with_jpeg if self._has_with_webp_option: - cmake.definitions["DLIB_WEBP_SUPPORT"] = self.options.with_webp - cmake.definitions["DLIB_LINK_WITH_SQLITE3"] = self.options.with_sqlite3 - cmake.definitions["DLIB_USE_BLAS"] = True # FIXME: all the logic behind is not sufficiently under control - cmake.definitions["DLIB_USE_LAPACK"] = True # FIXME: all the logic behind is not sufficiently under control - cmake.definitions["DLIB_USE_CUDA"] = False # TODO: add with_cuda option? - cmake.definitions["DLIB_PNG_SUPPORT"] = self.options.with_png - cmake.definitions["DLIB_GIF_SUPPORT"] = self.options.with_gif - cmake.definitions["DLIB_USE_MKL_FFT"] = False + tc.variables["DLIB_WEBP_SUPPORT"] = self.options.with_webp + tc.variables["DLIB_LINK_WITH_SQLITE3"] = self.options.with_sqlite3 + tc.variables["DLIB_USE_BLAS"] = True # FIXME: all the logic behind is not sufficiently under control + tc.variables["DLIB_USE_LAPACK"] = True # FIXME: all the logic behind is not sufficiently under control + tc.variables["DLIB_USE_CUDA"] = False # TODO: add with_cuda option? + tc.variables["DLIB_PNG_SUPPORT"] = self.options.with_png + tc.variables["DLIB_GIF_SUPPORT"] = self.options.with_gif + tc.variables["DLIB_USE_MKL_FFT"] = False # Configure SIMD options if possible if self.settings.arch in ["x86", "x86_64"]: if self.options.with_sse2 != "auto": - cmake.definitions["USE_SSE2_INSTRUCTIONS"] = self.options.with_sse2 + tc.variables["USE_SSE2_INSTRUCTIONS"] = self.options.with_sse2 if self.options.with_sse4 != "auto": - cmake.definitions["USE_SSE4_INSTRUCTIONS"] = self.options.with_sse4 + tc.variables["USE_SSE4_INSTRUCTIONS"] = self.options.with_sse4 if self.options.with_avx != "auto": - cmake.definitions["USE_AVX_INSTRUCTIONS"] = self.options.with_avx - - cmake.configure(build_folder=self._build_subfolder) - return cmake + tc.variables["USE_AVX_INSTRUCTIONS"] = self.options.with_avx + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, "dlib")) cmake.build() def package(self): - cmake = self._configure_cmake() + cmake = CMake(self) cmake.install() - - self.copy("LICENSE.txt", "licenses", os.path.join(self._source_subfolder, "dlib"), keep_path=False) - - # Remove configuration files + copy(self, "LICENSE.txt", src=os.path.join(self.source_folder, "dlib"), dst=os.path.join(self.package_folder, "licenses"), keep_path=False) for dir_to_remove in [ os.path.join("lib", "cmake"), os.path.join("lib", "pkgconfig"), @@ -182,15 +175,15 @@ def package(self): os.path.join("include", "dlib", "external", "pybind11", "tools") ]: rmdir(self, os.path.join(self.package_folder, dir_to_remove)) + rm(self, "*.txt", os.path.join(self.package_folder, "include", "dlib")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "dlib") self.cpp_info.set_property("cmake_target_name", "dlib::dlib") self.cpp_info.set_property("pkg_config_name", "dlib-1") - self.cpp_info.libs = tools.collect_libs(self) + # INFO: Unix systems use dlib as library name, but on Windows it includes settings, e.g dlib19.24.0_release_64bit_msvc1933.lib + self.cpp_info.libs = collect_libs(self) if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["pthread"] + self.cpp_info.system_libs = ["pthread", "nsl"] elif self.settings.os == "Windows": self.cpp_info.system_libs = ["ws2_32", "winmm", "comctl32", "gdi32", "imm32"] - - self.cpp_info.names["pkg_config"] = "dlib-1" diff --git a/recipes/dlib/all/test_package/CMakeLists.txt b/recipes/dlib/all/test_package/CMakeLists.txt index 50caaa372ec830..9ce5dccc129836 100644 --- a/recipes/dlib/all/test_package/CMakeLists.txt +++ b/recipes/dlib/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) find_package(dlib REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} dlib::dlib) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) +target_link_libraries(${PROJECT_NAME} PRIVATE dlib::dlib) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/dlib/all/test_package/conanfile.py b/recipes/dlib/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/dlib/all/test_package/conanfile.py +++ b/recipes/dlib/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/dlib/all/test_v1_package/CMakeLists.txt b/recipes/dlib/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..be00a8c7f57c71 --- /dev/null +++ b/recipes/dlib/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/dlib/all/test_v1_package/conanfile.py b/recipes/dlib/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..e0660e0801b965 --- /dev/null +++ b/recipes/dlib/all/test_v1_package/conanfile.py @@ -0,0 +1,15 @@ +import os +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type", + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "test_package"), run_environment=True) From b43e1349398d546db9687ce2d257f72dc474d09a Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 22 Aug 2023 19:27:28 +0900 Subject: [PATCH 0358/1140] (#18595) xnnpack: add version cci.20230715, add package_type * xnnpack: add version cci.20230715 * drop support for gcc < 11 and clang < 8 * update cpuinfo * use cpuinfo/cci.20220228 for older versions --- recipes/xnnpack/all/conandata.yml | 3 +++ recipes/xnnpack/all/conanfile.py | 31 +++++++++++++++++++------------ recipes/xnnpack/config.yml | 2 ++ 3 files changed, 24 insertions(+), 12 deletions(-) diff --git a/recipes/xnnpack/all/conandata.yml b/recipes/xnnpack/all/conandata.yml index 271fcb3d93eebc..97d441c786f9fc 100644 --- a/recipes/xnnpack/all/conandata.yml +++ b/recipes/xnnpack/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "cci.20230715": + url: "https://github.com/google/XNNPACK/archive/645035286fe31d47eeb07900450f4f6540b75c2c.tar.gz" + sha256: "4c91153dfe4648dc3b325db0b4d6719d6e16f7ce30940b4ceb65abd033e5245e" "cci.20220801": url: "https://github.com/google/XNNPACK/archive/8e3d3359f9bec608e09fac1f7054a2a14b1bd73c.tar.gz" sha256: "c82327543249bd333034bbaa0300ed1fc9c7060fa73673a285042e3f042540e0" diff --git a/recipes/xnnpack/all/conanfile.py b/recipes/xnnpack/all/conanfile.py index 7263f61d28bb8a..5d80f5f3cd1674 100644 --- a/recipes/xnnpack/all/conanfile.py +++ b/recipes/xnnpack/all/conanfile.py @@ -15,11 +15,11 @@ class XnnpackConan(ConanFile): "neural network inference operators for ARM, WebAssembly, " \ "and x86 platforms." license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/google/XNNPACK" topics = ("neural-network", "inference", "multithreading", "inference-optimization", "matrix-multiplication", "simd") - homepage = "https://github.com/google/XNNPACK" - url = "https://github.com/conan-io/conan-center-index" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -46,7 +46,6 @@ def config_options(self): def configure(self): if self.options.shared: self.options.rm_safe("fPIC") - # for plain C projects only self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") @@ -54,9 +53,12 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("cpuinfo/cci.20220228") + if self.version in ["cci.20220801", "cci.20220621", "cci.20211210"]: + self.requires("cpuinfo/cci.20220228") + else: + self.requires("cpuinfo/cci.20230118") self.requires("fp16/cci.20210320") - # https://github.com/google/XNNPACK/blob/ed5f9c0562e016a08b274a4579de5ef500fec134/include/xnnpack.h#L15 + # https://github.com/google/XNNPACK/blob/ed5f9c0562e016a08b274a4579de5ef500fec134/include/xnnpack.h#L15 self.requires("pthreadpool/cci.20210218", transitive_headers=True) self.requires("fxdiv/cci.20200417") @@ -64,13 +66,18 @@ def validate(self): check_min_vs(self, 192) compiler = self.info.settings.compiler compiler_version = Version(compiler.version) - if (compiler == "gcc" and compiler_version < "6") or \ - (compiler == "clang" and compiler_version < "5"): - raise ConanInvalidConfiguration(f"{self.ref} doesn't support {compiler} {compiler.version}") + if self.version < "cci.20230715": + if (compiler == "gcc" and compiler_version < "6") or \ + (compiler == "clang" and compiler_version < "5"): + raise ConanInvalidConfiguration(f"{self.ref} doesn't support {compiler} {compiler.version}") + else: + # since cci.20230715, xnnpack requires avx512 header file + if (compiler == "gcc" and compiler_version < "11") or \ + (compiler == "clang" and compiler_version < "8"): + raise ConanInvalidConfiguration(f"{self.ref} doesn't support {compiler} {compiler.version}") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) @@ -100,7 +107,7 @@ def generate(self): # The CMake scripts don't use targets prefixed with `namespace::` # so we can coerce CMakeDeps to define the exact target names that # are expected. This works in tandem with the file - # `CMAKE_PROJECT_XNNPACK_INCLUDE` which ensure an early call to + # `CMAKE_PROJECT_XNNPACK_INCLUDE` which ensure an early call to # the relevant `find_package` deps.set_property("cpuinfo", "cmake_target_name", "cpuinfo") deps.set_property("cpuinfo", "cmake_target_aliases", ["clog"] ) diff --git a/recipes/xnnpack/config.yml b/recipes/xnnpack/config.yml index d1b55a81c6c28b..a1c159e3728ee6 100644 --- a/recipes/xnnpack/config.yml +++ b/recipes/xnnpack/config.yml @@ -1,4 +1,6 @@ versions: + "cci.20230715": + folder: all "cci.20220801": folder: all "cci.20220621": From 98e398a3bb6c1b8b1c10f38cbbc0f6f0e544d4b7 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 22 Aug 2023 20:06:49 +0900 Subject: [PATCH 0359/1140] (#18622) wavelet_buffer: add version 0.7.1 * wavelet_buffer: add version 0.7.1 * update libs for 0.7.1 * rm cmake files * update libjpeg-turbo * use streamvbyte, fpzip cci's recipes --- recipes/wavelet_buffer/all/conandata.yml | 18 +++-- recipes/wavelet_buffer/all/conanfile.py | 14 +++- ...tch => 0.4.0-0001-cmake-no-openblas.patch} | 0 ...ch => 0.4.0-0002-cmake-find-jpeblib.patch} | 0 .../all/patches/0.7.1-0001-fix-packages.patch | 24 +++++++ .../patches/0.7.1-0002-use-cci-packages.patch | 66 +++++++++++++++++++ recipes/wavelet_buffer/config.yml | 2 + 7 files changed, 117 insertions(+), 7 deletions(-) rename recipes/wavelet_buffer/all/patches/{0001-0.4.0-cmake-no-openblas.patch => 0.4.0-0001-cmake-no-openblas.patch} (100%) rename recipes/wavelet_buffer/all/patches/{0002-0.4.0-cmake-find-jpeblib.patch => 0.4.0-0002-cmake-find-jpeblib.patch} (100%) create mode 100644 recipes/wavelet_buffer/all/patches/0.7.1-0001-fix-packages.patch create mode 100644 recipes/wavelet_buffer/all/patches/0.7.1-0002-use-cci-packages.patch diff --git a/recipes/wavelet_buffer/all/conandata.yml b/recipes/wavelet_buffer/all/conandata.yml index fbf3768205fccf..16606180f5c324 100644 --- a/recipes/wavelet_buffer/all/conandata.yml +++ b/recipes/wavelet_buffer/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.7.1": + url: "https://github.com/panda-official/WaveletBuffer/archive/refs/tags/v0.7.1.tar.gz" + sha256: "34931da9a8f3c36a37e7e72c801f5ae139006e3c84013511e6baaae3f8d3da3c" "0.5.0": url: "https://github.com/panda-official/WaveletBuffer/archive/refs/tags/v0.5.0.tar.gz" sha256: "2b1fa552f9a6e032dfd9f59bd05c049bf0cac46aced7cd42f49ff0d020cfdb50" @@ -6,19 +9,26 @@ sources: url: "https://github.com/panda-official/WaveletBuffer/archive/refs/tags/v0.4.0.tar.gz" sha256: "0a30080a6d1e9e7f8947ae0c3395d3c86888900c7ae09730f8dd0ed5138daab2" patches: + "0.7.1": + - patch_file: "patches/0.7.1-0001-fix-packages.patch" + patch_description: "don't find catch2, use jpeg instead of libjpeg-turbo" + patch_type: "conan" + - patch_file: "patches/0.7.1-0002-use-cci-packages.patch" + patch_description: "use cci's packages" + patch_type: "conan" "0.5.0": - - patch_file: "patches/0001-0.4.0-cmake-no-openblas.patch" + - patch_file: "patches/0.4.0-0001-cmake-no-openblas.patch" patch_description: "Fix CMakeLists: OpenBLAS is not a dependency" patch_type: "conan" patch_source: "https://github.com/panda-official/WaveletBuffer/pull/49" - - patch_file: "patches/0002-0.4.0-cmake-find-jpeblib.patch" + - patch_file: "patches/0.4.0-0002-cmake-find-jpeblib.patch" patch_description: "Fix CMakeLists: link to jpeg lib only" patch_type: "conan" "0.4.0": - - patch_file: "patches/0001-0.4.0-cmake-no-openblas.patch" + - patch_file: "patches/0.4.0-0001-cmake-no-openblas.patch" patch_description: "Fix CMakeLists: OpenBLAS is not a dependency" patch_type: "conan" patch_source: "https://github.com/panda-official/WaveletBuffer/pull/49" - - patch_file: "patches/0002-0.4.0-cmake-find-jpeblib.patch" + - patch_file: "patches/0.4.0-0002-cmake-find-jpeblib.patch" patch_description: "Fix CMakeLists: link to jpeg lib only" patch_type: "conan" diff --git a/recipes/wavelet_buffer/all/conanfile.py b/recipes/wavelet_buffer/all/conanfile.py index 8e72fbe22217ef..f5ce671013fd5a 100644 --- a/recipes/wavelet_buffer/all/conanfile.py +++ b/recipes/wavelet_buffer/all/conanfile.py @@ -60,12 +60,15 @@ def layout(self): def requirements(self): self.requires("blaze/3.8", transitive_headers=True) - self.requires("cimg/3.0.2") + self.requires("cimg/3.2.5") if self.options.jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") else: self.requires("libjpeg/9e") # FIXME: unvendor SfCompressor which is currently downloaded at build time :s + if Version(self.version) >= "0.6.0": + self.requires("streamvbyte/1.0.0") + self.requires("fpzip/1.3.0") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -105,12 +108,17 @@ def package(self): cmake = CMake(self) cmake.install() rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "wavelet_buffer") self.cpp_info.set_property("cmake_target_name", "wavelet_buffer::wavelet_buffer") - self.cpp_info.libs = ["wavelet_buffer", "sf_compressor"] self.cpp_info.requires = ["blaze::blaze", "cimg::cimg"] + if Version(self.version) >= "0.6.0": + self.cpp_info.libs = ["wavelet_buffer"] + self.cpp_info.requires.extend(["streamvbyte::streamvbyte", "fpzip::fpzip"]) + else: + self.cpp_info.libs = ["wavelet_buffer", "sf_compressor"] if self.options.jpeg == "libjpeg-turbo": self.cpp_info.requires.append("libjpeg-turbo::jpeg") else: diff --git a/recipes/wavelet_buffer/all/patches/0001-0.4.0-cmake-no-openblas.patch b/recipes/wavelet_buffer/all/patches/0.4.0-0001-cmake-no-openblas.patch similarity index 100% rename from recipes/wavelet_buffer/all/patches/0001-0.4.0-cmake-no-openblas.patch rename to recipes/wavelet_buffer/all/patches/0.4.0-0001-cmake-no-openblas.patch diff --git a/recipes/wavelet_buffer/all/patches/0002-0.4.0-cmake-find-jpeblib.patch b/recipes/wavelet_buffer/all/patches/0.4.0-0002-cmake-find-jpeblib.patch similarity index 100% rename from recipes/wavelet_buffer/all/patches/0002-0.4.0-cmake-find-jpeblib.patch rename to recipes/wavelet_buffer/all/patches/0.4.0-0002-cmake-find-jpeblib.patch diff --git a/recipes/wavelet_buffer/all/patches/0.7.1-0001-fix-packages.patch b/recipes/wavelet_buffer/all/patches/0.7.1-0001-fix-packages.patch new file mode 100644 index 00000000000000..6621e790da38b8 --- /dev/null +++ b/recipes/wavelet_buffer/all/patches/0.7.1-0001-fix-packages.patch @@ -0,0 +1,24 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e2a6681..5ef9cbb 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -59,9 +59,8 @@ else() + endif() + + find_package(blaze REQUIRED) +-find_package(libjpeg-turbo REQUIRED) ++find_package(JPEG REQUIRED) + find_package(cimg REQUIRED) +-find_package(Catch2 REQUIRED) + + # Create wb target + set(WB_TARGET_NAME ${PROJECT_NAME}) +@@ -146,7 +145,7 @@ target_include_directories( + # Link dependencies + target_link_libraries(${WB_TARGET_NAME} PRIVATE streamvbyte) + target_link_libraries(${WB_TARGET_NAME} PRIVATE fpzip) +-target_link_libraries(${WB_TARGET_NAME} PRIVATE libjpeg-turbo::libjpeg-turbo) ++target_link_libraries(${WB_TARGET_NAME} PRIVATE JPEG::JPEG) + target_link_libraries(${WB_TARGET_NAME} PRIVATE cimg::cimg) + + target_link_libraries(${WB_TARGET_NAME} PUBLIC blaze::blaze) diff --git a/recipes/wavelet_buffer/all/patches/0.7.1-0002-use-cci-packages.patch b/recipes/wavelet_buffer/all/patches/0.7.1-0002-use-cci-packages.patch new file mode 100644 index 00000000000000..260b4ac4bbddc3 --- /dev/null +++ b/recipes/wavelet_buffer/all/patches/0.7.1-0002-use-cci-packages.patch @@ -0,0 +1,66 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 5ef9cbb..fed641b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -80,39 +80,12 @@ add_library( + sources/internal/matrix_compressor.cc + ) + +-include(FetchContent) +- +-fetchcontent_declare( +- streamvbyte +- URL https://github.com/lemire/streamvbyte/archive/refs/tags/v1.0.0.zip +- URL_HASH MD5=3d1a01cfb704947fa6498944082aeed1 +-) +- +-fetchcontent_declare( +- fpzip +- URL https://github.com/LLNL/fpzip/releases/download/1.3.0/fpzip-1.3.0.zip +- URL_HASH MD5=933ed7628de406a24fe2de61c8c3356c +-) +- +-fetchcontent_makeavailable(streamvbyte) +- +-fetchcontent_getproperties(fpzip) +- +-if(NOT fpzip_POPULATED) +- fetchcontent_populate(fpzip) +- # Make subproject to use 'BUILD_SHARED_LIBS=ON' setting. +- set(BUILD_SHARED_LIBS OFF CACHE INTERNAL "Build SHARED libraries") +- add_subdirectory(${fpzip_SOURCE_DIR} ${fpzip_BINARY_DIR}) +-endif() ++find_package(streamvbyte REQUIRED CONFIG) ++find_package(fpzip REQUIRED CONFIG) + + # Add alias + add_library(${WB_TARGET_NAME}::${WB_TARGET_NAME} ALIAS ${WB_TARGET_NAME}) + +-# Set fPIC +-set_target_properties(${WB_TARGET_NAME} PROPERTIES POSITION_INDEPENDENT_CODE ON) +-set_target_properties(streamvbyte PROPERTIES POSITION_INDEPENDENT_CODE ON) +-set_target_properties(fpzip PROPERTIES POSITION_INDEPENDENT_CODE ON) +- + # Turn off parallelization in blaze + target_compile_definitions( + ${WB_TARGET_NAME} +@@ -143,8 +116,8 @@ target_include_directories( + ) + + # Link dependencies +-target_link_libraries(${WB_TARGET_NAME} PRIVATE streamvbyte) +-target_link_libraries(${WB_TARGET_NAME} PRIVATE fpzip) ++target_link_libraries(${WB_TARGET_NAME} PRIVATE streamvbyte::streamvbyte) ++target_link_libraries(${WB_TARGET_NAME} PRIVATE fpzip::fpzip) + target_link_libraries(${WB_TARGET_NAME} PRIVATE JPEG::JPEG) + target_link_libraries(${WB_TARGET_NAME} PRIVATE cimg::cimg) + +@@ -178,7 +151,7 @@ endif() + include(GNUInstallDirs) + + # Create package targets file +-install(TARGETS ${WB_TARGET_NAME} streamvbyte EXPORT ${WB_TARGET_NAME}-target) ++install(TARGETS ${WB_TARGET_NAME} EXPORT ${WB_TARGET_NAME}-target) + install( + EXPORT ${WB_TARGET_NAME}-target + FILE ${WB_TARGET_NAME}-targets.cmake diff --git a/recipes/wavelet_buffer/config.yml b/recipes/wavelet_buffer/config.yml index d13fcfd021b7b0..80a49141e8ea47 100644 --- a/recipes/wavelet_buffer/config.yml +++ b/recipes/wavelet_buffer/config.yml @@ -1,4 +1,6 @@ versions: + "0.7.1": + folder: all "0.5.0": folder: all "0.4.0": From 1da5f06fbb13aba9e551712d4cecc4fa255e3917 Mon Sep 17 00:00:00 2001 From: Andrei Malashkin Date: Tue, 22 Aug 2023 13:29:31 +0200 Subject: [PATCH 0360/1140] (#18990) implement newmat/11.0.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * implement newmat/11.0.1 * remove blank line in conandata * fix linter warnings * set src_folder to src * fix linter * remove cmake dir * add m as system lib * add license * cleanup * correct test package in order not to depend on zlib * mark shared lib on windows as invalid config * add forgotten import * Apply suggestions from code review Co-authored-by: Uilian Ries * fix review comments * extract license from htm document * reintroduce patch * don't use collect_libs * simplify test package * fix newlines * try to fix conan v1 test * change language to cpp * make cmake names in lowercase * disable macos builds * fix lib names for macos * add patch description * Apply suggestions from code review Co-authored-by: Uilian Ries * add missing import * remove v1 test package * revert of self.cpp_info.libs changes * remove test v1; cmake changes --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Uilian Ries --- recipes/newmat/all/CMakeLists.txt | 92 +++++++++++++++++++ recipes/newmat/all/conandata.yml | 9 ++ recipes/newmat/all/conanfile.py | 87 ++++++++++++++++++ .../all/patches/11.0.1/newmat6.cpp.patch | 12 +++ .../newmat/all/test_package/CMakeLists.txt | 7 ++ recipes/newmat/all/test_package/conanfile.py | 26 ++++++ .../newmat/all/test_package/test_package.cpp | 7 ++ recipes/newmat/config.yml | 3 + 8 files changed, 243 insertions(+) create mode 100644 recipes/newmat/all/CMakeLists.txt create mode 100644 recipes/newmat/all/conandata.yml create mode 100644 recipes/newmat/all/conanfile.py create mode 100644 recipes/newmat/all/patches/11.0.1/newmat6.cpp.patch create mode 100644 recipes/newmat/all/test_package/CMakeLists.txt create mode 100644 recipes/newmat/all/test_package/conanfile.py create mode 100644 recipes/newmat/all/test_package/test_package.cpp create mode 100644 recipes/newmat/config.yml diff --git a/recipes/newmat/all/CMakeLists.txt b/recipes/newmat/all/CMakeLists.txt new file mode 100644 index 00000000000000..768502b8f6a7f8 --- /dev/null +++ b/recipes/newmat/all/CMakeLists.txt @@ -0,0 +1,92 @@ +cmake_minimum_required(VERSION 3.0) + +project( + "newmat" + DESCRIPTION + "The package is intended for scientists and engineers who need to \ + manipulate a variety of types of matrices using standard matrix \ + operations. Emphasis is on the kind of operations needed in statistical \ + calculations such as least squares, linear equation solve and eigenvalues." + HOMEPAGE_URL "http://www.robertnz.net/nm11.htm" + LANGUAGES CXX) + +option(SETUP_C_SUBSCRIPTS "Activate SETUP_C_SUBSCRIPTS if you want to use traditional C style element access" OFF) +if (SETUP_C_SUBSCRIPTS) + add_compile_definitions(SETUP_C_SUBSCRIPTS) +endif() +message("Build with C style element access ${SETUP_C_SUBSCRIPTS}") + +# ------------- +# target +# ------------- +set(source_subfolder_ "src") +set(lib_name ${PROJECT_NAME}) +add_library(${lib_name}) + +target_sources( + ${lib_name} + PRIVATE + ${source_subfolder_}/bandmat.cpp + ${source_subfolder_}/jacobi.cpp + ${source_subfolder_}/newmat3.cpp + ${source_subfolder_}/newmat8.cpp + ${source_subfolder_}/nm_misc.cpp + ${source_subfolder_}/cholesky.cpp + ${source_subfolder_}/myexcept.cpp + ${source_subfolder_}/newmat4.cpp + ${source_subfolder_}/newmat9.cpp + ${source_subfolder_}/solution.cpp + ${source_subfolder_}/evalue.cpp + ${source_subfolder_}/newfft.cpp + ${source_subfolder_}/newmat5.cpp + ${source_subfolder_}/newmatex.cpp + ${source_subfolder_}/sort.cpp + ${source_subfolder_}/fft.cpp + ${source_subfolder_}/newmat1.cpp + ${source_subfolder_}/newmat6.cpp + ${source_subfolder_}/newmatnl.cpp + ${source_subfolder_}/submat.cpp + ${source_subfolder_}/hholder.cpp + ${source_subfolder_}/newmat2.cpp + ${source_subfolder_}/newmat7.cpp + ${source_subfolder_}/newmatrm.cpp + ${source_subfolder_}/svd.cpp +) + +set(include_dir ${PROJECT_SOURCE_DIR}/${source_subfolder_}) + +target_include_directories( + ${lib_name} PUBLIC $) +target_include_directories( + ${lib_name} INTERFACE $) + +# code has throwing desctructors, thus try to compile with c++98 +set_property(TARGET ${lib_name} PROPERTY CXX_STANDARD 98) + +# ------------- +# installation +# ------------- +include(GNUInstallDirs) +install( + FILES + ${include_dir}/controlw.h + ${include_dir}/include.h + ${include_dir}/myexcept.h + ${include_dir}/newmatap.h + ${include_dir}/newmat.h + ${include_dir}/newmatio.h + ${include_dir}/newmatnl.h + ${include_dir}/newmatrc.h + ${include_dir}/newmatrm.h + ${include_dir}/precisio.h + ${include_dir}/solution.h + DESTINATION + include/newmat +) +install( + TARGETS ${lib_name} + INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} +) diff --git a/recipes/newmat/all/conandata.yml b/recipes/newmat/all/conandata.yml new file mode 100644 index 00000000000000..e5211d2f682950 --- /dev/null +++ b/recipes/newmat/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "11.0.1": + url: "http://www.robertnz.net/ftp/newmat11.tar.gz" + sha256: "daf313a4db0db14dfcce236ad3cdc514d449e62ddd4f1b07cc31179b0787db6f" +patches: + "11.0.1": + - patch_file: "patches/11.0.1/newmat6.cpp.patch" + patch_type: portability + patch_description: "Fix comparison of pointer and int for new compilers" diff --git a/recipes/newmat/all/conanfile.py b/recipes/newmat/all/conanfile.py new file mode 100644 index 00000000000000..1e8f73c3d75fc7 --- /dev/null +++ b/recipes/newmat/all/conanfile.py @@ -0,0 +1,87 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rmdir, save, load +from conan.tools.microsoft import is_msvc +import os + +required_conan_version = ">=1.53.0" + + +class NewmatConan(ConanFile): + name = "newmat" + description = "Manipulate a variety of types of matrices using standard matrix operations." + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://newmat.net" + topics = ("matrix") + license = "LicenseRef-newmat" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_c_subscripts": [True, False] + } + default_options = { + "shared": False, + "fPIC": True, + "with_c_subscripts": False, + } + + def export_sources(self): + copy(self, "CMakeLists.txt", self.recipe_folder, self.export_sources_folder) + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if is_msvc(self) and self.options.shared: + raise ConanInvalidConfiguration(f"{self.ref} does not support dynamic library with msvc.") + + def source(self): + get(self, **self.conan_data["sources"][self.version], + destination=self.source_folder) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["SETUP_C_SUBSCRIPTS"] = self.options.with_c_subscripts + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) + cmake.build() + + def _extract_license(self): + header = load(self, os.path.join(self.source_folder, "nm11.htm")) + return header[header.find("I place no restrictions", 1) : header.find("report bugs to me.", 1) + 18] + + def package(self): + cmake = CMake(self) + cmake.install() + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), self._extract_license()) + rmdir(self, os.path.join(self.package_folder, "cmake")) + if self.settings.os == "Windows": + rmdir(self, os.path.join(self.package_folder, "bin")) + + def package_info(self): + self.cpp_info.libs = ["newmat"] + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] + + self.cpp_info.includedirs.append(os.path.join("include", "newmat")) + if self.options.with_c_subscripts: + self.cpp_info.defines = ["SETUP_C_SUBSCRIPTS"] + diff --git a/recipes/newmat/all/patches/11.0.1/newmat6.cpp.patch b/recipes/newmat/all/patches/11.0.1/newmat6.cpp.patch new file mode 100644 index 00000000000000..2cbfaaa6c4648f --- /dev/null +++ b/recipes/newmat/all/patches/11.0.1/newmat6.cpp.patch @@ -0,0 +1,12 @@ +@@ -1,11 +0,0 @@ +--- newmat6.cpp ++++ newmat6.cpp +@@ -428,7 +428,7 @@ + { + if (&gm == this) { REPORT tag_val = -1; return; } + REPORT +- if (indx > 0) { delete [] indx; indx = 0; } ++ if (indx != 0) { delete [] indx; indx = 0; } + ((CroutMatrix&)gm).get_aux(*this); + Eq(gm); + } diff --git a/recipes/newmat/all/test_package/CMakeLists.txt b/recipes/newmat/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..b7da1c805dfbd3 --- /dev/null +++ b/recipes/newmat/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +find_package(newmat REQUIRED) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE newmat::newmat) diff --git a/recipes/newmat/all/test_package/conanfile.py b/recipes/newmat/all/test_package/conanfile.py new file mode 100644 index 00000000000000..0a6bc68712d901 --- /dev/null +++ b/recipes/newmat/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/newmat/all/test_package/test_package.cpp b/recipes/newmat/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..bcd358b815b251 --- /dev/null +++ b/recipes/newmat/all/test_package/test_package.cpp @@ -0,0 +1,7 @@ +#include "newmatap.h" + +int main() +{ + Matrix A(2,3); + return 0; +} diff --git a/recipes/newmat/config.yml b/recipes/newmat/config.yml new file mode 100644 index 00000000000000..d7fc56a2cf1b3f --- /dev/null +++ b/recipes/newmat/config.yml @@ -0,0 +1,3 @@ +versions: + "11.0.1": + folder: all From de91d8e7acd9781a74df582938eb4b916d921de3 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Tue, 22 Aug 2023 14:08:13 +0200 Subject: [PATCH 0361/1140] (#19065) aws-c-compression: add version 0.2.17 * aws-c-compression: add version 0.2.17 * cleanup: remove test_v1_package folder * Revert "cleanup: remove test_v1_package folder" This reverts commit 2b5643590e31a46fc05e049b9c0154b9e6e6243a. --- recipes/aws-c-compression/all/conandata.yml | 3 +++ recipes/aws-c-compression/all/conanfile.py | 8 ++++++-- recipes/aws-c-compression/config.yml | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/recipes/aws-c-compression/all/conandata.yml b/recipes/aws-c-compression/all/conandata.yml index 1baf0be5b106a8..d936f5ef9af185 100644 --- a/recipes/aws-c-compression/all/conandata.yml +++ b/recipes/aws-c-compression/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.2.17": + url: "https://github.com/awslabs/aws-c-compression/archive/v0.2.17.tar.gz" + sha256: "703d1671e395ea26f8b0b70d678ed471421685a89e127f8aa125e2b2ecedb0e0" "0.2.15": url: "https://github.com/awslabs/aws-c-compression/archive/v0.2.15.tar.gz" sha256: "11d58a229e2961b2b36493155a981dea2c8a0bc0d113b0073deb8c3189cfa04e" diff --git a/recipes/aws-c-compression/all/conanfile.py b/recipes/aws-c-compression/all/conanfile.py index 828f55f6431895..2c6e25346108a2 100644 --- a/recipes/aws-c-compression/all/conanfile.py +++ b/recipes/aws-c-compression/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import copy, get, rmdir, save +from conan.tools.scm import Version import os import textwrap @@ -13,7 +14,7 @@ class AwsCCompression(ConanFile): topics = ("aws", "amazon", "cloud", "compression", "huffman", ) url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/awslabs/aws-c-compression" - license = "Apache-2.0", + license = "Apache-2.0" package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -39,7 +40,10 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + if Version(self.version) <= "0.2.15": + self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True, transitive_libs=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/aws-c-compression/config.yml b/recipes/aws-c-compression/config.yml index 5a381bb0e66743..aae181600c27e2 100644 --- a/recipes/aws-c-compression/config.yml +++ b/recipes/aws-c-compression/config.yml @@ -1,4 +1,6 @@ versions: + "0.2.17": + folder: all "0.2.15": folder: all "0.2.14": From 208f1807b5bf5598155df1360299c028967aec2e Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Tue, 22 Aug 2023 14:50:22 +0200 Subject: [PATCH 0362/1140] (#19032) openssl/1.x.x: Added socket to system_libs for Neutrino --- recipes/openssl/1.x.x/conanfile.py | 2 ++ recipes/openssl/3.x.x/conanfile.py | 2 ++ 2 files changed, 4 insertions(+) diff --git a/recipes/openssl/1.x.x/conanfile.py b/recipes/openssl/1.x.x/conanfile.py index d7807c3f39ee09..c6f1558ac1cf1c 100644 --- a/recipes/openssl/1.x.x/conanfile.py +++ b/recipes/openssl/1.x.x/conanfile.py @@ -905,6 +905,8 @@ def package_info(self): elif self.settings.os == "Neutrino": self.cpp_info.components["crypto"].system_libs.append("atomic") self.cpp_info.components["ssl"].system_libs.append("atomic") + self.cpp_info.components["crypto"].system_libs.append("socket") + self.cpp_info.components["ssl"].system_libs.append("socket") # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.names["cmake_find_package"] = "OpenSSL" diff --git a/recipes/openssl/3.x.x/conanfile.py b/recipes/openssl/3.x.x/conanfile.py index 59da5e3bc24344..f2c81b311e8fd9 100644 --- a/recipes/openssl/3.x.x/conanfile.py +++ b/recipes/openssl/3.x.x/conanfile.py @@ -657,6 +657,8 @@ def package_info(self): elif self.settings.os == "Neutrino": self.cpp_info.components["crypto"].system_libs.append("atomic") self.cpp_info.components["ssl"].system_libs.append("atomic") + self.cpp_info.components["crypto"].system_libs.append("socket") + self.cpp_info.components["ssl"].system_libs.append("socket") self.cpp_info.components["crypto"].set_property("cmake_target_name", "OpenSSL::Crypto") self.cpp_info.components["crypto"].set_property("pkg_config_name", "libcrypto") From a065baf819453997f577a29a5aaefe1e96615096 Mon Sep 17 00:00:00 2001 From: Marian Klymov Date: Tue, 22 Aug 2023 16:45:12 +0300 Subject: [PATCH 0363/1140] (#18298) itk: migrate to Conan v2 * itk: migrate to Conan v2 * Delete CMakeLists.txt * Remove hdf5 from test * bump libtiff to 4.5.1 * Add empty EOL to test_package.cpp * Replace CRLF with LF in test_package.cpp * itksys: link with dl --- recipes/itk/all/CMakeLists.txt | 22 - .../itk/all/conan_cmake_project_include.cmake | 8 + recipes/itk/all/conandata.yml | 6 +- recipes/itk/all/conanfile.py | 483 +++++++++--------- recipes/itk/all/test_package/CMakeLists.txt | 13 +- recipes/itk/all/test_package/conanfile.py | 19 +- recipes/itk/all/test_package/test_package.cpp | 14 +- .../itk/all/test_v1_package/CMakeLists.txt | 8 + recipes/itk/all/test_v1_package/conanfile.py | 18 + 9 files changed, 304 insertions(+), 287 deletions(-) delete mode 100644 recipes/itk/all/CMakeLists.txt create mode 100644 recipes/itk/all/conan_cmake_project_include.cmake create mode 100644 recipes/itk/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/itk/all/test_v1_package/conanfile.py diff --git a/recipes/itk/all/CMakeLists.txt b/recipes/itk/all/CMakeLists.txt deleted file mode 100644 index 7ae2d73951a0de..00000000000000 --- a/recipes/itk/all/CMakeLists.txt +++ /dev/null @@ -1,22 +0,0 @@ -cmake_minimum_required(VERSION 3.10.2) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -# conan created FindXXX.cmake modules that create IMPORTED targets -# that not have the GLOBAL option set. By requiring them here, -# these targets are visible in all the subprojects. -file(GLOB conan_modules "Find*.cmake") -message("modules: ${conan_modules}") -foreach(module ${conan_modules}) - get_filename_component(modname "${module}" NAME) - string(REGEX MATCH "^Find(.*).cmake$" modmatch "${modname}") - if(NOT modmatch) - message(FATAL_ERROR "Not a module?? ${module} (${modname})") - endif() - message(STATUS "requiring package ${CMAKE_MATCH_1}") - find_package("${CMAKE_MATCH_1}" REQUIRED) -endforeach() - -add_subdirectory(source_subfolder) diff --git a/recipes/itk/all/conan_cmake_project_include.cmake b/recipes/itk/all/conan_cmake_project_include.cmake new file mode 100644 index 00000000000000..1583596ab78787 --- /dev/null +++ b/recipes/itk/all/conan_cmake_project_include.cmake @@ -0,0 +1,8 @@ +find_package(double-conversion REQUIRED CONFIG) +find_package(Eigen3 REQUIRED CONFIG) +find_package(EXPAT REQUIRED MODULE) +find_package(JPEG REQUIRED CONFIG) +find_package(OpenJPEG REQUIRED CONFIG) +find_package(PNG REQUIRED) +find_package(TIFF REQUIRED) +find_package(ZLIB REQUIRED) diff --git a/recipes/itk/all/conandata.yml b/recipes/itk/all/conandata.yml index 3cb9b81826a595..9e7f86e6f5246c 100644 --- a/recipes/itk/all/conandata.yml +++ b/recipes/itk/all/conandata.yml @@ -8,7 +8,9 @@ sources: patches: "5.1.2": - patch_file: "patches/0001-find-conan-packages.patch" - base_path: "source_subfolder" + patch_description: "inject thirdparties from conan" + patch_type: "conan" "5.1.0": - patch_file: "patches/0001-find-conan-packages.patch" - base_path: "source_subfolder" + patch_description: "inject thirdparties from conan" + patch_type: "conan" diff --git a/recipes/itk/all/conanfile.py b/recipes/itk/all/conanfile.py index 3c833fb68b4469..432d4013dd2a62 100644 --- a/recipes/itk/all/conanfile.py +++ b/recipes/itk/all/conanfile.py @@ -1,20 +1,25 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rmdir, save +from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.scm import Version +from conan.errors import ConanInvalidConfiguration import glob import os import textwrap -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class ITKConan(ConanFile): name = "itk" - topics = ("itk", "scientific", "image", "processing") - homepage = "http://www.itk.org/" - url = "https://github.com/conan-io/conan-center-index" + description = "Open-source, cross-platform toolkit for N-dimensional scientific image processing, segmentation, and registration" license = "Apache-2.0" - description = "Insight Segmentation and Registration Toolkit" - + url = "https://github.com/conan-io/conan-center-index" + homepage = "http://www.itk.org/" + topics = ("medical-imaging", "scientific", "image", "processing") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -26,26 +31,23 @@ class ITKConan(ConanFile): } short_paths = True - generators = "cmake", "cmake_find_package" - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 11 @property - def _build_subfolder(self): - return "build_subfolder" - - # TODO: Some packages can be added as optional, but they are not in CCI: - # - mkl - # - vtk - # - opencv + def _compilers_minimum_version(self): + return { + "Visual Studio": "14", + "gcc": "4.8.1", + "clang": "3.3", + "apple-clang": "9", + } def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) + copy(self, "conan_cmake_project_include.cmake", self.recipe_folder, os.path.join(self.export_sources_folder, "src")) def config_options(self): if self.settings.os == "Windows": @@ -53,250 +55,222 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("dcmtk/3.6.6") - self.requires("double-conversion/3.2.0") + # TODO: Some packages can be added as optional, but they are not in CCI: + # - mkl + # - vtk + # - opencv + #todo: enable after fixing dcmtk compatibility with openssl on Windows + #self.requires("dcmtk/3.6.7") + self.requires("double-conversion/3.3.0") self.requires("eigen/3.4.0") - self.requires("expat/2.4.8") - self.requires("fftw/3.3.9") - self.requires("gdcm/3.0.9") - self.requires("hdf5/1.12.0") - self.requires("icu/71.1") # TODO: to remove? Seems to be a transitivie dependency through dcmtk - self.requires("libjpeg/9d") - self.requires("libpng/1.6.37") - self.requires("libtiff/4.3.0") - self.requires("openjpeg/2.4.0") - self.requires("onetbb/2020.3") - self.requires("zlib/1.2.12") - - @property - def _minimum_cpp_standard(self): - return 11 - - @property - def _minimum_compilers_version(self): - return { - "Visual Studio": "14", - "gcc": "4.8.1", - "clang": "3.3", - "apple-clang": "9", - } + self.requires("expat/2.5.0") + self.requires("fftw/3.3.10") + self.requires("gdcm/3.0.21") + self.requires("hdf5/1.14.1") + self.requires("libjpeg/9e") + self.requires("libpng/1.6.40") + self.requires("libtiff/4.5.1") + self.requires("openjpeg/2.5.0") + self.requires("onetbb/2021.9.0") + self.requires("zlib/1.2.13") def validate(self): - if self.options.shared and not self.options["hdf5"].shared: + if self.options.shared and not self.dependencies["hdf5"].options.shared: raise ConanInvalidConfiguration("When building a shared itk, hdf5 needs to be shared too (or not linked to by the consumer).\n" "This is because H5::DataSpace::ALL might get initialized twice, which will cause a H5::DataSpaceIException to be thrown).") - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) - min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) - if not min_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) - else: - if tools.Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration("{} requires C++{} support. The current compiler {} {} does not support it.".format( - self.name, self._minimum_cpp_standard, self.settings.compiler, self.settings.compiler.version)) - + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 190) + if not is_msvc(self): + 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): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - - self._cmake = CMake(self) - self._cmake.definitions["BUILD_EXAMPLES"] = False - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.definitions["BUILD_DOCUMENTATION"] = False - self._cmake.definitions["ITK_SKIP_PATH_LENGTH_CHECKS"] = True - - self._cmake.definitions["ITK_USE_SYSTEM_LIBRARIES"] = True - self._cmake.definitions["ITK_USE_SYSTEM_DCMTK"] = True - self._cmake.definitions["ITK_USE_SYSTEM_DOUBLECONVERSION"] = True - self._cmake.definitions["ITK_USE_SYSTEM_EIGEN"] = True - self._cmake.definitions["ITK_USE_SYSTEM_FFTW"] = True - self._cmake.definitions["ITK_USE_SYSTEM_GDCM"] = True - self._cmake.definitions["ITK_USE_SYSTEM_HDF5"] = True - self._cmake.definitions["ITK_USE_SYSTEM_ICU"] = True - self._cmake.definitions["ITK_USE_SYSTEM_JPEG"] = True - self._cmake.definitions["ITK_USE_SYSTEM_PNG"] = True - self._cmake.definitions["ITK_USE_SYSTEM_TIFF"] = True - self._cmake.definitions["ITK_USE_SYSTEM_ZLIB"] = True + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + #call find_package on top level + tc.cache_variables["CMAKE_PROJECT_ITK_INCLUDE"] = os.path.join(self.source_folder, "conan_cmake_project_include.cmake") + tc.variables["BUILD_EXAMPLES"] = False + tc.variables["BUILD_TESTING"] = False + tc.variables["BUILD_DOCUMENTATION"] = False + tc.variables["ITK_SKIP_PATH_LENGTH_CHECKS"] = True + + tc.variables["ITK_USE_SYSTEM_LIBRARIES"] = True + tc.variables["ITK_USE_SYSTEM_DCMTK"] = True + tc.variables["ITK_USE_SYSTEM_DOUBLECONVERSION"] = True + tc.variables["ITK_USE_SYSTEM_EIGEN"] = True + tc.variables["ITK_USE_SYSTEM_FFTW"] = True + tc.variables["ITK_USE_SYSTEM_GDCM"] = True + tc.variables["ITK_USE_SYSTEM_HDF5"] = True + tc.variables["ITK_USE_SYSTEM_ICU"] = True + tc.variables["ITK_USE_SYSTEM_JPEG"] = True + tc.variables["ITK_USE_SYSTEM_PNG"] = True + tc.variables["ITK_USE_SYSTEM_TIFF"] = True + tc.variables["ITK_USE_SYSTEM_ZLIB"] = True # FIXME: Missing Kwiml recipe - self._cmake.definitions["ITK_USE_SYSTEM_KWIML"] = False + tc.variables["ITK_USE_SYSTEM_KWIML"] = False # FIXME: Missing VXL recipe - self._cmake.definitions["ITK_USE_SYSTEM_VXL"] = False - self._cmake.definitions["GDCM_USE_SYSTEM_OPENJPEG"] = True - - self._cmake.definitions["ITK_BUILD_DEFAULT_MODULES"] = False - self._cmake.definitions["Module_ITKDeprecated"] = False - self._cmake.definitions["Module_ITKMINC"] = False - self._cmake.definitions["Module_ITKIOMINC"] = False - - self._cmake.definitions["Module_ITKVideoBridgeOpenCV"] = False - - self._cmake.definitions["Module_ITKDCMTK"] = True - self._cmake.definitions["Module_ITKIODCMTK"] = True - self._cmake.definitions["Module_ITKIOHDF5"] = True - self._cmake.definitions["Module_ITKIOTransformHDF5"] = False - self._cmake.definitions["Module_ITKAnisotropicSmoothing"] = True - self._cmake.definitions["Module_ITKAntiAlias"] = True - self._cmake.definitions["Module_ITKBiasCorrection"] = True - self._cmake.definitions["Module_ITKBinaryMathematicalMorphology"] = True - self._cmake.definitions["Module_ITKBioCell"] = True - self._cmake.definitions["Module_ITKClassifiers"] = True - self._cmake.definitions["Module_ITKColormap"] = True - self._cmake.definitions["Module_ITKConnectedComponents"] = True - self._cmake.definitions["Module_ITKConvolution"] = True - self._cmake.definitions["Module_ITKCurvatureFlow"] = True - self._cmake.definitions["Module_ITKDeconvolution"] = True - self._cmake.definitions["Module_ITKDeformableMesh"] = True - self._cmake.definitions["Module_ITKDenoising"] = True - self._cmake.definitions["Module_ITKDiffusionTensorImage"] = True - self._cmake.definitions["Module_ITKDisplacementField"] = True - self._cmake.definitions["Module_ITKDistanceMap"] = True - self._cmake.definitions["Module_ITKEigen"] = True - self._cmake.definitions["Module_ITKFEM"] = True - self._cmake.definitions["Module_ITKFEMRegistration"] = True - self._cmake.definitions["Module_ITKFFT"] = True - self._cmake.definitions["Module_ITKFastMarching"] = True - self._cmake.definitions["Module_ITKGIFTI"] = True - self._cmake.definitions["Module_ITKGPUAnisotropicSmoothing"] = True - self._cmake.definitions["Module_ITKGPUImageFilterBase"] = True - self._cmake.definitions["Module_ITKGPUPDEDeformableRegistration"] = True - self._cmake.definitions["Module_ITKGPURegistrationCommon"] = True - self._cmake.definitions["Module_ITKGPUSmoothing"] = True - self._cmake.definitions["Module_ITKGPUThresholding"] = True - self._cmake.definitions["Module_ITKIOCSV"] = True - self._cmake.definitions["Module_ITKIOGE"] = True - self._cmake.definitions["Module_ITKIOIPL"] = True - self._cmake.definitions["Module_ITKIOMesh"] = True - self._cmake.definitions["Module_ITKIOPhilipsREC"] = True - self._cmake.definitions["Module_ITKIORAW"] = True - self._cmake.definitions["Module_ITKIOSiemens"] = True - self._cmake.definitions["Module_ITKIOSpatialObjects"] = True - self._cmake.definitions["Module_ITKIOTransformBase"] = True - self._cmake.definitions["Module_ITKIOTransformInsightLegacy"] = True - self._cmake.definitions["Module_ITKIOTransformMatlab"] = True - self._cmake.definitions["Module_ITKIOXML"] = True - self._cmake.definitions["Module_ITKImageCompare"] = True - self._cmake.definitions["Module_ITKImageCompose"] = True - self._cmake.definitions["Module_ITKImageFeature"] = True - self._cmake.definitions["Module_ITKImageFusion"] = True - self._cmake.definitions["Module_ITKImageGradient"] = True - self._cmake.definitions["Module_ITKImageGrid"] = True - self._cmake.definitions["Module_ITKImageIntensity"] = True - self._cmake.definitions["Module_ITKImageLabel"] = True - self._cmake.definitions["Module_ITKImageSources"] = True - self._cmake.definitions["Module_ITKImageStatistics"] = True - self._cmake.definitions["Module_ITKIntegratedTest"] = True - self._cmake.definitions["Module_ITKKLMRegionGrowing"] = True - self._cmake.definitions["Module_ITKLabelMap"] = True - self._cmake.definitions["Module_ITKLabelVoting"] = True - self._cmake.definitions["Module_ITKLevelSets"] = True - self._cmake.definitions["Module_ITKLevelSetsv4"] = True - self._cmake.definitions["Module_ITKMarkovRandomFieldsClassifiers"] = True - self._cmake.definitions["Module_ITKMathematicalMorphology"] = True - self._cmake.definitions["Module_ITKMetricsv4"] = True - self._cmake.definitions["Module_ITKNarrowBand"] = True - self._cmake.definitions["Module_ITKNeuralNetworks"] = True - self._cmake.definitions["Module_ITKOptimizers"] = True - self._cmake.definitions["Module_ITKOptimizersv4"] = True - self._cmake.definitions["Module_ITKPDEDeformableRegistration"] = True - self._cmake.definitions["Module_ITKPath"] = True - self._cmake.definitions["Module_ITKPolynomials"] = True - self._cmake.definitions["Module_ITKQuadEdgeMeshFiltering"] = True - self._cmake.definitions["Module_ITKRegionGrowing"] = True - self._cmake.definitions["Module_ITKRegistrationCommon"] = True - self._cmake.definitions["Module_ITKRegistrationMethodsv4"] = True - self._cmake.definitions["Module_ITKReview"] = True - self._cmake.definitions["Module_ITKSignedDistanceFunction"] = True - self._cmake.definitions["Module_ITKSmoothing"] = True - self._cmake.definitions["Module_ITKSpatialFunction"] = True - self._cmake.definitions["Module_ITKTBB"] = True - self._cmake.definitions["Module_ITKThresholding"] = True - self._cmake.definitions["Module_ITKVideoCore"] = True - self._cmake.definitions["Module_ITKVideoFiltering"] = True - self._cmake.definitions["Module_ITKVideoIO"] = False - self._cmake.definitions["Module_ITKVoronoi"] = True - self._cmake.definitions["Module_ITKWatersheds"] = True - self._cmake.definitions["Module_ITKDICOMParser"] = True - - self._cmake.definitions["Module_ITKVTK"] = False - self._cmake.definitions["Module_ITKVtkGlue"] = False + tc.variables["ITK_USE_SYSTEM_VXL"] = False + tc.variables["GDCM_USE_SYSTEM_OPENJPEG"] = True + + tc.variables["ITK_BUILD_DEFAULT_MODULES"] = False + tc.variables["Module_ITKDeprecated"] = False + tc.variables["Module_ITKMINC"] = False + tc.variables["Module_ITKIOMINC"] = False + + tc.variables["Module_ITKVideoBridgeOpenCV"] = False + + #todo: enable after fixing dcmtk compatibility with openssl on Windows + tc.variables["Module_ITKDCMTK"] = False + tc.variables["Module_ITKIODCMTK"] = False + + tc.variables["Module_ITKIOHDF5"] = True + tc.variables["Module_ITKIOTransformHDF5"] = False + tc.variables["Module_ITKAnisotropicSmoothing"] = True + tc.variables["Module_ITKAntiAlias"] = True + tc.variables["Module_ITKBiasCorrection"] = True + tc.variables["Module_ITKBinaryMathematicalMorphology"] = True + tc.variables["Module_ITKBioCell"] = True + tc.variables["Module_ITKClassifiers"] = True + tc.variables["Module_ITKColormap"] = True + tc.variables["Module_ITKConnectedComponents"] = True + tc.variables["Module_ITKConvolution"] = True + tc.variables["Module_ITKCurvatureFlow"] = True + tc.variables["Module_ITKDeconvolution"] = True + tc.variables["Module_ITKDeformableMesh"] = True + tc.variables["Module_ITKDenoising"] = True + tc.variables["Module_ITKDiffusionTensorImage"] = True + tc.variables["Module_ITKDisplacementField"] = True + tc.variables["Module_ITKDistanceMap"] = True + tc.variables["Module_ITKEigen"] = True + tc.variables["Module_ITKFEM"] = True + tc.variables["Module_ITKFEMRegistration"] = True + tc.variables["Module_ITKFFT"] = True + tc.variables["Module_ITKFastMarching"] = True + tc.variables["Module_ITKGIFTI"] = True + tc.variables["Module_ITKGPUAnisotropicSmoothing"] = True + tc.variables["Module_ITKGPUImageFilterBase"] = True + tc.variables["Module_ITKGPUPDEDeformableRegistration"] = True + tc.variables["Module_ITKGPURegistrationCommon"] = True + tc.variables["Module_ITKGPUSmoothing"] = True + tc.variables["Module_ITKGPUThresholding"] = True + tc.variables["Module_ITKIOCSV"] = True + tc.variables["Module_ITKIOGE"] = True + tc.variables["Module_ITKIOIPL"] = True + tc.variables["Module_ITKIOMesh"] = True + tc.variables["Module_ITKIOPhilipsREC"] = True + tc.variables["Module_ITKIORAW"] = True + tc.variables["Module_ITKIOSiemens"] = True + tc.variables["Module_ITKIOSpatialObjects"] = True + tc.variables["Module_ITKIOTransformBase"] = True + tc.variables["Module_ITKIOTransformInsightLegacy"] = True + tc.variables["Module_ITKIOTransformMatlab"] = True + tc.variables["Module_ITKIOXML"] = True + tc.variables["Module_ITKImageCompare"] = True + tc.variables["Module_ITKImageCompose"] = True + tc.variables["Module_ITKImageFeature"] = True + tc.variables["Module_ITKImageFusion"] = True + tc.variables["Module_ITKImageGradient"] = True + tc.variables["Module_ITKImageGrid"] = True + tc.variables["Module_ITKImageIntensity"] = True + tc.variables["Module_ITKImageLabel"] = True + tc.variables["Module_ITKImageSources"] = True + tc.variables["Module_ITKImageStatistics"] = True + tc.variables["Module_ITKIntegratedTest"] = True + tc.variables["Module_ITKKLMRegionGrowing"] = True + tc.variables["Module_ITKLabelMap"] = True + tc.variables["Module_ITKLabelVoting"] = True + tc.variables["Module_ITKLevelSets"] = True + tc.variables["Module_ITKLevelSetsv4"] = True + tc.variables["Module_ITKMarkovRandomFieldsClassifiers"] = True + tc.variables["Module_ITKMathematicalMorphology"] = True + tc.variables["Module_ITKMetricsv4"] = True + tc.variables["Module_ITKNarrowBand"] = True + tc.variables["Module_ITKNeuralNetworks"] = True + tc.variables["Module_ITKOptimizers"] = True + tc.variables["Module_ITKOptimizersv4"] = True + tc.variables["Module_ITKPDEDeformableRegistration"] = True + tc.variables["Module_ITKPath"] = True + tc.variables["Module_ITKPolynomials"] = True + tc.variables["Module_ITKQuadEdgeMeshFiltering"] = True + tc.variables["Module_ITKRegionGrowing"] = True + tc.variables["Module_ITKRegistrationCommon"] = True + tc.variables["Module_ITKRegistrationMethodsv4"] = True + tc.variables["Module_ITKReview"] = True + tc.variables["Module_ITKSignedDistanceFunction"] = True + tc.variables["Module_ITKSmoothing"] = True + tc.variables["Module_ITKSpatialFunction"] = True + tc.variables["Module_ITKTBB"] = True + tc.variables["Module_ITKThresholding"] = True + tc.variables["Module_ITKVideoCore"] = True + tc.variables["Module_ITKVideoFiltering"] = True + tc.variables["Module_ITKVideoIO"] = False + tc.variables["Module_ITKVoronoi"] = True + tc.variables["Module_ITKWatersheds"] = True + tc.variables["Module_ITKDICOMParser"] = True + + tc.variables["Module_ITKVTK"] = False + tc.variables["Module_ITKVtkGlue"] = False # Disabled on Linux (link errors) - self._cmake.definitions["Module_ITKLevelSetsv4Visualization"] = False + tc.variables["Module_ITKLevelSetsv4Visualization"] = False # Disabled because Vxl vidl is not built anymore - self._cmake.definitions["Module_ITKVideoBridgeVXL"] = False + tc.variables["Module_ITKVideoBridgeVXL"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + tc.generate() + + tc = CMakeDeps(self) + tc.generate() + + def _patch_sources(self): + apply_conandata_patches(self) + #The CMake policy CMP0091 must be NEW, but is '' + replace_in_file(self, + os.path.join(self.source_folder, "Modules", "ThirdParty", "VNL", "src", "vxl", "config", "cmake", "config", "VXLIntrospectionConfig.cmake"), + "-DCMAKE_CXX_FLAGS:STRING=${CMAKE_CXX_FLAGS}", + "-DCMAKE_POLICY_DEFAULT_CMP0091=NEW -DCMAKE_CXX_FLAGS:STRING=${CMAKE_CXX_FLAGS}") def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() - def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() - cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, self._cmake_module_dir, "Modules")) - # Do not remove UseITK.cmake and *.h.in files - for cmake_file in glob.glob(os.path.join(self.package_folder, self._cmake_module_dir, "*.cmake")): - if os.path.basename(cmake_file) != "UseITK.cmake": - os.remove(cmake_file) - - self._create_cmake_module_alias_targets( - os.path.join(self.package_folder, self._module_file_rel_path), - {target:"ITK::{}".format(target) for target in self._itk_components.keys()}, - ) - - @staticmethod - def _create_cmake_module_alias_targets(module_file, targets): - content = "" - for alias, aliased in targets.items(): - content += textwrap.dedent("""\ - if(TARGET {aliased} AND NOT TARGET {alias}) - add_library({alias} INTERFACE IMPORTED) - set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) - endif() - """.format(alias=alias, aliased=aliased)) - tools.save(module_file, content) - @property - def _module_file_rel_path(self): - return os.path.join(self._cmake_module_dir, "conan-official-{}-targets.cmake".format(self.name)) + def _itk_subdir(self): + v = Version(self.version) + return f"ITK-{v.major}.{v.minor}" @property def _cmake_module_dir(self): return os.path.join("lib", "cmake", self._itk_subdir) @property - def _itk_subdir(self): - v = tools.Version(self.version) - return "ITK-{}.{}".format(v.major, v.minor) + def _module_file_rel_path(self): + return os.path.join(self._cmake_module_dir, f"conan-official-{self.name}-targets.cmake") @property def _itk_components(self): def libm(): return ["m"] if self.settings.os in ["Linux", "FreeBSD"] else [] + def libdl(): + return ["dl"] if self.settings.os in ["Linux", "FreeBSD"] else [] return { - "itksys": {}, + "itksys": {"system_libs": libdl()}, "itkvcl": {"system_libs": libm()}, "itkv3p_netlib": {"system_libs": libm()}, "itkvnl": {"requires": ["itkvcl"]}, @@ -386,7 +360,8 @@ def libm(): "ITKIOBMP": {"requires": ["ITKIOImageBase"]}, "ITKIOBioRad": {"requires": ["ITKIOImageBase"]}, "ITKIOCSV": {"requires": ["ITKIOImageBase"]}, - "ITKIODCMTK": {"requires": ["ITKIOImageBase", "dcmtk::dcmtk", "icu::icu"]}, + #todo: enable after fixing dcmtk compatibility with openssl on Windows + #"ITKIODCMTK": {"requires": ["ITKIOImageBase", "dcmtk::dcmtk"]}, "ITKIOGDCM": {"requires": ["ITKCommon", "ITKIOImageBase", "gdcm::gdcmDICT", "gdcm::gdcmMSFF"]}, "ITKIOIPL": {"requires": ["ITKIOImageBase"]}, "ITKIOGE": {"requires": ["ITKIOIPL", "ITKIOImageBase"]}, @@ -477,32 +452,58 @@ def libm(): "ITKVideoCore": {"requires": ["ITKCommon"]}, } + def _create_cmake_module_alias_targets(self): + targets = {target:f"ITK::{target}" for target in self._itk_components.keys()} + content = "" + for alias, aliased in targets.items(): + content += textwrap.dedent(f"""\ + if(TARGET {aliased} AND NOT TARGET {alias}) + add_library({alias} INTERFACE IMPORTED) + set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) + endif() + """) + save(self, os.path.join(self.package_folder, self._module_file_rel_path), content) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, self._cmake_module_dir, "Modules")) + # Do not remove UseITK.cmake and *.h.in files + for cmake_file in glob.glob(os.path.join(self.package_folder, self._cmake_module_dir, "*.cmake")): + if os.path.basename(cmake_file) != "UseITK.cmake": + os.remove(cmake_file) + self._create_cmake_module_alias_targets() + def package_info(self): self.cpp_info.set_property("cmake_file_name", "ITK") self.cpp_info.set_property("cmake_build_modules", [os.path.join(self._cmake_module_dir, "UseITK.cmake")]) - itk_version = tools.Version(self.version) - lib_suffix = "-{}.{}".format(itk_version.major, itk_version.minor) + itk_version = Version(self.version) + lib_suffix = f"-{itk_version.major}.{itk_version.minor}" for name, values in self._itk_components.items(): is_header_only = values.get("header_only", False) system_libs = values.get("system_libs", []) requires = values.get("requires", []) self.cpp_info.components[name].set_property("cmake_target_name", name) + self.cpp_info.components[name].set_property("cmake_target_aliases", [f"ITK::{name}"]) self.cpp_info.components[name].builddirs.append(self._cmake_module_dir) self.cpp_info.components[name].includedirs.append(os.path.join("include", self._itk_subdir)) if not is_header_only: - self.cpp_info.components[name].libs = ["{}{}".format(name, lib_suffix)] + self.cpp_info.components[name].libs = [f"{name}{lib_suffix}"] self.cpp_info.components[name].system_libs = system_libs self.cpp_info.components[name].requires = requires # TODO: to remove in conan v2 once cmake_find_package* generators removed - self.cpp_info.components[name].names["cmake_find_package"] = name - self.cpp_info.components[name].names["cmake_find_package_multi"] = name - self.cpp_info.components[name].build_modules.append(os.path.join(self._cmake_module_dir, "UseITK.cmake")) - self.cpp_info.components[name].build_modules["cmake_find_package"].append(self._module_file_rel_path) - self.cpp_info.components[name].build_modules["cmake_find_package_multi"].append(self._module_file_rel_path) + for generator in ["cmake_find_package", "cmake_find_package_multi"]: + self.cpp_info.components[name].names[generator] = name + self.cpp_info.components[name].build_modules[generator].append(self._module_file_rel_path) + self.cpp_info.components[name].build_modules[generator].append(os.path.join(self._cmake_module_dir, "UseITK.cmake")) # TODO: to remove in conan v2 once cmake_find_package* generators removed - self.cpp_info.names["cmake_find_package"] = "ITK" - self.cpp_info.names["cmake_find_package_multi"] = "ITK" + for generator in ["cmake_find_package", "cmake_find_package_multi"]: + self.cpp_info.names[generator] = "ITK" diff --git a/recipes/itk/all/test_package/CMakeLists.txt b/recipes/itk/all/test_package/CMakeLists.txt index f9c2acebbb0bbc..ad9e58069124d6 100644 --- a/recipes/itk/all/test_package/CMakeLists.txt +++ b/recipes/itk/all/test_package/CMakeLists.txt @@ -1,12 +1,11 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +project(test_package CXX) find_package(ITK REQUIRED CONFIG) -find_package(HDF5 COMPONENTS CXX) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ITKCommon hdf5::hdf5_cpp) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) +target_link_libraries(${PROJECT_NAME} PRIVATE ITKCommon) +#itksys is already linked through dependencies of ITKCommon but we also want to check name alias +target_link_libraries(${PROJECT_NAME} PRIVATE ITK::itksys) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/itk/all/test_package/conanfile.py b/recipes/itk/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/itk/all/test_package/conanfile.py +++ b/recipes/itk/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/itk/all/test_package/test_package.cpp b/recipes/itk/all/test_package/test_package.cpp index ef775457ccc9cb..56077cb584102e 100644 --- a/recipes/itk/all/test_package/test_package.cpp +++ b/recipes/itk/all/test_package/test_package.cpp @@ -1,8 +1,5 @@ #include "itkLightObject.h" -#include -#include - #include class Test : public itk::LightObject { @@ -12,12 +9,9 @@ class Test : public itk::LightObject { const char *GetNameOfClass() { return "Test"; } }; -int main(int, char **) try { - //Test::Pointer test = Test::New(); - //std::cout << test->GetNameOfClass() << std::endl; - return 0; -} catch(const H5::DataSpaceIException &e) { - std::cerr << "CAUGHT\n"; - e.printErrorStack(); +int main(int, char **) +{ + Test::Pointer test = Test::New(); + std::cout << test->GetNameOfClass() << std::endl; return 0; } diff --git a/recipes/itk/all/test_v1_package/CMakeLists.txt b/recipes/itk/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/itk/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/itk/all/test_v1_package/conanfile.py b/recipes/itk/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..5a05af3c2dfd2f --- /dev/null +++ b/recipes/itk/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake +from conan.tools.build import cross_building +import os + + +class TestPackageV1Conan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 9be5d7923cee7aa97900a8376302ec49b261a726 Mon Sep 17 00:00:00 2001 From: Esteban Dugueperoux <43169544+EstebanDugueperoux2@users.noreply.github.com> Date: Tue, 22 Aug 2023 16:09:49 +0200 Subject: [PATCH 0364/1140] (#18389) Add pcl PointCloudLibrary package * Add pcl PointCloudLibrary package Inspired from https://github.com/conan-io/conan-center-index/pull/1891 * pcl: misc recipe tweaks * Update recipes/pcl/all/conanfile.py Co-authored-by: Martin Valgur * pcl: Further fixes to Conan targets use in CMake * pcl: Fix buggy OpenNI detection if libusb missing * pcl: Fix PCL CMake config breaking OpenGL detection * pcl: Fix _add_component() bugs * pcl: add TODOs for missing Conan packages * pcl: set_property("cmake_find_mode", "both") * pcl: more accurate modelling of PCL components * pcl: tidy description * Enable opengl event if with_vtk is false - Enable opengl event if with_vtk is false as done in PCL CMakeLists.txt * Revert "Enable opengl event if with_vtk is false" This reverts commit c4be26d44c9f2fd6ed4bd323714ff6bf2e67ed0d. * Enable opengl only if with_vtk==True * test is_msvc() method * test is_msvc_static_runtime * pcl: make components optional, add full dependency info * pcl: fixes to the component system * pcl: set OpenGL_GL_PREFERENCE=GLVND * pcl: fix _extra_libs handling * pcl: fix CUDA support * pcl: add all VTK system package variants * pcl: add missing transitive_headers=True based on installed header includes * pcl: add ws2_32 dep on Windows * Restore is_msvc_static_runtime import * pcl: fix Conan v1 issue * pcl: new add_build_type_postfix option, fix library naming on Windows * Take into account @maksim-petukhov remark * Take into account @valgur remark * Take into account maksim-petukhov remark * Set instantiate_only_core_point_types option at True * pcl: restore zlib dependency * pcl: adjust precompile_only_core_point_types name, add comment Based on https://github.com/PointCloudLibrary/pcl/blob/3ed96c246e5c873713ec670b895469d09149a552/cmake/pcl_options.cmake#L49 * Add rm to prevent PDBs files install --------- Co-authored-by: Martin Valgur --- recipes/pcl/all/conandata.yml | 19 + recipes/pcl/all/conanfile.py | 579 ++++++++++++++++++ ...n3-Eigen-target-in-pcl_common-target.patch | 25 + ...FixAboutMemoryConsumptionDuringBuild.patch | 38 ++ .../0001-cmake_use_conan_targets.patch | 52 ++ .../all/patches/0001-fix-FindOpenNI-bug.patch | 32 + recipes/pcl/all/test_package/CMakeLists.txt | 10 + recipes/pcl/all/test_package/conanfile.py | 27 + recipes/pcl/all/test_package/test_package.cpp | 73 +++ recipes/pcl/config.yml | 3 + 10 files changed, 858 insertions(+) create mode 100644 recipes/pcl/all/conandata.yml create mode 100644 recipes/pcl/all/conanfile.py create mode 100644 recipes/pcl/all/patches/0001-Add-Eigen3-Eigen-target-in-pcl_common-target.patch create mode 100644 recipes/pcl/all/patches/0001-ReportFixAboutMemoryConsumptionDuringBuild.patch create mode 100644 recipes/pcl/all/patches/0001-cmake_use_conan_targets.patch create mode 100644 recipes/pcl/all/patches/0001-fix-FindOpenNI-bug.patch create mode 100644 recipes/pcl/all/test_package/CMakeLists.txt create mode 100644 recipes/pcl/all/test_package/conanfile.py create mode 100644 recipes/pcl/all/test_package/test_package.cpp create mode 100644 recipes/pcl/config.yml diff --git a/recipes/pcl/all/conandata.yml b/recipes/pcl/all/conandata.yml new file mode 100644 index 00000000000000..6eea92ef4a7619 --- /dev/null +++ b/recipes/pcl/all/conandata.yml @@ -0,0 +1,19 @@ +sources: + "1.13.1": + url: https://github.com/PointCloudLibrary/pcl/archive/refs/tags/pcl-1.13.1.tar.gz + sha256: 8ab98a9db371d822de0859084a375a74bdc7f31c96d674147710cf4101b79621 +patches: + "1.13.1": + - patch_file: "patches/0001-cmake_use_conan_targets.patch" + patch_description: "Update PCL CMake files to work with Conan" + patch_type: "conan" + - patch_file: "patches/0001-fix-FindOpenNI-bug.patch" + patch_description: "Fix a libusb detection bug in FindOpenNI.cmake" + patch_type: "bugfix" + - patch_file: "patches/0001-Add-Eigen3-Eigen-target-in-pcl_common-target.patch" + patch_description: "Add Eigen3::Eigen target to pcl_common target" + patch_type: "conan" + - patch_file: "patches/0001-ReportFixAboutMemoryConsumptionDuringBuild.patch" + patch_description: "MovingLeastSquares: reduce the number of instantiations to reduce compile time" + patch_source: "https://github.com/PointCloudLibrary/pcl/pull/5764" + patch_type: "conan" diff --git a/recipes/pcl/all/conanfile.py b/recipes/pcl/all/conanfile.py new file mode 100644 index 00000000000000..c957981fea188d --- /dev/null +++ b/recipes/pcl/all/conanfile.py @@ -0,0 +1,579 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir, rm +from conan.tools.gnu import PkgConfigDeps +from conan.tools.scm import Version +from conan.tools.system import package_manager +import os + +required_conan_version = ">=1.53.0" + +class PclConan(ConanFile): + name = "pcl" + description = ("The Point Cloud Library (PCL) is a standalone, large-scale, " + "open project for 2D/3D image and point cloud processing.") + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/PointCloudLibrary/pcl" + topics = ("computer vision", "point cloud", "pointcloud", "3d", "pcd", "ply", "stl", "ifs", "vtk") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + # Enable/disable individual components + "2d": [True, False], + "features": [True, False], + "filters": [True, False], + "geometry": [True, False], + "io": [True, False], + "kdtree": [True, False], + "keypoints": [True, False], + "ml": [True, False], + "octree": [True, False], + "outofcore": [True, False], + "people": [True, False], + "recognition": [True, False], + "registration": [True, False], + "sample_consensus": [True, False], + "search": [True, False], + "segmentation": [True, False], + "simulation": [True, False], + "stereo": [True, False], + "surface": [True, False], + "tracking": [True, False], + "visualization": [True, False], + "cuda_common": [True, False], + "cuda_features": [True, False], + "cuda_io": [True, False], + "cuda_sample_consensus": [True, False], + "cuda_segmentation": [True, False], + "gpu_containers": [True, False], + "gpu_features": [True, False], + "gpu_kinfu": [True, False], + "gpu_kinfu_large_scale": [True, False], + "gpu_octree": [True, False], + "gpu_people": [True, False], + "gpu_segmentation": [True, False], + "gpu_surface": [True, False], + "gpu_tracking": [True, False], + "gpu_utils": [True, False], + "apps": [True, False], + "tools": [True, False], + # Optional external dependencies. + # Only used if the corresponding component is enabled. + "with_cuda": [True, False], + "with_flann": [True, False], + "with_libusb": [True, False], + "with_opencv": [True, False], + "with_opengl": [True, False], + "with_openmp": [True, False], + "with_pcap": [True, False], + "with_png": [True, False], + "with_qhull": [True, False], + "with_qt": [True, False], + "with_vtk": [True, False], + # TODO: + # "with_davidsdk": [True, False], + # "with_dssdk": [True, False], + # "with_ensenso": [True, False], + # "with_fzapi": [True, False], + # "with_metslib": [True, False], + # "with_openni": [True, False], + # "with_openni2": [True, False], + # "with_rssdk": [True, False], + # "with_rssdk2": [True, False], + # "with_qvtk": [True, False], + # Precompile for a minimal set of point types only instead of all (e.g., pcl::PointXYZ instead of PCL_XYZ_POINT_TYPES) + "precompile_only_core_point_types": [True, False], + # Whether to append a ''/d/rd/s postfix to executables on Windows depending on the build type + "add_build_type_postfix": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + # Enable/disable individual components + "2d": True, + "features": True, + "filters": True, + "geometry": True, + "io": True, + "kdtree": True, + "keypoints": True, + "ml": True, + "octree": True, + "outofcore": False, + "people": False, + "recognition": True, + "registration": True, + "sample_consensus": True, + "search": True, + "segmentation": True, + "simulation": False, + "stereo": True, + "surface": True, + "tracking": True, + # Visualization is currently disabled by default due to missing VTK package + "visualization": False, + # GPU components are disabled by default + "cuda_common": False, + "cuda_features": False, + "cuda_io": False, + "cuda_sample_consensus": False, + "cuda_segmentation": False, + "gpu_containers": False, + "gpu_features": False, + "gpu_kinfu": False, + "gpu_kinfu_large_scale": False, + "gpu_octree": False, + "gpu_people": False, + "gpu_segmentation": False, + "gpu_surface": False, + "gpu_tracking": False, + "gpu_utils": False, + "apps": False, + "tools": False, + # Optional external dependencies + "with_cuda": False, + "with_flann": True, + "with_libusb": True, + "with_opencv": True, + "with_opengl": True, + "with_openmp": False, + "with_pcap": True, + "with_png": True, + "with_qhull": True, + "with_qt": True, + "with_vtk": False, + # Enabled to avoid excessive memory usage during compilation in CCI + "precompile_only_core_point_types": True, + "add_build_type_postfix": False, + } + + short_paths = True + + # The component details have been extracted from their CMakeLists.txt files using + # https://gist.github.com/valgur/e54e39b6a8931b58cc1776515104c828 + @property + def _external_deps(self): + return { + "common": ["boost", "eigen"], + "cuda_common": ["cuda"], + "cuda_features": ["cuda"], + "cuda_io": ["cuda", "openni"], + "cuda_sample_consensus": ["cuda"], + "cuda_segmentation": ["cuda"], + "gpu_containers": ["cuda"], + "gpu_features": ["cuda"], + "gpu_kinfu": ["cuda"], + "gpu_kinfu_large_scale": ["cuda"], + "gpu_octree": ["cuda"], + "gpu_people": ["cuda"], + "gpu_segmentation": ["cuda"], + "gpu_surface": ["cuda"], + "gpu_tracking": ["cuda"], + "gpu_utils": ["cuda"], + "io": ["zlib"], + "people": ["vtk"], + "surface": ["zlib"], + "visualization": ["vtk"], + } + + @property + def _external_optional_deps(self): + return { + "2d": ["vtk"], + "io": ["davidsdk", "dssdk", "ensenso", "fzapi", "libusb", "openni", "openni2", "pcap", "png", "rssdk", "rssdk2", "vtk"], + "kdtree": ["flann"], + "people": ["openni"], + "recognition": ["metslib"], + "search": ["flann"], + "simulation": ["opengl"], + "surface": ["qhull", "vtk"], + "visualization": ["davidsdk", "dssdk", "ensenso", "opengl", "openni", "openni2", "qvtk", "rssdk"], + "apps": ["cuda", "libusb", "opengl", "openni", "png", "qhull", "qt", "qvtk", "vtk"], + "tools": ["cuda", "davidsdk", "dssdk", "ensenso", "opencv", "opengl", "openni", "openni2", "qhull", "rssdk", "vtk"], + } + + def _ext_dep_to_conan_target(self, dep): + if not self._is_enabled(dep): + return [] + return { + "boost": ["boost::boost"], + "cuda": [], + "davidsdk": [], + "dssdk": [], + "eigen": ["eigen::eigen"], + "ensenso": [], + "flann": ["flann::flann"], + "fzapi": [], + "libusb": ["libusb::libusb"], + "metslib": [], + "opencv": ["opencv::opencv"], + "opengl": ["opengl::opengl", "freeglut::freeglut", "glew::glew", "glu::glu"], + "openni": [], + "openni2": [], + "pcap": ["libpcap::libpcap"], + "png": ["libpng::libpng"], + "qhull": ["qhull::qhull"], + "qt": ["qt::qt"], + "qvtk": [], + "rssdk": [], + "rssdk2": [], + "vtk": [], + "zlib": ["zlib::zlib"], + }[dep] + + @property + def _internal_deps(self): + return { + "2d": ["common", "filters"], + "common": [], + "cuda_common": [], + "cuda_features": ["common", "cuda_common", "io"], + "cuda_io": ["common", "cuda_common", "io"], + "cuda_sample_consensus": ["common", "cuda_common", "io"], + "cuda_segmentation": ["common", "cuda_common", "io"], + "features": ["2d", "common", "filters", "kdtree", "octree", "search"], + "filters": ["common", "kdtree", "octree", "sample_consensus", "search"], + "geometry": ["common"], + "gpu_containers": ["common"], + "gpu_features": ["common", "geometry", "gpu_containers", "gpu_octree", "gpu_utils"], + "gpu_kinfu": ["common", "geometry", "gpu_containers", "io", "search"], + "gpu_kinfu_large_scale": ["common", "features", "filters", "geometry", "gpu_containers", + "gpu_utils", "io", "kdtree", "octree", "search", "surface"], + "gpu_octree": ["common", "gpu_containers", "gpu_utils"], + "gpu_people": ["common", "features", "filters", "geometry", "gpu_containers", + "gpu_utils", "io", "kdtree", "octree", "search", "segmentation", + "surface", "visualization"], + "gpu_segmentation": ["common", "gpu_containers", "gpu_octree", "gpu_utils"], + "gpu_surface": ["common", "geometry", "gpu_containers", "gpu_utils"], + "gpu_tracking": ["common", "filters", "gpu_containers", "gpu_octree", + "gpu_utils", "kdtree", "octree", "search", "tracking"], + "gpu_utils": ["common", "gpu_containers"], + "io": ["common", "octree"], + "kdtree": ["common"], + "keypoints": ["common", "features", "filters", "kdtree", "octree", "search"], + "ml": ["common"], + "octree": ["common"], + "outofcore": ["common", "filters", "io", "octree", "visualization"], + "people": ["common", "filters", "geometry", "io", "kdtree", "octree", + "sample_consensus", "search", "segmentation", "visualization"], + "recognition": ["common", "features", "filters", "io", "kdtree", "ml", + "octree", "registration", "sample_consensus", "search"], + "registration": ["common", "features", "filters", "kdtree", "octree", + "sample_consensus", "search"], + "sample_consensus": ["common", "search"], + "search": ["common", "kdtree", "octree"], + "segmentation": ["common", "features", "filters", "geometry", "kdtree", + "ml", "octree", "sample_consensus", "search"], + "simulation": ["common", "features", "filters", "geometry", "io", + "kdtree", "octree", "search", "surface", "visualization"], + "stereo": ["common", "io"], + "surface": ["common", "kdtree", "octree", "search"], + "tracking": ["common", "filters", "kdtree", "octree", "search"], + "visualization": ["common", "geometry", "io", "kdtree", "octree", "search"], + } + + @property + def _internal_optional_deps(self): + return { + "apps": ["2d", "common", "cuda_common", "cuda_features", "cuda_io", + "cuda_sample_consensus", "cuda_segmentation", "features", "filters", + "geometry", "io", "kdtree", "keypoints", "ml", "octree", "recognition", + "registration", "sample_consensus", "search", "segmentation", "stereo", + "surface", "tracking", "visualization"], + "tools": ["features", "filters", "geometry", "gpu_kinfu", "gpu_kinfu_large_scale", + "io", "kdtree", "keypoints", "ml", "octree", "recognition", "registration", + "sample_consensus", "search", "segmentation", "surface", "visualization"], + } + + def _is_header_only(self, component): + return component in {"2d", "cuda_common", "geometry"} + + @property + def _extra_libs(self): + return {"io": ["pcl_io_ply"]} + + def _enabled_components(self, opts=None): + opts = opts or self.options + return {c for c in self._internal_deps if opts.get_safe(c)} | {"common"} + + def _disabled_components(self, opts=None): + opts = opts or self.options + return {c for c in self._internal_deps if not opts.get_safe(c)} - {"common"} + + def _used_ext_deps(self, opts): + all_deps = set() + for component in self._enabled_components(opts): + all_deps.update(self._external_deps.get(component, [])) + all_deps.update(self._external_optional_deps.get(component, [])) + return all_deps + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "7", + "clang": "7", + "apple-clang": "10", + "msvc": "191", + "Visual Studio": "15", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def system_requirements(self): + if self._is_enabled("vtk"): + # TODO: add vtk/system package? + # https://repology.org/project/vtk/versions + package_manager.Apt(self).install(["libvtk9-dev"], update=True, check=True) + package_manager.Dnf(self).install(["vtk-devel"], update=True, check=True) + package_manager.Yum(self).install(["vtk-devel"], update=True, check=True) + package_manager.PacMan(self).install(["vtk"], update=True, check=True) + package_manager.Zypper(self).install(["vtk"], update=True, check=True) + package_manager.Pkg(self).install(["vtk9"], update=True, check=True) + package_manager.Brew(self).install(["vtk"], update=True, check=True) + if self.settings.os == "Windows": + self.output.warning("VTK must be installed manually on Windows.") + + def _is_enabled(self, dep): + always_available = ["boost", "eigen", "zlib"] + is_available = self.options.get_safe(f"with_{dep}") or dep in always_available + is_used = dep in self._used_ext_deps(self.options) + return is_available and is_used + + def requirements(self): + self.requires("boost/1.82.0", transitive_headers=True) + self.requires("eigen/3.4.0", transitive_headers=True) + if self._is_enabled("flann"): + self.requires("flann/1.9.2", transitive_headers=True) + if self._is_enabled("png"): + self.requires("libpng/1.6.40") + if self._is_enabled("qhull"): + self.requires("qhull/8.0.1", transitive_headers=True) + if self._is_enabled("qt"): + self.requires("qt/6.5.1") + if self._is_enabled("libusb"): + self.requires("libusb/1.0.26", transitive_headers=True) + if self._is_enabled("pcap"): + self.requires("libpcap/1.10.4") + if self._is_enabled("opengl"): + # OpenGL is only used if VTK is available + self.requires("opengl/system", transitive_headers=True) + self.requires("freeglut/3.4.0", transitive_headers=True) + self.requires("glew/2.2.0", transitive_headers=True) + self.requires("glu/system", transitive_headers=True) + if self._is_enabled("opencv"): + self.requires("opencv/4.5.5", transitive_headers=True) + if self._is_enabled("zlib"): + self.requires("zlib/1.2.13") + # TODO: + # self.requires("vtk/9.x.x", transitive_headers=True) + # self.requires("openni/x.x.x", transitive_headers=True) + # self.requires("openni2/x.x.x", transitive_headers=True) + # self.requires("ensenso/x.x.x", transitive_headers=True) + # self.requires("davidsdk/x.x.x", transitive_headers=True) + # self.requires("dssdk/x.x.x", transitive_headers=True) + # self.requires("rssdk/x.x.x", transitive_headers=True) + # self.requires("metslib/x.x.x", transitive_headers=True) + # self.requires("openmp/system", transitive_headers=True) + # self.requires("opennurbs/x.x.x", transitive_headers=True) + # self.requires("poisson4/x.x.x", transitive_headers=True) + + def package_id(self): + used_deps = self._used_ext_deps(self.info.options) + # Disable options that have no effect + all_opts = [opt for opt, value in self.info.options.items()] + for opt in all_opts: + if opt.startswith("with_") and opt.split("_", 1)[1] not in used_deps: + setattr(self.info.options, opt, False) + + def validate(self): + enabled_components = self._enabled_components() + for component in sorted(enabled_components): + for dep in self._external_deps.get(component, []): + if not self._is_enabled(dep): + raise ConanInvalidConfiguration( + f"'with_{dep}=True' is required when '{component}' is enabled." + ) + for dep in self._internal_deps[component]: + if dep not in enabled_components: + raise ConanInvalidConfiguration( + f"'{dep}=True' is required when '{component}' is enabled." + ) + + if self.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) + + def generate(self): + tc = CMakeToolchain(self) + tc.cache_variables["PCL_SHARED_LIBS"] = self.options.shared + tc.cache_variables["WITH_LIBUSB"] = self._is_enabled("libusb") + tc.cache_variables["WITH_OPENGL"] = self._is_enabled("opengl") + tc.cache_variables["WITH_OPENMP"] = self._is_enabled("openmp") + tc.cache_variables["WITH_PCAP"] = self._is_enabled("pcap") + tc.cache_variables["WITH_PNG"] = self._is_enabled("png") + tc.cache_variables["WITH_QHULL"] = self._is_enabled("qhull") + tc.cache_variables["WITH_QT"] = self._is_enabled("qt") + tc.cache_variables["WITH_VTK"] = self._is_enabled("vtk") + tc.cache_variables["WITH_CUDA"] = self._is_enabled("cuda") + tc.cache_variables["BUILD_CUDA"] = self._is_enabled("cuda") + tc.cache_variables["BUILD_GPU"] = self._is_enabled("cuda") + tc.cache_variables["WITH_SYSTEM_ZLIB"] = True + tc.cache_variables["PCL_ONLY_CORE_POINT_TYPES"] = self.options.precompile_only_core_point_types + # The default False setting breaks OpenGL detection in CMake + tc.cache_variables["PCL_ALLOW_BOTH_SHARED_AND_STATIC_DEPENDENCIES"] = True + tc.variables["OpenGL_GL_PREFERENCE"] = "GLVND" + + if not self.options.add_build_type_postfix: + tc.cache_variables["CMAKE_DEBUG_POSTFIX"] = "" + tc.cache_variables["CMAKE_RELEASE_POSTFIX"] = "" + tc.cache_variables["CMAKE_RELWITHDEBINFO_POSTFIX"] = "" + tc.cache_variables["CMAKE_MINSIZEREL_POSTFIX"] = "" + + tc.cache_variables["BUILD_tools"] = self.options.tools + tc.cache_variables["BUILD_apps"] = self.options.apps + tc.cache_variables["BUILD_examples"] = False + enabled = sorted(self._enabled_components()) + disabled = sorted(self._disabled_components()) + self.output.info("Enabled components: " + ", ".join(enabled)) + self.output.info("Disabled components: " + ", ".join(disabled)) + for comp in enabled: + tc.cache_variables[f"BUILD_{comp}"] = True + for comp in disabled: + tc.cache_variables[f"BUILD_{comp}"] = False + + tc.generate() + + deps = CMakeDeps(self) + deps.set_property("eigen", "cmake_file_name", "EIGEN") + deps.set_property("flann", "cmake_file_name", "FLANN") + deps.set_property("flann", "cmake_target_name", "FLANN::FLANN") + deps.set_property("libpcap", "cmake_file_name", "PCAP") + deps.set_property("qhull", "cmake_file_name", "QHULL") + deps.set_property("qhull", "cmake_target_name", "QHULL::QHULL") + deps.generate() + + deps = PkgConfigDeps(self) + deps.generate() + + def _patch_sources(self): + apply_conandata_patches(self) + for mod in ["Eigen", "FLANN", "GLEW", "Pcap", "Qhull", "libusb"]: + os.remove(os.path.join(self.source_folder, "cmake", "Modules", f"Find{mod}.cmake")) + + def build(self): + self._patch_sources() + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + + cmake = CMake(self) + cmake.install() + + rmdir(self, os.path.join(self.package_folder, "cmake")) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.pdb", os.path.join(self.package_folder, "lib")) + rm(self, "*.pdb", os.path.join(self.package_folder, "bin")) + # Remove MSVC runtime libraries + for dll_pattern_to_remove in ["concrt*.dll", "msvcp*.dll", "vcruntime*.dll"]: + rm(self, dll_pattern_to_remove, os.path.join(self.package_folder, "bin")) + + @property + def _version_suffix(self): + semver = Version(self.version) + return f"{semver.major}.{semver.minor}" + + def package_info(self): + self.cpp_info.set_property("cmake_file_name", "PCL") + self.cpp_info.set_property("cmake_target_name", "PCL::PCL") + self.cpp_info.set_property("cmake_find_mode", "both") + + for name in sorted(self._enabled_components()): + component = self.cpp_info.components[name] + component.names["cmake_find_package"] = name + component.names["cmake_find_package_multi"] = name + component.set_property("cmake_file_name", name) + component.set_property("cmake_module_file_name", name) + component.set_property("cmake_target_name", f"PCL::{name}") + component.set_property("pkg_config_name", f"pcl_{name}-{self._version_suffix}") + component.includedirs = [os.path.join("include", f"pcl-{self._version_suffix}")] + if not self._is_header_only(name): + component.libs = [f"pcl_{name}"] + component.libs += self._extra_libs.get(name, []) + component.requires += self._internal_deps[name] + for opt_dep in self._internal_optional_deps.get(name, []): + if self.options.get_safe(opt_dep): + component.requires.append(opt_dep) + for dep in self._external_deps.get(name, []) + self._external_optional_deps.get(name, []): + component.requires += self._ext_dep_to_conan_target(dep) + self.output.info(f"Component {name} requires: {component.requires}") + + if self.options.apps: + component = self.cpp_info.components["apps"] + component.libs = [] + component.includedirs = [] + component.requires = self._internal_optional_deps["apps"] + for dep in self._external_optional_deps["apps"]: + component.requires += self._ext_dep_to_conan_target(dep) + + if self.options.tools: + component = self.cpp_info.components["tools"] + component.libs = [] + component.includedirs = [] + component.requires = self._internal_optional_deps["tools"] + for dep in self._external_optional_deps["tools"]: + component.requires += self._ext_dep_to_conan_target(dep) + + common = self.cpp_info.components["common"] + if not self.options.shared: + if self.settings.os in ["Linux", "FreeBSD"]: + common.system_libs.append("pthread") + if self.options.with_openmp: + if self.settings.os == "Linux": + if self.settings.compiler == "gcc": + common.sharedlinkflags.append("-fopenmp") + common.exelinkflags.append("-fopenmp") + elif self.settings.os == "Windows": + if self.settings.compiler == "msvc": + common.system_libs.append("delayimp") + elif self.settings.compiler == "gcc": + common.system_libs.append("gomp") + if self.settings.os == "Windows": + common.system_libs.append("ws2_32") + + # TODO: Legacy, to be removed on Conan 2.0 + self.cpp_info.names["cmake_find_package"] = "PCL" + self.cpp_info.names["cmake_find_package_multi"] = "PCL" diff --git a/recipes/pcl/all/patches/0001-Add-Eigen3-Eigen-target-in-pcl_common-target.patch b/recipes/pcl/all/patches/0001-Add-Eigen3-Eigen-target-in-pcl_common-target.patch new file mode 100644 index 00000000000000..5dfeedf59e5f46 --- /dev/null +++ b/recipes/pcl/all/patches/0001-Add-Eigen3-Eigen-target-in-pcl_common-target.patch @@ -0,0 +1,25 @@ +From a975f68d2e399a1563fe0d66b2c048978f0282d1 Mon Sep 17 00:00:00 2001 +From: Esteban DUGUEPEROUX +Date: Mon, 7 Aug 2023 23:50:12 +0200 +Subject: [PATCH] Add Eigen3::Eigen target in pcl_common target + +--- + common/CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt +index 48e1a202e..e0ced5241 100644 +--- a/common/CMakeLists.txt ++++ b/common/CMakeLists.txt +@@ -179,7 +179,7 @@ target_include_directories(${LIB_NAME} PUBLIC + $ + ) + +-target_link_libraries(${LIB_NAME} Boost::boost) ++target_link_libraries(${LIB_NAME} Boost::boost Eigen3::Eigen) + + if(MSVC AND NOT (MSVC_VERSION LESS 1915)) + # MSVC resolved a byte alignment issue in compiler version 15.9 +-- +2.41.0 + diff --git a/recipes/pcl/all/patches/0001-ReportFixAboutMemoryConsumptionDuringBuild.patch b/recipes/pcl/all/patches/0001-ReportFixAboutMemoryConsumptionDuringBuild.patch new file mode 100644 index 00000000000000..35fba73e8b0675 --- /dev/null +++ b/recipes/pcl/all/patches/0001-ReportFixAboutMemoryConsumptionDuringBuild.patch @@ -0,0 +1,38 @@ +From 0bc2f2cc369f7d013ee5c29075188c4e26ea6f87 Mon Sep 17 00:00:00 2001 +From: Markus Vieth +Date: Sat, 15 Jul 2023 15:49:25 +0200 +Subject: [PATCH] MovingLeastSquares: reduce the number of instantiations to + reduce compile time PCL_XYZ_POINT_TYPES currently contains 18 types, so + previously, MLS was instantiated for 18*18=324 different type combinations. + However, among those were instantiations which are likely used by nobody + (like `pcl::MovingLeastSquares`). With + these changes, MLS is only instantiated 6*6+(18-6)=48 times. The most common + type combinations should be covered, but if someone uses an uncommon + combinations, they have to add `#define PCL_NO_PRECOMPILE` before including + `pcl/surface/mls.h` to avoid linker errors. + +--- + surface/src/mls.cpp | 11 ++++++++++- + 1 file changed, 10 insertions(+), 1 deletion(-) + +diff --git a/surface/src/mls.cpp b/surface/src/mls.cpp +index ba2fd655300..c948f4d19e1 100644 +--- a/surface/src/mls.cpp ++++ b/surface/src/mls.cpp +@@ -80,6 +80,15 @@ pcl::MLSResult::calculatePrincipalCurvatures (const double u, const double v) co + PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal)(pcl::PointNormal)) + ((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal)(pcl::PointNormal))) + #else +- PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, (PCL_XYZ_POINT_TYPES)(PCL_XYZ_POINT_TYPES)) ++ // PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, (PCL_XYZ_POINT_TYPES)(PCL_XYZ_POINT_TYPES)) ++ // All instantiations that are available with PCL_ONLY_CORE_POINT_TYPES, plus instantiations for all XYZ types where PointInT and PointOutT are the same ++ #define PCL_INSTANTIATE_MovingLeastSquaresSameInAndOut(T) template class PCL_EXPORTS pcl::MovingLeastSquares; ++ PCL_INSTANTIATE(MovingLeastSquaresSameInAndOut, PCL_XYZ_POINT_TYPES) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZ))((pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal)(pcl::PointNormal))) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZI))((pcl::PointXYZ)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal)(pcl::PointNormal))) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZRGB))((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal)(pcl::PointNormal))) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZRGBA))((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBNormal)(pcl::PointNormal))) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointXYZRGBNormal))((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointNormal))) ++ PCL_INSTANTIATE_PRODUCT(MovingLeastSquares, ((pcl::PointNormal))((pcl::PointXYZ)(pcl::PointXYZI)(pcl::PointXYZRGB)(pcl::PointXYZRGBA)(pcl::PointXYZRGBNormal))) + #endif + #endif // PCL_NO_PRECOMPILE diff --git a/recipes/pcl/all/patches/0001-cmake_use_conan_targets.patch b/recipes/pcl/all/patches/0001-cmake_use_conan_targets.patch new file mode 100644 index 00000000000000..5461a0bfed49e0 --- /dev/null +++ b/recipes/pcl/all/patches/0001-cmake_use_conan_targets.patch @@ -0,0 +1,52 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -297,7 +297,7 @@ + # OpenMP (optional) + option(WITH_OPENMP "Build with parallelization using OpenMP" TRUE) + if(WITH_OPENMP) +- find_package(OpenMP COMPONENTS C CXX) ++ find_package(OpenMP REQUIRED COMPONENTS C CXX) + endif() + if(OpenMP_FOUND) + string(APPEND CMAKE_C_FLAGS " ${OpenMP_C_FLAGS}") +@@ -319,11 +319,11 @@ + find_package(Threads REQUIRED) + + # Eigen (required) +-find_package(Eigen 3.3 REQUIRED) ++find_package(EIGEN REQUIRED CONFIG) + include_directories(SYSTEM ${EIGEN_INCLUDE_DIRS}) + + # FLANN (required) +-find_package(FLANN 1.9.1 REQUIRED) ++find_package(FLANN CONFIG) + if(NOT (${FLANN_LIBRARY_TYPE} MATCHES ${PCL_FLANN_REQUIRED_TYPE}) AND NOT (${PCL_FLANN_REQUIRED_TYPE} MATCHES "DONTCARE")) + message(FATAL_ERROR "Flann was selected with ${PCL_FLANN_REQUIRED_TYPE} but found as ${FLANN_LIBRARY_TYPE}") + endif() +@@ -359,7 +359,7 @@ + # LibPNG + option(WITH_PNG "PNG file support" TRUE) + if(WITH_PNG) +- find_package(PNG) ++ find_package(PNG REQUIRED CONFIG) + if(PNG_FOUND) + set(HAVE_PNG ON) + include_directories(SYSTEM "${PNG_INCLUDE_DIR}") +@@ -369,7 +369,7 @@ + # Qhull + option(WITH_QHULL "Include convex-hull operations" TRUE) + if(WITH_QHULL) +- find_package(Qhull) ++ find_package(QHULL REQUIRED CONFIG) + if(NOT (${QHULL_LIBRARY_TYPE} MATCHES ${PCL_QHULL_REQUIRED_TYPE}) AND NOT (${PCL_QHULL_REQUIRED_TYPE} MATCHES "DONTCARE")) + message(FATAL_ERROR "Qhull was selected with ${PCL_QHULL_REQUIRED_TYPE} but found as ${QHULL_LIBRARY_TYPE}") + endif() +@@ -404,7 +404,7 @@ + #Find PCAP + option(WITH_PCAP "pcap file capabilities in Velodyne HDL driver" TRUE) + if(WITH_PCAP) +- find_package(Pcap) ++ find_package(PCAP REQUIRED CONFIG) + endif() + + # OpenGL and GLUT diff --git a/recipes/pcl/all/patches/0001-fix-FindOpenNI-bug.patch b/recipes/pcl/all/patches/0001-fix-FindOpenNI-bug.patch new file mode 100644 index 00000000000000..34cf4a671e2859 --- /dev/null +++ b/recipes/pcl/all/patches/0001-fix-FindOpenNI-bug.patch @@ -0,0 +1,32 @@ +--- cmake/Modules/FindOpenNI.cmake ++++ cmake/Modules/FindOpenNI.cmake +@@ -52,7 +52,12 @@ + + # Libraries + if(NOT WIN32) +- find_package(libusb REQUIRED) ++ find_package(libusb QUIET) ++ if (NOT libusb_FOUND) ++ message(WARNING "Found OpenNI library, but required libusb is not available") ++ set(OPENNI_FOUND FALSE) ++ return() ++ endif() + set(OPENNI_LIBRARIES ${OPENNI_LIBRARY} libusb::libusb) + else() + set(OPENNI_LIBRARIES ${OPENNI_LIBRARY}) +--- cmake/Modules/FindOpenNI2.cmake ++++ cmake/Modules/FindOpenNI2.cmake +@@ -42,7 +42,12 @@ + + # Libraries + if(NOT WIN32) +- find_package(libusb REQUIRED) ++ find_package(libusb QUIET) ++ if (NOT libusb_FOUND) ++ message(WARNING "Found OpenNI2 library, but required libusb is not available") ++ set(OPENNI2_FOUND FALSE) ++ return() ++ endif() + set(OPENNI2_LIBRARIES ${OPENNI2_LIBRARY} libusb::libusb) + else() + set(OPENNI2_LIBRARIES ${OPENNI2_LIBRARY}) diff --git a/recipes/pcl/all/test_package/CMakeLists.txt b/recipes/pcl/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..57794a612df2a9 --- /dev/null +++ b/recipes/pcl/all/test_package/CMakeLists.txt @@ -0,0 +1,10 @@ +cmake_minimum_required(VERSION 3.15) + +project(test_package CXX) + +find_package(PCL REQUIRED surface CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) + +target_link_libraries(${PROJECT_NAME} PRIVATE PCL::filters) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/pcl/all/test_package/conanfile.py b/recipes/pcl/all/test_package/conanfile.py new file mode 100644 index 00000000000000..02eb5ce439fb40 --- /dev/null +++ b/recipes/pcl/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +# It will become the standard on Conan 2.x +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pcl/all/test_package/test_package.cpp b/recipes/pcl/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..cca717d08eb8f6 --- /dev/null +++ b/recipes/pcl/all/test_package/test_package.cpp @@ -0,0 +1,73 @@ +// Copied from https://github.com/PointCloudLibrary/pcl/blob/pcl-1.13.1/examples/filters/example_extract_indices.cpp +/* + * Software License Agreement (BSD License) + * + * Point Cloud Library (PCL) - www.pointclouds.org + * Copyright (c) 2009-2011, Willow Garage, Inc. + * + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * * Redistributions of source code must retain the above copyright + * notice, this list of conditions and the following disclaimer. + * * Redistributions in binary form must reproduce the above + * copyright notice, this list of conditions and the following + * disclaimer in the documentation and/or other materials provided + * with the distribution. + * * Neither the name of Willow Garage, Inc. nor the names of its + * contributors may be used to endorse or promote products derived + * from this software without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS + * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT + * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS + * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE + * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, + * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, + * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; + * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER + * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN + * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE + * POSSIBILITY OF SUCH DAMAGE. + * + * $Id: example_ExtractIndices.cpp 4117 2012-01-31 17:56:02Z aichim $ + * + */ + +#include + +#include + +int +main (int, char**) +{ + using PointType = pcl::PointXYZ; + using CloudType = pcl::PointCloud; + CloudType::Ptr cloud (new CloudType); + cloud->is_dense = false; + PointType p; + for (unsigned int i = 0; i < 5; ++i) + { + p.x = p.y = p.z = static_cast (i); + cloud->push_back (p); + } + + std::cout << "Cloud has " << cloud->size () << " points." << std::endl; + + pcl::PointIndices indices; + indices.indices.push_back (0); + indices.indices.push_back (2); + + pcl::ExtractIndices extract_indices; + extract_indices.setIndices (pcl::make_shared (indices)); + extract_indices.setInputCloud (cloud); + pcl::PointCloud::Ptr output (new pcl::PointCloud); + extract_indices.filter (*output); + + std::cout << "Output has " << output->size () << " points." << std::endl; + return (0); +} diff --git a/recipes/pcl/config.yml b/recipes/pcl/config.yml new file mode 100644 index 00000000000000..aac1819cc10c01 --- /dev/null +++ b/recipes/pcl/config.yml @@ -0,0 +1,3 @@ +versions: + "1.13.1": + folder: all From 31978b690b3dca0ee0ddb59d6bf5afe19ba839d9 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 22 Aug 2023 16:42:22 +0200 Subject: [PATCH 0365/1140] (#19334) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 09348eebe130c7..0732b711379141 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -96,6 +96,7 @@ required_for_references: - boost - boost-ext-ut - boost-leaf +- boostdep - box2d - breakpad - brigand @@ -637,6 +638,7 @@ required_for_references: - libx264 - libx265 - libxcrypt +- libxft - libxls - libxlsxwriter - libxml2 @@ -854,6 +856,7 @@ required_for_references: - picobench - picojson - picosha2 +- pipes - pixman - pkgconf - platform.delegates From 407df7256d184ed32c64a11885ad230f256c3b2f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 22 Aug 2023 18:08:21 +0300 Subject: [PATCH 0366/1140] (#18814) fltk: migrate to Conan v2 * fltk: migrate to Conan v2 * fltk: restore VirtualRunEnv in test_package * fltk: bump deps * fltk: add missing macOS system frameworks * Remove incorrect system framework * Remove opengl32 framework dep --- recipes/fltk/all/CMakeLists.txt | 7 - recipes/fltk/all/conandata.yml | 9 +- recipes/fltk/all/conanfile.py | 128 +++++++++--------- recipes/fltk/all/test_package/CMakeLists.txt | 7 +- recipes/fltk/all/test_package/conanfile.py | 20 ++- .../fltk/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/fltk/all/test_v1_package/conanfile.py | 16 +++ 7 files changed, 105 insertions(+), 90 deletions(-) delete mode 100644 recipes/fltk/all/CMakeLists.txt create mode 100644 recipes/fltk/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/fltk/all/test_v1_package/conanfile.py diff --git a/recipes/fltk/all/CMakeLists.txt b/recipes/fltk/all/CMakeLists.txt deleted file mode 100644 index 60dd71d7363c30..00000000000000 --- a/recipes/fltk/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8) -project(cmake_wrapper) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/fltk/all/conandata.yml b/recipes/fltk/all/conandata.yml index 1b3f085545004d..0f349ed1289218 100644 --- a/recipes/fltk/all/conandata.yml +++ b/recipes/fltk/all/conandata.yml @@ -5,9 +5,6 @@ sources: patches: "1.3.8": - - base_path: "source_subfolder" - patch_file: "patches/1.3.8-0001-remove-fluid.patch" - - base_path: "source_subfolder" - patch_file: "patches/1.3.8-0002-fix-resources.patch" - - base_path: "source_subfolder" - patch_file: "patches/1.3.8-0003-build-static-only-on-static.patch" + - patch_file: "patches/1.3.8-0001-remove-fluid.patch" + - patch_file: "patches/1.3.8-0002-fix-resources.patch" + - patch_file: "patches/1.3.8-0003-build-static-only-on-static.patch" diff --git a/recipes/fltk/all/conanfile.py b/recipes/fltk/all/conanfile.py index 0533063aab5851..a7feaec5a6e94b 100644 --- a/recipes/fltk/all/conanfile.py +++ b/recipes/fltk/all/conanfile.py @@ -1,19 +1,22 @@ import os -import conan.tools.files as tools from conan import ConanFile -from conans import CMake +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, rm, rmdir -required_conan_version = ">=1.50.0" +required_conan_version = ">=1.53.0" class FltkConan(ConanFile): name = "fltk" description = "Fast Light Toolkit is a cross-platform C++ GUI toolkit" - topics = ("fltk", "gui") - homepage = "https://www.fltk.org" - url = "https://github.com/conan-io/conan-center-index" license = "LGPL-2.0-custom" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.fltk.org" + topics = ("gui",) + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -21,31 +24,25 @@ class FltkConan(ConanFile): "with_gl": [True, False], "with_threads": [True, False], "with_gdiplus": [True, False], - "abi_version": "ANY" + "abi_version": ["ANY"], } default_options = { "shared": False, "fPIC": True, "with_gl": True, "with_threads": True, - "with_gdiplus": True + "with_gdiplus": True, } - generators = "cmake", "cmake_find_package_multi" - - @property - def _source_subfolder(self): - return "source_subfolder" def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC else: - del self.options.with_gdiplus + self.options.rm_safe("with_gdiplus") + if self.options.abi_version == None: _version_token = self.version.split(".") _version_major = int(_version_token[0]) @@ -56,84 +53,81 @@ def config_options(self): _version_minor = int(_version_token[1]) _version_patch = 0 self.options.abi_version = str( - int(_version_major) * 10000 + - int(_version_minor) * 100 + - int(_version_patch) + int(_version_major) * 10000 + int(_version_minor) * 100 + int(_version_patch) ) def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.12") - self.requires("libjpeg/9d") - self.requires("libpng/1.6.37") - if self.settings.os == "Linux": + self.requires("zlib/1.2.13") + self.requires("libjpeg/9e") + self.requires("libpng/1.6.40") + if self.settings.os in ["Linux", "FreeBSD"]: self.requires("opengl/system") self.requires("glu/system") - self.requires("fontconfig/2.13.93") + self.requires("fontconfig/2.14.2") self.requires("xorg/system") def source(self): - tools.get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions['OPTION_BUILD_SHARED_LIBS'] = self.options.shared - cmake.definitions['FLTK_BUILD_TEST'] = False - cmake.definitions['FLTK_BUILD_EXAMPLES'] = False - cmake.definitions['OPTION_USE_GL'] = self.options.with_gl - cmake.definitions['OPTION_USE_THREADS'] = self.options.with_threads - cmake.definitions['OPTION_BUILD_HTML_DOCUMENTATION'] = False - cmake.definitions['OPTION_BUILD_PDF_DOCUMENTATION'] = False + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["OPTION_BUILD_SHARED_LIBS"] = self.options.shared + tc.variables["FLTK_BUILD_TEST"] = False + tc.variables["FLTK_BUILD_EXAMPLES"] = False + tc.variables["OPTION_USE_GL"] = self.options.with_gl + tc.variables["OPTION_USE_THREADS"] = self.options.with_threads + tc.variables["OPTION_BUILD_HTML_DOCUMENTATION"] = False + tc.variables["OPTION_BUILD_PDF_DOCUMENTATION"] = False if self.options.abi_version: - cmake.definitions['OPTION_ABI_VERSION'] = self.options.abi_version - cmake.configure() - return cmake + tc.variables["OPTION_ABI_VERSION"] = self.options.abi_version + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(self, **patch) - - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(self, os.path.join(self.package_folder, "share")) - tools.rmdir(self, os.path.join(self.package_folder, "FLTK.framework")) - tools.rmdir(self, os.path.join(self.package_folder, "CMake")) - tools.rm(self, "fltk-config*", os.path.join(self.package_folder, "bin")) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "FLTK.framework")) + rmdir(self, os.path.join(self.package_folder, "CMake")) + rm(self, "fltk-config*", os.path.join(self.package_folder, "bin")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "fltk") self.cpp_info.set_property("cmake_target_name", "fltk::fltk") - - self.cpp_info.names["cmake_find_package"] = "fltk" - self.cpp_info.names["cmake_find_package_multi"] = "fltk" + self.cpp_info.libs = collect_libs(self) if self.options.shared and self.settings.os == "Windows": self.cpp_info.defines.append("FL_DLL") - self.cpp_info.libs = tools.collect_libs(self) if self.settings.os in ("Linux", "FreeBSD"): if self.options.with_threads: - self.cpp_info.system_libs.extend(['pthread', 'dl']) + self.cpp_info.system_libs.extend(["pthread", "dl"]) if self.options.with_gl: - self.cpp_info.system_libs.extend(['GL', 'GLU']) - if self.settings.os == "Macos": - self.cpp_info.frameworks = ['Cocoa', 'OpenGL', 'IOKit', 'Carbon', 'CoreFoundation', 'CoreVideo'] - if self.settings.os == "Windows": - self.cpp_info.system_libs = [ - "gdi32", - "imm32", - "msimg32", - "ole32", - "oleaut32", - "uuid", + self.cpp_info.system_libs.extend(["GL", "GLU"]) + if is_apple_os(self): + self.cpp_info.frameworks = [ + "AppKit", "ApplicationServices", "Carbon", "Cocoa", "CoreFoundation", "CoreGraphics", + "CoreText", "CoreVideo", "Foundation", "IOKit", "OpenGL", ] + if self.settings.os == "Windows": + self.cpp_info.system_libs = ["gdi32", "imm32", "msimg32", "ole32", "oleaut32", "uuid"] if self.options.get_safe("with_gdiplus"): self.cpp_info.system_libs.append("gdiplus") + + # TODO: to remove in conan v2 once legacy generators removed + self.cpp_info.names["cmake_find_package"] = "fltk" + self.cpp_info.names["cmake_find_package_multi"] = "fltk" diff --git a/recipes/fltk/all/test_package/CMakeLists.txt b/recipes/fltk/all/test_package/CMakeLists.txt index a163bc26a443bb..cf30c297c55310 100644 --- a/recipes/fltk/all/test_package/CMakeLists.txt +++ b/recipes/fltk/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(fltk REQUIRED CONFIG) diff --git a/recipes/fltk/all/test_package/conanfile.py b/recipes/fltk/all/test_package/conanfile.py index a500b98343c743..ef5d7042163ecc 100644 --- a/recipes/fltk/all/test_package/conanfile.py +++ b/recipes/fltk/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fltk/all/test_v1_package/CMakeLists.txt b/recipes/fltk/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/fltk/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/fltk/all/test_v1_package/conanfile.py b/recipes/fltk/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a500b98343c743 --- /dev/null +++ b/recipes/fltk/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 7f826fd40c7aebbc248d4d5b2495a69245cbf154 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Tue, 22 Aug 2023 17:49:01 +0200 Subject: [PATCH 0367/1140] (#19066) aws-c-cal: add version 0.6.1 * aws-c-cal: add version 0.6.1 * cleanup: remove test_v1_package folder * Revert "cleanup: remove test_v1_package folder" This reverts commit f3d4ca5e4f19312285ddf339f5d85d736f633e5c. --- recipes/aws-c-cal/all/conandata.yml | 8 ++++++ recipes/aws-c-cal/all/conanfile.py | 4 ++- .../0002-apple-corefoundation-0.6.1.patch | 26 +++++++++++++++++++ recipes/aws-c-cal/config.yml | 2 ++ 4 files changed, 39 insertions(+), 1 deletion(-) create mode 100644 recipes/aws-c-cal/all/patches/0002-apple-corefoundation-0.6.1.patch diff --git a/recipes/aws-c-cal/all/conandata.yml b/recipes/aws-c-cal/all/conandata.yml index e1b848e4dfa2d2..c1c97333e92883 100644 --- a/recipes/aws-c-cal/all/conandata.yml +++ b/recipes/aws-c-cal/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.6.1": + url: "https://github.com/awslabs/aws-c-cal/archive/v0.6.1.tar.gz" + sha256: "52df95150a8548ac35a0e4b6f59fbdebff27e4124c0b7e5eaa969ed3ba62fc82" "0.5.20": url: "https://github.com/awslabs/aws-c-cal/archive/v0.5.20.tar.gz" sha256: "acc352359bd06f8597415c366cf4ec4f00d0b0da92d637039a73323dd55b6cd0" @@ -18,6 +21,11 @@ sources: url: "https://github.com/awslabs/aws-c-cal/archive/v0.5.11.tar.gz" sha256: "ef46e121b2231a0b19afce8af4b32d77501df4d470e926990918456636cd83c0" patches: + "0.6.1": + - patch_file: "patches/0002-apple-corefoundation-0.6.1.patch" + patch_description: "Link to CoreFoundation on Apple" + patch_type: "backport" + patch_source: "https://github.com/awslabs/aws-c-cal/pull/126" "0.5.20": - patch_file: "patches/0002-apple-corefoundation-0.5.13.patch" patch_description: "Link to CoreFoundation on Apple" diff --git a/recipes/aws-c-cal/all/conanfile.py b/recipes/aws-c-cal/all/conanfile.py index bb8fb82e75aabe..e6dc85b56045fb 100644 --- a/recipes/aws-c-cal/all/conanfile.py +++ b/recipes/aws-c-cal/all/conanfile.py @@ -53,8 +53,10 @@ def requirements(self): # without it for conan v2 (we would have to required aws-c-common in test package, but we can't know # which version to require in test package) self.requires("aws-c-common/0.6.11", transitive_headers=True, transitive_libs=True) - else: + elif Version(self.version) <= "0.5.20": self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True, transitive_libs=True) if self._needs_openssl: self.requires("openssl/[>=1.1 <4]") diff --git a/recipes/aws-c-cal/all/patches/0002-apple-corefoundation-0.6.1.patch b/recipes/aws-c-cal/all/patches/0002-apple-corefoundation-0.6.1.patch new file mode 100644 index 00000000000000..616d8257a2980a --- /dev/null +++ b/recipes/aws-c-cal/all/patches/0002-apple-corefoundation-0.6.1.patch @@ -0,0 +1,26 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -84,7 +84,12 @@ elseif (APPLE) + message(FATAL_ERROR "Security Framework not found") + endif () + +- list(APPEND PLATFORM_LIBS "-framework Security") ++ find_library(COREFOUNDATION_LIB CoreFoundation) ++ if(NOT COREFOUNDATION_LIB) ++ message(FATAL_ERROR "CoreFoundation Framework not found") ++ endif() ++ ++ list(APPEND PLATFORM_LIBS "-framework Security -framework CoreFoundation") + endif() + else () + if (NOT BYO_CRYPTO) +--- a/source/darwin/securityframework_ecc.c ++++ b/source/darwin/securityframework_ecc.c +@@ -7,6 +7,7 @@ + #include + #include + ++#include + #include + #include + diff --git a/recipes/aws-c-cal/config.yml b/recipes/aws-c-cal/config.yml index f969df4acc5839..7fb368557bdced 100644 --- a/recipes/aws-c-cal/config.yml +++ b/recipes/aws-c-cal/config.yml @@ -1,4 +1,6 @@ versions: + "0.6.1": + folder: all "0.5.20": folder: all "0.5.19": From 8d1e68463b5bf691ec6e8c36cb5c42f23fc4258c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 22 Aug 2023 19:31:23 +0300 Subject: [PATCH 0368/1140] (#19267) rpclib: migrate to Conan v2 --- recipes/rpclib/all/CMakeLists.txt | 9 -- recipes/rpclib/all/conanfile.py | 103 +++++++++++------- .../rpclib/all/test_package/CMakeLists.txt | 7 +- recipes/rpclib/all/test_package/conanfile.py | 21 +++- .../rpclib/all/test_v1_package/CMakeLists.txt | 8 ++ .../rpclib/all/test_v1_package/conanfile.py | 15 +++ 6 files changed, 104 insertions(+), 59 deletions(-) delete mode 100644 recipes/rpclib/all/CMakeLists.txt create mode 100644 recipes/rpclib/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rpclib/all/test_v1_package/conanfile.py diff --git a/recipes/rpclib/all/CMakeLists.txt b/recipes/rpclib/all/CMakeLists.txt deleted file mode 100644 index de7e444eb2469a..00000000000000 --- a/recipes/rpclib/all/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) - -conan_basic_setup() -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -add_subdirectory("source_subfolder") diff --git a/recipes/rpclib/all/conanfile.py b/recipes/rpclib/all/conanfile.py index 30a8488efd8a1f..f7ea155c14f7cf 100644 --- a/recipes/rpclib/all/conanfile.py +++ b/recipes/rpclib/all/conanfile.py @@ -1,37 +1,51 @@ -from conans import ConanFile, tools, CMake -from conan.tools.microsoft import msvc_runtime_flag import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, export_conandata_patches, get, rmdir, rename, mkdir +from conan.tools.microsoft import is_msvc_static_runtime +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" class rpclibConan(ConanFile): name = "rpclib" description = "A modern C++ msgpack-RPC server and client library." license = "MIT" - topics = ("rpc", "ipc", "rpc-server") - homepage = "https://github.com/rpclib/rpclib/" url = "https://github.com/conan-io/conan-center-index" - exports_sources = ["CMakeLists.txt", "patches/*"] - generators = "cmake" + homepage = "https://github.com/rpclib/rpclib/" + topics = ("rpc", "ipc", "rpc-server") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False] + "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 14 @property - def _build_subfolder(self): - return "build_subfolder" + def _compilers_minimum_version(self): + return { + "Visual Studio": "15", + "msvc": "14.1", + "gcc": "5", + "clang": "5", + "apple-clang": "5.1", + } + + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -39,49 +53,58 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.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): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + if is_msvc_static_runtime(self): + tc.variables["RPCLIB_MSVC_STATIC_RUNTIME"] = True + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - if "MT" in str(msvc_runtime_flag(self)): - self._cmake.definitions["RPCLIB_MSVC_STATIC_RUNTIME"] = True - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("LICENSE.md", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE.md", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + if self.settings.os == "Windows" and self.options.shared: + mkdir(self, self.package_path / "bin") + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.set_property("cmake_file_name", "rpclib") self.cpp_info.set_property("cmake_target_name", "rpclib::rpc") self.cpp_info.set_property("pkg_config_name", "rpclib") - # Fix for installing dll to lib folder - # - Default CMAKE installs the dll to the lib folder - # causing the test_package to fail - if self.settings.os in ["Windows"]: - if self.options.shared: - self.cpp_info.components["_rpc"].bindirs.append( - os.path.join(self.package_folder, "lib")) - # TODO: Remove after Conan 2.0 self.cpp_info.components["_rpc"].names["cmake_find_package"] = "rpc" self.cpp_info.components["_rpc"].names["cmake_find_package_multi"] = "rpc" self.cpp_info.components["_rpc"].libs = ["rpc"] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["_rpc"].system_libs = ["pthread"] - self.cpp_info.names["pkg_config"] = "librpc" diff --git a/recipes/rpclib/all/test_package/CMakeLists.txt b/recipes/rpclib/all/test_package/CMakeLists.txt index e585430312fe02..81dbfad0943b63 100644 --- a/recipes/rpclib/all/test_package/CMakeLists.txt +++ b/recipes/rpclib/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1.3) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(rpclib CONFIG REQUIRED) +find_package(rpclib REQUIRED CONFIG) add_executable(example example.cpp) set_target_properties(example PROPERTIES CXX_STANDARD 14) diff --git a/recipes/rpclib/all/test_package/conanfile.py b/recipes/rpclib/all/test_package/conanfile.py index 67c12602a84f3a..8d52b7021efe14 100644 --- a/recipes/rpclib/all/test_package/conanfile.py +++ b/recipes/rpclib/all/test_package/conanfile.py @@ -1,9 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - self.run( os.path.join("bin", "example"), run_environment=True ) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/rpclib/all/test_v1_package/CMakeLists.txt b/recipes/rpclib/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rpclib/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rpclib/all/test_v1_package/conanfile.py b/recipes/rpclib/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..67c12602a84f3a --- /dev/null +++ b/recipes/rpclib/all/test_v1_package/conanfile.py @@ -0,0 +1,15 @@ +import os +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run( os.path.join("bin", "example"), run_environment=True ) From ff06bf6a60038ad7d76e20fc66587cf51956d8f1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 22 Aug 2023 20:13:16 +0300 Subject: [PATCH 0369/1140] (#19268) duktape: migrate to Conan v2 * duktape: migrate to Conan v2 * duktape: fix shared Windows builds --- recipes/duktape/all/CMakeLists.txt | 14 +--- recipes/duktape/all/conanfile.py | 81 ++++++++++--------- .../duktape/all/test_package/CMakeLists.txt | 8 +- recipes/duktape/all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../duktape/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 88 insertions(+), 61 deletions(-) create mode 100644 recipes/duktape/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/duktape/all/test_v1_package/conanfile.py diff --git a/recipes/duktape/all/CMakeLists.txt b/recipes/duktape/all/CMakeLists.txt index 76bab4dba57c05..cc4f8cfa2df773 100644 --- a/recipes/duktape/all/CMakeLists.txt +++ b/recipes/duktape/all/CMakeLists.txt @@ -1,12 +1,8 @@ -cmake_minimum_required(VERSION 2.8.12) - +cmake_minimum_required(VERSION 3.12) project(duktape C) -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -file(GLOB SOURCES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/src/*.c) -file(GLOB HEADERS ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/src/*.h) +file(GLOB SOURCES ${CMAKE_CURRENT_LIST_DIR}/src/src/*.c) +file(GLOB HEADERS ${CMAKE_CURRENT_LIST_DIR}/src/src/*.h) add_library(duktape ${SOURCES} ${HEADERS}) set_target_properties(duktape PROPERTIES PUBLIC_HEADER "${HEADERS}") @@ -14,10 +10,8 @@ if (UNIX AND NOT APPLE AND NOT ANDROID) target_link_libraries(duktape m) endif() +include(GNUInstallDirs) install( TARGETS duktape - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib PUBLIC_HEADER DESTINATION include ) diff --git a/recipes/duktape/all/conanfile.py b/recipes/duktape/all/conanfile.py index 3e582932bd5957..588a96a8c0f571 100644 --- a/recipes/duktape/all/conanfile.py +++ b/recipes/duktape/all/conanfile.py @@ -1,29 +1,33 @@ import os -from conans import CMake, ConanFile, tools -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" + class DuktapeConan(ConanFile): name = "duktape" - license = "MIT" description = "Duktape is an embeddable Javascript engine, with a focus on portability and compact footprint." - topics = ("javascript", "engine", "embeddable", "compact") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://duktape.org" - exports_sources = ["CMakeLists.txt"] - generators = "cmake" + topics = ("javascript", "engine", "embeddable", "compact") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} + options = { + "shared": [True, False], + "fPIC": [True, False], + } default_options = { "shared": False, "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -31,44 +35,41 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + if self.settings.os == "Windows" and self.options.shared: + # Duktape has a configure script with a number of options. + # However, it requires python 2 and PyYAML package + # which is quite an unusual combination to have. + # The most crucial option is --dll which enables + # DUK_F_DLL_BUILD and the following defines. + tc.preprocessor_definitions["DUK_EXTERNAL_DECL"] = "extern __declspec(dllexport)" + tc.preprocessor_definitions["DUK_EXTERNAL"] = "__declspec(dllexport)" + tc.generate() def build(self): - # Duktape has configure script with a number of options. - # However it requires python 2 and PyYAML package - # which is quite an unusual combination to have. - # The most crucial option is --dll which just flips this define. - if self.settings.os == "Windows" and self.options.shared: - tools.replace_in_file( - os.path.join(self._source_subfolder, "src", "duk_config.h"), - "#undef DUK_F_DLL_BUILD", - "#define DUK_F_DLL_BUILD", - ) - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("LICENSE.txt", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): self.cpp_info.libs = ["duktape"] - if not self.options.shared and str(self.settings.os) in ( - "Linux", - "FreeBSD", - "SunOS", - ): + if not self.options.shared and self.settings.os in ("Linux", "FreeBSD", "SunOS"): self.cpp_info.system_libs = ["m"] diff --git a/recipes/duktape/all/test_package/CMakeLists.txt b/recipes/duktape/all/test_package/CMakeLists.txt index 526e8d40c66a27..e6adea9e794dde 100644 --- a/recipes/duktape/all/test_package/CMakeLists.txt +++ b/recipes/duktape/all/test_package/CMakeLists.txt @@ -1,9 +1,7 @@ -cmake_minimum_required(VERSION 3.1) - +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(duktape REQUIRED CONFIG) add_executable(${CMAKE_PROJECT_NAME} test_package.c) -target_link_libraries(${CMAKE_PROJECT_NAME} CONAN_PKG::duktape) +target_link_libraries(${CMAKE_PROJECT_NAME} duktape::duktape) diff --git a/recipes/duktape/all/test_package/conanfile.py b/recipes/duktape/all/test_package/conanfile.py index ca9da956709115..ef5d7042163ecc 100644 --- a/recipes/duktape/all/test_package/conanfile.py +++ b/recipes/duktape/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import CMake, ConanFile, tools - class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - self.run(os.path.join("bin", "test_package"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/duktape/all/test_v1_package/CMakeLists.txt b/recipes/duktape/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/duktape/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/duktape/all/test_v1_package/conanfile.py b/recipes/duktape/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..d47b5097e761e7 --- /dev/null +++ b/recipes/duktape/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os + +from conans import CMake, ConanFile, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "test_package"), run_environment=True) From 1c06fbdc6cf1dfb08664e56168fa3ac988f40410 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Tue, 22 Aug 2023 10:42:25 -0700 Subject: [PATCH 0370/1140] (#19280) lyra: clean up package_info & old versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * lyra: clean up package_info * lyra: clean up old versions * Update recipes/lyra/all/conanfile.py * Keep a few more minor versions around --------- Co-authored-by: Rubén Rincón Blanco --- recipes/lyra/all/conandata.yml | 36 +++++++------------ recipes/lyra/all/conanfile.py | 2 +- .../lyra/all/test_v1_package/CMakeLists.txt | 11 ------ recipes/lyra/all/test_v1_package/conanfile.py | 17 --------- .../lyra/all/test_v1_package/test_package.cpp | 6 ---- recipes/lyra/config.yml | 16 +++------ 6 files changed, 17 insertions(+), 71 deletions(-) delete mode 100644 recipes/lyra/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/lyra/all/test_v1_package/conanfile.py delete mode 100644 recipes/lyra/all/test_v1_package/test_package.cpp diff --git a/recipes/lyra/all/conandata.yml b/recipes/lyra/all/conandata.yml index f6627e78699fe4..8d693ef2d527dd 100644 --- a/recipes/lyra/all/conandata.yml +++ b/recipes/lyra/all/conandata.yml @@ -1,28 +1,16 @@ sources: - "1.0.0": - sha256: ede5446cdd2b74a8cbaa12b998e820d0a1489574649bd76e7e67e69cb841ae22 - url: https://github.com/bfgroup/Lyra/archive/lyra-1.0.tar.gz - "1.1.0": - sha256: c2d70a926f698fb7decb99c7215bb55ab770100f9574c290998bf91416bd8217 - url: https://github.com/bfgroup/Lyra/archive/1.1.tar.gz - "1.2.0": - sha256: 3134fb6d170ba78d139068232b12ca9948082fafc54a3373193c8b8d6e760cd9 - url: https://github.com/bfgroup/Lyra/archive/1.2.tar.gz - "1.3.0": - sha256: 1e9757b850d1afc14413ceb9eb47af5693f6f03a0f1231617fac39df8534db2b - url: https://github.com/bfgroup/Lyra/archive/1.3.tar.gz - "1.4.0": - sha256: 86cc0c4978312582393e196d534011a1f186db9e3e09ba34fd250c2a59ebf814 - url: https://github.com/bfgroup/Lyra/archive/1.4.tar.gz - "1.5.0": - sha256: 5a251ba8c1082875a6655cdcd11c3a7771cd9c40011f1b0e5ac8636054f27dfd - url: https://github.com/bfgroup/Lyra/archive/1.5.tar.gz - "1.5.1": - sha256: 11ccdfc6f776b9a2ebe987d9b4e492981f88f3642546fd1c2e1115741863cae0 - url: https://github.com/bfgroup/Lyra/archive/1.5.1.tar.gz - "1.6.0": - sha256: 919e92a9c02fea3f365a3a7bdccd8b306311a28a7f2044dac8e7651106d7b644 - url: https://github.com/bfgroup/Lyra/archive/1.6.tar.gz "1.6.1": sha256: a93f247ed89eba11ca36eb24c4f8ba7be636bf24e74aaaa8e1066e0954bec7e3 url: https://github.com/bfgroup/Lyra/archive/1.6.1.tar.gz + "1.6.0": + sha256: 919e92a9c02fea3f365a3a7bdccd8b306311a28a7f2044dac8e7651106d7b644 + url: https://github.com/bfgroup/Lyra/archive/1.6.tar.gz + "1.5.1": + sha256: 11ccdfc6f776b9a2ebe987d9b4e492981f88f3642546fd1c2e1115741863cae0 + url: https://github.com/bfgroup/Lyra/archive/1.5.1.tar.gz + "1.4.0": + sha256: 86cc0c4978312582393e196d534011a1f186db9e3e09ba34fd250c2a59ebf814 + url: https://github.com/bfgroup/Lyra/archive/1.4.tar.gz + "1.3.0": + sha256: 1e9757b850d1afc14413ceb9eb47af5693f6f03a0f1231617fac39df8534db2b + url: https://github.com/bfgroup/Lyra/archive/1.3.tar.gz diff --git a/recipes/lyra/all/conanfile.py b/recipes/lyra/all/conanfile.py index f549011151d40e..676ec9b46357ae 100644 --- a/recipes/lyra/all/conanfile.py +++ b/recipes/lyra/all/conanfile.py @@ -47,7 +47,6 @@ def package(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "lyra") self.cpp_info.set_property("cmake_target_name", "bfg::lyra") - # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.components["_lyra"].set_property( "cmake_target_name", "bfg::lyra") @@ -58,3 +57,4 @@ def package_info(self): self.cpp_info.components["_lyra"].names["cmake_find_package"] = "lyra" self.cpp_info.components["_lyra"].names["cmake_find_package_multi"] = "lyra" self.cpp_info.components["_lyra"].libdirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/lyra/all/test_v1_package/CMakeLists.txt b/recipes/lyra/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index b200e21129c408..00000000000000 --- a/recipes/lyra/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,11 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(lyra REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} bfg::lyra) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/lyra/all/test_v1_package/conanfile.py b/recipes/lyra/all/test_v1_package/conanfile.py deleted file mode 100644 index 49a3a66ea5bad4..00000000000000 --- a/recipes/lyra/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,17 +0,0 @@ -from conans import ConanFile, CMake, tools -import os - - -class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) diff --git a/recipes/lyra/all/test_v1_package/test_package.cpp b/recipes/lyra/all/test_v1_package/test_package.cpp deleted file mode 100644 index 5298875e31c6a1..00000000000000 --- a/recipes/lyra/all/test_v1_package/test_package.cpp +++ /dev/null @@ -1,6 +0,0 @@ -#include - -int main(int argc, const char** argv) -{ - auto cli = lyra::cli_parser(); -} diff --git a/recipes/lyra/config.yml b/recipes/lyra/config.yml index 425271e9a388e1..839c2a460a6e7d 100644 --- a/recipes/lyra/config.yml +++ b/recipes/lyra/config.yml @@ -1,19 +1,11 @@ versions: - "1.0.0": - folder: all - "1.1.0": - folder: all - "1.2.0": - folder: all - "1.3.0": - folder: all - "1.4.0": + "1.6.1": folder: all - "1.5.0": + "1.6.0": folder: all "1.5.1": folder: all - "1.6.0": + "1.4.0": folder: all - "1.6.1": + "1.3.0": folder: all From a80eba1b1c125aaa3b81d660a933da2765e0e061 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Tue, 22 Aug 2023 10:55:21 -0700 Subject: [PATCH 0371/1140] (#19283) spdlog: make sure libdirs is empty when header_only=True --- recipes/spdlog/all/conanfile.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/recipes/spdlog/all/conanfile.py b/recipes/spdlog/all/conanfile.py index f2653d49db0738..8b194e1f8f481a 100644 --- a/recipes/spdlog/all/conanfile.py +++ b/recipes/spdlog/all/conanfile.py @@ -142,7 +142,9 @@ def package_info(self): self.cpp_info.components["libspdlog"].defines.append("SPDLOG_FMT_EXTERNAL") self.cpp_info.components["libspdlog"].requires = ["fmt::fmt"] - if not self.options.header_only: + if self.options.header_only: + self.cpp_info.components["libspdlog"].libdirs = [] + else: suffix = "d" if self.settings.build_type == "Debug" else "" self.cpp_info.components["libspdlog"].libs = [f"spdlog{suffix}"] self.cpp_info.components["libspdlog"].defines.append("SPDLOG_COMPILED_LIB") From e29a9253e65efe9d598c2b3336048a0f02fc04a7 Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Tue, 22 Aug 2023 20:55:01 +0200 Subject: [PATCH 0372/1140] (#19290) [OGDF] enable shared build on Windows * [OGDF] enable shared build on Windows * Drop unused imports --- recipes/ogdf/all/conanfile.py | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/recipes/ogdf/all/conanfile.py b/recipes/ogdf/all/conanfile.py index e47d024478deba..84c6c4df651b53 100644 --- a/recipes/ogdf/all/conanfile.py +++ b/recipes/ogdf/all/conanfile.py @@ -1,9 +1,7 @@ from conan import ConanFile from conan.tools.apple import fix_apple_shared_install_name from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.errors import ConanInvalidConfiguration from conan.tools.files import copy, get, replace_in_file, rmdir -from conan.tools.microsoft import is_msvc from os.path import join required_conan_version = ">=1.53.0" @@ -26,10 +24,6 @@ class OGDFConan(ConanFile): "fPIC": True, } - def validate(self): - if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -85,12 +79,13 @@ def package(self): copy(self, pattern="LICENSE*.txt", src=self.source_folder, dst=join(self.package_folder, "licenses")) copy(self, pattern="*.h", src=join(self.source_folder, "include"), dst=join(self.package_folder, "include")) copy(self, pattern="*.h", src=join(self.build_folder, "include"), dst=join(self.package_folder, "include")) + copy(self, pattern="*.lib", src=self.build_folder, dst=join(self.package_folder, "lib"), keep_path=False) if self.options.shared: copy(self, pattern="*.so*", src=self.build_folder, dst=join(self.package_folder, "lib")) copy(self, pattern="*.dylib*", src=self.build_folder, dst=join(self.package_folder, "lib")) + copy(self, pattern="*.dll", src=self.build_folder, dst=join(self.package_folder, "bin"), keep_path=False) else: copy(self, pattern="*.a", src=self.build_folder, dst=join(self.package_folder, "lib")) - copy(self, pattern="*.lib", src=self.build_folder, dst=join(self.package_folder, "lib"), keep_path=False) fix_apple_shared_install_name(self) def package_info(self): From 57a5c1c55dd4047267f9cb57e71e3e774b456fdf Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 22 Aug 2023 22:31:02 +0300 Subject: [PATCH 0373/1140] (#19322) pupnp: fix invalid use of self.options[] self.options[] returns a `PackageOptions` object instead of a `PackageOption` one like attribute access or .get_safe() does. --- recipes/pupnp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pupnp/all/conanfile.py b/recipes/pupnp/all/conanfile.py index b3ee88419c46cf..ec9c1261d9bacf 100644 --- a/recipes/pupnp/all/conanfile.py +++ b/recipes/pupnp/all/conanfile.py @@ -96,7 +96,7 @@ def generate(self): features["samples"] = False features["blocking_tcp_connections"] = self.options["blocking-tcp"] for opt in ("ipv6", "reuseaddr", "webserver", "client", "device", "largefile", "tools", "debug"): - features[opt] = self.options[opt] + features[opt] = self.options.get_safe(opt) for feature, enabled in features.items(): what = "enable" if enabled else "disable" tc.configure_args.append(f"--{what}-{feature}") From acd1a15c65d2a1807d17bdd58754027a63994e18 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 05:36:30 +0900 Subject: [PATCH 0374/1140] (#19328) drogon: add version 1.8.5, update dependencies MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * drogon: add version 1.8.5, update dependencies * Update recipes/drogon/all/conandata.yml --------- Co-authored-by: Rubén Rincón Blanco --- recipes/drogon/all/conandata.yml | 10 +++ recipes/drogon/all/conanfile.py | 10 +-- .../1.8.5-0001-remove-shared-libs.patch | 12 ++++ .../1.8.5-0002-find-cci-packages.patch | 71 +++++++++++++++++++ recipes/drogon/config.yml | 2 + 5 files changed, 100 insertions(+), 5 deletions(-) create mode 100644 recipes/drogon/all/patches/1.8.5-0001-remove-shared-libs.patch create mode 100644 recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch diff --git a/recipes/drogon/all/conandata.yml b/recipes/drogon/all/conandata.yml index dd03c6b133f928..5ff1403cfce784 100644 --- a/recipes/drogon/all/conandata.yml +++ b/recipes/drogon/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.5": + url: "https://github.com/drogonframework/drogon/archive/v1.8.5.tar.gz" + sha256: "9469f99408c114bc1e89945a3a8dab4640ea6d8cb06e7d42f06c1dfda3f71d2a" "1.8.4": url: "https://github.com/drogonframework/drogon/archive/v1.8.4.tar.gz" sha256: "6f2f59ead0f0c37b0aac4bc889cbaedf3c2540f3020e892596c72f0a4d887a18" @@ -15,6 +18,13 @@ sources: url: "https://github.com/drogonframework/drogon/archive/refs/tags/v1.7.5.tar.gz" sha256: "e2af7c55dcabafef16f26f5b3242692f5a2b54c19b7b626840bf9132d24766f6" patches: + "1.8.5": + - patch_file: "patches/1.8.5-0001-remove-shared-libs.patch" + patch_description: "remove shared libs option" + patch_type: "conan" + - patch_file: "patches/1.8.5-0002-find-cci-packages.patch" + patch_description: "Fix jsoncpp cmake target name" + patch_type: "conan" "1.8.4": - patch_file: "patches/1.8.4-0001-remove-shared-libs.patch" patch_description: "remove shared libs option" diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index 0b84047ab4ed5f..033ced85d21352 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -108,7 +108,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} requires boost on C++14") def requirements(self): - self.requires("trantor/1.5.11", transitive_headers=True, transitive_libs=True) + self.requires("trantor/1.5.12", transitive_headers=True, transitive_libs=True) self.requires("jsoncpp/1.9.5", transitive_headers=True, transitive_libs=True) self.requires("openssl/[>=1.1 <4]") self.requires("zlib/1.2.13") @@ -117,17 +117,17 @@ def requirements(self): if self.options.with_profile: self.requires("coz/cci.20210322") if self.options.with_boost: - self.requires("boost/1.82.0", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) if self.options.with_brotli: self.requires("brotli/1.0.9") if self.options.get_safe("with_postgres"): - self.requires("libpq/14.7") + self.requires("libpq/15.4") if self.options.get_safe("with_mysql"): - self.requires("libmysqlclient/8.0.31") + self.requires("libmysqlclient/8.1.0") if self.options.get_safe("with_sqlite"): self.requires("sqlite3/3.42.0") if self.options.get_safe("with_redis"): - self.requires("hiredis/1.1.0") + self.requires("hiredis/1.2.0") if self.options.with_yaml_cpp: self.requires("yaml-cpp/0.7.0") diff --git a/recipes/drogon/all/patches/1.8.5-0001-remove-shared-libs.patch b/recipes/drogon/all/patches/1.8.5-0001-remove-shared-libs.patch new file mode 100644 index 00000000000000..9920eee5341394 --- /dev/null +++ b/recipes/drogon/all/patches/1.8.5-0001-remove-shared-libs.patch @@ -0,0 +1,12 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index db95642..e3e7fcf 100755 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -8,7 +8,6 @@ option(BUILD_CTL "Build drogon_ctl" ON) + option(BUILD_EXAMPLES "Build examples" ON) + option(BUILD_ORM "Build orm" ON) + option(COZ_PROFILING "Use coz for profiling" OFF) +-option(BUILD_SHARED_LIBS "Build drogon as a shared lib" OFF) + option(BUILD_DOC "Build Doxygen documentation" OFF) + option(BUILD_BROTLI "Build Brotli" ON) + option(BUILD_YAML_CONFIG "Build yaml config" ON) diff --git a/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch b/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch new file mode 100644 index 00000000000000..c0d5c051d80a78 --- /dev/null +++ b/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch @@ -0,0 +1,71 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e3e7fcf..b82cb66 100755 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -198,9 +198,9 @@ else() + endif() + + # jsoncpp +-find_package(Jsoncpp REQUIRED) +-target_link_libraries(${PROJECT_NAME} PUBLIC Jsoncpp_lib) +-list(APPEND INCLUDE_DIRS_FOR_DYNAMIC_VIEW ${JSONCPP_INCLUDE_DIRS}) ++find_package(jsoncpp REQUIRED) ++target_link_libraries(${PROJECT_NAME} PUBLIC jsoncpp_lib) ++list(APPEND INCLUDE_DIRS_FOR_DYNAMIC_VIEW ${jsoncpp_INCLUDE_DIRS}) + + # yamlcpp + if(BUILD_YAML_CONFIG) +@@ -217,7 +217,7 @@ if(BUILD_YAML_CONFIG) + endif() + else() + message(STATUS "yaml-cpp found ") +- target_link_libraries(${PROJECT_NAME} PUBLIC ${YAML_CPP_LIBRARIES}) ++ target_link_libraries(${PROJECT_NAME} PUBLIC yaml-cpp) + target_compile_definitions(${PROJECT_NAME} PUBLIC HAS_YAML_CPP) + endif() + else() +@@ -442,7 +442,7 @@ if (BUILD_SQLITE) + find_package(SQLite3 QUIET) + find_package(unofficial-sqlite3 QUIET) + if (SQLite3_FOUND) +- target_link_libraries(${PROJECT_NAME} PRIVATE SQLite3_lib) ++ target_link_libraries(${PROJECT_NAME} PRIVATE SQLite::SQLite3) + set(DROGON_FOUND_SQLite3 TRUE) + elseif (unofficial-sqlite3_FOUND) + target_link_libraries(${PROJECT_NAME} PRIVATE unofficial::sqlite3::sqlite3) +@@ -465,10 +465,10 @@ if (BUILD_SQLITE) + endif (BUILD_SQLITE) + + if (BUILD_REDIS) +- find_package(Hiredis) +- if (Hiredis_FOUND) ++ find_package(hiredis) ++ if (hiredis_FOUND) + add_definitions(-DUSE_REDIS) +- target_link_libraries(${PROJECT_NAME} PRIVATE Hiredis_lib) ++ target_link_libraries(${PROJECT_NAME} PRIVATE hiredis::hiredis) + set(DROGON_SOURCES + ${DROGON_SOURCES} + nosql_lib/redis/src/RedisClientImpl.cc +@@ -488,10 +488,10 @@ if (BUILD_REDIS) + nosql_lib/redis/src/SubscribeContext.h + nosql_lib/redis/src/RedisSubscriberImpl.h) + +- endif (Hiredis_FOUND) ++ endif () + endif (BUILD_REDIS) + +-if (NOT Hiredis_FOUND) ++if (NOT hiredis_FOUND) + set(DROGON_SOURCES + ${DROGON_SOURCES} + lib/src/RedisClientSkipped.cc +@@ -500,7 +500,7 @@ if (NOT Hiredis_FOUND) + set(private_headers + ${private_headers} + lib/src/RedisClientManager.h) +-endif (NOT Hiredis_FOUND) ++endif () + + if (BUILD_TESTING) + add_subdirectory(nosql_lib/redis/tests) diff --git a/recipes/drogon/config.yml b/recipes/drogon/config.yml index 7b7f0bad90e217..bf708bafce8a97 100644 --- a/recipes/drogon/config.yml +++ b/recipes/drogon/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.5": + folder: "all" "1.8.4": folder: "all" "1.8.3": From f7030b437a9cd0f315eb2df1e5bcb63deed9e8ae Mon Sep 17 00:00:00 2001 From: fcorso2016 <35567462+fcorso2016@users.noreply.github.com> Date: Tue, 22 Aug 2023 17:26:43 -0400 Subject: [PATCH 0375/1140] (#18391) Fix issue with building shared on windows MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Fix issue with building shared on windows * Properly disable static registration * Make disabling static registration an option * Update recipes/onnxruntime/all/conanfile.py Co-authored-by: Pau Farré * Update recipes/onnxruntime/all/conanfile.py Co-authored-by: Pau Farré * Update recipes/onnxruntime/all/conanfile.py Co-authored-by: Pau Farré --------- Co-authored-by: Pau Farré --- recipes/onnxruntime/all/conanfile.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/onnxruntime/all/conanfile.py b/recipes/onnxruntime/all/conanfile.py index d9a55a421eb6f4..c69e32a34aa82f 100644 --- a/recipes/onnxruntime/all/conanfile.py +++ b/recipes/onnxruntime/all/conanfile.py @@ -119,7 +119,8 @@ def generate(self): # disable downloading dependencies to ensure conan ones are used tc.variables["FETCHCONTENT_FULLY_DISCONNECTED"] = True if self.version >= Version("1.15.0") and self.options.shared: - tc.variables["Python_EXECUTABLE"] = sys.executable + # Need to replace windows path seperators with linux path seperators to keep CMake from crashing + tc.variables["Python_EXECUTABLE"] = sys.executable.replace("\\", "/") tc.variables["onnxruntime_BUILD_SHARED_LIB"] = self.options.shared tc.variables["onnxruntime_USE_FULL_PROTOBUF"] = not self.dependencies["protobuf"].options.lite From b2bb5da964f3e4c517f8bf56b1ee26711dc3e322 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 07:13:39 +0900 Subject: [PATCH 0376/1140] (#19331) sophus: update fmt/10.1.0, delete with_fmt in 1.0.0 --- recipes/sophus/all/conanfile.py | 32 +++++++++++++++++--------------- 1 file changed, 17 insertions(+), 15 deletions(-) diff --git a/recipes/sophus/all/conanfile.py b/recipes/sophus/all/conanfile.py index 7fa9bd18760cf6..ef703f320333fa 100644 --- a/recipes/sophus/all/conanfile.py +++ b/recipes/sophus/all/conanfile.py @@ -10,11 +10,10 @@ class SophusConan(ConanFile): name = "sophus" description = "C++ implementation of Lie Groups using Eigen." - topics = ("eigen", "numerical", "math") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://strasdat.github.io/Sophus/" - license = "MIT" - no_copy_source = True + topics = ("eigen", "numerical", "math", "header-only") package_type = "header-library" settings = "os", "arch", "compiler", "build_type" options = { @@ -23,23 +22,28 @@ class SophusConan(ConanFile): default_options = { "with_fmt": True, } + no_copy_source = True + + def configure(self): + if Version(self.version) < "1.22.4": + del self.options.with_fmt + + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): self.requires("eigen/3.4.0", transitive_headers=True) - if self.options.with_fmt and Version(self.version) >= Version("1.22.10"): - self.requires("fmt/9.1.0", transitive_headers=True) - elif self.options.with_fmt and Version(self.version) >= Version("1.22.4"): - self.requires("fmt/8.1.1", transitive_headers=True) + if self.options.get_safe("with_fmt"): + if Version(self.version) >= "1.22.10": + self.requires("fmt/10.1.0", transitive_headers=True) + else: + self.requires("fmt/8.1.1", transitive_headers=True) def package_id(self): self.info.clear() - def layout(self): - basic_layout(self, src_folder="src") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, "LICENSE.txt", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) @@ -51,10 +55,8 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "Sophus::Sophus") self.cpp_info.set_property("pkg_config_name", "sophus") self.cpp_info.bindirs = [] - self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] - if not self.options.with_fmt: + if self.options.get_safe("with_fmt") == False: self.cpp_info.defines.append("SOPHUS_USE_BASIC_LOGGING=1") # TODO: to remove in conan v2 once cmake_find_package* generator removed From c8a640996a5589f883de0c792abca10de837534c Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Wed, 23 Aug 2023 00:50:03 +0200 Subject: [PATCH 0377/1140] (#19333) [rtmidi] Add patch descriptions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/rtmidi/all/conandata.yml | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/recipes/rtmidi/all/conandata.yml b/recipes/rtmidi/all/conandata.yml index 9413bb8e982462..7f688e03dcce49 100644 --- a/recipes/rtmidi/all/conandata.yml +++ b/recipes/rtmidi/all/conandata.yml @@ -11,7 +11,14 @@ sources: patches: "4.0.0": - patch_file: "patches/4.0.0-0001-add-a-separate-licence-file-0b5d67c.patch" + patch_description: "Add a separate LICENCE file" + patch_source: "https://github.com/thestk/rtmidi/commit/0b5d67c" + patch_type: "conan" - patch_file: "patches/4.0.0-0002-rtmidiconfig-install-location-da51f21.patch" + patch_description: "Install rtmidiconfig in the correct location" + patch_source: "https://github.com/conan-io/conan-center-index/issues/252" + patch_type: "conan" - patch_file: "patches/4.0.0-0003-relocatable-macos.patch" patch_description: "Relocatable shared lib on macOS" + patch_source: "https://github.com/thestk/rtmidi/pull/211" patch_type: "conan" From 72cbd4efacab4439ae603ae4523cb907506fcadd Mon Sep 17 00:00:00 2001 From: igormironchik Date: Wed, 23 Aug 2023 02:31:55 +0300 Subject: [PATCH 0378/1140] (#19337) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index b2befced4887a1..00fa1030957d57 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.11": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.11.tar.gz" + sha256: "990979474bcbb924efb1c046581589e11889d502e5ad24b9779c131c4f3d9941" "2.0.10": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.10.tar.gz" sha256: "efcb7c97999ce2d78aba67041a61dda45feb54113e5b21851b0532fdcbc460a8" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 20cb1b119cc183..e8eabfb453af93 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.11": + folder: all "2.0.10": folder: all "2.0.9": From 89d182643244d1a9ffe8bc89d51038111d181aec Mon Sep 17 00:00:00 2001 From: krabbstek Date: Wed, 23 Aug 2023 02:18:30 +0200 Subject: [PATCH 0379/1140] (#19343) Added SDL version 2.28.2 --- recipes/sdl/all/conandata.yml | 3 +++ recipes/sdl/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sdl/all/conandata.yml b/recipes/sdl/all/conandata.yml index 9aefd688061541..e6726e853f758a 100644 --- a/recipes/sdl/all/conandata.yml +++ b/recipes/sdl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.28.2": + url: "https://www.libsdl.org/release/SDL2-2.28.2.tar.gz" + sha256: "64b1102fa22093515b02ef33dd8739dee1ba57e9dbba6a092942b8bbed1a1c5e" "2.26.5": url: "https://www.libsdl.org/release/SDL2-2.26.5.tar.gz" sha256: "ad8fea3da1be64c83c45b1d363a6b4ba8fd60f5bde3b23ec73855709ec5eabf7" diff --git a/recipes/sdl/config.yml b/recipes/sdl/config.yml index 960f4e5e4f3c04..31a6d05fcb201a 100644 --- a/recipes/sdl/config.yml +++ b/recipes/sdl/config.yml @@ -1,4 +1,6 @@ versions: + "2.28.2": + folder: all "2.26.5": folder: all "2.26.1": From 7d5424036f3d1a1047430ec4c823bf1b8bb71a12 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 09:51:41 +0900 Subject: [PATCH 0380/1140] (#19353) glaze: add version 1.3.6 --- recipes/glaze/all/conandata.yml | 3 +++ recipes/glaze/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index ca57858e477eab..b43003828dbc64 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.6": + url: "https://github.com/stephenberry/glaze/archive/v1.3.6.tar.gz" + sha256: "c339f036a96fef72f9b8542d6a1e2ecb4bd3fa5d3d09a206da5e844765d2b6c3" "1.3.5": url: "https://github.com/stephenberry/glaze/archive/v1.3.5.tar.gz" sha256: "de5d59cb7f31193d45f67f25d8ced1499df50c0d926a1461432b87f2b2368817" diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index ae1392b97f20d9..a37f70afd642ac 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.6": + folder: all "1.3.5": folder: all "1.3.2": From b1c8af235ffdad135793a0ade9f4ab58e73a9af2 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 10:10:55 +0900 Subject: [PATCH 0381/1140] (#19354) trantor: add version 1.5.13 --- recipes/trantor/all/conandata.yml | 7 +++++++ recipes/trantor/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/trantor/all/conandata.yml b/recipes/trantor/all/conandata.yml index 336360051b220b..2c3c3f7c60a560 100644 --- a/recipes/trantor/all/conandata.yml +++ b/recipes/trantor/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.13": + url: "https://github.com/an-tao/trantor/archive/v1.5.13.tar.gz" + sha256: "36f02302bff3ffa8d2b1bff29f451d7a11d215a43963fb95aa543b555de2f9bf" "1.5.12": url: "https://github.com/an-tao/trantor/archive/v1.5.12.tar.gz" sha256: "3389a2ace83fdc0df7e3e7f9cd9fa9b774f8054889a13a73777c71e2d8e2f364" @@ -21,6 +24,10 @@ sources: url: "https://github.com/an-tao/trantor/archive/refs/tags/v1.5.5.tar.gz" sha256: "5a549c6efebe7ecba73a944cfba4a9713130704d4ccc82af534a2e108b9a0e71" patches: + "1.5.13": + - patch_file: "patches/1.5.12-0001-disable-werror.patch" + patch_description: "disable -Werror for gcc5" + patch_type: "portability" "1.5.12": - patch_file: "patches/1.5.12-0001-disable-werror.patch" patch_description: "disable -Werror for gcc5" diff --git a/recipes/trantor/config.yml b/recipes/trantor/config.yml index ceb70d24170866..51f47024c02e3c 100644 --- a/recipes/trantor/config.yml +++ b/recipes/trantor/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.13": + folder: "all" "1.5.12": folder: "all" "1.5.11": From d30aabdf32d608da0c940be2e86082fcb6047ec3 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 12:54:10 +0900 Subject: [PATCH 0382/1140] (#19357) simdjson: add version 3.2.3 --- recipes/simdjson/all/conandata.yml | 3 +++ recipes/simdjson/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/simdjson/all/conandata.yml b/recipes/simdjson/all/conandata.yml index 4dd45c1bc80bce..c81b28e0ad2e38 100644 --- a/recipes/simdjson/all/conandata.yml +++ b/recipes/simdjson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.3": + url: "https://github.com/simdjson/simdjson/archive/v3.2.3.tar.gz" + sha256: "ab72701b8560c4f93a5de525657b3bf34094f99a1e63bd9db3195d1bcb90aa09" "3.2.2": url: "https://github.com/simdjson/simdjson/archive/v3.2.2.tar.gz" sha256: "13a702536e051db612cdca82bf8585f2c69d9c6fd156ef291b170f13202c1b4c" diff --git a/recipes/simdjson/config.yml b/recipes/simdjson/config.yml index cda9ed23f089a0..78febe4d556f02 100644 --- a/recipes/simdjson/config.yml +++ b/recipes/simdjson/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.3": + folder: all "3.2.2": folder: all "3.2.1": From e1bb3cd9759e10882bedbbdd7438234fc322798c Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 13:37:52 +0900 Subject: [PATCH 0383/1140] (#19358) cpp-httplib: add version 0.14.0 --- recipes/cpp-httplib/all/conandata.yml | 3 +++ recipes/cpp-httplib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cpp-httplib/all/conandata.yml b/recipes/cpp-httplib/all/conandata.yml index 448d3a594468dc..cf312a0b54c1d0 100644 --- a/recipes/cpp-httplib/all/conandata.yml +++ b/recipes/cpp-httplib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.14.0": + url: "https://github.com/yhirose/cpp-httplib/archive/v0.14.0.tar.gz" + sha256: "3a92248ef8cf2c32ad07f910b8e3052ff2427022b2adb871cf326fb620d2438e" "0.13.3": url: "https://github.com/yhirose/cpp-httplib/archive/v0.13.3.tar.gz" sha256: "2a4503f9f2015f6878baef54cd94b01849cc3ed19dfe95f2c9775655bea8b73f" diff --git a/recipes/cpp-httplib/config.yml b/recipes/cpp-httplib/config.yml index 8e636ccafe3a6d..3a4d3cd3226a9c 100644 --- a/recipes/cpp-httplib/config.yml +++ b/recipes/cpp-httplib/config.yml @@ -1,4 +1,6 @@ versions: + "0.14.0": + folder: all "0.13.3": folder: all "0.13.1": From 3ce53911176ae5973050a490512fd2ac683278b9 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 16:15:49 +0900 Subject: [PATCH 0384/1140] (#19359) drogon: update trantor/1.5.13 --- recipes/drogon/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index 033ced85d21352..fc1a2251f569c1 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -108,7 +108,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} requires boost on C++14") def requirements(self): - self.requires("trantor/1.5.12", transitive_headers=True, transitive_libs=True) + self.requires("trantor/1.5.13", transitive_headers=True, transitive_libs=True) self.requires("jsoncpp/1.9.5", transitive_headers=True, transitive_libs=True) self.requires("openssl/[>=1.1 <4]") self.requires("zlib/1.2.13") From b44aacecdda035222774f4e241610bdedbd31dc2 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 23 Aug 2023 10:03:55 +0200 Subject: [PATCH 0385/1140] (#19360) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 0732b711379141..670a5cceabe103 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -241,6 +241,7 @@ required_for_references: - dirent - discount - djinni-generator +- dlib - dlpack - docopt.cpp - doctest @@ -444,6 +445,7 @@ required_for_references: - iqa - irrxml - iso8601lib +- itk - itlib - ittapi - ixwebsocket @@ -760,6 +762,7 @@ required_for_references: - neargye-semver - netcdf - nettle +- newmat - nextsilicon-cpp-subprocess - nfrechette-acl - ninja @@ -819,6 +822,7 @@ required_for_references: - openmvg - openssl - opensubdiv +- opentdf-client - opentelemetry-cpp - opentelemetry-proto - opentracing-cpp From cf4f29933e574d8dcf5b9616be5940f325be6884 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 23 Aug 2023 12:20:58 +0200 Subject: [PATCH 0386/1140] (#19362) dbus 1.15.8 --- recipes/dbus/1.x.x/conandata.yml | 3 +++ recipes/dbus/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/dbus/1.x.x/conandata.yml b/recipes/dbus/1.x.x/conandata.yml index 3dc58977ca2ea4..04a0982deff4bf 100644 --- a/recipes/dbus/1.x.x/conandata.yml +++ b/recipes/dbus/1.x.x/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.15.8": + url: "https://dbus.freedesktop.org/releases/dbus/dbus-1.15.8.tar.xz" + sha256: "84fc597e6ec82f05dc18a7d12c17046f95bad7be99fc03c15bc254c4701ed204" "1.15.6": url: "https://dbus.freedesktop.org/releases/dbus/dbus-1.15.6.tar.xz" sha256: "f97f5845f9c4a5a1fb3df67dfa9e16b5a3fd545d348d6dc850cb7ccc9942bd8c" diff --git a/recipes/dbus/config.yml b/recipes/dbus/config.yml index 53bb57eb6cadcd..a6d5fb2e5d5f7f 100644 --- a/recipes/dbus/config.yml +++ b/recipes/dbus/config.yml @@ -1,4 +1,6 @@ versions: + "1.15.8": + folder: 1.x.x "1.15.6": folder: 1.x.x "1.15.2": From 8f6a100c7f292bcbb9e47cbb6c65e4395055a654 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Wed, 23 Aug 2023 04:18:18 -0700 Subject: [PATCH 0387/1140] (#19348) date: make sure libdirs is empty when `header-only=True` --- recipes/date/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/date/all/conanfile.py b/recipes/date/all/conanfile.py index 74e5999eba368b..16a2a092edd68d 100644 --- a/recipes/date/all/conanfile.py +++ b/recipes/date/all/conanfile.py @@ -138,3 +138,4 @@ def package_info(self): self.cpp_info.components["date-tz"].defines.extend(defines) else: self.cpp_info.defines.append("DATE_HEADER_ONLY") + self.cpp_info.libdirs = [] From cc5f14bd4f5e76d07665c369786d7260335d0c51 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Wed, 23 Aug 2023 13:49:30 +0200 Subject: [PATCH 0388/1140] (#18933) caf: add version 0.19.2 * caf: add version 0.19.2 * caf: fix build for gcc 13 only necessary caf version < 0.19 * caf: test_v1_package no longer required * add version 0.19.2 to config.yml * Revert "caf: test_v1_package no longer required" This reverts commit 27bf600a3234c7f0fe754c9e5f2e63dbca355225. --- recipes/caf/all/conandata.yml | 24 +++++++++++++++++++ recipes/caf/all/conanfile.py | 6 ++++- .../all/patches/0001-fix-gcc-13-include.patch | 21 ++++++++++++++++ recipes/caf/config.yml | 2 ++ 4 files changed, 52 insertions(+), 1 deletion(-) create mode 100644 recipes/caf/all/patches/0001-fix-gcc-13-include.patch diff --git a/recipes/caf/all/conandata.yml b/recipes/caf/all/conandata.yml index 71354ad6bae80a..260be0caef66de 100644 --- a/recipes/caf/all/conandata.yml +++ b/recipes/caf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.19.2": + url: "https://github.com/actor-framework/actor-framework/archive/0.19.2.tar.gz" + sha256: "aa3fcc494424e0e20b177125458a6a6ed39c751a3d3d5193054e88bdf8a146d2" "0.18.6": url: "https://github.com/actor-framework/actor-framework/archive/0.18.6.tar.gz" sha256: "c2ead63a0322d992fea8813a7f7d15b4d16cbb8bbe026722f2616a79109b91cc" @@ -11,3 +14,24 @@ sources: "0.18.0": url: "https://github.com/actor-framework/actor-framework/archive/0.18.0.tar.gz" sha256: "df765fa78861e67d44e2587c0ac0c1c662d8c93fe5ffc8757f552fc7ac15941f" +patches: + "0.18.6": + - patch_file: "patches/0001-fix-gcc-13-include.patch" + patch_description: "add missing include to support gcc 13" + patch_type: "bugfix" + patch_source: "https://github.com/actor-framework/actor-framework/commit/c2ee99c" + "0.18.5": + - patch_file: "patches/0001-fix-gcc-13-include.patch" + patch_description: "add missing include to support gcc 13" + patch_type: "bugfix" + patch_source: "https://github.com/actor-framework/actor-framework/commit/c2ee99c" + "0.18.2": + - patch_file: "patches/0001-fix-gcc-13-include.patch" + patch_description: "add missing include to support gcc 13" + patch_type: "bugfix" + patch_source: "https://github.com/actor-framework/actor-framework/commit/c2ee99c" + "0.18.0": + - patch_file: "patches/0001-fix-gcc-13-include.patch" + patch_description: "add missing include to support gcc 13" + patch_type: "bugfix" + patch_source: "https://github.com/actor-framework/actor-framework/commit/c2ee99c" diff --git a/recipes/caf/all/conanfile.py b/recipes/caf/all/conanfile.py index 7a5cb98c5ded6f..08713d4f8b3b0f 100644 --- a/recipes/caf/all/conanfile.py +++ b/recipes/caf/all/conanfile.py @@ -2,7 +2,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd, valid_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, rmdir +from conan.tools.files import apply_conandata_patches, export_conandata_patches, copy, get, rmdir from conan.tools.scm import Version import os @@ -47,6 +47,9 @@ def _minimum_compilers_version(self): "apple-clang": "10", } + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -97,6 +100,7 @@ def generate(self): deps.generate() def build(self): + apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/caf/all/patches/0001-fix-gcc-13-include.patch b/recipes/caf/all/patches/0001-fix-gcc-13-include.patch new file mode 100644 index 00000000000000..3ad9d6d3ba42fa --- /dev/null +++ b/recipes/caf/all/patches/0001-fix-gcc-13-include.patch @@ -0,0 +1,21 @@ +--- a/libcaf_core/caf/detail/ripemd_160.hpp ++++ b/libcaf_core/caf/detail/ripemd_160.hpp +@@ -42,6 +42,7 @@ + + #include + #include ++#include + + #include "caf/detail/core_export.hpp" + +--- a/libcaf_core/caf/telemetry/metric_type.hpp ++++ b/libcaf_core/caf/telemetry/metric_type.hpp +@@ -4,6 +4,8 @@ + + #pragma once + ++#include ++ + namespace caf::telemetry { + + enum class metric_type : uint8_t { diff --git a/recipes/caf/config.yml b/recipes/caf/config.yml index 1e73f6993a4549..9d2f0ee39c4640 100644 --- a/recipes/caf/config.yml +++ b/recipes/caf/config.yml @@ -1,4 +1,6 @@ versions: + "0.19.2": + folder: all "0.18.6": folder: all "0.18.5": From aee3869b4fad1a371e3268e47a0eeefeb6fc52ab Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Wed, 23 Aug 2023 14:34:20 +0200 Subject: [PATCH 0389/1140] (#19341) aws-c-io: add version 0.13.32 --- recipes/aws-c-io/all/conandata.yml | 3 +++ recipes/aws-c-io/all/conanfile.py | 5 ++++- recipes/aws-c-io/config.yml | 2 ++ 3 files changed, 9 insertions(+), 1 deletion(-) diff --git a/recipes/aws-c-io/all/conandata.yml b/recipes/aws-c-io/all/conandata.yml index 4a9102a6ede26e..0d0d5af78f68c7 100644 --- a/recipes/aws-c-io/all/conandata.yml +++ b/recipes/aws-c-io/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.13.32": + url: "https://github.com/awslabs/aws-c-io/archive/v0.13.32.tar.gz" + sha256: "2a6b18c544d014ca4f55cb96002dbbc1e52a2120541c809fa974cb0838ea72cc" "0.13.4": url: "https://github.com/awslabs/aws-c-io/archive/v0.13.4.tar.gz" sha256: "133bd0aa46caa2041962cd4f6d076209686ce2934af82f86d1a258df4cbdce8b" diff --git a/recipes/aws-c-io/all/conanfile.py b/recipes/aws-c-io/all/conanfile.py index 20a04052e80c52..eaf12a0cfcd8db 100644 --- a/recipes/aws-c-io/all/conanfile.py +++ b/recipes/aws-c-io/all/conanfile.py @@ -45,9 +45,12 @@ def requirements(self): if Version(self.version) <= "0.10.9": self.requires("aws-c-common/0.6.11", transitive_headers=True, transitive_libs=True) self.requires("aws-c-cal/0.5.11") - else: + elif Version(self.version) <= "0.13.4": self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) self.requires("aws-c-cal/0.5.13") + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True, transitive_libs=True) + self.requires("aws-c-cal/0.6.1", transitive_headers=True) if self.settings.os in ["Linux", "FreeBSD", "Android"]: self.requires("s2n/1.3.31") diff --git a/recipes/aws-c-io/config.yml b/recipes/aws-c-io/config.yml index 6dca88e3f05544..febe94b14a0b39 100644 --- a/recipes/aws-c-io/config.yml +++ b/recipes/aws-c-io/config.yml @@ -1,4 +1,6 @@ versions: + "0.13.32": + folder: all "0.13.4": folder: all "0.11.2": From 6b82acd7b519147cf54cd21c27b4492677618915 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 23 Aug 2023 22:43:56 +0900 Subject: [PATCH 0390/1140] (#19355) perfetto: add version 37.0, remove older versions, add package_type * perfetto: add version 37.0, remove older versions, add package_type * remove versions in config.yml --- recipes/perfetto/all/conandata.yml | 34 ++----------------- recipes/perfetto/all/conanfile.py | 10 +++--- ...ging-when-PERFETTO_DISABLE_LOG-activ.patch | 14 -------- ...ging-when-PERFETTO_DISABLE_LOG-activ.patch | 14 -------- ...ging-when-PERFETTO_DISABLE_LOG-activ.patch | 14 -------- ...-MSVC-Fix-narrowing-conversion-error.patch | 13 ------- recipes/perfetto/config.yml | 16 ++------- 7 files changed, 9 insertions(+), 106 deletions(-) delete mode 100644 recipes/perfetto/all/patches/v20.1/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch delete mode 100644 recipes/perfetto/all/patches/v21.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch delete mode 100644 recipes/perfetto/all/patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch delete mode 100644 recipes/perfetto/all/patches/v25.0/0001-MSVC-Fix-narrowing-conversion-error.patch diff --git a/recipes/perfetto/all/conandata.yml b/recipes/perfetto/all/conandata.yml index 9a9ac089dcd8fe..455f1bec30e976 100644 --- a/recipes/perfetto/all/conandata.yml +++ b/recipes/perfetto/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "37.0": + url: "https://github.com/google/perfetto/archive/refs/tags/v37.0.tar.gz" + sha256: "39d7b3635834398828cfd189bd61afb0657ca2a3a08efbfd9866bfbcd440810b" "35.0": url: "https://github.com/google/perfetto/archive/refs/tags/v35.0.tar.gz" sha256: "224b6552e60ad0fc7c1447bdf719ddd9ceceaf2b6773b71541c21df5890f4166" @@ -23,27 +26,6 @@ sources: "26.1": url: "https://github.com/google/perfetto/archive/refs/tags/v26.1.tar.gz" sha256: "cce387e82e2a137fce2eba927f80f20407764b77637a1a92b9b24065a500ce6d" - "25.0": - url: "https://github.com/google/perfetto/archive/refs/tags/v25.0.tar.gz" - sha256: "73a4b895df9222ddb231b8d903099d6da08cd079f27983f540e89156fa88ba67" - "24.2": - url: "https://github.com/google/perfetto/archive/refs/tags/v24.2.tar.gz" - sha256: "b296d0a939e694fd2e73ed6c6418b774b5ef6809ddf60988989416e5cbf90b41" - "23.0": - url: "https://github.com/google/perfetto/archive/refs/tags/v23.0.tar.gz" - sha256: "9d2955736ce9d234e0f5153acfefea8facfa762c9167024902ea98f9010207aa" - "22.1": - url: "https://github.com/google/perfetto/archive/refs/tags/v22.1.tar.gz" - sha256: "013ba743019a1ca04627f7ce8bf424b60ed7f0f57e232eff719ae879be4c90fd" - "22.0": - url: "https://github.com/google/perfetto/archive/refs/tags/v22.0.tar.gz" - sha256: "c62e9059a566136665b0c69e1f9901fc747b1eca813cd59a76e941bc2772340c" - "21.0": - url: "https://github.com/google/perfetto/archive/refs/tags/v21.0.tar.gz" - sha256: "8ce7d7c3dd8a2edd6d37092eb139e11bbf9c7e33a9964bab96c0505def6e1ad4" - "20.1": - url: "https://github.com/google/perfetto/archive/refs/tags/v20.1.tar.gz" - sha256: "d681bb76e2b73e6ba46db53c1502f31f4f16c36cd6e91d4ae839a3b44272f646" patches: "31.0": - patch_file: "patches/v31.0/0001-tracing-fix-compile-on-MSVC.patch" @@ -51,13 +33,3 @@ patches: patch_type: "backport" patch_source: "https://android-review.googlesource.com/c/platform/external/perfetto/+/2355222" sha256: "ad253a9bba3941bd8d1f206422d60eb1c06cb6d75d60eff5b5b8ae0f2ec7e15c" - "25.0": - - patch_file: "patches/v25.0/0001-MSVC-Fix-narrowing-conversion-error.patch" - "22.1": - - patch_file: "patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch" - "22.0": - - patch_file: "patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch" - "21.0": - - patch_file: "patches/v21.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch" - "20.1": - - patch_file: "patches/v20.1/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch" diff --git a/recipes/perfetto/all/conanfile.py b/recipes/perfetto/all/conanfile.py index 44d0edf055cd6e..6c9cecd7c62eff 100644 --- a/recipes/perfetto/all/conanfile.py +++ b/recipes/perfetto/all/conanfile.py @@ -12,11 +12,12 @@ class PerfettoConan(ConanFile): name = "perfetto" + description = "Performance instrumentation and tracing for Android, Linux and Chrome" license = "Apache-2.0" - homepage = "https://perfetto.dev" url = "https://github.com/conan-io/conan-center-index" - description = "Performance instrumentation and tracing for Android, Linux and Chrome" + homepage = "https://perfetto.dev" topics = ("linux", "profiling", "tracing") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -28,7 +29,6 @@ class PerfettoConan(ConanFile): "fPIC": True, "disable_logging": False, } - short_paths = True @property @@ -78,8 +78,7 @@ def loose_lt_semver(v1, v2): ) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) @@ -107,4 +106,3 @@ def package_info(self): self.cpp_info.system_libs.append("ws2_32") if is_msvc(self): self.cpp_info.cxxflags.append("/Zc:__cplusplus") - diff --git a/recipes/perfetto/all/patches/v20.1/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch b/recipes/perfetto/all/patches/v20.1/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch deleted file mode 100644 index 27f4b089cd4fdc..00000000000000 --- a/recipes/perfetto/all/patches/v20.1/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/sdk/perfetto.h b/sdk/perfetto.h -index a362342d0..d5fb9e997 100644 ---- a/sdk/perfetto.h -+++ b/sdk/perfetto.h -@@ -580,7 +580,8 @@ PERFETTO_EXPORT void LogMessage(LogLev, - __LINE__, ##__VA_ARGS__); \ - } while (0) - #elif defined(PERFETTO_DISABLE_LOG) --#define PERFETTO_XLOG(...) ::perfetto::base::ignore_result(__VA_ARGS__) -+#define PERFETTO_XLOG(level, fmt, ...) ::perfetto::base::ignore_result(level, \ -+ fmt, ##__VA_ARGS__) - #else - #define PERFETTO_XLOG(level, fmt, ...) \ - ::perfetto::base::LogMessage(level, ::perfetto::base::Basename(__FILE__), \ diff --git a/recipes/perfetto/all/patches/v21.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch b/recipes/perfetto/all/patches/v21.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch deleted file mode 100644 index 56e86bb66c9e9b..00000000000000 --- a/recipes/perfetto/all/patches/v21.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/sdk/perfetto.h b/sdk/perfetto.h -index 4509cbda5..7cd41d570 100644 ---- a/sdk/perfetto.h -+++ b/sdk/perfetto.h -@@ -622,7 +622,8 @@ inline void MaybeSerializeLastLogsForCrashReporting() {} - __LINE__, ##__VA_ARGS__); \ - } while (0) - #elif defined(PERFETTO_DISABLE_LOG) --#define PERFETTO_XLOG(...) ::perfetto::base::ignore_result(__VA_ARGS__) -+#define PERFETTO_XLOG(level, fmt, ...) ::perfetto::base::ignore_result(level, \ -+ fmt, ##__VA_ARGS__) - #else - #define PERFETTO_XLOG(level, fmt, ...) \ - ::perfetto::base::LogMessage(level, ::perfetto::base::Basename(__FILE__), \ diff --git a/recipes/perfetto/all/patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch b/recipes/perfetto/all/patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch deleted file mode 100644 index 5e4004e7ada011..00000000000000 --- a/recipes/perfetto/all/patches/v22.x/0001-Fix-perfetto-logging-when-PERFETTO_DISABLE_LOG-activ.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/sdk/perfetto.h b/sdk/perfetto.h -index f88ac9728..a242b37a4 100644 ---- a/sdk/perfetto.h -+++ b/sdk/perfetto.h -@@ -623,7 +623,8 @@ inline void MaybeSerializeLastLogsForCrashReporting() {} - __LINE__, ##__VA_ARGS__); \ - } while (0) - #elif defined(PERFETTO_DISABLE_LOG) --#define PERFETTO_XLOG(...) ::perfetto::base::ignore_result(__VA_ARGS__) -+#define PERFETTO_XLOG(level, fmt, ...) ::perfetto::base::ignore_result(level, \ -+ fmt, ##__VA_ARGS__) - #else - #define PERFETTO_XLOG(level, fmt, ...) \ - ::perfetto::base::LogMessage(level, ::perfetto::base::Basename(__FILE__), \ diff --git a/recipes/perfetto/all/patches/v25.0/0001-MSVC-Fix-narrowing-conversion-error.patch b/recipes/perfetto/all/patches/v25.0/0001-MSVC-Fix-narrowing-conversion-error.patch deleted file mode 100644 index d109447e2946e7..00000000000000 --- a/recipes/perfetto/all/patches/v25.0/0001-MSVC-Fix-narrowing-conversion-error.patch +++ /dev/null @@ -1,13 +0,0 @@ -diff --git a/sdk/perfetto.h b/sdk/perfetto.h -index 677e0e2..df0de12 100644 ---- a/sdk/perfetto.h -+++ b/sdk/perfetto.h -@@ -16140,7 +16140,7 @@ template <> - struct TraceTimestampTraits { - static inline TraceTimestamp ConvertTimestampToTraceTimeNs( - const uint64_t& timestamp) { -- return {internal::TrackEventInternal::GetClockId(), timestamp}; -+ return {static_cast(internal::TrackEventInternal::GetClockId()), timestamp}; - } - }; - diff --git a/recipes/perfetto/config.yml b/recipes/perfetto/config.yml index bd944a09e558ee..aecfcbd517f2d2 100644 --- a/recipes/perfetto/config.yml +++ b/recipes/perfetto/config.yml @@ -1,4 +1,6 @@ versions: + "37.0": + folder: all "35.0": folder: all "34.0": @@ -15,17 +17,3 @@ versions: folder: all "26.1": folder: all - "25.0": - folder: all - "24.2": - folder: all - "23.0": - folder: all - "22.1": - folder: all - "22.0": - folder: all - "21.0": - folder: all - "20.1": - folder: all From ae4e9b06c9d94e8f42e570fd00c1b3b17a692a2a Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 24 Aug 2023 00:22:12 +0900 Subject: [PATCH 0391/1140] (#19356) cimg: add version 3.2.6, fix requires --- recipes/cimg/all/conandata.yml | 3 +++ recipes/cimg/all/conanfile.py | 10 ++-------- recipes/cimg/config.yml | 2 ++ 3 files changed, 7 insertions(+), 8 deletions(-) diff --git a/recipes/cimg/all/conandata.yml b/recipes/cimg/all/conandata.yml index c4ba41f9e21b54..7139132fb19a98 100644 --- a/recipes/cimg/all/conandata.yml +++ b/recipes/cimg/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.6": + url: "https://cimg.eu/files/CImg_3.2.6.zip" + sha256: "8da3aa995027231bb18f97bb986e12788ef464b3ab8a34151650bf1217baeda7" "3.2.5": url: "https://cimg.eu/files/CImg_3.2.5.zip" sha256: "3ab9f25cd7e5f7256dde67b4ea78ead05834bee0db9160c89668a388ba141cd9" diff --git a/recipes/cimg/all/conanfile.py b/recipes/cimg/all/conanfile.py index cbed93e0b8d513..01ef66f480f653 100644 --- a/recipes/cimg/all/conanfile.py +++ b/recipes/cimg/all/conanfile.py @@ -68,17 +68,11 @@ def requirements(self): if self.options.enable_jpeg: self.requires("libjpeg/9e") if self.options.enable_openexr: - if self.options.enable_opencv: - self.requires("openexr/3.1.7") - else: - self.requires("openexr/3.1.7") + self.requires("openexr/3.1.9") if self.options.enable_png: self.requires("libpng/1.6.40") if self.options.enable_tiff: - if self.options.enable_opencv: - self.requires("libtiff/4.5.1") - else: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.5.1") if self.options.enable_ffmpeg: if self.options.enable_opencv: self.requires("ffmpeg/4.4") diff --git a/recipes/cimg/config.yml b/recipes/cimg/config.yml index b39649938fc2eb..a0c4dfee0ab1c7 100644 --- a/recipes/cimg/config.yml +++ b/recipes/cimg/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.6": + folder: all "3.2.5": folder: all "3.2.0": From 861d4c7f737342efcb26e94673db0c5e7be9c468 Mon Sep 17 00:00:00 2001 From: Nicolai Grodzitski Date: Wed, 23 Aug 2023 17:47:51 +0200 Subject: [PATCH 0392/1140] (#18215) [SObjectizer] Add version 5.8.0 and support Conan 2.x * Add SObjectizer 5.8.0 * Refresh for Conan V2 Also use different compiler version requirements for v5.8.0. * FIx typo in test_v1_package * Adding msvc * Use warning properly * Review updates * Remove CMakelists.txt wrapper Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/sobjectizer/all/CMakeLists.txt | 7 -- recipes/sobjectizer/all/conandata.yml | 3 + recipes/sobjectizer/all/conanfile.py | 93 ++++++++++--------- .../all/test_package/CMakeLists.txt | 3 - .../sobjectizer/all/test_package/conanfile.py | 19 +++- .../all/test_v1_package/CMakeLists.txt | 15 +++ .../all/test_v1_package/conanfile.py | 16 ++++ recipes/sobjectizer/config.yml | 2 + 8 files changed, 101 insertions(+), 57 deletions(-) delete mode 100644 recipes/sobjectizer/all/CMakeLists.txt create mode 100644 recipes/sobjectizer/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/sobjectizer/all/test_v1_package/conanfile.py diff --git a/recipes/sobjectizer/all/CMakeLists.txt b/recipes/sobjectizer/all/CMakeLists.txt deleted file mode 100644 index 20ac539cce8621..00000000000000 --- a/recipes/sobjectizer/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.8) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory(source_subfolder/dev/so_5) diff --git a/recipes/sobjectizer/all/conandata.yml b/recipes/sobjectizer/all/conandata.yml index b8c5263a27c95c..6518ae7fc9919b 100644 --- a/recipes/sobjectizer/all/conandata.yml +++ b/recipes/sobjectizer/all/conandata.yml @@ -33,3 +33,6 @@ sources: "5.7.5": url: "https://github.com/Stiffstream/sobjectizer/archive/v.5.7.5.tar.gz" sha256: "282b7c72f6a6ee30b9c08b5339c3e327452903e1b246a163a7c8e57b3e37932f" + "5.8.0": + url: "https://github.com/Stiffstream/sobjectizer/archive/v.5.8.0.tar.gz" + sha256: "de2b4ae0e817a108dae6d6787c79ed84c33bd447842b5fdcb780f6697b4c2d49" diff --git a/recipes/sobjectizer/all/conanfile.py b/recipes/sobjectizer/all/conanfile.py index 6ebed35c1f8308..6dfd80e4c926f7 100644 --- a/recipes/sobjectizer/all/conanfile.py +++ b/recipes/sobjectizer/all/conanfile.py @@ -1,8 +1,12 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout +from conan.tools.files import get, copy, rmdir, collect_libs +from conan.tools.scm import Version import os -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class SobjectizerConan(ConanFile): @@ -27,80 +31,85 @@ class SobjectizerConan(ConanFile): "fPIC": True, } - exports_sources = ["CMakeLists.txt"] - generators = "cmake" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - - def validate(self): - minimal_cpp_standard = "17" - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, minimal_cpp_standard) - minimal_version = { + self.options.rm_safe("fPIC") + + def _compiler_support_lut(self): + if self.version >= Version("5.8.0"): + # Since v5.8.0 requirements to compilers were updated: + return { + "gcc": "10", + "clang": "11", + "apple-clang": "13", + "Visual Studio": "17", + "msvc": "192" + } + + return { "gcc": "7", "clang": "6", "apple-clang": "10", - "Visual Studio": "15" + "Visual Studio": "15", + "msvc": "191" } + + def validate(self): + minimal_cpp_standard = "17" + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, minimal_cpp_standard) + minimal_version = self._compiler_support_lut() + compiler = str(self.settings.compiler) if compiler not in minimal_version: - self.output.warn( + self.output.warning( "%s recipe lacks information about the %s compiler standard version support" % (self.name, compiler)) - self.output.warn( + self.output.warning( "%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) return - version = tools.Version(self.settings.compiler.version) + version = Version(self.settings.compiler.version) if version < minimal_version[compiler]: raise ConanInvalidConfiguration("%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) - def _configure_cmake(self): - if self._cmake: - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["SOBJECTIZER_BUILD_SHARED"] = self.options.shared + tc.variables["SOBJECTIZER_BUILD_STATIC"] = not self.options.shared + tc.variables["SOBJECTIZER_INSTALL"] = True + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0091"] = "NEW" + tc.generate() - self._cmake = CMake(self) - self._cmake.definitions["SOBJECTIZER_BUILD_SHARED"] = self.options.shared - self._cmake.definitions["SOBJECTIZER_BUILD_STATIC"] = not self.options.shared - self._cmake.definitions["SOBJECTIZER_INSTALL"] = True + cmake_deps = CMakeDeps(self) + cmake_deps.generate() - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def layout(self): + cmake_layout(self, src_folder="src") def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, "dev", "so_5")) cmake.build() def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - self.copy("license*", src=self._source_subfolder, dst="licenses", ignore_case=True, keep_path=False) - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): cmake_target = "SharedLib" if self.options.shared else "StaticLib" self.cpp_info.set_property("cmake_file_name", "sobjectizer") self.cpp_info.set_property("cmake_target_name", "sobjectizer::{}".format(cmake_target)) # TODO: back to global scope in conan v2 once cmake_find_package* generators removed - self.cpp_info.components["_sobjectizer"].libs = tools.collect_libs(self) + self.cpp_info.components["_sobjectizer"].libs = collect_libs(self) if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["_sobjectizer"].system_libs = ["pthread", "m"] if not self.options.shared: diff --git a/recipes/sobjectizer/all/test_package/CMakeLists.txt b/recipes/sobjectizer/all/test_package/CMakeLists.txt index 9a72279fda74fb..38c12b1dc72ca7 100644 --- a/recipes/sobjectizer/all/test_package/CMakeLists.txt +++ b/recipes/sobjectizer/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ cmake_minimum_required(VERSION 3.8) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(sobjectizer REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/sobjectizer/all/test_package/conanfile.py b/recipes/sobjectizer/all/test_package/conanfile.py index 38f4483872d47f..a9fb96656f2039 100644 --- a/recipes/sobjectizer/all/test_package/conanfile.py +++ b/recipes/sobjectizer/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/sobjectizer/all/test_v1_package/CMakeLists.txt b/recipes/sobjectizer/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..c960a336839f6a --- /dev/null +++ b/recipes/sobjectizer/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,15 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package CXX) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +find_package(sobjectizer REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +if(TARGET sobjectizer::SharedLib) + target_link_libraries(${PROJECT_NAME} sobjectizer::SharedLib) +else() + target_link_libraries(${PROJECT_NAME} sobjectizer::StaticLib) +endif() diff --git a/recipes/sobjectizer/all/test_v1_package/conanfile.py b/recipes/sobjectizer/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..9b63bd176646ba --- /dev/null +++ b/recipes/sobjectizer/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "test_package"), run_environment=True) diff --git a/recipes/sobjectizer/config.yml b/recipes/sobjectizer/config.yml index 31292d0fc47479..ecd4ce4a44c0ff 100644 --- a/recipes/sobjectizer/config.yml +++ b/recipes/sobjectizer/config.yml @@ -21,3 +21,5 @@ versions: folder: all "5.7.5": folder: all + "5.8.0": + folder: all From 18b52712b13739bc34cafcbebbc7d5caaa0c8516 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 23 Aug 2023 18:51:55 +0200 Subject: [PATCH 0393/1140] (#19364) glib: add version 2.77.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/glib/all/conandata.yml | 3 +++ recipes/glib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glib/all/conandata.yml b/recipes/glib/all/conandata.yml index 861fdaf0233953..0dd31b0d40a5ba 100644 --- a/recipes/glib/all/conandata.yml +++ b/recipes/glib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.77.2": + url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.2.tar.xz" + sha256: "16279739e4d30ec47be3e82909f5aeaaa41a8206bae3bead10a23fb2deff02a6" "2.77.1": url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.1.tar.xz" sha256: "dce8d0c9e916d8c81a64436bd4ee4d6515a52dd3d157c994e1cdb9b3d6300a03" diff --git a/recipes/glib/config.yml b/recipes/glib/config.yml index f86b1571991633..808c4e2fcb441e 100644 --- a/recipes/glib/config.yml +++ b/recipes/glib/config.yml @@ -1,4 +1,6 @@ versions: + "2.77.2": + folder: all "2.77.1": folder: all "2.77.0": From 4adbf0e5da9409b1a34dd3e07f65f42323bcad97 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 24 Aug 2023 17:39:35 +0900 Subject: [PATCH 0394/1140] (#19376) lexbor: add version 2.3.0 --- recipes/lexbor/all/conandata.yml | 3 +++ recipes/lexbor/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/lexbor/all/conandata.yml b/recipes/lexbor/all/conandata.yml index ae25e89b70b284..ea023ab0ff4cf3 100644 --- a/recipes/lexbor/all/conandata.yml +++ b/recipes/lexbor/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.3.0": + url: "https://github.com/lexbor/lexbor/archive/v2.3.0.zip" + sha256: "5ebdaca76715d737ba5ce5cb782c743caabccdf918854c19c1d5a9a3dd5f19e9" "2.2.0": url: "https://github.com/lexbor/lexbor/archive/v2.2.0.zip" sha256: "837d75e253c9dc157e20246984d7357a7288e2bd2a2b53f371ac047fec3b88e9" diff --git a/recipes/lexbor/config.yml b/recipes/lexbor/config.yml index ca654973c95120..1da7c205b6ff26 100644 --- a/recipes/lexbor/config.yml +++ b/recipes/lexbor/config.yml @@ -1,4 +1,6 @@ versions: + "2.3.0": + folder: "all" "2.2.0": folder: "all" "2.1.0": From 92729dbb536cc53c50611f5e825367f502f5092d Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Thu, 24 Aug 2023 02:41:25 -0700 Subject: [PATCH 0395/1140] (#19351) boost: make sure libdirs is empty with header-only=True and used via `boost::boost` target --- recipes/boost/all/conanfile.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/recipes/boost/all/conanfile.py b/recipes/boost/all/conanfile.py index d6c700ab42217f..d24854dcb4b47c 100644 --- a/recipes/boost/all/conanfile.py +++ b/recipes/boost/all/conanfile.py @@ -1491,6 +1491,8 @@ def package_info(self): self.cpp_info.components["_boost_cmake"].set_property("cmake_target_name", "Boost::boost") self.cpp_info.components["_boost_cmake"].names["cmake_find_package"] = "boost" self.cpp_info.components["_boost_cmake"].names["cmake_find_package_multi"] = "boost" + if self.options.header_only: + self.cpp_info.components["_boost_cmake"].libdirs = [] if not self.options.header_only: self.cpp_info.components["_libboost"].requires = ["headers"] From e2aecf90dc48f54ff7b90646a898ff808b0405e3 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Thu, 24 Aug 2023 13:03:42 +0200 Subject: [PATCH 0396/1140] (#19375) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 670a5cceabe103..ff746e7be2df12 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -256,6 +256,7 @@ required_for_references: - drwav - dtl - duckdb +- duktape - eabase - earcut - eastl @@ -314,6 +315,7 @@ required_for_references: - flatbush - flecs - flex +- fltk - fmt - fmtlog - fontconfig @@ -845,6 +847,7 @@ required_for_references: - pbtools - pcapplusplus - pcg-cpp +- pcl - pcre - pcre2 - pdfgen @@ -953,6 +956,7 @@ required_for_references: - rmm - roaring - robin-hood-hashing +- rpclib - rply - rtklib - rtm @@ -1003,6 +1007,7 @@ required_for_references: - sml - snappy - snowhouse +- sobjectizer - soci - sofa - sokol From 3d79d70864cf5fd3b46fcf26df9db113ac8ad7a8 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Thu, 24 Aug 2023 16:49:04 +0300 Subject: [PATCH 0397/1140] (#19383) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 00fa1030957d57..1edae9a58ce1d7 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.12": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.12.tar.gz" + sha256: "07c89e37c624da036008acac88115b5aee6440f9e9f326139f256f34022f9a20" "2.0.11": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.11.tar.gz" sha256: "990979474bcbb924efb1c046581589e11889d502e5ad24b9779c131c4f3d9941" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index e8eabfb453af93..4852bb383cf447 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.12": + folder: all "2.0.11": folder: all "2.0.10": From cb1c70233f261942310025c6c0e33ec6e38d9573 Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Thu, 24 Aug 2023 18:03:25 +0200 Subject: [PATCH 0398/1140] (#18968) rsync/3.2.7: Added package MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * rsync: Added rsync package * Update recipes/rsync/all/conanfile.py * Update recipes/rsync/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/rsync/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/rsync/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/rsync/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/rsync/all/test_package/conanfile.py Co-authored-by: Uilian Ries * Update recipes/rsync/all/conanfile.py Co-authored-by: Uilian Ries * Remove unused import from test package --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Uilian Ries --- recipes/rsync/all/conandata.yml | 4 + recipes/rsync/all/conanfile.py | 114 ++++++++++++++++++++ recipes/rsync/all/test_package/conanfile.py | 17 +++ recipes/rsync/config.yml | 3 + 4 files changed, 138 insertions(+) create mode 100644 recipes/rsync/all/conandata.yml create mode 100644 recipes/rsync/all/conanfile.py create mode 100644 recipes/rsync/all/test_package/conanfile.py create mode 100644 recipes/rsync/config.yml diff --git a/recipes/rsync/all/conandata.yml b/recipes/rsync/all/conandata.yml new file mode 100644 index 00000000000000..a7d6fc86710c87 --- /dev/null +++ b/recipes/rsync/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "3.2.7": + url: "https://download.samba.org/pub/rsync/src/rsync-3.2.7.tar.gz" + sha256: "4e7d9d3f6ed10878c58c5fb724a67dacf4b6aac7340b13e488fb2dc41346f2bb" diff --git a/recipes/rsync/all/conanfile.py b/recipes/rsync/all/conanfile.py new file mode 100644 index 00000000000000..959c1c6253bb0d --- /dev/null +++ b/recipes/rsync/all/conanfile.py @@ -0,0 +1,114 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.gnu import Autotools, AutotoolsToolchain, AutotoolsDeps +from conan.tools.files import copy, get, rmdir +from conan.tools.layout import basic_layout +from conan.tools.apple import is_apple_os +import os + +required_conan_version = ">=1.60.0" + +class RsyncConan(ConanFile): + name = "rsync" + description = "rsync is an open source utility that provides fast incremental file transfer" + topics = ("backup", "transferring", "file-transfer", "ssh", "compression") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://rsync.samba.org/" + license = ("GPL-3.0", "LGPL-3.0") + package_type = "application" + settings = "os", "arch", "compiler", "build_type" + + options = { + "with_zlib": [True, False], + "with_openssl": [True, False], + "with_zstd": [True, False], + "with_xxhash": [True, False], + "with_lz4": [True, False], + "enable_acl": [True, False] + } + default_options = { + "with_zlib": True, + "with_openssl": True, + "with_zstd": True, + "with_xxhash": True, + "with_lz4": True, + "enable_acl": False + } + + def configure(self): + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package_id(self): + del self.info.settings.compiler + + def requirements(self): + if self.options.with_openssl: + self.requires("openssl/[>=1.1 <4]") + + if self.options.with_zlib: + self.requires("zlib/1.2.13") + + if self.options.with_zstd: + self.requires("zstd/1.5.5") + + if self.options.with_lz4: + self.requires("lz4/1.9.2") + + if self.options.with_xxhash: + self.requires("xxhash/0.8.1") + + def validate(self): + if self.settings.os == "Windows": + raise ConanInvalidConfiguration(f"{self.ref} is not supported on Windows.") + + if is_apple_os(self): + raise ConanInvalidConfiguration(f"{self.ref} is not supported on Apple systems.") + + def generate(self): + ad = AutotoolsDeps(self) + ad.generate() + + yes_no = lambda v: "yes" if v else "no" + tc = AutotoolsToolchain(self) + tc.configure_args.extend([ + f"--enable-acl-support={yes_no(self.options.enable_acl)}", + f"--with-included-zlib={yes_no(not self.options.with_zlib)}", + "--disable-openssl" if not self.options.with_openssl else "--enable-openssl", + f"--with-zstd={yes_no(self.options.with_zstd)}", + f"--with-lz4={yes_no(self.options.with_lz4)}", + f"--with-xxhash={yes_no(self.options.with_xxhash)}", + + "--enable-manpages=no", + ]) + + if self.settings.os == "Neutrino": + tc.extra_defines.append("MAKEDEV_TAKES_3_ARGS") + + tc.generate() + + def build(self): + autotools = Autotools(self) + autotools.configure() + autotools.make() + + def package(self): + autotools = Autotools(self) + autotools.install() + + rmdir(self, os.path.join(self.package_folder, "share")) + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses"), ignore_case=True) + + def package_info(self): + self.cpp_info.includedirs = [] + self.cpp_info.libdirs = [] + + # TODO: Remove after dropping Conan 1.x from ConanCenterIndex + bindir = os.path.join(self.package_folder, "bin") + self.runenv_info.prepend_path("PATH", bindir) diff --git a/recipes/rsync/all/test_package/conanfile.py b/recipes/rsync/all/test_package/conanfile.py new file mode 100644 index 00000000000000..92140298fe3402 --- /dev/null +++ b/recipes/rsync/all/test_package/conanfile.py @@ -0,0 +1,17 @@ +from conan import ConanFile +from conan.tools.build import can_run + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def test(self): + if not can_run(self): + return + + self.run("rsync --version", env="conanrun") diff --git a/recipes/rsync/config.yml b/recipes/rsync/config.yml new file mode 100644 index 00000000000000..115b04e9ac7796 --- /dev/null +++ b/recipes/rsync/config.yml @@ -0,0 +1,3 @@ +versions: + "3.2.7": + folder: all From d11dc8ce9da2ac37455be30e3a026c62469286bf Mon Sep 17 00:00:00 2001 From: Fernando Pelliccioni Date: Thu, 24 Aug 2023 19:21:56 +0200 Subject: [PATCH 0399/1140] (#19346) GMP: bump version * bump GMP version * fix * add patch file for 6.3.x * fix patches --- recipes/gmp/all/conandata.yml | 12 ++++++++++-- ...ch => 6.x.x-0001-fix-MSVC-next-prime-error.patch} | 0 recipes/gmp/config.yml | 2 ++ 3 files changed, 12 insertions(+), 2 deletions(-) rename recipes/gmp/all/patches/{6.2.x-0001-fix-MSVC-next-prime-error.patch => 6.x.x-0001-fix-MSVC-next-prime-error.patch} (100%) diff --git a/recipes/gmp/all/conandata.yml b/recipes/gmp/all/conandata.yml index 3c3f2645e9c313..71709fecc31aa7 100644 --- a/recipes/gmp/all/conandata.yml +++ b/recipes/gmp/all/conandata.yml @@ -1,4 +1,9 @@ sources: + "6.3.0": + url: + - "https://ftp.gnu.org/gnu/gmp/gmp-6.3.0.tar.bz2" + - "https://gmplib.org/download/gmp/gmp-6.3.0.tar.bz2" + sha256: "ac28211a7cfb609bae2e2c8d6058d66c8fe96434f740cf6fe2e47b000d1c20cb" "6.2.1": url: - "https://ftp.gnu.org/gnu/gmp/gmp-6.2.1.tar.bz2" @@ -11,12 +16,15 @@ sources: url: "https://gmplib.org/download/gmp/gmp-6.1.2.tar.bz2" sha256: "5275bb04f4863a13516b2f39392ac5e272f5e1bb8057b18aec1c9b79d73d8fb2" patches: + "6.3.0": + - patch_file: "patches/0001-msvc-dumpbin-yasm-wrapper.patch" + - patch_file: "patches/6.x.x-0001-fix-MSVC-next-prime-error.patch" "6.2.1": - patch_file: "patches/0001-msvc-dumpbin-yasm-wrapper.patch" - - patch_file: "patches/6.2.x-0001-fix-MSVC-next-prime-error.patch" + - patch_file: "patches/6.x.x-0001-fix-MSVC-next-prime-error.patch" "6.2.0": - patch_file: "patches/0001-msvc-dumpbin-yasm-wrapper.patch" - - patch_file: "patches/6.2.x-0001-fix-MSVC-next-prime-error.patch" + - patch_file: "patches/6.x.x-0001-fix-MSVC-next-prime-error.patch" "6.1.2": - patch_file: "patches/0001-msvc-dumpbin-yasm-wrapper.patch" - patch_file: "patches/6.1.x-0001-fix-MSVC-next-prime-error.patch" diff --git a/recipes/gmp/all/patches/6.2.x-0001-fix-MSVC-next-prime-error.patch b/recipes/gmp/all/patches/6.x.x-0001-fix-MSVC-next-prime-error.patch similarity index 100% rename from recipes/gmp/all/patches/6.2.x-0001-fix-MSVC-next-prime-error.patch rename to recipes/gmp/all/patches/6.x.x-0001-fix-MSVC-next-prime-error.patch diff --git a/recipes/gmp/config.yml b/recipes/gmp/config.yml index 7beafba5ffe630..4be5637d7da8f0 100644 --- a/recipes/gmp/config.yml +++ b/recipes/gmp/config.yml @@ -1,4 +1,6 @@ versions: + "6.3.0": + folder: all "6.2.1": folder: all "6.2.0": From f4342e54445f68c1a94ce2f3676d6a9570e0845e Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 24 Aug 2023 20:05:10 +0200 Subject: [PATCH 0400/1140] (#19365) qt6: remove multimedia plugins they are legacy from qt5, but never existed in qt6: https://github.com/qt/qtmultimedia/commit/805b10624ced9b97283e94594a5c7db4c10c63c4 https://github.com/qt/qtmultimedia/commit/98148969b112f82d2b49e77950ea5f6d8b37b8b2 https://github.com/qt/qtmultimedia/commit/aa441d63a1ed0843f4632da2d0a97a7b8bb24b43 https://github.com/qt/qtmultimedia/commit/f16dbe174cee73308cae2aae512fe837e07e0f55 https://github.com/qt/qtmultimedia/commit/58e74015c5239f269a1f0a59eabe43e92c47acd5 fixes https://github.com/conan-io/conan-center-index/issues/19146 --- recipes/qt/6.x.x/conanfile.py | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/recipes/qt/6.x.x/conanfile.py b/recipes/qt/6.x.x/conanfile.py index 70ddeb3bf605a4..3edb49f690ce44 100644 --- a/recipes/qt/6.x.x/conanfile.py +++ b/recipes/qt/6.x.x/conanfile.py @@ -1205,24 +1205,8 @@ def _create_plugin(pluginname, libname, plugintype, requires): _create_module("MultimediaWidgets", ["Multimedia", "Widgets", "Gui"]) if self.options.qtdeclarative and qt_quick_enabled: _create_module("MultimediaQuick", ["Multimedia", "Quick"]) - _create_plugin("QM3uPlaylistPlugin", "qtmultimedia_m3u", "playlistformats", []) if self.options.with_gstreamer: - _create_module("MultimediaGstTools", ["Multimedia", "MultimediaWidgets", "Gui", "gst-plugins-base::gst-plugins-base"]) - _create_plugin("QGstreamerAudioDecoderServicePlugin", "gstaudiodecoder", "mediaservice", []) - _create_plugin("QGstreamerCaptureServicePlugin", "gstmediacapture", "mediaservice", []) - _create_plugin("QGstreamerPlayerServicePlugin", "gstmediaplayer", "mediaservice", []) - if self.settings.os == "Linux": - _create_plugin("CameraBinServicePlugin", "gstcamerabin", "mediaservice", []) - _create_plugin("QAlsaPlugin", "qtaudio_alsa", "audio", []) - if self.settings.os == "Windows": - _create_plugin("AudioCaptureServicePlugin", "qtmedia_audioengine", "mediaservice", []) - _create_plugin("DSServicePlugin", "dsengine", "mediaservice", []) - _create_plugin("QWindowsAudioPlugin", "qtaudio_windows", "audio", []) - if self.settings.os == "Macos": - _create_plugin("AudioCaptureServicePlugin", "qtmedia_audioengine", "mediaservice", []) - _create_plugin("AVFMediaPlayerServicePlugin", "qavfmediaplayer", "mediaservice", []) - _create_plugin("AVFServicePlugin", "qavfcamera", "mediaservice", []) - _create_plugin("CoreAudioPlugin", "qtaudio_coreaudio", "audio", []) + _create_plugin("QGstreamerMediaPlugin", "gstreamermediaplugin", "multimedia", ["gst-plugins-base::gst-plugins-base"]) if self.options.get_safe("qtpositioning"): _create_module("Positioning", []) From a38ae8e0bb84b4ed361fa8fa06ddee57f8546c65 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Thu, 24 Aug 2023 21:31:04 +0300 Subject: [PATCH 0401/1140] (#19396) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 1edae9a58ce1d7..a7f8c97edc459e 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.13": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.13.tar.gz" + sha256: "4e6cdcd54c5ce1e1ed9a97bd18ac5aeb7c15bb303193b4261058aef724fe9a41" "2.0.12": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.12.tar.gz" sha256: "07c89e37c624da036008acac88115b5aee6440f9e9f326139f256f34022f9a20" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 4852bb383cf447..3a7084f75ff201 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.13": + folder: all "2.0.12": folder: all "2.0.11": From debe3d293daad963a4c7acb68eec70828f1bcfd2 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 25 Aug 2023 03:48:19 +0900 Subject: [PATCH 0402/1140] (#19395) sqlite3: add version 3.43.0 --- recipes/sqlite3/all/conandata.yml | 3 +++ recipes/sqlite3/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sqlite3/all/conandata.yml b/recipes/sqlite3/all/conandata.yml index efde056fcf092a..7d17c799d5f248 100644 --- a/recipes/sqlite3/all/conandata.yml +++ b/recipes/sqlite3/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.43.0": + url: "https://sqlite.org/2023/sqlite-amalgamation-3430000.zip" + sha256: "bb5849ae4d7129c09d20596379a0b3f7b1ac59cf9998eba5ef283ea9b6c000a5" "3.42.0": url: "https://sqlite.org/2023/sqlite-amalgamation-3420000.zip" sha256: "1cc824d0f5e675829fa37018318fda833ea56f7e9de2b41eddd9f7643b5ec29e" diff --git a/recipes/sqlite3/config.yml b/recipes/sqlite3/config.yml index 50ef72c5285aba..f5a78a2be1eed6 100644 --- a/recipes/sqlite3/config.yml +++ b/recipes/sqlite3/config.yml @@ -1,4 +1,6 @@ versions: + "3.43.0": + folder: all "3.42.0": folder: all "3.41.2": From 6445bc697a77f4dd5b3cc7254b1b7d2d05c98dcd Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 24 Aug 2023 22:19:19 +0200 Subject: [PATCH 0403/1140] (#17117) aws-c-s3: add missing interface definition if shared + modernize more for conan v2 * add AWS_S3_USE_IMPORT_EXPORT interface definition if shared * modernize more * more elegant way to define target for legacy generators * aws-c-common, aws-c-auth & aws-c-io are public dependencies * aws-c-s3: add direct dependency on aws-c-cal * aws-c-s3: fix requirement on aws-c-cal * aws-c-s3: drop older version --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/aws-c-s3/all/conandata.yml | 3 - recipes/aws-c-s3/all/conanfile.py | 83 ++++++++++--------- .../all/test_v1_package/CMakeLists.txt | 8 +- recipes/aws-c-s3/config.yml | 2 - 4 files changed, 47 insertions(+), 49 deletions(-) diff --git a/recipes/aws-c-s3/all/conandata.yml b/recipes/aws-c-s3/all/conandata.yml index af6e82a742aa67..776d2c58fad6ac 100644 --- a/recipes/aws-c-s3/all/conandata.yml +++ b/recipes/aws-c-s3/all/conandata.yml @@ -11,6 +11,3 @@ sources: "0.1.27": url: "https://github.com/awslabs/aws-c-s3/archive/v0.1.27.tar.gz" sha256: "8fccbf967c3b29f0feaa1ba3de158b7ead805c3b4302c45b7cad3429f045920c" - "0.1.19": - url: "https://github.com/awslabs/aws-c-s3/archive/v0.1.19.tar.gz" - sha256: "30e17e31eed18e8d621cd3d3978b2e6eeeee5557bfc3a9d701d0d3e1c4a8a74d" diff --git a/recipes/aws-c-s3/all/conanfile.py b/recipes/aws-c-s3/all/conanfile.py index 131627214ba790..4854a0ec7c6d5e 100644 --- a/recipes/aws-c-s3/all/conanfile.py +++ b/recipes/aws-c-s3/all/conanfile.py @@ -1,18 +1,21 @@ from conan import ConanFile -from conan.tools.files import get, copy, rmdir -from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import get, copy, rmdir, save +from conan.tools.scm import Version import os +import textwrap + +required_conan_version = ">=1.53.0" -required_conan_version = ">=1.47.0" class AwsCS3(ConanFile): name = "aws-c-s3" description = "C99 implementation of the S3 client" - license = "Apache-2.0", + license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/awslabs/aws-c-s3" topics = ("aws", "amazon", "cloud", "s3") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -29,37 +32,29 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2") + self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + self.requires("aws-c-cal/0.5.13") if Version(self.version) < "0.1.49": - self.requires("aws-c-io/0.10.20") + self.requires("aws-c-auth/0.6.11", transitive_headers=True) self.requires("aws-c-http/0.6.13") - self.requires("aws-c-auth/0.6.11") + self.requires("aws-c-io/0.10.20", transitive_headers=True) else: - self.requires("aws-c-io/0.13.4") + self.requires("aws-c-auth/0.6.17", transitive_headers=True) self.requires("aws-c-http/0.6.22") - self.requires("aws-c-auth/0.6.17") + self.requires("aws-c-io/0.13.4", transitive_headers=True) if Version(self.version) >= "0.1.36": self.requires("aws-checksums/0.1.13") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) @@ -80,24 +75,34 @@ def package(self): cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "aws-c-s3")) + # TODO: to remove in conan v2 once legacy generators removed + self._create_cmake_module_alias_targets( + os.path.join(self.package_folder, self._module_file_rel_path), + {"AWS::aws-c-s3": "aws-c-s3::aws-c-s3"} + ) + + def _create_cmake_module_alias_targets(self, module_file, targets): + content = "" + for alias, aliased in targets.items(): + content += textwrap.dedent(f"""\ + if(TARGET {aliased} AND NOT TARGET {alias}) + add_library({alias} INTERFACE IMPORTED) + set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) + endif() + """) + save(self, module_file, content) + + @property + def _module_file_rel_path(self): + return os.path.join("lib", "cmake", f"conan-official-{self.name}-targets.cmake") + def package_info(self): self.cpp_info.set_property("cmake_file_name", "aws-c-s3") self.cpp_info.set_property("cmake_target_name", "AWS::aws-c-s3") + self.cpp_info.libs = ["aws-c-s3"] + if self.options.shared: + self.cpp_info.defines.append("AWS_S3_USE_IMPORT_EXPORT") - self.cpp_info.filenames["cmake_find_package"] = "aws-c-s3" - self.cpp_info.filenames["cmake_find_package_multi"] = "aws-c-s3" - self.cpp_info.names["cmake_find_package"] = "AWS" - self.cpp_info.names["cmake_find_package_multi"] = "AWS" - self.cpp_info.components["aws-c-s3-lib"].names["cmake_find_package"] = "aws-c-s3" - self.cpp_info.components["aws-c-s3-lib"].names["cmake_find_package_multi"] = "aws-c-s3" - self.cpp_info.components["aws-c-s3-lib"].set_property("cmake_target_name", "AWS::aws-c-s3") - - self.cpp_info.components["aws-c-s3-lib"].libs = ["aws-c-s3"] - self.cpp_info.components["aws-c-s3-lib"].requires = [ - "aws-c-common::aws-c-common-lib", - "aws-c-io::aws-c-io-lib", - "aws-c-http::aws-c-http-lib", - "aws-c-auth::aws-c-auth-lib" - ] - if Version(self.version) >= "0.1.36": - self.cpp_info.components["aws-c-s3-lib"].requires.append("aws-checksums::aws-checksums-lib") + # TODO: to remove in conan v2 once cmake_find_package* generators removed + self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] diff --git a/recipes/aws-c-s3/all/test_v1_package/CMakeLists.txt b/recipes/aws-c-s3/all/test_v1_package/CMakeLists.txt index 0778b2e2c7246d..0d20897301b68b 100644 --- a/recipes/aws-c-s3/all/test_v1_package/CMakeLists.txt +++ b/recipes/aws-c-s3/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES C) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(aws-c-s3 REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE AWS::aws-c-s3) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/aws-c-s3/config.yml b/recipes/aws-c-s3/config.yml index 182095498622bf..9a2f6a3845f5c9 100644 --- a/recipes/aws-c-s3/config.yml +++ b/recipes/aws-c-s3/config.yml @@ -7,5 +7,3 @@ versions: folder: all "0.1.27": folder: all - "0.1.19": - folder: all From fa9d7398a23b8f3bc5e026c6318a92c82f1b06cd Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 24 Aug 2023 22:58:57 +0200 Subject: [PATCH 0404/1140] (#19388) libsecret/all: bump deps * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsecret/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/libsecret/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libsecret/all/conanfile.py b/recipes/libsecret/all/conanfile.py index 2988bdf94bf2c7..d8c295c9287a32 100644 --- a/recipes/libsecret/all/conanfile.py +++ b/recipes/libsecret/all/conanfile.py @@ -53,7 +53,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glib/2.76.0", transitive_headers=True, transitive_libs=True) + self.requires("glib/2.77.2", transitive_headers=True, transitive_libs=True) if self._use_gcrypt: self.requires("libgcrypt/1.8.4") @@ -64,9 +64,9 @@ def validate(self): ) def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") self.tool_requires("glib/") if self.settings.os == "Macos": From a7996c0fd3839233a31bd1cc22f1bb43aed648b6 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 24 Aug 2023 23:37:32 +0200 Subject: [PATCH 0405/1140] (#19403) libselinux/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/libselinux/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libselinux/all/conanfile.py b/recipes/libselinux/all/conanfile.py index b584e1b1696aaa..b6e6523df64530 100644 --- a/recipes/libselinux/all/conanfile.py +++ b/recipes/libselinux/all/conanfile.py @@ -54,7 +54,7 @@ def validate(self): def build_requirements(self): self.tool_requires("flex/2.6.4") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") def source(self): for download in self.conan_data["sources"][self.version]: From 8734f9aa0ae2f50062661f34b032f431bbae24d5 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 25 Aug 2023 00:19:12 +0200 Subject: [PATCH 0406/1140] (#19390) glibmm/all: bump deps * glibmm/all/: bump deps * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glibmm/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * unbump libsigcpp --- recipes/glibmm/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/glibmm/all/conanfile.py b/recipes/glibmm/all/conanfile.py index df88638f61d356..e1e08552bf5e9e 100644 --- a/recipes/glibmm/all/conanfile.py +++ b/recipes/glibmm/all/conanfile.py @@ -75,7 +75,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glib/2.76.0") + self.requires("glib/2.77.2") if self._abi_version == "2.68": self.requires("libsigcpp/3.0.7") else: @@ -97,9 +97,9 @@ def validate(self): raise ConanInvalidConfiguration("Linking shared glib with the MSVC static runtime is not supported") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 8f1a7c79b9bdf62bbb46071e36a9f5c0af27e2a3 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 25 Aug 2023 00:56:41 +0200 Subject: [PATCH 0407/1140] (#19392) pulseaudio/alll: bump deps * pulseaudio/all/: bump deps * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/pulseaudio/all/conanfile.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/pulseaudio/all/conanfile.py b/recipes/pulseaudio/all/conanfile.py index 84e7c6bf375e7f..f1b1de05bf9676 100644 --- a/recipes/pulseaudio/all/conanfile.py +++ b/recipes/pulseaudio/all/conanfile.py @@ -58,13 +58,13 @@ def layout(self): def requirements(self): self.requires("libiconv/1.17") - self.requires("libsndfile/1.2.0") - self.requires("libcap/2.66") + self.requires("libsndfile/1.2.2") + self.requires("libcap/2.68") self.requires("libtool/2.4.7") if self.options.with_alsa: self.requires("libalsa/1.2.7.2") if self.options.with_glib: - self.requires("glib/2.76.1") + self.requires("glib/2.77.2") if self.options.get_safe("with_fftw"): self.requires("fftw/3.3.10") if self.options.with_x11: @@ -72,7 +72,7 @@ def requirements(self): if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_dbus: - self.requires("dbus/1.15.2") + self.requires("dbus/1.15.8") def validate(self): if self.settings.os != "Linux": @@ -90,7 +90,7 @@ def build_requirements(self): self.tool_requires("gettext/0.21") self.tool_requires("libtool/2.4.7") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 4c28c55d2e6591434e75b423ad7f5533c0693631 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 25 Aug 2023 01:49:42 +0200 Subject: [PATCH 0408/1140] (#19382) [bot] Update authorized users list (2023-08-24) --- .c3i/authorized_users.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index fcf61aaa08fd3d..b68f4b3ff03987 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1216,3 +1216,4 @@ authorized_users: - adattatri - jwfallawuiuc - tgurriet +- mgfernan From c81c3dff91bd05112ff7e71725ab6f28817a9777 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 25 Aug 2023 02:02:58 +0200 Subject: [PATCH 0409/1140] (#19394) [nasm] Configure assembler compiler by cpp_info Signed-off-by: Uilian Ries --- recipes/nasm/all/conanfile.py | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/recipes/nasm/all/conanfile.py b/recipes/nasm/all/conanfile.py index 25d5fec8b82ba4..f570e673ace4db 100644 --- a/recipes/nasm/all/conanfile.py +++ b/recipes/nasm/all/conanfile.py @@ -17,7 +17,7 @@ class NASMConan(ConanFile): homepage = "http://www.nasm.us" description = "The Netwide Assembler, NASM, is an 80x86 and x86-64 assembler" license = "BSD-2-Clause" - topics = ("nasm", "installer", "assembler") + topics = ("asm", "installer", "assembler",) settings = "os", "arch", "compiler", "build_type" @@ -25,6 +25,20 @@ class NASMConan(ConanFile): def _settings_build(self): return getattr(self, "settings_build", self.settings) + @property + def _nasm(self): + suffix = "w.exe" if is_msvc(self) else "" + return os.path.join(self.package_folder, "bin", f"nasm{suffix}") + + @property + def _ndisasm(self): + suffix = "w.exe" if is_msvc(self) else "" + return os.path.join(self.package_folder, "bin", f"ndisasm{suffix}") + + def _chmod_plus_x(self, filename): + if os.name == "posix": + os.chmod(filename, os.stat(filename).st_mode | 0o111) + def export_sources(self): export_conandata_patches(self) @@ -94,10 +108,21 @@ def package(self): autotools = Autotools(self) autotools.install() rmdir(self, os.path.join(self.package_folder, "share")) + self._chmod_plus_x(self._nasm) + self._chmod_plus_x(self._ndisasm) def package_info(self): self.cpp_info.libdirs = [] self.cpp_info.includedirs = [] + compiler_executables = {"asm": self._nasm} + self.conf_info.update("tools.build:compiler_executables", compiler_executables) + self.buildenv_info.define_path("NASM", self._nasm) + self.buildenv_info.define_path("NDISASM", self._ndisasm) + self.buildenv_info.define_path("AS", self._nasm) + # TODO: Legacy, to be removed on Conan 2.0 self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) + self.env_info.NASM = self._nasm + self.env_info.NDISASM = self._ndisasm + self.env_info.AS = self._nasm From 57acb4c8623cce7c97ebe393f706c8d4e0dbe289 Mon Sep 17 00:00:00 2001 From: Holger Detering Date: Fri, 25 Aug 2023 02:49:11 +0200 Subject: [PATCH 0410/1140] (#19368) aws-c-event-stream: add version 0.3.1 --- recipes/aws-c-event-stream/all/conandata.yml | 3 +++ recipes/aws-c-event-stream/all/conanfile.py | 12 +++++++++--- recipes/aws-c-event-stream/config.yml | 2 ++ 3 files changed, 14 insertions(+), 3 deletions(-) diff --git a/recipes/aws-c-event-stream/all/conandata.yml b/recipes/aws-c-event-stream/all/conandata.yml index 61428e916296b3..4c8f01cd490cba 100644 --- a/recipes/aws-c-event-stream/all/conandata.yml +++ b/recipes/aws-c-event-stream/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.3.1": + url: "https://github.com/awslabs/aws-c-event-stream/archive/v0.3.1.tar.gz" + sha256: "bdbc420efc2572689fb167ac288e982a01224876eb79d80e2411fad4c43e9dc0" "0.2.15": url: "https://github.com/awslabs/aws-c-event-stream/archive/v0.2.15.tar.gz" sha256: "4ff2ada07ede3c6afa4b8e6e20de541e717038307f29b38c27efa7c4d875ee26" diff --git a/recipes/aws-c-event-stream/all/conanfile.py b/recipes/aws-c-event-stream/all/conanfile.py index 2d51b3c4c313f0..d88a017a7e6baa 100644 --- a/recipes/aws-c-event-stream/all/conanfile.py +++ b/recipes/aws-c-event-stream/all/conanfile.py @@ -43,13 +43,19 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) - self.requires("aws-checksums/0.1.13") + if Version(self.version) < "0.3.1": + self.requires("aws-c-common/0.8.2", transitive_headers=True, transitive_libs=True) + self.requires("aws-checksums/0.1.13") + else: + self.requires("aws-c-common/0.9.0", transitive_headers=True, transitive_libs=True) + self.requires("aws-checksums/0.1.17") if Version(self.version) >= "0.2": if Version(self.version) < "0.2.11": self.requires("aws-c-io/0.10.20") - else: + elif Version(self.version) < "0.3.1": self.requires("aws-c-io/0.13.4") + else: + self.requires("aws-c-io/0.13.32") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/aws-c-event-stream/config.yml b/recipes/aws-c-event-stream/config.yml index 96ac653286f12a..4a2530c32b47bd 100644 --- a/recipes/aws-c-event-stream/config.yml +++ b/recipes/aws-c-event-stream/config.yml @@ -1,4 +1,6 @@ versions: + "0.3.1": + folder: all "0.2.15": folder: all "0.2.12": From 779dc12c83d2a20a24f487e7530dc8092d2eb6f3 Mon Sep 17 00:00:00 2001 From: Marian Klymov Date: Fri, 25 Aug 2023 05:05:11 +0300 Subject: [PATCH 0411/1140] (#19018) utfcpp: add utf8::cpp alias * utfcpp: add utf8::cpp alias * fix build module for v1 * Get rid of alias for CMake < 3.18 --- recipes/utfcpp/all/conanfile.py | 11 ++++++----- recipes/utfcpp/all/test_package/CMakeLists.txt | 2 ++ 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/recipes/utfcpp/all/conanfile.py b/recipes/utfcpp/all/conanfile.py index 34e0685b4ddb26..247b54396ade22 100644 --- a/recipes/utfcpp/all/conanfile.py +++ b/recipes/utfcpp/all/conanfile.py @@ -38,7 +38,8 @@ def package(self): # TODO: to remove in conan v2 once cmake_find_package* generators removed self._create_cmake_module_alias_targets( os.path.join(self.package_folder, self._module_file_rel_path), - {"utf8cpp": "utf8cpp::utf8cpp"}, + {"utf8cpp": "utf8cpp::utf8cpp", + "utf8::cpp": "utf8cpp::utf8cpp"}, ) def _create_cmake_module_alias_targets(self, module_file, targets): @@ -59,12 +60,12 @@ def _module_file_rel_path(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "utf8cpp") self.cpp_info.set_property("cmake_target_name", "utf8cpp") + self.cpp_info.set_property("cmake_target_aliases", ["utf8::cpp"]) self.cpp_info.includedirs.append(os.path.join("include", "utf8cpp")) self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed - self.cpp_info.names["cmake_find_package"] = "utf8cpp" - self.cpp_info.names["cmake_find_package_multi"] = "utf8cpp" - self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] + for generator in ["cmake_find_package", "cmake_find_package_multi"]: + self.cpp_info.names[generator] = "utf8cpp" + self.cpp_info.build_modules[generator] = [self._module_file_rel_path] diff --git a/recipes/utfcpp/all/test_package/CMakeLists.txt b/recipes/utfcpp/all/test_package/CMakeLists.txt index fe794ae36be57c..7624c136189142 100644 --- a/recipes/utfcpp/all/test_package/CMakeLists.txt +++ b/recipes/utfcpp/all/test_package/CMakeLists.txt @@ -5,4 +5,6 @@ find_package(utf8cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE utf8cpp) +#check alias +target_link_libraries(${PROJECT_NAME} PRIVATE utf8::cpp) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) From 56d92fb9f5ef7678d296c2b12900bfd684e327ea Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Thu, 24 Aug 2023 22:38:43 -0700 Subject: [PATCH 0412/1140] (#19345) expected-lite: make sure libdirs is empty for this header-only library --- recipes/expected-lite/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/expected-lite/all/conanfile.py b/recipes/expected-lite/all/conanfile.py index d5786a1bd1873f..591dbe00d1ead5 100644 --- a/recipes/expected-lite/all/conanfile.py +++ b/recipes/expected-lite/all/conanfile.py @@ -52,3 +52,4 @@ def package_info(self): self.cpp_info.components["expectedlite"].names["cmake_find_package"] = "expected-lite" self.cpp_info.components["expectedlite"].names["cmake_find_package_multi"] = "expected-lite" self.cpp_info.components["expectedlite"].set_property("cmake_target_name", "nonstd::expected-lite") + self.cpp_info.components["expectedlite"].libdirs = [] From 29309eb45e2f3c9365c54342d65743562e32603d Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 25 Aug 2023 15:19:34 +0900 Subject: [PATCH 0413/1140] (#19377) simdutf: add version 3.2.17 --- recipes/simdutf/all/conandata.yml | 7 ++++++ .../all/patches/3.2.17-0001-fix-cmake.patch | 22 +++++++++++++++++++ recipes/simdutf/config.yml | 2 ++ 3 files changed, 31 insertions(+) create mode 100644 recipes/simdutf/all/patches/3.2.17-0001-fix-cmake.patch diff --git a/recipes/simdutf/all/conandata.yml b/recipes/simdutf/all/conandata.yml index a0fbb535961972..7b21b415ea0072 100644 --- a/recipes/simdutf/all/conandata.yml +++ b/recipes/simdutf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.17": + url: "https://github.com/simdutf/simdutf/archive/v3.2.17.tar.gz" + sha256: "c24e3eec1e08522a09b33e603352e574f26d367a7701bf069a65881f64acd519" "3.2.15": url: "https://github.com/simdutf/simdutf/archive/v3.2.15.tar.gz" sha256: "c26d2e2e9124e1c20335d3880d74c8b0d74a5e247ba82ef82d15df4ccc413bcd" @@ -30,6 +33,10 @@ sources: url: "https://github.com/simdutf/simdutf/archive/v1.0.1.tar.gz" sha256: "e7832ba58fb95fe00de76dbbb2f17d844a7ad02a6f5e3e9e5ce9520e820049a0" patches: + "3.2.17": + - patch_file: "patches/3.2.17-0001-fix-cmake.patch" + patch_description: "remove static build, enable rpath on macOS" + patch_type: "conan" "3.2.15": - patch_file: "patches/3.2.14-0001-fix-cmake.patch" patch_description: "remove static build, enable rpath on macOS" diff --git a/recipes/simdutf/all/patches/3.2.17-0001-fix-cmake.patch b/recipes/simdutf/all/patches/3.2.17-0001-fix-cmake.patch new file mode 100644 index 00000000000000..6f1f0aa23c2310 --- /dev/null +++ b/recipes/simdutf/all/patches/3.2.17-0001-fix-cmake.patch @@ -0,0 +1,22 @@ +diff --git a/cmake/simdutf-flags.cmake b/cmake/simdutf-flags.cmake +index d1e9bcd..2ff37c0 100644 +--- a/cmake/simdutf-flags.cmake ++++ b/cmake/simdutf-flags.cmake +@@ -22,4 +22,3 @@ set(SIMDUTF_CXX_STANDARD 11 CACHE STRING "the C++ standard to use for simdutf") + set(CMAKE_CXX_STANDARD ${SIMDUTF_CXX_STANDARD}) + set(CMAKE_CXX_STANDARD_REQUIRED ON) + set(CMAKE_CXX_EXTENSIONS OFF) +-set(CMAKE_MACOSX_RPATH OFF) +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index ed6be55..0b649c6 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -3,7 +3,7 @@ target_include_directories(simdutf-include-source INTERFACE $/simdutf.cpp) + target_link_libraries(simdutf-source INTERFACE simdutf-include-source) +-add_library(simdutf STATIC simdutf.cpp) ++add_library(simdutf simdutf.cpp) + target_include_directories(simdutf PRIVATE $ ) + target_include_directories(simdutf PUBLIC "$") + diff --git a/recipes/simdutf/config.yml b/recipes/simdutf/config.yml index 997781983cc10b..809aaef06ef294 100644 --- a/recipes/simdutf/config.yml +++ b/recipes/simdutf/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.17": + folder: all "3.2.15": folder: all "3.2.14": From 4af9a10888afe03d29f5c2378b7045e683d260f1 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 25 Aug 2023 15:39:28 +0900 Subject: [PATCH 0414/1140] (#19409) gperftools: add version 2.12.0 --- recipes/gperftools/all/conandata.yml | 3 +++ recipes/gperftools/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/gperftools/all/conandata.yml b/recipes/gperftools/all/conandata.yml index 439e56462f63f3..9b61f5954a26d7 100644 --- a/recipes/gperftools/all/conandata.yml +++ b/recipes/gperftools/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.12.0": + url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.12/gperftools-2.12.tar.gz" + sha256: "fb611b56871a3d9c92ab0cc41f9c807e8dfa81a54a4a9de7f30e838756b5c7c6" "2.11.0": url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.11/gperftools-2.11.tar.gz" sha256: "8ffda10e7c500fea23df182d7adddbf378a203c681515ad913c28a64b87e24dc" diff --git a/recipes/gperftools/config.yml b/recipes/gperftools/config.yml index caf3d644433044..901ed44b80295c 100644 --- a/recipes/gperftools/config.yml +++ b/recipes/gperftools/config.yml @@ -1,4 +1,6 @@ versions: + "2.12.0": + folder: all "2.11.0": folder: all "2.10.0": From ca82fe3535e6642dbf6671e90d7cc58bf11ab3b3 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 25 Aug 2023 13:59:15 +0200 Subject: [PATCH 0415/1140] (#19413) libmount: fixup license files --- recipes/libmount/all/conanfile.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/libmount/all/conanfile.py b/recipes/libmount/all/conanfile.py index 04bcc9f5b860fe..b9ec541d71963d 100644 --- a/recipes/libmount/all/conanfile.py +++ b/recipes/libmount/all/conanfile.py @@ -61,7 +61,8 @@ def build(self): autotools.make() def package(self): - copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, "COPYING", src=os.path.join(self.source_folder, "libmount"), dst=os.path.join(self.package_folder, "licenses")) + copy(self, "COPYING.LGPL-2.1-or-later", src=os.path.join(self.source_folder, "Documentation", "licenses"), dst=os.path.join(self.package_folder, "licenses")) autotools = Autotools(self) autotools.install() rmdir(self, os.path.join(self.package_folder, "sbin")) From fca6afcc18519a6679c16a3b8916e5efacecc3b8 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 25 Aug 2023 21:36:13 +0900 Subject: [PATCH 0416/1140] (#19151) yaml-cpp: add version 0.8.0 * yaml-cpp: add version 0.8.0 * support static build on msvc --- recipes/yaml-cpp/all/conandata.yml | 9 +++++++++ recipes/yaml-cpp/all/conanfile.py | 5 ++++- recipes/yaml-cpp/config.yml | 2 ++ 3 files changed, 15 insertions(+), 1 deletion(-) diff --git a/recipes/yaml-cpp/all/conandata.yml b/recipes/yaml-cpp/all/conandata.yml index 59546f980c76eb..542de368538ce3 100644 --- a/recipes/yaml-cpp/all/conandata.yml +++ b/recipes/yaml-cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.8.0": + url: "https://github.com/jbeder/yaml-cpp/archive/refs/tags/0.8.0.tar.gz" + sha256: "fbe74bbdcee21d656715688706da3c8becfd946d92cd44705cc6098bb23b3a16" "0.7.0": url: "https://github.com/jbeder/yaml-cpp/archive/yaml-cpp-0.7.0.tar.gz" sha256: "43e6a9fcb146ad871515f0d0873947e5d497a1c9c60c58cb102a97b47208b7c3" @@ -8,4 +11,10 @@ sources: patches: "0.7.0": - patch_file: "patches/0001-install-0.7.0.patch" + patch_description: "trigger installation through add_subdirectory from another CMakeLists.txt" + patch_type: "conan" + patch_source: "https://github.com/jbeder/yaml-cpp/pull/847" - patch_file: "patches/0002-libcxx-and-gcc.patch" + patch_description: "Adds assert to enable compilation with libcxx + gcc" + patch_type: "portability" + patch_source: "https://github.com/jbeder/yaml-cpp/pull/947" diff --git a/recipes/yaml-cpp/all/conanfile.py b/recipes/yaml-cpp/all/conanfile.py index 1b66ae0cdf060d..5b5671d6ceeee4 100644 --- a/recipes/yaml-cpp/all/conanfile.py +++ b/recipes/yaml-cpp/all/conanfile.py @@ -4,6 +4,7 @@ from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, rmdir, save from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +from conan.tools.scm import Version import os import textwrap @@ -110,8 +111,10 @@ def package_info(self): self.cpp_info.system_libs.append("m") if is_msvc(self): self.cpp_info.defines.append("_NOEXCEPT=noexcept") - if self.options.shared: + if Version(self.version) < "0.8.0" and self.options.shared: self.cpp_info.defines.append("YAML_CPP_DLL") + if Version(self.version) >= "0.8.0" and not self.options.shared: + self.cpp_info.defines.append("YAML_CPP_STATIC_DEFINE") # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] diff --git a/recipes/yaml-cpp/config.yml b/recipes/yaml-cpp/config.yml index ecd70890a4473e..3ad5266d60fe22 100644 --- a/recipes/yaml-cpp/config.yml +++ b/recipes/yaml-cpp/config.yml @@ -1,4 +1,6 @@ versions: + "0.8.0": + folder: all "0.7.0": folder: all "0.6.3": From 241a271eb365ce007109ca27776ddc8e522489f1 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 25 Aug 2023 15:43:10 +0200 Subject: [PATCH 0417/1140] (#19387) keychain/all: bump deps * keychain/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * keychain/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * keychain/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * keychain/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * keychain/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/keychain/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/keychain/all/conanfile.py b/recipes/keychain/all/conanfile.py index 216336cf7d3683..102f9369ebd89e 100644 --- a/recipes/keychain/all/conanfile.py +++ b/recipes/keychain/all/conanfile.py @@ -33,12 +33,12 @@ def validate(self): def requirements(self): if self.settings.os == "Linux": - self.requires("libsecret/0.20.4") - self.requires("glib/2.76.0") + self.requires("libsecret/0.20.5") + self.requires("glib/2.77.2") def build_requirements(self): if self.settings.os == "Linux": - self.tool_requires("pkgconf/1.7.3") + self.tool_requires("pkgconf/1.9.5") def layout(self): cmake_layout(self, src_folder="src") From 76883247305bc86e10aebe6f55a9b2775771c185 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 25 Aug 2023 16:04:10 +0200 Subject: [PATCH 0418/1140] (#19389) libverto/all: bump deps * libverto/all/: bump deps * libverto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libverto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libverto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libverto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libverto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/libverto/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/libverto/all/conanfile.py b/recipes/libverto/all/conanfile.py index a35c9bf481ff4e..e1a35934809245 100644 --- a/recipes/libverto/all/conanfile.py +++ b/recipes/libverto/all/conanfile.py @@ -75,7 +75,7 @@ def layout(self): def requirements(self): if self.options.with_glib: - self.requires("glib/2.76.0") + self.requires("glib/2.77.2") if self.options.with_libevent: self.requires("libevent/2.1.12") if self.options.with_libev: @@ -109,7 +109,7 @@ def validate(self): def build_requirements(self): if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") self.tool_requires("libtool/2.4.7") if self._settings_build.os == "Windows": self.win_bash = True From 227d6d18921b31119734da4bdc0059969b131174 Mon Sep 17 00:00:00 2001 From: Thomas Steiner <47025493+steinerthomas@users.noreply.github.com> Date: Fri, 25 Aug 2023 16:56:48 +0200 Subject: [PATCH 0419/1140] (#19414) xmlsec: bump libxml2 to 2.11.4 * xmlsec: bump libxml2 to 2.11.4 * test_package 2.11.4 --- recipes/xmlsec/all/conanfile.py | 2 +- recipes/xmlsec/all/test_package/conanfile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/xmlsec/all/conanfile.py b/recipes/xmlsec/all/conanfile.py index 6cbfca0ca36caf..146dd548ccbb56 100644 --- a/recipes/xmlsec/all/conanfile.py +++ b/recipes/xmlsec/all/conanfile.py @@ -60,7 +60,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("libxml2/2.10.4", transitive_headers=True) + self.requires("libxml2/2.11.4", transitive_headers=True) if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]", transitive_headers=True) if self.options.with_xslt: diff --git a/recipes/xmlsec/all/test_package/conanfile.py b/recipes/xmlsec/all/test_package/conanfile.py index e977f9247d9e3b..b846bc292a759e 100644 --- a/recipes/xmlsec/all/test_package/conanfile.py +++ b/recipes/xmlsec/all/test_package/conanfile.py @@ -14,7 +14,7 @@ def layout(self): def requirements(self): self.requires(self.tested_reference_str) - self.requires("libxml2/2.10.4") + self.requires("libxml2/2.11.4") def generate(self): tc = CMakeToolchain(self) From eec8b0073a02776872ff04f803b46a691a14ff1a Mon Sep 17 00:00:00 2001 From: Daniel Date: Fri, 25 Aug 2023 18:05:43 +0200 Subject: [PATCH 0420/1140] (#19380) [fix] Arrow: Make it conan v2 comaptible, refactor auto options and add 12.0.1 version * arrow: add version 12.0.1, with dirty workaround for conan v2 * [fix] Arrow: Make it conan v2 comaptible, refactor auto options and add 12.0.1 * remove prints --------- Co-authored-by: toge --- recipes/arrow/all/conandata.yml | 3 + recipes/arrow/all/conanfile.py | 236 +++++++++++++++----------------- recipes/arrow/config.yml | 2 + 3 files changed, 119 insertions(+), 122 deletions(-) diff --git a/recipes/arrow/all/conandata.yml b/recipes/arrow/all/conandata.yml index 772cdfef9c3c2d..256a5f614578c5 100644 --- a/recipes/arrow/all/conandata.yml +++ b/recipes/arrow/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "12.0.1": + url: "https://www.apache.org/dyn/closer.lua/arrow/arrow-12.0.1/apache-arrow-12.0.1.tar.gz?action=download" + sha256: "3481c411393aa15c75e88d93cf8315faf7f43e180fe0790128d3840d417de858" "12.0.0": url: "https://www.apache.org/dyn/closer.lua/arrow/arrow-12.0.0/apache-arrow-12.0.0.tar.gz?action=download" sha256: "ddd8347882775e53af7d0965a1902b7d8fcd0a030fd14f783d4f85e821352d52" diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index 50780c591a6e71..abed7f510dbed9 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -49,8 +49,9 @@ class ArrowConan(ConanFile): "with_glog": ["auto", True, False], "with_grpc": ["auto", True, False], "with_jemalloc": ["auto", True, False], - "with_mimalloc": ["auto", True, False], + "with_mimalloc": [True, False], "with_json": [True, False], + "with_thrift": ["auto", True, False], "with_llvm": ["auto", True, False], "with_openssl": ["auto", True, False], "with_opentelemetry": [True, False], @@ -99,6 +100,7 @@ class ArrowConan(ConanFile): "with_glog": "auto", "with_grpc": "auto", "with_json": False, + "with_thrift": "auto", "with_llvm": "auto", "with_openssl": "auto", "with_opentelemetry": False, @@ -155,6 +157,22 @@ def config_options(self): if Version(self.version) < "8.0.0": del self.options.substrait + self.options.parquet = self._parquet() + self.options.compute = self._compute() + self.options.dataset_modules = self._dataset_modules() + self.options.with_boost = self._with_boost() + self.options.with_flight_rpc = self._with_flight_rpc() + self.options.with_gflags = self._with_gflags() + self.options.with_glog = self._with_glog() + self.options.with_grpc = self._with_grpc() + self.options.with_jemalloc = self._with_jemalloc() + self.options.with_thrift = self._with_thrift() + self.options.with_llvm = self._with_llvm() + self.options.with_openssl = self._with_openssl() + self.options.with_protobuf = self._with_protobuf() + self.options.with_re2 = self._with_re2() + self.options.with_utf8proc = self._with_utf8proc() + def configure(self): if self.options.shared: self.options.rm_safe("fPIC") @@ -162,32 +180,32 @@ def configure(self): def layout(self): cmake_layout(self, src_folder="src") - def _compute(self, required=False): - if required or self.options.compute == "auto": + def _compute(self): + if self.options.compute == "auto": return bool(self._parquet() or self._dataset_modules()) or bool(self.options.get_safe("substrait", False)) else: return bool(self.options.compute) - def _parquet(self, required=False): - if required or self.options.parquet == "auto": + def _parquet(self): + if self.options.parquet == "auto": return bool(self.options.get_safe("substrait", False)) else: return bool(self.options.parquet) - def _dataset_modules(self, required=False): - if required or self.options.dataset_modules == "auto": + def _dataset_modules(self): + if self.options.dataset_modules == "auto": return bool(self.options.get_safe("substrait", False)) else: return bool(self.options.dataset_modules) - def _with_jemalloc(self, required=False): - if required or self.options.with_jemalloc == "auto": + def _with_jemalloc(self): + if self.options.with_jemalloc == "auto": return bool("BSD" in str(self.settings.os)) else: return bool(self.options.with_jemalloc) - def _with_re2(self, required=False): - if required or self.options.with_re2 == "auto": + def _with_re2(self): + if self.options.with_re2 == "auto": if self.options.gandiva or self.options.parquet: return True if Version(self) >= "7.0.0" and (self._compute() or self._dataset_modules()): @@ -196,38 +214,38 @@ def _with_re2(self, required=False): else: return bool(self.options.with_re2) - def _with_protobuf(self, required=False): - if required or self.options.with_protobuf == "auto": + def _with_protobuf(self): + if self.options.with_protobuf == "auto": return bool(self.options.gandiva or self._with_flight_rpc() or self.options.with_orc or self.options.get_safe("substrait", False)) else: return bool(self.options.with_protobuf) - def _with_flight_rpc(self, required=False): - if required or self.options.with_flight_rpc == "auto": + def _with_flight_rpc(self): + if self.options.with_flight_rpc == "auto": return bool(self.options.get_safe("with_flight_sql", False)) else: return bool(self.options.with_flight_rpc) - def _with_gflags(self, required=False): - if required or self.options.with_gflags == "auto": + def _with_gflags(self): + if self.options.with_gflags == "auto": return bool(self._with_glog() or self._with_grpc()) else: return bool(self.options.with_gflags) - def _with_glog(self, required=False): - if required or self.options.with_glog == "auto": + def _with_glog(self): + if self.options.with_glog == "auto": return False else: return bool(self.options.with_glog) - def _with_grpc(self, required=False): - if required or self.options.with_grpc == "auto": + def _with_grpc(self): + if self.options.with_grpc == "auto": return self._with_flight_rpc() else: return bool(self.options.with_grpc) - def _with_boost(self, required=False): - if required or self.options.with_boost == "auto": + def _with_boost(self): + if self.options.with_boost == "auto": if self.options.gandiva: return True version = Version(self.version) @@ -241,29 +259,31 @@ def _with_boost(self, required=False): else: return bool(self.options.with_boost) - def _with_thrift(self, required=False): - # No self.options.with_thift exists - return bool(required or self._parquet()) + def _with_thrift(self): + if self.options.with_thrift == "auto": + return bool(self._parquet()) + else: + return bool(self.options.with_thrift) - def _with_utf8proc(self, required=False): - if required or self.options.with_utf8proc == "auto": + def _with_utf8proc(self): + if self.options.with_utf8proc == "auto": return bool(self._compute() or self.options.gandiva) else: return bool(self.options.with_utf8proc) - def _with_llvm(self, required=False): - if required or self.options.with_llvm == "auto": + def _with_llvm(self): + if self.options.with_llvm == "auto": return bool(self.options.gandiva) else: return bool(self.options.with_llvm) - def _with_openssl(self, required=False): - if required or self.options.with_openssl == "auto": + def _with_openssl(self): + if self.options.with_openssl == "auto": return bool(self.options.encryption or self._with_flight_rpc() or self.options.with_s3) else: return bool(self.options.with_openssl) - def _with_rapidjson(self): + def _requires_rapidjson(self): if self.options.with_json: return True if Version(self.version) >= "7.0.0" and self.options.encryption: @@ -271,29 +291,29 @@ def _with_rapidjson(self): return False def requirements(self): - if self._with_thrift(): + if self.options.with_thrift: self.requires("thrift/0.17.0") - if self._with_protobuf(): + if self.options.with_protobuf: self.requires("protobuf/3.21.9") - if self._with_jemalloc(): + if self.options.with_jemalloc: self.requires("jemalloc/5.3.0") if self.options.with_mimalloc: self.requires("mimalloc/1.7.6") - if self._with_boost(): + if self.options.with_boost: self.requires("boost/1.81.0") - if self._with_gflags(): + if self.options.with_gflags: self.requires("gflags/2.2.2") - if self._with_glog(): + if self.options.with_glog: self.requires("glog/0.6.0") if self.options.get_safe("with_gcs"): self.requires("google-cloud-cpp/1.40.1") - if self._with_grpc(): + if self.options.with_grpc: self.requires("grpc/1.50.0") - if self._with_rapidjson(): + if self._requires_rapidjson(): self.requires("rapidjson/1.1.0") - if self._with_llvm(): + if self.options.with_llvm: self.requires("llvm-core/13.0.0") - if self._with_openssl(): + if self.options.with_openssl: # aws-sdk-cpp requires openssl/1.1.1. it uses deprecated functions in openssl/3.0.0 if self.options.with_s3: self.requires("openssl/1.1.1t") @@ -319,24 +339,20 @@ def requirements(self): self.requires("zlib/1.2.13") if self.options.with_zstd: self.requires("zstd/1.5.2") - if self._with_re2(): + if self.options.with_re2: self.requires("re2/20220601") - if self._with_utf8proc(): + if self.options.with_utf8proc: self.requires("utf8proc/2.8.0") if self.options.with_backtrace: self.requires("libbacktrace/cci.20210118") - def package_id(self): - self.info.options.with_gflags = self._with_gflags() - self.info.options.with_protobuf = self._with_protobuf() - self.info.options.with_re2 = self._with_re2() - self.info.options.with_jemalloc = self._with_jemalloc() - self.info.options.with_openssl = self._with_openssl() - self.info.options.with_boost = self._with_boost() - self.info.options.with_glog = self._with_glog() - self.info.options.with_grpc = self._with_grpc() - def validate(self): + # validate options with 'auto' as default value + auto_options = ["parquet", "compute", "dataset_modules", "with_boost", "with_flight_rpc", "with_gflags", "with_glog", + "with_grpc", "with_jemalloc", "with_thrift", "with_llvm", "with_openssl", "with_protobuf", "with_re2", "with_utf8proc"] + for option in auto_options: + assert "auto" not in str(self.options.get_safe(option)), f"Option '{option}' contains 'auto' value, wich is not allowed. Generally the final value should be True/False" + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) @@ -346,32 +362,8 @@ def validate(self): f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - if self.options.compute == False and not self._compute(True): - raise ConanInvalidConfiguration("compute options is required (or choose auto)") - if self.options.parquet == False and self._parquet(True): - raise ConanInvalidConfiguration("parquet options is required (or choose auto)") - if self.options.dataset_modules == False and self._dataset_modules(True): - raise ConanInvalidConfiguration("dataset_modules options is required (or choose auto)") if self.options.get_safe("skyhook", False): raise ConanInvalidConfiguration("CCI has no librados recipe (yet)") - if self.options.with_jemalloc == False and self._with_jemalloc(True): - raise ConanInvalidConfiguration("with_jemalloc option is required (or choose auto)") - if self.options.with_re2 == False and self._with_re2(True): - raise ConanInvalidConfiguration("with_re2 option is required (or choose auto)") - if self.options.with_protobuf == False and self._with_protobuf(True): - raise ConanInvalidConfiguration("with_protobuf option is required (or choose auto)") - if self.options.with_gflags == False and self._with_gflags(True): - raise ConanInvalidConfiguration("with_gflags options is required (or choose auto)") - if self.options.with_flight_rpc == False and self._with_flight_rpc(True): - raise ConanInvalidConfiguration("with_flight_rpc options is required (or choose auto)") - if self.options.with_grpc == False and self._with_grpc(True): - raise ConanInvalidConfiguration("with_grpc options is required (or choose auto)") - if self.options.with_boost == False and self._with_boost(True): - raise ConanInvalidConfiguration("with_boost options is required (or choose auto)") - if self.options.with_openssl == False and self._with_openssl(True): - raise ConanInvalidConfiguration("with_openssl options is required (or choose auto)") - if self.options.with_llvm == False and self._with_llvm(True): - raise ConanInvalidConfiguration("with_llvm options is required (or choose auto)") if self.options.with_cuda: raise ConanInvalidConfiguration("CCI has no cuda recipe (yet)") if self.options.with_orc: @@ -379,7 +371,7 @@ def validate(self): if self.options.with_s3 and not self.dependencies["aws-sdk-cpp"].options.config: raise ConanInvalidConfiguration("arrow:with_s3 requires aws-sdk-cpp:config is True.") - if self.options.shared and self._with_jemalloc(): + if self.options.shared and self.options.with_jemalloc: if self.dependencies["jemalloc"].options.enable_cxx: raise ConanInvalidConfiguration("jemmalloc.enable_cxx of a static jemalloc must be disabled") @@ -404,10 +396,10 @@ def generate(self): tc.variables["ARROW_DEPENDENCY_SOURCE"] = "SYSTEM" tc.variables["ARROW_PACKAGE_KIND"] = "conan" # See https://github.com/conan-io/conan-center-index/pull/14903/files#r1057938314 for details tc.variables["ARROW_GANDIVA"] = bool(self.options.gandiva) - tc.variables["ARROW_PARQUET"] = self._parquet() + tc.variables["ARROW_PARQUET"] = self.options.parquet tc.variables["ARROW_SUBSTRAIT"] = bool(self.options.get_safe("substrait", False)) tc.variables["ARROW_ACERO"] = bool(self.options.acero) - tc.variables["ARROW_DATASET"] = self._dataset_modules() + tc.variables["ARROW_DATASET"] = self.options.dataset_modules tc.variables["ARROW_FILESYSTEM"] = bool(self.options.filesystem_layer) tc.variables["PARQUET_REQUIRE_ENCRYPTION"] = bool(self.options.encryption) tc.variables["ARROW_HDFS"] = bool(self.options.hdfs_bridgs) @@ -415,12 +407,12 @@ def generate(self): tc.variables["ARROW_BUILD_SHARED"] = bool(self.options.shared) tc.variables["ARROW_BUILD_STATIC"] = not bool(self.options.shared) tc.variables["ARROW_NO_DEPRECATED_API"] = not bool(self.options.deprecated) - tc.variables["ARROW_FLIGHT"] = self._with_flight_rpc() + tc.variables["ARROW_FLIGHT"] = self.options.with_flight_rpc tc.variables["ARROW_FLIGHT_SQL"] = bool(self.options.get_safe("with_flight_sql", False)) - tc.variables["ARROW_COMPUTE"] = self._compute() + tc.variables["ARROW_COMPUTE"] = self.options.compute tc.variables["ARROW_CSV"] = bool(self.options.with_csv) tc.variables["ARROW_CUDA"] = bool(self.options.with_cuda) - tc.variables["ARROW_JEMALLOC"] = self._with_jemalloc() + tc.variables["ARROW_JEMALLOC"] = self.options.with_jemalloc tc.variables["jemalloc_SOURCE"] = "SYSTEM" tc.variables["ARROW_MIMALLOC"] = bool(self.options.with_mimalloc) tc.variables["ARROW_JSON"] = bool(self.options.with_json) @@ -428,13 +420,13 @@ def generate(self): tc.variables["ARROW_GCS"] = bool(self.options.get_safe("with_gcs", False)) tc.variables["BOOST_SOURCE"] = "SYSTEM" tc.variables["Protobuf_SOURCE"] = "SYSTEM" - if self._with_protobuf(): + if self.options.with_protobuf: tc.variables["ARROW_PROTOBUF_USE_SHARED"] = bool(self.dependencies["protobuf"].options.shared) tc.variables["gRPC_SOURCE"] = "SYSTEM" - if self._with_grpc(): + if self.options.with_grpc: tc.variables["ARROW_GRPC_USE_SHARED"] = bool(self.dependencies["grpc"].options.shared) - tc.variables["ARROW_USE_GLOG"] = self._with_glog() + tc.variables["ARROW_USE_GLOG"] = self.options.with_glog tc.variables["GLOG_SOURCE"] = "SYSTEM" tc.variables["ARROW_WITH_BACKTRACE"] = bool(self.options.with_backtrace) tc.variables["ARROW_WITH_BROTLI"] = bool(self.options.with_brotli) @@ -442,7 +434,7 @@ def generate(self): if self.options.with_brotli: tc.variables["ARROW_BROTLI_USE_SHARED"] = bool(self.dependencies["brotli"].options.shared) tc.variables["gflags_SOURCE"] = "SYSTEM" - if self._with_gflags(): + if self.options.with_gflags: tc.variables["ARROW_GFLAGS_USE_SHARED"] = bool(self.dependencies["gflags"].options.shared) tc.variables["ARROW_WITH_BZ2"] = bool(self.options.with_bz2) tc.variables["BZip2_SOURCE"] = "SYSTEM" @@ -471,16 +463,16 @@ def generate(self): if self.options.with_zstd: tc.variables["ARROW_ZSTD_USE_SHARED"] = bool(self.dependencies["zstd"].options.shared) tc.variables["ORC_SOURCE"] = "SYSTEM" - tc.variables["ARROW_WITH_THRIFT"] = self._with_thrift() + tc.variables["ARROW_WITH_THRIFT"] = bool(self.options.with_thrift) tc.variables["Thrift_SOURCE"] = "SYSTEM" - if self._with_thrift(): + if self.options.with_thrift: tc.variables["THRIFT_VERSION"] = bool(self.dependencies["thrift"].ref.version) # a recent thrift does not require boost tc.variables["ARROW_THRIFT_USE_SHARED"] = bool(self.dependencies["thrift"].options.shared) - tc.variables["ARROW_USE_OPENSSL"] = self._with_openssl() - if self._with_openssl(): + tc.variables["ARROW_USE_OPENSSL"] = self.options.with_openssl + if self.options.with_openssl: tc.variables["OPENSSL_ROOT_DIR"] = self.dependencies["openssl"].package_folder.replace("\\", "/") tc.variables["ARROW_OPENSSL_USE_SHARED"] = bool(self.dependencies["openssl"].options.shared) - if self._with_boost(): + if self.options.with_boost: tc.variables["ARROW_USE_BOOST"] = True tc.variables["ARROW_BOOST_USE_SHARED"] = bool(self.dependencies["boost"].options.shared) tc.variables["ARROW_S3"] = bool(self.options.with_s3) @@ -493,15 +485,15 @@ def generate(self): tc.variables["ARROW_ENABLE_TIMING_TESTS"] = False tc.variables["ARROW_BUILD_BENCHMARKS"] = False tc.variables["LLVM_SOURCE"] = "SYSTEM" - tc.variables["ARROW_WITH_UTF8PROC"] = self._with_utf8proc() - tc.variables["ARROW_BOOST_REQUIRED"] = self._with_boost() + tc.variables["ARROW_WITH_UTF8PROC"] = self.options.with_utf8proc + tc.variables["ARROW_BOOST_REQUIRED"] = self.options.with_boost tc.variables["utf8proc_SOURCE"] = "SYSTEM" - if self._with_utf8proc(): + if self.options.with_utf8proc: tc.variables["ARROW_UTF8PROC_USE_SHARED"] = bool(self.dependencies["utf8proc"].options.shared) tc.variables["BUILD_WARNING_LEVEL"] = "PRODUCTION" if is_msvc(self): tc.variables["ARROW_USE_STATIC_CRT"] = is_msvc_static_runtime(self) - if self._with_llvm(): + if self.options.with_llvm: tc.variables["LLVM_DIR"] = self.dependencies["llvm-core"].package_folder.replace("\\", "/") tc.generate() @@ -559,7 +551,7 @@ def package_info(self): if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["libarrow"].system_libs = ["pthread", "m", "dl", "rt"] - if self._parquet(): + if self.options.parquet: self.cpp_info.components["libparquet"].set_property("pkg_config_name", "parquet") self.cpp_info.components["libparquet"].libs = [f"parquet{suffix}"] self.cpp_info.components["libparquet"].requires = ["libarrow"] @@ -588,7 +580,7 @@ def package_info(self): if not self.options.shared: self.cpp_info.components["libgandiva"].defines = ["GANDIVA_STATIC"] - if self._with_flight_rpc(): + if self.options.with_flight_rpc: self.cpp_info.components["libarrow_flight"].set_property("pkg_config_name", "flight_rpc") self.cpp_info.components["libarrow_flight"].libs = [f"arrow_flight{suffix}"] self.cpp_info.components["libarrow_flight"].requires = ["libarrow"] @@ -598,54 +590,54 @@ def package_info(self): self.cpp_info.components["libarrow_flight_sql"].libs = [f"arrow_flight_sql{suffix}"] self.cpp_info.components["libarrow_flight_sql"].requires = ["libarrow", "libarrow_flight"] - if self._dataset_modules(): + if self.options.dataset_modules: self.cpp_info.components["dataset"].libs = ["arrow_dataset"] - if self._parquet(): + if self.options.parquet: self.cpp_info.components["dataset"].requires = ["libparquet"] - if self.options.cli and (self.options.with_cuda or self._with_flight_rpc() or self._parquet()): + if self.options.cli and (self.options.with_cuda or self.options.with_flight_rpc or self.options.parquet): binpath = os.path.join(self.package_folder, "bin") self.output.info(f"Appending PATH env var: {binpath}") self.env_info.PATH.append(binpath) - if self._with_boost(): + if self.options.with_boost: if self.options.gandiva: # FIXME: only filesystem component is used self.cpp_info.components["libgandiva"].requires.append("boost::boost") - if self._parquet() and self.settings.compiler == "gcc" and self.settings.compiler.version < Version("4.9"): + if self.options.parquet and self.settings.compiler == "gcc" and self.settings.compiler.version < Version("4.9"): self.cpp_info.components["libparquet"].requires.append("boost::boost") if Version(self.version) >= "2.0": # FIXME: only headers components is used self.cpp_info.components["libarrow"].requires.append("boost::boost") - if self._with_openssl(): + if self.options.with_openssl: self.cpp_info.components["libarrow"].requires.append("openssl::openssl") - if self._with_gflags(): + if self.options.with_gflags: self.cpp_info.components["libarrow"].requires.append("gflags::gflags") - if self._with_glog(): + if self.options.with_glog: self.cpp_info.components["libarrow"].requires.append("glog::glog") - if self._with_jemalloc(): + if self.options.with_jemalloc: self.cpp_info.components["libarrow"].requires.append("jemalloc::jemalloc") if self.options.with_mimalloc: self.cpp_info.components["libarrow"].requires.append("mimalloc::mimalloc") - if self._with_re2(): + if self.options.with_re2: if self.options.gandiva: self.cpp_info.components["libgandiva"].requires.append("re2::re2") - if self._parquet(): + if self.options.parquet: self.cpp_info.components["libparquet"].requires.append("re2::re2") self.cpp_info.components["libarrow"].requires.append("re2::re2") - if self._with_llvm(): + if self.options.with_llvm: self.cpp_info.components["libgandiva"].requires.append("llvm-core::llvm-core") - if self._with_protobuf(): + if self.options.with_protobuf: self.cpp_info.components["libarrow"].requires.append("protobuf::protobuf") - if self._with_utf8proc(): + if self.options.with_utf8proc: self.cpp_info.components["libarrow"].requires.append("utf8proc::utf8proc") - if self._with_thrift(): + if self.options.with_thrift: self.cpp_info.components["libarrow"].requires.append("thrift::thrift") if self.options.with_backtrace: self.cpp_info.components["libarrow"].requires.append("libbacktrace::libbacktrace") if self.options.with_cuda: self.cpp_info.components["libarrow"].requires.append("cuda::cuda") - if self._with_rapidjson(): + if self._requires_rapidjson(): self.cpp_info.components["libarrow"].requires.append("rapidjson::rapidjson") if self.options.with_s3: self.cpp_info.components["libarrow"].requires.append("aws-sdk-cpp::s3") @@ -669,11 +661,11 @@ def package_info(self): self.cpp_info.components["libarrow"].requires.append("zlib::zlib") if self.options.with_zstd: self.cpp_info.components["libarrow"].requires.append("zstd::zstd") - if self._with_boost(): + if self.options.with_boost: self.cpp_info.components["libarrow"].requires.append("boost::boost") - if self._with_grpc(): + if self.options.with_grpc: self.cpp_info.components["libarrow"].requires.append("grpc::grpc") - if self._with_flight_rpc(): + if self.options.with_flight_rpc: self.cpp_info.components["libarrow_flight"].requires.append("protobuf::protobuf") # TODO: to remove in conan v2 @@ -681,7 +673,7 @@ def package_info(self): self.cpp_info.filenames["cmake_find_package_multi"] = "Arrow" self.cpp_info.components["libarrow"].names["cmake_find_package"] = "arrow" self.cpp_info.components["libarrow"].names["cmake_find_package_multi"] = "arrow" - if self._parquet(): + if self.options.parquet: self.cpp_info.components["libparquet"].names["cmake_find_package"] = "parquet" self.cpp_info.components["libparquet"].names["cmake_find_package_multi"] = "parquet" if self.options.get_safe("substrait"): @@ -690,11 +682,11 @@ def package_info(self): if self.options.gandiva: self.cpp_info.components["libgandiva"].names["cmake_find_package"] = "gandiva" self.cpp_info.components["libgandiva"].names["cmake_find_package_multi"] = "gandiva" - if self._with_flight_rpc(): + if self.options.with_flight_rpc: self.cpp_info.components["libarrow_flight"].names["cmake_find_package"] = "flight_rpc" self.cpp_info.components["libarrow_flight"].names["cmake_find_package_multi"] = "flight_rpc" if self.options.get_safe("with_flight_sql"): self.cpp_info.components["libarrow_flight_sql"].names["cmake_find_package"] = "flight_sql" self.cpp_info.components["libarrow_flight_sql"].names["cmake_find_package_multi"] = "flight_sql" - if self.options.cli and (self.options.with_cuda or self._with_flight_rpc() or self._parquet()): + if self.options.cli and (self.options.with_cuda or self.options.with_flight_rpc or self.options.parquet): self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) diff --git a/recipes/arrow/config.yml b/recipes/arrow/config.yml index 06c575d489c3c2..b6c86580b3492d 100644 --- a/recipes/arrow/config.yml +++ b/recipes/arrow/config.yml @@ -1,4 +1,6 @@ versions: + "12.0.1": + folder: all "12.0.0": folder: all "11.0.0": From 1cd0a41952b3197b7cf00be2dd6733d94d48153f Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 26 Aug 2023 08:50:16 +0900 Subject: [PATCH 0421/1140] (#19422) simple-yaml: update dependencies --- recipes/simple-yaml/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/simple-yaml/all/conanfile.py b/recipes/simple-yaml/all/conanfile.py index 9573f235455af4..afb2abee08c4c0 100644 --- a/recipes/simple-yaml/all/conanfile.py +++ b/recipes/simple-yaml/all/conanfile.py @@ -47,10 +47,10 @@ def layout(self): def requirements(self): self.requires("pretty-name/1.0.0") - self.requires("yaml-cpp/0.7.0") + self.requires("yaml-cpp/0.8.0") self.requires("source_location/0.2.1") if self.options.enable_enum: - self.requires("magic_enum/0.7.3") + self.requires("magic_enum/0.9.3") def package_id(self): self.info.clear() From dd9babe8e5133e61da59d1135c8f49990fa9f93e Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 26 Aug 2023 12:49:00 +0900 Subject: [PATCH 0422/1140] (#19425) serdepp: update dependencies --- recipes/serdepp/all/conanfile.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/recipes/serdepp/all/conanfile.py b/recipes/serdepp/all/conanfile.py index 3a9cae70272de1..db1294b2b46730 100644 --- a/recipes/serdepp/all/conanfile.py +++ b/recipes/serdepp/all/conanfile.py @@ -53,18 +53,18 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("nameof/0.10.1") - self.requires("magic_enum/0.7.3") + self.requires("nameof/0.10.3") + self.requires("magic_enum/0.9.3") if self.options.with_toml11: - self.requires("toml11/3.7.0") + self.requires("toml11/3.7.1") if self.options.with_yamlcpp: - self.requires("yaml-cpp/0.7.0") + self.requires("yaml-cpp/0.8.0") if self.options.with_rapidjson: self.requires("rapidjson/1.1.0") if self.options.with_fmt: - self.requires("fmt/8.1.1") + self.requires("fmt/10.1.0") if self.options.with_nlohmann_json: - self.requires("nlohmann_json/3.10.5") + self.requires("nlohmann_json/3.11.2") def package_id(self): self.info.clear() From ae698505364ceaf2c6c95af963040d6c80fd65da Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 26 Aug 2023 13:30:34 +0900 Subject: [PATCH 0423/1140] (#19424) s2n: add version 1.3.50 --- recipes/s2n/all/conandata.yml | 3 +++ recipes/s2n/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/s2n/all/conandata.yml b/recipes/s2n/all/conandata.yml index 26760a8527f224..4ada91d8a20e63 100644 --- a/recipes/s2n/all/conandata.yml +++ b/recipes/s2n/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.50": + url: "https://github.com/aws/s2n-tls/archive/refs/tags/v1.3.50.tar.gz" + sha256: "19c9a7e9e0ce14aae3fc0c55995759f4eadd5b55f5353de69f82c62ccb3693f8" "1.3.49": url: "https://github.com/aws/s2n-tls/archive/refs/tags/v1.3.49.tar.gz" sha256: "2bc7b170a750a435ad02ab8e696c3ad6e9bb7a585c02899472793f87670184dd" diff --git a/recipes/s2n/config.yml b/recipes/s2n/config.yml index 7c0e248cb28f01..e02cebf4f0c065 100644 --- a/recipes/s2n/config.yml +++ b/recipes/s2n/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.50": + folder: all "1.3.49": folder: all "1.3.31": From c8ed1c2b5c5524fd04a22ef3a4987c2343808c8b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 26 Aug 2023 10:46:30 +0300 Subject: [PATCH 0424/1140] (#18717) rectanglebinpack: migrate to Conan v2, correct license * rectanglebinpack: migrate to Conan v2 * rectanglebinpack: restore VirtualRunEnv in test_package * Make license more specific Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/rectanglebinpack/all/CMakeLists.txt | 9 -- recipes/rectanglebinpack/all/conandata.yml | 3 - recipes/rectanglebinpack/all/conanfile.py | 89 +++++++++++-------- .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 21 +++-- .../all/test_package/test_package.cpp | 55 ++++++------ .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 8 files changed, 121 insertions(+), 90 deletions(-) delete mode 100644 recipes/rectanglebinpack/all/CMakeLists.txt create mode 100644 recipes/rectanglebinpack/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/rectanglebinpack/all/test_v1_package/conanfile.py diff --git a/recipes/rectanglebinpack/all/CMakeLists.txt b/recipes/rectanglebinpack/all/CMakeLists.txt deleted file mode 100644 index eab353d6877362..00000000000000 --- a/recipes/rectanglebinpack/all/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.8) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -add_subdirectory("source_subfolder") diff --git a/recipes/rectanglebinpack/all/conandata.yml b/recipes/rectanglebinpack/all/conandata.yml index 076654555cbc69..e93b6ba1b60128 100644 --- a/recipes/rectanglebinpack/all/conandata.yml +++ b/recipes/rectanglebinpack/all/conandata.yml @@ -2,9 +2,6 @@ sources: "cci.20210901": - url: "https://github.com/juj/RectangleBinPack/archive/a40fcaf3871da57b0f6a080655b3387374840877.zip" sha256: "88cec105ca8d90d09e9e81f9862caa0cc1cdb851560fb701555eb58b29515748" - - url: "https://unlicense.org/UNLICENSE" - sha256: "7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c" patches: "cci.20210901": - patch_file: "patches/0001_fix_win32_build.patch" - base_path: "source_subfolder" diff --git a/recipes/rectanglebinpack/all/conanfile.py b/recipes/rectanglebinpack/all/conanfile.py index c7332f95311645..f77182eff1815c 100644 --- a/recipes/rectanglebinpack/all/conanfile.py +++ b/recipes/rectanglebinpack/all/conanfile.py @@ -1,19 +1,23 @@ -from conans import ConanFile, CMake, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, load, save + +required_conan_version = ">=1.53.0" class RectangleBinPackConan(ConanFile): name = "rectanglebinpack" - license = "Unlicense" + description = "The code can be used to solve the problem of packing a set of 2D rectangles into a larger bin." + license = "LicenseRef-rectanglebinpack-public-domain" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/juj/RectangleBinPack" - description = "The code can be used to solve the problem of packing a set of 2D rectangles into a larger bin." topics = ("rectangle", "packing", "bin") - exports_sources = ["CMakeLists.txt", "patches/**"] - generators = "cmake" - settings = "os", "compiler", "build_type", "arch" + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -23,15 +27,8 @@ class RectangleBinPackConan(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -39,40 +36,58 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 11) + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version][0], - strip_root=True, destination=self._source_subfolder) - tools.download(filename="LICENSE", **self.conan_data["sources"][self.version][1]) + get(self, **self.conan_data["sources"][self.version][0], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = self.options.shared + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def _extract_license(self): + readme_content = load(self, os.path.join(self.source_folder, "Readme.txt"), encoding="latin-1") + license_content = "\n".join(readme_content.splitlines()[-4:]) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_content) def package(self): - self.copy("LICENSE", dst="licenses") - self.copy("*.h", dst=os.path.join("include", self.name), src=self._source_subfolder, excludes="old/**") - self.copy("*.dll", dst="bin", keep_path=False) - self.copy("*.lib", dst="lib", keep_path=False) - self.copy("*.so", dst="lib", keep_path=False) - self.copy("*.dylib", dst="lib", keep_path=False) - self.copy("*.a", dst="lib", keep_path=False) + self._extract_license() + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include", self.name), + src=self.source_folder, + excludes="old/**") + copy(self, "*.dll", + dst=os.path.join(self.package_folder, "bin"), + src=self.build_folder, + keep_path=False) + for pattern in ["*.lib", "*.so", "*.dylib", "*.a"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder, + keep_path=False) def package_info(self): self.cpp_info.libs = ["RectangleBinPack"] + self.cpp_info.set_property("cmake_file_name", "RectangleBinPack") + self.cpp_info.set_property("cmake_target_name", "RectangleBinPack::RectangleBinPack") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.names["cmake_find_package"] = "RectangleBinPack" self.cpp_info.names["cmake_find_package_multi"] = "RectangleBinPack" diff --git a/recipes/rectanglebinpack/all/test_package/CMakeLists.txt b/recipes/rectanglebinpack/all/test_package/CMakeLists.txt index 2d0f2eeb0d7460..4147475a867bb6 100644 --- a/recipes/rectanglebinpack/all/test_package/CMakeLists.txt +++ b/recipes/rectanglebinpack/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.4) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(RectangleBinPack REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE RectangleBinPack::RectangleBinPack) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/rectanglebinpack/all/test_package/conanfile.py b/recipes/rectanglebinpack/all/test_package/conanfile.py index 16ec9f68ef9742..ef5d7042163ecc 100644 --- a/recipes/rectanglebinpack/all/test_package/conanfile.py +++ b/recipes/rectanglebinpack/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/rectanglebinpack/all/test_package/test_package.cpp b/recipes/rectanglebinpack/all/test_package/test_package.cpp index b5c67148547b02..7a8bca93d78396 100644 --- a/recipes/rectanglebinpack/all/test_package/test_package.cpp +++ b/recipes/rectanglebinpack/all/test_package/test_package.cpp @@ -5,43 +5,38 @@ #include #include -#include #include +#include using namespace rbp; -bool AreDisjoint(const Rect &a, const Rect &b) -{ - return a.x >= b.x + b.width || a.x + a.width <= b.x || - a.y >= b.y + b.height || a.y + a.height <= b.y; +bool AreDisjoint(const Rect &a, const Rect &b) { + return a.x >= b.x + b.width || a.x + a.width <= b.x || a.y >= b.y + b.height || + a.y + a.height <= b.y; } -bool AllRectsDisjoint(std::vector &packed) -{ - for(size_t i = 0; i < packed.size(); ++i) - for(size_t j = i+1; j < packed.size(); ++j) - { - if (!AreDisjoint(packed[i], packed[j])) - return false; - } - return true; +bool AllRectsDisjoint(std::vector &packed) { + for (size_t i = 0; i < packed.size(); ++i) + for (size_t j = i + 1; j < packed.size(); ++j) { + if (!AreDisjoint(packed[i], packed[j])) + return false; + } + return true; } -int main() -{ - MaxRectsBinPack pack(256, 256, true); +int main() { + MaxRectsBinPack pack(256, 256, true); - std::vector packed; - srand(12412); - for(int i = 1; i < 128; ++i) - { - int a = (rand() % 128) + 1; - int b = (rand() % 128) + 1; - Rect r = pack.Insert(a, b, MaxRectsBinPack::RectBestShortSideFit); - if (!r.width) - break; - packed.push_back(r); - } - printf("Packed %d rectangles. All rects disjoint: %s. Occupancy: %f\n", - (int)packed.size(), AllRectsDisjoint(packed) ? "yes" : "NO!", pack.Occupancy()); + std::vector packed; + srand(12412); + for (int i = 1; i < 128; ++i) { + int a = (rand() % 128) + 1; + int b = (rand() % 128) + 1; + Rect r = pack.Insert(a, b, MaxRectsBinPack::RectBestShortSideFit); + if (!r.width) + break; + packed.push_back(r); + } + printf("Packed %d rectangles. All rects disjoint: %s. Occupancy: %f\n", (int)packed.size(), + AllRectsDisjoint(packed) ? "yes" : "NO!", pack.Occupancy()); } diff --git a/recipes/rectanglebinpack/all/test_v1_package/CMakeLists.txt b/recipes/rectanglebinpack/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/rectanglebinpack/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/rectanglebinpack/all/test_v1_package/conanfile.py b/recipes/rectanglebinpack/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..90eb89e3f2f46b --- /dev/null +++ b/recipes/rectanglebinpack/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 923fae70e06055ebd2a1724adb48e06ed9eb080a Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Sat, 26 Aug 2023 11:02:07 +0200 Subject: [PATCH 0425/1140] (#19420) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index ff746e7be2df12..2a4a0fc59737a7 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -61,6 +61,7 @@ required_for_references: - aws-c-http - aws-c-io - aws-c-mqtt +- aws-c-s3 - aws-c-sdkutils - aws-checksums - aws-kvs-pic @@ -958,6 +959,7 @@ required_for_references: - robin-hood-hashing - rpclib - rply +- rsync - rtklib - rtm - rtmidi From 181e238807021704d2f7df56f99f4b81ca7d8a80 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 26 Aug 2023 12:13:05 +0200 Subject: [PATCH 0426/1140] (#19427) onnx: add version 1.14.1 --- recipes/onnx/all/conandata.yml | 3 +++ recipes/onnx/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/onnx/all/conandata.yml b/recipes/onnx/all/conandata.yml index 7a261fa84daf5a..5f05c1310659aa 100644 --- a/recipes/onnx/all/conandata.yml +++ b/recipes/onnx/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.14.1": + url: "https://github.com/onnx/onnx/archive/v1.14.1.tar.gz" + sha256: "e296f8867951fa6e71417a18f2e550a730550f8829bd35e947b4df5e3e777aa1" "1.14.0": url: "https://github.com/onnx/onnx/archive/v1.14.0.tar.gz" sha256: "1b02ad523f79d83f9678c749d5a3f63f0bcd0934550d5e0d7b895f9a29320003" diff --git a/recipes/onnx/config.yml b/recipes/onnx/config.yml index 553b17a4b40e94..cfdc9b9959f822 100644 --- a/recipes/onnx/config.yml +++ b/recipes/onnx/config.yml @@ -1,4 +1,6 @@ versions: + "1.14.1": + folder: all "1.14.0": folder: all "1.13.1": From 66f230451e6430f10a4af43243cf06b0e9fa5c11 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 26 Aug 2023 13:49:56 +0300 Subject: [PATCH 0427/1140] (#18926) hdf4: migrate to Conan v2 * hdf4: migrate to Conan v2 * hdf4: fix missing link_libraries() * hdf4: bump deps * hdf4: add Linux system libs --- recipes/hdf4/all/CMakeLists.txt | 7 - recipes/hdf4/all/conandata.yml | 2 - recipes/hdf4/all/conanfile.py | 158 ++++++++++-------- recipes/hdf4/all/test_package/CMakeLists.txt | 13 +- recipes/hdf4/all/test_package/conanfile.py | 26 ++- recipes/hdf4/all/test_package/test_package.c | 10 +- .../hdf4/all/test_v1_package/CMakeLists.txt | 8 + recipes/hdf4/all/test_v1_package/conanfile.py | 24 +++ 8 files changed, 146 insertions(+), 102 deletions(-) delete mode 100644 recipes/hdf4/all/CMakeLists.txt create mode 100644 recipes/hdf4/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/hdf4/all/test_v1_package/conanfile.py diff --git a/recipes/hdf4/all/CMakeLists.txt b/recipes/hdf4/all/CMakeLists.txt deleted file mode 100644 index 217b9530b904d4..00000000000000 --- a/recipes/hdf4/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/hdf4/all/conandata.yml b/recipes/hdf4/all/conandata.yml index c28edc581baba6..b74cc986517d24 100644 --- a/recipes/hdf4/all/conandata.yml +++ b/recipes/hdf4/all/conandata.yml @@ -5,6 +5,4 @@ sources: patches: "4.2.15": - patch_file: "patches/fix-export-macro.patch" - base_path: "source_subfolder" - patch_file: "patches/fix-missing-unistd-include.patch" - base_path: "source_subfolder" diff --git a/recipes/hdf4/all/conanfile.py b/recipes/hdf4/all/conanfile.py index 6e61dd7455655d..f3f6af54d2d434 100644 --- a/recipes/hdf4/all/conanfile.py +++ b/recipes/hdf4/all/conanfile.py @@ -1,20 +1,22 @@ +import os + from conan import ConanFile from conan.tools.build import cross_building -from conan.tools.files import get, rmdir -from conans import CMake, tools -import os +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, save -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" class Hdf4Conan(ConanFile): name = "hdf4" description = "HDF4 is a data model, library, and file format for storing and managing data." license = "BSD-3-Clause" - topics = ("conan", "hdf4", "hdf", "data") - homepage = "https://portal.hdfgroup.org/display/HDF4/HDF4" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://portal.hdfgroup.org/display/HDF4/HDF4" + topics = ("hdf", "data") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -31,17 +33,8 @@ class Hdf4Conan(ConanFile): "szip_encoding": False, } - exports_sources = ["CMakeLists.txt", "patches/**"] - generators = "cmake", "cmake_find_package" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -49,16 +42,19 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") if not bool(self.options.szip_support): del self.options.szip_encoding + def layout(self): + cmake_layout(self, src_folder="src") + def requirements(self): self.requires("zlib/1.2.13") if self.options.jpegturbo: - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") else: self.requires("libjpeg/9e") if self.options.szip_support == "with_libaec": @@ -67,78 +63,108 @@ def requirements(self): self.requires("szip/2.1.1") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.cache_variables["HDF4_EXTERNALLY_CONFIGURED"] = True + tc.cache_variables["HDF4_EXTERNAL_LIB_PREFIX"] = "" + tc.cache_variables["HDF4_NO_PACKAGES"] = True + tc.cache_variables["ONLY_SHARED_LIBS"] = self.options.shared + tc.cache_variables["HDF4_ENABLE_COVERAGE"] = False + tc.cache_variables["HDF4_ENABLE_DEPRECATED_SYMBOLS"] = True + tc.cache_variables["HDF4_ENABLE_JPEG_LIB_SUPPORT"] = True # HDF can't compile without libjpeg or libjpeg-turbo + tc.cache_variables["HDF4_ENABLE_Z_LIB_SUPPORT"] = True # HDF can't compile without zlib + tc.cache_variables["HDF4_ENABLE_SZIP_SUPPORT"] = bool(self.options.szip_support) + tc.cache_variables["HDF4_ENABLE_SZIP_ENCODING"] = self.options.get_safe("szip_encoding") or False + tc.cache_variables["HDF4_PACKAGE_EXTLIBS"] = False + tc.cache_variables["HDF4_BUILD_XDR_LIB"] = True + tc.cache_variables["BUILD_TESTING"] = False + tc.cache_variables["HDF4_INSTALL_INCLUDE_DIR"] = os.path.join(self.package_folder, "include", "hdf4").replace("\\", "/") + tc.cache_variables["HDF4_BUILD_FORTRAN"] = False + tc.cache_variables["HDF4_BUILD_UTILS"] = False + tc.cache_variables["HDF4_BUILD_TOOLS"] = False + tc.cache_variables["HDF4_BUILD_EXAMPLES"] = False + tc.cache_variables["HDF4_BUILD_JAVA"] = False + if cross_building(self): + tc.cache_variables["H4_PRINTF_LL_TEST_RUN"] = "0" + tc.cache_variables["H4_PRINTF_LL_TEST_RUN__TRYRUN_OUTPUT"] = "" + tc.generate() + + deps = CMakeDeps(self) + if self.options.szip_support == "with_szip": + deps.set_property("szip", "cmake_file_name", "SZIP") + deps.set_property("szip", "cmake_target_name", "SZIP::SZIP") + elif self.options.szip_support == "with_libaec": + deps.set_property("libaec", "cmake_file_name", "SZIP") + deps.set_property("libaec", "cmake_target_name", "SZIP::SZIP") + deps.generate() + + def _patch_sources(self): + apply_conandata_patches(self) + libs = ["JPEG::JPEG", "ZLIB::ZLIB"] + if self.options.szip_support: + libs.append("SZIP::SZIP") + save(self, os.path.join(self.source_folder, "CMakeFilters.cmake"), + "\nlink_libraries({})".format(" ".join(libs)), append=True) def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + self._patch_sources() + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["HDF4_EXTERNALLY_CONFIGURED"] = True - self._cmake.definitions["HDF4_EXTERNAL_LIB_PREFIX"] = "" - self._cmake.definitions["HDF4_NO_PACKAGES"] = True - self._cmake.definitions["ONLY_SHARED_LIBS"] = self.options.shared - self._cmake.definitions["HDF4_ENABLE_COVERAGE"] = False - self._cmake.definitions["HDF4_ENABLE_DEPRECATED_SYMBOLS"] = True - self._cmake.definitions["HDF4_ENABLE_JPEG_LIB_SUPPORT"] = True # HDF can't compile without libjpeg or libjpeg-turbo - self._cmake.definitions["HDF4_ENABLE_Z_LIB_SUPPORT"] = True # HDF can't compile without zlib - self._cmake.definitions["HDF4_ENABLE_SZIP_SUPPORT"] = bool(self.options.szip_support) - self._cmake.definitions["HDF4_ENABLE_SZIP_ENCODING"] = self.options.get_safe("szip_encoding") or False - self._cmake.definitions["HDF4_PACKAGE_EXTLIBS"] = False - self._cmake.definitions["HDF4_BUILD_XDR_LIB"] = True - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.definitions["HDF4_INSTALL_INCLUDE_DIR"] = os.path.join(self.package_folder, "include", "hdf4") - self._cmake.definitions["HDF4_BUILD_FORTRAN"] = False - self._cmake.definitions["HDF4_BUILD_UTILS"] = False - self._cmake.definitions["HDF4_BUILD_TOOLS"] = False - self._cmake.definitions["HDF4_BUILD_EXAMPLES"] = False - self._cmake.definitions["HDF4_BUILD_JAVA"] = False - if cross_building(self): - self._cmake.definitions["H4_PRINTF_LL_TEST_RUN"] = "0" - self._cmake.definitions["H4_PRINTF_LL_TEST_RUN__TRYRUN_OUTPUT"] = "" - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) os.remove(os.path.join(self.package_folder, "lib", "libhdf4.settings")) + def _get_decorated_lib(self, name): + libname = name + if self.settings.os == "Windows" and self.settings.compiler != "gcc" and not self.options.shared: + libname = "lib" + libname + if self.settings.build_type == "Debug": + libname += "_D" if self.settings.os == "Windows" else "_debug" + return libname + def package_info(self): - self.cpp_info.names["pkg_config"] = "hdf" + self.cpp_info.set_property("pkg_config_name", "hdf") unofficial_includedir = os.path.join(self.package_folder, "include", "hdf4") + target_suffix = "shared" if self.options.shared else "static" + # xdr - xdr_cmake = "xdr-shared" if self.options.shared else "xdr-static" + xdr_cmake = f"xdr-{target_suffix}" + self.cpp_info.components["xdr"].set_property("cmake_target_name", f"hdf4::{xdr_cmake}") self.cpp_info.components["xdr"].names["cmake_find_package"] = xdr_cmake self.cpp_info.components["xdr"].names["cmake_find_package_multi"] = xdr_cmake self.cpp_info.components["xdr"].includedirs.append(unofficial_includedir) self.cpp_info.components["xdr"].libs = [self._get_decorated_lib("xdr")] if self.settings.os == "Windows": self.cpp_info.components["xdr"].system_libs.append("ws2_32") + # hdf - hdf_cmake = "hdf-shared" if self.options.shared else "hdf-static" + hdf_cmake = f"hdf-{target_suffix}" + self.cpp_info.components["hdf"].set_property("cmake_target_name", f"hdf4::{hdf_cmake}") self.cpp_info.components["hdf"].names["cmake_find_package"] = hdf_cmake self.cpp_info.components["hdf"].names["cmake_find_package_multi"] = hdf_cmake self.cpp_info.components["hdf"].includedirs.append(unofficial_includedir) self.cpp_info.components["hdf"].libs = [self._get_decorated_lib("hdf")] self.cpp_info.components["hdf"].requires = [ "zlib::zlib", - "libjpeg-turbo::libjpeg-turbo" if self.options.jpegturbo else "libjpeg::libjpeg" + "libjpeg-turbo::libjpeg-turbo" if self.options.jpegturbo else "libjpeg::libjpeg", ] if self.options.szip_support == "with_libaec": self.cpp_info.components["hdf"].requires.append("libaec::libaec") elif self.options.szip_support == "with_szip": self.cpp_info.components["hdf"].requires.append("szip::szip") + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["hdf"].system_libs = ["m", "dl"] + # mfhdf - mfhdf_cmake = "mfhdf-shared" if self.options.shared else "mfhdf-static" + mfhdf_cmake = f"mfhdf-{target_suffix}" + self.cpp_info.components["mfhdf"].set_property("cmake_target_name", f"hdf4::{mfhdf_cmake}") self.cpp_info.components["mfhdf"].names["cmake_find_package"] = mfhdf_cmake self.cpp_info.components["mfhdf"].names["cmake_find_package_multi"] = mfhdf_cmake self.cpp_info.components["mfhdf"].includedirs.append(unofficial_includedir) @@ -149,11 +175,3 @@ def package_info(self): self.cpp_info.components["xdr"].defines.append("H4_BUILT_AS_DYNAMIC_LIB=1") self.cpp_info.components["hdf"].defines.append("H4_BUILT_AS_DYNAMIC_LIB=1") self.cpp_info.components["mfhdf"].defines.append("H4_BUILT_AS_DYNAMIC_LIB=1") - - def _get_decorated_lib(self, name): - libname = name - if self.settings.os == "Windows" and self.settings.compiler != "gcc" and not self.options.shared: - libname = "lib" + libname - if self.settings.build_type == "Debug": - libname += "_D" if self.settings.os == "Windows" else "_debug" - return libname diff --git a/recipes/hdf4/all/test_package/CMakeLists.txt b/recipes/hdf4/all/test_package/CMakeLists.txt index a6de4b12710219..546a9e09d090d3 100644 --- a/recipes/hdf4/all/test_package/CMakeLists.txt +++ b/recipes/hdf4/all/test_package/CMakeLists.txt @@ -1,14 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(hdf4 REQUIRED) +find_package(hdf4 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -if(TARGET hdf4::hdf-shared) - target_link_libraries(${PROJECT_NAME} hdf4::hdf-shared) -else() - target_link_libraries(${PROJECT_NAME} hdf4::hdf-static) -endif() +target_link_libraries(${PROJECT_NAME} hdf4::hdf4) diff --git a/recipes/hdf4/all/test_package/conanfile.py b/recipes/hdf4/all/test_package/conanfile.py index 612db2552bfca3..7d51739a368b21 100644 --- a/recipes/hdf4/all/test_package/conanfile.py +++ b/recipes/hdf4/all/test_package/conanfile.py @@ -1,17 +1,27 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.apple import is_apple_os +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) def build_requirements(self): - if self.settings.os == "Macos" and self.settings.arch == "armv8": + if is_apple_os(self) and self.settings.arch == "armv8": # Attempting to use @rpath without CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG being # set. This could be because you are using a Mac OS X version less than 10.5 # or because CMake's platform configuration is corrupt. - self.build_requires("cmake/3.20.1") + self.tool_requires("cmake/[>=3.20]") + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -19,6 +29,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/hdf4/all/test_package/test_package.c b/recipes/hdf4/all/test_package/test_package.c index 4efcf0be4d7a7a..2e268465bf9bd6 100644 --- a/recipes/hdf4/all/test_package/test_package.c +++ b/recipes/hdf4/all/test_package/test_package.c @@ -49,12 +49,12 @@ int main() { file_desc_id = ANcreatef(an_id, AN_FILE_DESC); /* - * Write the annotation to the file description. + * Write the annotation to the file description. */ status_32 = ANwriteann(file_desc_id, FILE_DESC_TXT, (int32) strlen(FILE_DESC_TXT)); /* - * Create a vgroup in the V interface. Note that the vgroup's ref number + * Create a vgroup in the V interface. Note that the vgroup's ref number * is set to -1 for creating and the access mode is "w" for writing. */ status_n = Vstart(file_id); @@ -63,13 +63,13 @@ int main() { /* * Obtain the tag and ref number of the vgroup for subsequent - * references. + * references. */ vgroup_tag = (uint16) VQuerytag(vgroup_id); vgroup_ref = (uint16) VQueryref(vgroup_id); /* - * Create the data label for the vgroup identified by its tag + * Create the data label for the vgroup identified by its tag * and ref number. */ data_label_id = ANcreate(an_id, vgroup_tag, vgroup_ref, AN_DATA_LABEL); @@ -80,7 +80,7 @@ int main() { status_32 = ANwriteann(data_label_id, DATA_LABEL_TXT, (int32) strlen(DATA_LABEL_TXT)); /* - * Create the data description for the vgroup identified by its tag + * Create the data description for the vgroup identified by its tag * and ref number. */ data_desc_id = ANcreate(an_id, vgroup_tag, vgroup_ref, AN_DATA_DESC); diff --git a/recipes/hdf4/all/test_v1_package/CMakeLists.txt b/recipes/hdf4/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/hdf4/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/hdf4/all/test_v1_package/conanfile.py b/recipes/hdf4/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..2d700055b1faf6 --- /dev/null +++ b/recipes/hdf4/all/test_v1_package/conanfile.py @@ -0,0 +1,24 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build_requirements(self): + if self.settings.os == "Macos" and self.settings.arch == "armv8": + # Attempting to use @rpath without CMAKE_SHARED_LIBRARY_RUNTIME_C_FLAG being + # set. This could be because you are using a Mac OS X version less than 10.5 + # or because CMake's platform configuration is corrupt. + self.build_requires("cmake/[>=3.20]") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 43bf55233b75b0c2e187eb671a10be0b078cb93e Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Sat, 26 Aug 2023 13:30:43 +0200 Subject: [PATCH 0428/1140] (#19030) openpam/20190224: Added openpam recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * openpam: Added openpam recipe * Update recipes/openpam/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/openpam/all/test_package/test_package.c Co-authored-by: Uilian Ries * Update recipes/openpam/all/conandata.yml Co-authored-by: Uilian Ries * Update recipes/openpam/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/openpam/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/openpam/all/conanfile.py Co-authored-by: Uilian Ries * Update recipes/openpam/all/conanfile.py Co-authored-by: Uilian Ries * Fix GitHub commit suggestion dupe --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Uilian Ries --- recipes/openpam/all/conandata.yml | 4 + recipes/openpam/all/conanfile.py | 73 +++++++++++++++++++ .../openpam/all/test_package/CMakeLists.txt | 7 ++ recipes/openpam/all/test_package/conanfile.py | 27 +++++++ .../openpam/all/test_package/test_package.c | 22 ++++++ recipes/openpam/config.yml | 3 + 6 files changed, 136 insertions(+) create mode 100644 recipes/openpam/all/conandata.yml create mode 100644 recipes/openpam/all/conanfile.py create mode 100644 recipes/openpam/all/test_package/CMakeLists.txt create mode 100644 recipes/openpam/all/test_package/conanfile.py create mode 100644 recipes/openpam/all/test_package/test_package.c create mode 100644 recipes/openpam/config.yml diff --git a/recipes/openpam/all/conandata.yml b/recipes/openpam/all/conandata.yml new file mode 100644 index 00000000000000..06219b641cc818 --- /dev/null +++ b/recipes/openpam/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "20190224": + url: "https://sourceforge.net/projects/openpam/files/openpam/Tabebuia/openpam-20190224.tar.gz" + sha256: "31f871f16b6868aef9c849f39aff6c52227977e09eee22b00fb8b7435ddf7105" diff --git a/recipes/openpam/all/conanfile.py b/recipes/openpam/all/conanfile.py new file mode 100644 index 00000000000000..b8d2328964b483 --- /dev/null +++ b/recipes/openpam/all/conanfile.py @@ -0,0 +1,73 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get, rmdir, rm +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +import os + + +required_conan_version = ">=1.54.0" + +class PackageConan(ConanFile): + name = "openpam" + description = "OpenPAM library" + license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://openpam.org/" + topics = ("pam") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) + + if self.settings.os not in ["Linux", "FreeBSD", "Neutrino"]: + raise ConanInvalidConfiguration(f"{self.ref} is not supported on {self.settings.os}.") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True, filename=f"openpam-{self.version}.tar.gz") + + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() + + def build(self): + autotools = Autotools(self) + autotools.configure() + autotools.make() + + def package(self): + autotools = Autotools(self) + autotools.install() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses"), ignore_case=True) + rmdir(self, os.path.join(self.package_folder, "share")) + rm(self, "*.la", os.path.join(self.package_folder, "lib")) + + def package_info(self): + self.cpp_info.libs = ["pam"] + self.cpp_info.system_libs = ["dl"] diff --git a/recipes/openpam/all/test_package/CMakeLists.txt b/recipes/openpam/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..d03b89e820ddd3 --- /dev/null +++ b/recipes/openpam/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) + +find_package(openpam REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE openpam::openpam) diff --git a/recipes/openpam/all/test_package/conanfile.py b/recipes/openpam/all/test_package/conanfile.py new file mode 100644 index 00000000000000..0a808db45f2453 --- /dev/null +++ b/recipes/openpam/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +# It will become the standard on Conan 2.x +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/openpam/all/test_package/test_package.c b/recipes/openpam/all/test_package/test_package.c new file mode 100644 index 00000000000000..50dff63a6c03a1 --- /dev/null +++ b/recipes/openpam/all/test_package/test_package.c @@ -0,0 +1,22 @@ +#include +#include +#include +#include +#include +#include + + +int main(void) { + pam_handle_t* pamh; + struct pam_conv pamc; + const char *user; + + int rv = pam_start("yes", user, &pamc, &pamh); + + if(rv == PAM_SUCCESS) { + pam_end(pamh, PAM_SUCCESS); + } + + return EXIT_SUCCESS; +} + diff --git a/recipes/openpam/config.yml b/recipes/openpam/config.yml new file mode 100644 index 00000000000000..1dd1dcdfcdd6f9 --- /dev/null +++ b/recipes/openpam/config.yml @@ -0,0 +1,3 @@ +versions: + "20190224": + folder: all From 5cd5c4483f79b327c24646129ad95e2cb1cbd3d2 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Sat, 26 Aug 2023 16:14:57 +0400 Subject: [PATCH 0429/1140] (#19352) opencl-clhpp-headers: align versions with opencl-headers --- recipes/opencl-clhpp-headers/all/conandata.yml | 18 ++++++++++++++++++ .../all/test_package/CMakeLists.txt | 4 ++++ .../all/test_package/test_package.cpp | 4 ++++ recipes/opencl-clhpp-headers/config.yml | 12 ++++++++++++ 4 files changed, 38 insertions(+) diff --git a/recipes/opencl-clhpp-headers/all/conandata.yml b/recipes/opencl-clhpp-headers/all/conandata.yml index e4e17b97c1724a..8181b741f827c5 100644 --- a/recipes/opencl-clhpp-headers/all/conandata.yml +++ b/recipes/opencl-clhpp-headers/all/conandata.yml @@ -11,3 +11,21 @@ sources: "2022.05.18": url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2022.05.18.tar.gz" sha256: "d29affd740c5037b4499790613f5af0718ffc88c325e793b73cb35b7592fc0f7" + "2022.01.04": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.16.tar.gz" + sha256: "869456032e60787eed9fceaeaf6c6cb4452bc0ff97e0f5a271510145a1c8f4d4" + "2021.06.30": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.15.tar.gz" + sha256: "0175806508abc699586fc9a9387e01eb37bf812ca534e3b493ff3091ec2a9246" + "2021.04.29": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.14.tar.gz" + sha256: "c8821a7638e57a2c4052631c941af720b581edda634db6ab0b59924c958d69b6" + "2020.12.18": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.13.tar.gz" + sha256: "8ff0d0cd94d728edd30c876db546bf13e370ee7863629b4b9b5e2ef8e130d23c" + "2020.06.16": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.12.tar.gz" + sha256: "20b28709ce74d3602f1a946d78a2024c1f6b0ef51358b9686612669897a58719" + "2020.03.13": + url: "https://github.com/KhronosGroup/OpenCL-CLHPP/archive/refs/tags/v2.0.11.tar.gz" + sha256: "ffc2ca08cf4ae90ee55f14ea3735ccc388f454f4422b69498b2e9b93a1d45181" diff --git a/recipes/opencl-clhpp-headers/all/test_package/CMakeLists.txt b/recipes/opencl-clhpp-headers/all/test_package/CMakeLists.txt index 3a0c8417853f50..733d421e88716e 100644 --- a/recipes/opencl-clhpp-headers/all/test_package/CMakeLists.txt +++ b/recipes/opencl-clhpp-headers/all/test_package/CMakeLists.txt @@ -8,3 +8,7 @@ find_package(OpenCLHeadersCpp REQUIRED CONFIG) add_library(${PROJECT_NAME} OBJECT test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE OpenCL::HeadersCpp) + +if(OpenCLHeadersCpp_VERSION VERSION_GREATER 2020.06.16) + target_compile_definitions(${PROJECT_NAME} PRIVATE USE_OPENCL_HPP) +endif() diff --git a/recipes/opencl-clhpp-headers/all/test_package/test_package.cpp b/recipes/opencl-clhpp-headers/all/test_package/test_package.cpp index 24cf50fffbbe2a..a1e2c103aae1ac 100644 --- a/recipes/opencl-clhpp-headers/all/test_package/test_package.cpp +++ b/recipes/opencl-clhpp-headers/all/test_package/test_package.cpp @@ -1,7 +1,11 @@ #define CL_HPP_MINIMUM_OPENCL_VERSION 120 #define CL_HPP_TARGET_OPENCL_VERSION 120 +#ifdef USE_OPENCL_HPP #include +#else +#include +#endif #include #include diff --git a/recipes/opencl-clhpp-headers/config.yml b/recipes/opencl-clhpp-headers/config.yml index 691c70a050912e..2bf575fcc94516 100644 --- a/recipes/opencl-clhpp-headers/config.yml +++ b/recipes/opencl-clhpp-headers/config.yml @@ -7,3 +7,15 @@ versions: folder: all "2022.05.18": folder: all + "2022.01.04": + folder: all + "2021.06.30": + folder: all + "2021.04.29": + folder: all + "2020.12.18": + folder: all + "2020.06.16": + folder: all + "2020.03.13": + folder: all From 6859d07b802ca2bb983364ed3db0946f58a31147 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 26 Aug 2023 21:52:05 +0900 Subject: [PATCH 0430/1140] (#19404) libzip: add version 1.10.1, rearrange patch files MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libzip: add version 1.10.1, rearrange patch files * Fix yaml list syntax --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libzip/all/conandata.yml | 60 ++++++++++++++----- recipes/libzip/all/conanfile.py | 38 +----------- .../patches/1.10.1-0002-remove-rpath.patch | 13 ++++ ... => 1.7.3-0001-cmake-install-bundle.patch} | 0 .../all/patches/1.7.3-0002-remove-rpath.patch | 13 ++++ .../all/patches/1.8.0-0002-remove-rpath.patch | 13 ++++ .../patches/1.8.0-0003-fix-zstd-name.patch | 33 ++++++++++ .../all/patches/1.9.2-0002-remove-rpath.patch | 13 ++++ .../patches/1.9.2-0003-fix-zstd-name.patch | 33 ++++++++++ recipes/libzip/config.yml | 2 + 10 files changed, 167 insertions(+), 51 deletions(-) create mode 100644 recipes/libzip/all/patches/1.10.1-0002-remove-rpath.patch rename recipes/libzip/all/patches/{0001-cmake-install-bundle.patch => 1.7.3-0001-cmake-install-bundle.patch} (100%) create mode 100644 recipes/libzip/all/patches/1.7.3-0002-remove-rpath.patch create mode 100644 recipes/libzip/all/patches/1.8.0-0002-remove-rpath.patch create mode 100644 recipes/libzip/all/patches/1.8.0-0003-fix-zstd-name.patch create mode 100644 recipes/libzip/all/patches/1.9.2-0002-remove-rpath.patch create mode 100644 recipes/libzip/all/patches/1.9.2-0003-fix-zstd-name.patch diff --git a/recipes/libzip/all/conandata.yml b/recipes/libzip/all/conandata.yml index 567f243d79a980..0dcb786c628748 100644 --- a/recipes/libzip/all/conandata.yml +++ b/recipes/libzip/all/conandata.yml @@ -1,26 +1,56 @@ sources: + "1.10.1": + url: + - "https://libzip.org/download/libzip-1.10.1.tar.gz" + - "https://github.com/nih-at/libzip/releases/download/v1.10.1/libzip-1.10.1.tar.gz" + sha256: "9669ae5dfe3ac5b3897536dc8466a874c8cf2c0e3b1fdd08d75b273884299363" "1.9.2": - url: [ - "https://libzip.org/download/libzip-1.9.2.tar.gz", - "https://github.com/nih-at/libzip/releases/download/v1.9.2/libzip-1.9.2.tar.gz", - ] + url: + - "https://libzip.org/download/libzip-1.9.2.tar.gz" + - "https://github.com/nih-at/libzip/releases/download/v1.9.2/libzip-1.9.2.tar.gz" sha256: "fd6a7f745de3d69cf5603edc9cb33d2890f0198e415255d0987a0cf10d824c6f" "1.8.0": - url: [ - "https://libzip.org/download/libzip-1.8.0.tar.gz", - "https://github.com/nih-at/libzip/releases/download/v1.8.0/libzip-1.8.0.tar.gz", - ] + url: + - "https://libzip.org/download/libzip-1.8.0.tar.gz" + - "https://github.com/nih-at/libzip/releases/download/v1.8.0/libzip-1.8.0.tar.gz" sha256: "30ee55868c0a698d3c600492f2bea4eb62c53849bcf696d21af5eb65f3f3839e" "1.7.3": - url: [ - "https://libzip.org/download/libzip-1.7.3.tar.gz", - "https://github.com/nih-at/libzip/releases/download/v1.7.3/libzip-1.7.3.tar.gz", - ] + url: + - "https://libzip.org/download/libzip-1.7.3.tar.gz" + - "https://github.com/nih-at/libzip/releases/download/v1.7.3/libzip-1.7.3.tar.gz" sha256: "0e2276c550c5a310d4ebf3a2c3dfc43fb3b4602a072ff625842ad4f3238cb9cc" patches: + "1.10.1": + - patch_file: "patches/1.7.3-0001-cmake-install-bundle.patch" + patch_description: "fix installation path of utilities" + patch_type: "conan" + - patch_file: "patches/1.10.1-0002-remove-rpath.patch" + patch_description: "remove rpath feature" + patch_type: "conan" "1.9.2": - - patch_file: "patches/0001-cmake-install-bundle.patch" + - patch_file: "patches/1.7.3-0001-cmake-install-bundle.patch" + patch_description: "fix installation path of utilities" + patch_type: "conan" + - patch_file: "patches/1.9.2-0002-remove-rpath.patch" + patch_description: "remove rpath feature" + patch_type: "conan" + - patch_file: "patches/1.9.2-0003-fix-zstd-name.patch" + patch_description: "fix zstd name" + patch_type: "portability" "1.8.0": - - patch_file: "patches/0001-cmake-install-bundle.patch" + - patch_file: "patches/1.7.3-0001-cmake-install-bundle.patch" + patch_description: "fix installation path of utilities" + patch_type: "conan" + - patch_file: "patches/1.8.0-0002-remove-rpath.patch" + patch_description: "remove rpath feature" + patch_type: "conan" + - patch_file: "patches/1.8.0-0003-fix-zstd-name.patch" + patch_description: "fix zstd name" + patch_type: "portability" "1.7.3": - - patch_file: "patches/0001-cmake-install-bundle.patch" + - patch_file: "patches/1.7.3-0001-cmake-install-bundle.patch" + patch_description: "fix installation path of utilities" + patch_type: "conan" + - patch_file: "patches/1.7.3-0002-remove-rpath.patch" + patch_description: "remove rpath feature" + patch_type: "conan" diff --git a/recipes/libzip/all/conanfile.py b/recipes/libzip/all/conanfile.py index 466b104bf29b9e..ef5f90cd053cb1 100644 --- a/recipes/libzip/all/conanfile.py +++ b/recipes/libzip/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rmdir +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir from conan.tools.scm import Version import os @@ -105,42 +105,8 @@ def generate(self): deps = CMakeDeps(self) deps.generate() - def _patch_sources(self): - apply_conandata_patches(self) - - top_cmakelists = os.path.join(self.source_folder, "CMakeLists.txt") - # Honor zstd enabled - if self._has_zstd_support: - def zstd_find_package_pattern(version): - if version >= "1.9.2": - return "find_package(Zstd 1.3.6)" - else: - return "find_package(Zstd)" - lib_cmakelists = os.path.join(self.source_folder, "lib", "CMakeLists.txt") - replace_in_file(self, top_cmakelists, zstd_find_package_pattern(Version(self.version)), "find_package(zstd)") - replace_in_file(self, top_cmakelists, "Zstd_FOUND", "zstd_FOUND") - replace_in_file( - self, - lib_cmakelists, - "Zstd::Zstd", - "$,zstd::libzstd_shared,zstd::libzstd_static>", - ) - # Do not pollute rpath of installed binaries - replace_in_file( - self, - top_cmakelists, - "set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR})", - "", - ) - replace_in_file( - self, - top_cmakelists, - "set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE)", - "", - ) - def build(self): - self._patch_sources() + apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/libzip/all/patches/1.10.1-0002-remove-rpath.patch b/recipes/libzip/all/patches/1.10.1-0002-remove-rpath.patch new file mode 100644 index 00000000000000..63858833767397 --- /dev/null +++ b/recipes/libzip/all/patches/1.10.1-0002-remove-rpath.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index b2e7724..d33fbd8 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -285,7 +285,7 @@ if(WIN32) + endif(WIN32) + + # rpath handling: use rpath in installed binaries +-if(NOT CMAKE_SYSTEM_NAME MATCHES Linux) ++if(0) + set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}) + set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + endif() diff --git a/recipes/libzip/all/patches/0001-cmake-install-bundle.patch b/recipes/libzip/all/patches/1.7.3-0001-cmake-install-bundle.patch similarity index 100% rename from recipes/libzip/all/patches/0001-cmake-install-bundle.patch rename to recipes/libzip/all/patches/1.7.3-0001-cmake-install-bundle.patch diff --git a/recipes/libzip/all/patches/1.7.3-0002-remove-rpath.patch b/recipes/libzip/all/patches/1.7.3-0002-remove-rpath.patch new file mode 100644 index 00000000000000..2682986aa602f1 --- /dev/null +++ b/recipes/libzip/all/patches/1.7.3-0002-remove-rpath.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 017f7cf..e9dd8d9 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -237,7 +237,7 @@ if(WIN32) + endif(WIN32) + + # rpath handling: use rpath in installed binaries +-if(NOT CMAKE_SYSTEM_NAME MATCHES Linux) ++if(0) + set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}) + set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + endif() diff --git a/recipes/libzip/all/patches/1.8.0-0002-remove-rpath.patch b/recipes/libzip/all/patches/1.8.0-0002-remove-rpath.patch new file mode 100644 index 00000000000000..511a8497170f98 --- /dev/null +++ b/recipes/libzip/all/patches/1.8.0-0002-remove-rpath.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 93b46a6..577865f 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -237,7 +237,7 @@ if(WIN32) + endif(WIN32) + + # rpath handling: use rpath in installed binaries +-if(NOT CMAKE_SYSTEM_NAME MATCHES Linux) ++if(0) + set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}) + set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + endif() diff --git a/recipes/libzip/all/patches/1.8.0-0003-fix-zstd-name.patch b/recipes/libzip/all/patches/1.8.0-0003-fix-zstd-name.patch new file mode 100644 index 00000000000000..d3a2faebb601a1 --- /dev/null +++ b/recipes/libzip/all/patches/1.8.0-0003-fix-zstd-name.patch @@ -0,0 +1,33 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 93b46a6..577865f 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -196,12 +196,12 @@ if(ENABLE_LZMA) + endif(ENABLE_LZMA) + + if(ENABLE_ZSTD) +- find_package(Zstd) +- if(Zstd_FOUND) ++ find_package(zstd) ++ if(zstd_FOUND) + set(HAVE_LIBZSTD 1) + else() + message(WARNING "-- zstd library not found; zstandard support disabled") +- endif(Zstd_FOUND) ++ endif(zstd_FOUND) + endif(ENABLE_ZSTD) + + if (COMMONCRYPTO_FOUND) +diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt +index 1069cec..c0148b9 100644 +--- a/lib/CMakeLists.txt ++++ b/lib/CMakeLists.txt +@@ -148,7 +148,7 @@ endif() + + if(HAVE_LIBZSTD) + target_sources(zip PRIVATE zip_algorithm_zstd.c) +- target_link_libraries(zip PRIVATE Zstd::Zstd) ++ target_link_libraries(zip PRIVATE $,zstd::libzstd_shared,zstd::libzstd_static>) + endif() + + if(HAVE_COMMONCRYPTO) diff --git a/recipes/libzip/all/patches/1.9.2-0002-remove-rpath.patch b/recipes/libzip/all/patches/1.9.2-0002-remove-rpath.patch new file mode 100644 index 00000000000000..24aeef7d82680c --- /dev/null +++ b/recipes/libzip/all/patches/1.9.2-0002-remove-rpath.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d00a4f9..bc45784 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -238,7 +238,7 @@ if(WIN32) + endif(WIN32) + + # rpath handling: use rpath in installed binaries +-if(NOT CMAKE_SYSTEM_NAME MATCHES Linux) ++if(0) + set(CMAKE_INSTALL_RPATH ${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}) + set(CMAKE_INSTALL_RPATH_USE_LINK_PATH TRUE) + endif() diff --git a/recipes/libzip/all/patches/1.9.2-0003-fix-zstd-name.patch b/recipes/libzip/all/patches/1.9.2-0003-fix-zstd-name.patch new file mode 100644 index 00000000000000..bbc20c6fe9ebe1 --- /dev/null +++ b/recipes/libzip/all/patches/1.9.2-0003-fix-zstd-name.patch @@ -0,0 +1,33 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index d00a4f9..bc45784 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -197,12 +197,12 @@ if(ENABLE_LZMA) + endif(ENABLE_LZMA) + + if(ENABLE_ZSTD) +- find_package(Zstd 1.3.6) +- if(Zstd_FOUND) ++ find_package(zstd) ++ if(zstd_FOUND) + set(HAVE_LIBZSTD 1) + else() + message(WARNING "-- zstd library not found; zstandard support disabled") +- endif(Zstd_FOUND) ++ endif(zstd_FOUND) + endif(ENABLE_ZSTD) + + if (COMMONCRYPTO_FOUND) +diff --git a/lib/CMakeLists.txt b/lib/CMakeLists.txt +index 1213fa0..b6446cb 100644 +--- a/lib/CMakeLists.txt ++++ b/lib/CMakeLists.txt +@@ -147,7 +147,7 @@ endif() + + if(HAVE_LIBZSTD) + target_sources(zip PRIVATE zip_algorithm_zstd.c) +- target_link_libraries(zip PRIVATE Zstd::Zstd) ++ target_link_libraries(zip PRIVATE $,zstd::libzstd_shared,zstd::libzstd_static>) + endif() + + if(HAVE_COMMONCRYPTO) diff --git a/recipes/libzip/config.yml b/recipes/libzip/config.yml index 63ddbcf63ff111..614d36cf38cf39 100644 --- a/recipes/libzip/config.yml +++ b/recipes/libzip/config.yml @@ -1,4 +1,6 @@ versions: + "1.10.1": + folder: all "1.9.2": folder: all "1.8.0": From c8ba536460d7378d221a71753d124b94f5d4daea Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 26 Aug 2023 22:30:41 +0900 Subject: [PATCH 0431/1140] (#19192) spdlog: update fmt/10.1.0 * spdlog: update fmt/10.1.0 * update fmt for 1.12.0 only --- recipes/spdlog/all/conanfile.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/recipes/spdlog/all/conanfile.py b/recipes/spdlog/all/conanfile.py index 8b194e1f8f481a..b24d1adfcb1ba7 100644 --- a/recipes/spdlog/all/conanfile.py +++ b/recipes/spdlog/all/conanfile.py @@ -56,7 +56,9 @@ def requirements(self): self_version = Version(self.version) fmt_version = "7.1.3" - if self_version >= "1.11.0": + if self_version >= "1.12.0": + fmt_version = "10.1.0" + elif self_version >= "1.11.0": fmt_version = "10.0.0" elif self_version >= "1.10.0": fmt_version = "8.1.1" From 157bdb74954b6253a20e89bb99bad51425c3c41e Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 01:34:52 +0900 Subject: [PATCH 0432/1140] (#19433) ada: add version 2.6.2 --- recipes/ada/all/conandata.yml | 3 +++ recipes/ada/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index 97acb278526f59..c93cb42b88d24d 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.2": + url: "https://github.com/ada-url/ada/archive/v2.6.2.tar.gz" + sha256: "425b8696a28a22d19ee7aa4516c26fc8ae3ab574870a9a74ef58ba8a345b822e" "2.6.0": url: "https://github.com/ada-url/ada/archive/v2.6.0.tar.gz" sha256: "09551bfbd92853e59d731e5f44a88a690425fd2906977ad03a6a1059615a02a5" diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index aa9794668e5459..cecfcc53ea282a 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.2": + folder: all "2.6.0": folder: all "2.5.1": From 9af64bba64456ea4329203a3ee47d5477d3bad17 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 02:13:02 +0900 Subject: [PATCH 0433/1140] (#19435) gegles-spdlog_setup: update fmt/10.1.0 --- recipes/gegles-spdlog_setup/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/gegles-spdlog_setup/all/conanfile.py b/recipes/gegles-spdlog_setup/all/conanfile.py index 7d53c34d32dd28..9385009e7bf437 100644 --- a/recipes/gegles-spdlog_setup/all/conanfile.py +++ b/recipes/gegles-spdlog_setup/all/conanfile.py @@ -40,7 +40,7 @@ def layout(self): def requirements(self): self.requires("cpptoml/0.1.1") self.requires("spdlog/1.12.0") - self.requires("fmt/10.0.0") + self.requires("fmt/10.1.0") def package_id(self): self.info.clear() From 511b65d069c6e781c23e266e32a6941adc749d34 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 02:53:48 +0900 Subject: [PATCH 0434/1140] (#19436) seadex-essentials: update dependencies --- recipes/seadex-essentials/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/seadex-essentials/all/conanfile.py b/recipes/seadex-essentials/all/conanfile.py index a316b2670766bb..118460968da913 100644 --- a/recipes/seadex-essentials/all/conanfile.py +++ b/recipes/seadex-essentials/all/conanfile.py @@ -51,9 +51,9 @@ def configure(self): def requirements(self): # Headers are exposed https://github.com/SeadexGmbH/essentials/blob/622a07dc1530f5668f5dde0ce18007d420c371cd/essentials/include/essentials/log/log_level.hpp#L15 - self.requires("spdlog/1.11.0", transitive_headers=True) + self.requires("spdlog/1.12.0", transitive_headers=True) # Exposes headers and symbols https://github.com/SeadexGmbH/essentials/blob/622a07dc1530f5668f5dde0ce18007d420c371cd/essentials/include/essentials/type_wrapper.hpp#L282 - self.requires("fmt/10.0.0", transitive_headers=True, transitive_libs=True) + self.requires("fmt/10.1.0", transitive_headers=True, transitive_libs=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 820f6c9c6d0a245b584e9e93ad565f2d005ae1fd Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 03:31:50 +0900 Subject: [PATCH 0435/1140] (#19431) aws-c-io: update s2n/1.3.50 --- recipes/aws-c-io/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/aws-c-io/all/conanfile.py b/recipes/aws-c-io/all/conanfile.py index eaf12a0cfcd8db..73f6dfc98f678e 100644 --- a/recipes/aws-c-io/all/conanfile.py +++ b/recipes/aws-c-io/all/conanfile.py @@ -53,7 +53,7 @@ def requirements(self): self.requires("aws-c-cal/0.6.1", transitive_headers=True) if self.settings.os in ["Linux", "FreeBSD", "Android"]: - self.requires("s2n/1.3.31") + self.requires("s2n/1.3.50") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 58a55c311329a4492a5a192b7069d7e4f910be8b Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 13:31:30 +0900 Subject: [PATCH 0436/1140] (#19440) etl: add version 20.38.0 --- recipes/etl/all/conandata.yml | 3 +++ recipes/etl/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/etl/all/conandata.yml b/recipes/etl/all/conandata.yml index 048eb0ba5716e3..aaf305dbf4ff24 100644 --- a/recipes/etl/all/conandata.yml +++ b/recipes/etl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20.38.0": + url: "https://github.com/ETLCPP/etl/archive/20.38.0.tar.gz" + sha256: "7e29ce81a2a2d5826286502a2ad5bde1f4b591d2c9e0ef7ccc335e75445223cd" "20.37.3": url: "https://github.com/ETLCPP/etl/archive/20.37.3.tar.gz" sha256: "fbdf60c770772cd96d1eb25bdf56e4f45f23bf4029e18ef1f2af1f2056b9ea41" diff --git a/recipes/etl/config.yml b/recipes/etl/config.yml index aa2b1c54bb8bdb..f57d0b4090ca85 100644 --- a/recipes/etl/config.yml +++ b/recipes/etl/config.yml @@ -1,4 +1,6 @@ versions: + "20.38.0": + folder: all "20.37.3": folder: all "20.37.2": From 8152b06c55f0f82426cdbaf084339da0a5731e28 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 15:12:02 +0900 Subject: [PATCH 0437/1140] (#19442) implot: add version 0.16 --- recipes/implot/all/conandata.yml | 3 +++ recipes/implot/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/implot/all/conandata.yml b/recipes/implot/all/conandata.yml index a9c9c08b5ed786..5aa143a53a4986 100644 --- a/recipes/implot/all/conandata.yml +++ b/recipes/implot/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.16": + url: "https://github.com/epezent/implot/archive/v0.16.tar.gz" + sha256: "961df327d8a756304d1b0a67316eebdb1111d13d559f0d3415114ec0eb30abd1" "0.15": url: "https://github.com/epezent/implot/archive/v0.15.tar.gz" sha256: "4c20f22fbfbe4ad055f3d344581918d62cde72070b233dad75419a4334f82146" diff --git a/recipes/implot/config.yml b/recipes/implot/config.yml index 5c3099f028cc24..60016fd219bda6 100644 --- a/recipes/implot/config.yml +++ b/recipes/implot/config.yml @@ -1,4 +1,6 @@ versions: + "0.16": + folder: "all" "0.15": folder: "all" "0.14": From 0d6f514395f546af3eadfd3782f349582c37adcb Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 16:53:08 +0900 Subject: [PATCH 0438/1140] (#19444) gsl-lite: add version 0.41.0 --- recipes/gsl-lite/all/conandata.yml | 3 +++ recipes/gsl-lite/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/gsl-lite/all/conandata.yml b/recipes/gsl-lite/all/conandata.yml index 010ad6b469c3c4..cc6eafeeee69d5 100644 --- a/recipes/gsl-lite/all/conandata.yml +++ b/recipes/gsl-lite/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.41.0": + url: "https://github.com/gsl-lite/gsl-lite/archive/v0.41.0.tar.gz" + sha256: "4682d8a60260321b92555760be3b9caab60e2a71f95eddbdfb91e557ee93302a" "0.40.0": url: "https://github.com/gsl-lite/gsl-lite/archive/v0.40.0.tar.gz" sha256: "65af4ec8a1050dac4f1ca4622881bb02a9c3978a9baec289fb56e25412d6cac7" diff --git a/recipes/gsl-lite/config.yml b/recipes/gsl-lite/config.yml index d21a23d317e336..cec66ae3b5e026 100644 --- a/recipes/gsl-lite/config.yml +++ b/recipes/gsl-lite/config.yml @@ -1,4 +1,6 @@ versions: + "0.41.0": + folder: all "0.40.0": folder: all "0.39.0": From ec6cf3f86cd1033be2cfcb17344bedce661f4a53 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 27 Aug 2023 22:12:39 +0900 Subject: [PATCH 0439/1140] (#19446) cassandra-cpp-driver: add version 2.17.0 --- recipes/cassandra-cpp-driver/all/conandata.yml | 17 +++++++++++++++++ recipes/cassandra-cpp-driver/config.yml | 2 ++ 2 files changed, 19 insertions(+) diff --git a/recipes/cassandra-cpp-driver/all/conandata.yml b/recipes/cassandra-cpp-driver/all/conandata.yml index 35b0bd34f38b7a..148e40f2a763f6 100644 --- a/recipes/cassandra-cpp-driver/all/conandata.yml +++ b/recipes/cassandra-cpp-driver/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.17.0": + url: "https://github.com/datastax/cpp-driver/archive/2.17.0.tar.gz" + sha256: "075af6a6920b0a8b12e37b8e5aa335b0c7919334aa1b451642668e6e37c5372f" "2.16.2": url: "https://github.com/datastax/cpp-driver/archive/2.16.2.tar.gz" sha256: "de60751bd575b5364c2c5a17a24a40f3058264ea2ee6fef19de126ae550febc9" @@ -6,6 +9,20 @@ sources: url: "https://github.com/datastax/cpp-driver/archive/2.15.3.tar.gz" sha256: "eccb53c5151621c3b647fc83781a542cfb93e76687b4178ebce418fc4c817293" patches: + "2.17.0": + - patch_file: "patches/2.16.2/fix-cmake.patch" + patch_description: "use cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-rapidjson.patch" + patch_description: "fix include path for cci package" + patch_type: "conan" + - patch_file: "patches/2.15.3/fix-atomic.patch" + patch_description: "Adapt MemoryOrder definition for C++ 20" + patch_type: "portability" + patch_source: "https://github.com/datastax/cpp-driver/pull/533" + - patch_file: "patches/2.15.3/remove-attribute-for-msvc.patch" + patch_description: "remove attribute for msvc" + patch_type: "portability" "2.16.2": - patch_file: "patches/2.16.2/fix-cmake.patch" patch_description: "use cci package" diff --git a/recipes/cassandra-cpp-driver/config.yml b/recipes/cassandra-cpp-driver/config.yml index fa0680a1da5b55..7062b1458afe22 100644 --- a/recipes/cassandra-cpp-driver/config.yml +++ b/recipes/cassandra-cpp-driver/config.yml @@ -1,4 +1,6 @@ versions: + "2.17.0": + folder: all "2.16.2": folder: all "2.15.3": From 3eb225b9e5397dd67c883fcbe05b329faa227101 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 28 Aug 2023 00:53:49 +0900 Subject: [PATCH 0440/1140] (#19450) maddy: add version 1.3.0 --- recipes/maddy/all/conandata.yml | 3 +++ recipes/maddy/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/maddy/all/conandata.yml b/recipes/maddy/all/conandata.yml index dfa40b0be62066..b4bf9474c36c13 100644 --- a/recipes/maddy/all/conandata.yml +++ b/recipes/maddy/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.0": + url: "https://github.com/progsource/maddy/archive/refs/tags/1.3.0.tar.gz" + sha256: "561681f8c8d2b998c153cda734107a0bc1dea4bb0df69fd813922da63fa9f3e7" "1.2.1": url: "https://github.com/progsource/maddy/archive/refs/tags/1.2.1.tar.gz" sha256: "b6058bce7ca32506969633ee7a4042e75b07464489f1c44be00913543cd687ef" diff --git a/recipes/maddy/config.yml b/recipes/maddy/config.yml index 12b8a7bf45a5bf..90c91d00495ebf 100644 --- a/recipes/maddy/config.yml +++ b/recipes/maddy/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.0": + folder: all "1.2.1": folder: all "1.1.2": From 230ab447b90a136dca3b2bf45875b39c62136103 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 28 Aug 2023 02:10:57 +0900 Subject: [PATCH 0441/1140] (#19451) capnproto: add version 1.0.1 --- recipes/capnproto/all/conandata.yml | 7 +++++++ recipes/capnproto/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/capnproto/all/conandata.yml b/recipes/capnproto/all/conandata.yml index 64808b6c7cee44..e635b41da8f05d 100644 --- a/recipes/capnproto/all/conandata.yml +++ b/recipes/capnproto/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.1": + url: "https://github.com/capnproto/capnproto/archive/v1.0.1.tar.gz" + sha256: "5bdb16f6b389a9e29b04214b9bae1759e8b7fe2b45049d7e3f1f286ba050a200" "1.0.0": url: "https://github.com/capnproto/capnproto/archive/v1.0.0.tar.gz" sha256: "bcd44dde78055313a7786cb6ab020cbef19b9045b53857f90cce101c9453f715" @@ -24,6 +27,10 @@ sources: url: "https://github.com/capnproto/capnproto/archive/v0.7.0.tar.gz" sha256: "76c7114a3d142ad08b7208b3964a26e72a6320ee81331d3f0b87569fc9c47a28" patches: + "1.0.1": + - patch_file: "patches/0015-disable-tests-for-1.0.0.patch" + patch_description: "disable test build" + patch_type: "conan" "1.0.0": - patch_file: "patches/0015-disable-tests-for-1.0.0.patch" patch_description: "disable test build" diff --git a/recipes/capnproto/config.yml b/recipes/capnproto/config.yml index fe4f6cbbb70b3f..887e41e533af81 100644 --- a/recipes/capnproto/config.yml +++ b/recipes/capnproto/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.1": + folder: all "1.0.0": folder: all "0.10.4": From ea188dba2a282d4099161aba9e54b79f03f8de92 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 28 Aug 2023 11:03:04 +0200 Subject: [PATCH 0442/1140] (#19453) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 2a4a0fc59737a7..afef60a60fac71 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -36,6 +36,7 @@ required_for_references: - args-parser - argtable2 - argtable3 +- arrow - arsenalgear - artery-font-format - asio @@ -406,6 +407,7 @@ required_for_references: - harfbuzz - hash-library - hazelcast-cpp-client +- hdf4 - hdf5 - hdrhistogram-c - heatshrink @@ -795,6 +797,7 @@ required_for_references: - ogdf - ogg - ois +- onedpl - onetbb - oniguruma - onnx @@ -823,6 +826,7 @@ required_for_references: - openjpeg - openmesh - openmvg +- openpam - openssl - opensubdiv - opentdf-client @@ -945,6 +949,7 @@ required_for_references: - readosm - recastnavigation - reckless +- rectanglebinpack - rectpack2d - redis-plus-plus - refl-cpp From 7c3eaecd37e074784b19539ee1a9495a912c54c2 Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Mon, 28 Aug 2023 11:51:40 +0200 Subject: [PATCH 0443/1140] (#19416) [openapi-generator] Add version 7.0.0 * [openapi-generator] Add version 7.0.0 * Revert old version removal --- recipes/openapi-generator/all/conandata.yml | 3 +++ recipes/openapi-generator/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/openapi-generator/all/conandata.yml b/recipes/openapi-generator/all/conandata.yml index b429533e05e274..9624e0bf21d4b3 100644 --- a/recipes/openapi-generator/all/conandata.yml +++ b/recipes/openapi-generator/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "7.0.0": + url: "https://repo1.maven.org/maven2/org/openapitools/openapi-generator-cli/7.0.0/openapi-generator-cli-7.0.0.jar" + sha256: "80e8e9d71bdbdf513b8c65cf7d3fc2fe3d88aaeb4e39a2c6e20831f00032c775" "6.6.0": url: "https://repo1.maven.org/maven2/org/openapitools/openapi-generator-cli/6.6.0/openapi-generator-cli-6.6.0.jar" sha256: "9718ff7844e89462c75dcd9b20a35136f6db257bfe1b874db1e3002e99de4609" diff --git a/recipes/openapi-generator/config.yml b/recipes/openapi-generator/config.yml index 805a487d9c79bf..fc03893757ba99 100644 --- a/recipes/openapi-generator/config.yml +++ b/recipes/openapi-generator/config.yml @@ -1,4 +1,6 @@ versions: + "7.0.0": + folder: all "6.6.0": folder: all "6.5.0": From 4e520dae17d2b9ceefcde43e550f89f4a452a3bc Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Mon, 28 Aug 2023 15:13:23 +0200 Subject: [PATCH 0444/1140] (#19458) [scippp] Remove obsolete exports_sources from recipe --- recipes/scippp/all/conanfile.py | 1 - 1 file changed, 1 deletion(-) diff --git a/recipes/scippp/all/conanfile.py b/recipes/scippp/all/conanfile.py index 72d7e95e14f56e..1301e60281e0ec 100644 --- a/recipes/scippp/all/conanfile.py +++ b/recipes/scippp/all/conanfile.py @@ -12,7 +12,6 @@ class ScipPlusPlus(ConanFile): name = "scippp" settings = "os", "compiler", "build_type", "arch" generators = "CMakeDeps" - exports_sources = "CMakeLists.txt", "source/*", "include/*" description = "SCIP++ is a C++ wrapper for SCIP's C interface" package_type = "library" topics = ("mip", "solver", "linear", "programming") From 78304f761c5ea658f9a258614aaa0e65b7e7fb3c Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 29 Aug 2023 01:11:46 +0900 Subject: [PATCH 0445/1140] (#19468) blend2d: add version 0.10.5 --- recipes/blend2d/all/conandata.yml | 7 +++++++ recipes/blend2d/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/blend2d/all/conandata.yml b/recipes/blend2d/all/conandata.yml index 81cc43bbe5bf8e..70d8d5d6571cbc 100644 --- a/recipes/blend2d/all/conandata.yml +++ b/recipes/blend2d/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.10.5": + url: "https://blend2d.com/download/blend2d-0.10.5.tar.xz" + sha256: "fff5a7b1a6b16c986f3d02052a9a030f138fbae3a9c16bf07915416515d6b9cd" "0.10.4": url: "https://blend2d.com/download/blend2d-0.10.4.tar.xz" sha256: "6363e5c13c1c9e4709f949585a6af772ee13a16f75b0084f91b3918dece2fff3" @@ -18,6 +21,10 @@ sources: url: "https://blend2d.com/download/blend2d-beta17.zip" sha256: "06ee8fb0bea281d09291e498900093139426501a1a7f09dba0ec801dd340635e" patches: + "0.10.5": + - patch_file: "patches/0.10-0001-disable-embed-asmjit.patch" + patch_description: "use asmjit cci package" + patch_type: "conan" "0.10.4": - patch_file: "patches/0.10-0001-disable-embed-asmjit.patch" patch_description: "use asmjit cci package" diff --git a/recipes/blend2d/config.yml b/recipes/blend2d/config.yml index abc5bb6a7611e5..741838b7d47520 100644 --- a/recipes/blend2d/config.yml +++ b/recipes/blend2d/config.yml @@ -1,4 +1,6 @@ versions: + "0.10.5": + folder: all "0.10.4": folder: all "0.10": From 864f915dc9c9440774b3692607fef720eabbbb12 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 29 Aug 2023 02:11:04 +0900 Subject: [PATCH 0446/1140] (#19467) fmt: add version 10.1.1 --- recipes/fmt/all/conandata.yml | 3 +++ recipes/fmt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/fmt/all/conandata.yml b/recipes/fmt/all/conandata.yml index 0ab235a8e96faf..1ddc76ef1e6675 100644 --- a/recipes/fmt/all/conandata.yml +++ b/recipes/fmt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "10.1.1": + url: "https://github.com/fmtlib/fmt/releases/download/10.1.1/fmt-10.1.1.zip" + sha256: "b84e58a310c9b50196cda48d5678d5fa0849bca19e5fdba6b684f0ee93ed9d1b" "10.1.0": url: "https://github.com/fmtlib/fmt/releases/download/10.1.0/fmt-10.1.0.zip" sha256: "d725fa83a8b57a3cedf238828fa6b167f963041e8f9f7327649bddc68ae316f4" diff --git a/recipes/fmt/config.yml b/recipes/fmt/config.yml index 94b218a3040259..74db66d3ff4032 100644 --- a/recipes/fmt/config.yml +++ b/recipes/fmt/config.yml @@ -1,4 +1,6 @@ versions: + "10.1.1": + folder: all "10.1.0": folder: all "10.0.0": From cb68eb8f93017379dd195c31ccb188754c024e7d Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Tue, 29 Aug 2023 04:48:31 +0400 Subject: [PATCH 0447/1140] (#19174) onetbb: fixed hwloc setting on Windows --- recipes/onetbb/all/conanfile.py | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index fa6e990f3c8293..c06d17f237a247 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -126,18 +126,22 @@ def generate(self): if Version(self.version) >= "2021.6.0" and self.options.get_safe("tbbproxy"): toolchain.variables["TBBMALLOC_PROXY_BUILD"] = self.options.tbbproxy toolchain.variables["TBB_DISABLE_HWLOC_AUTOMATIC_SEARCH"] = not self._tbbbind_build - if self._tbbbind_build: - deps = PkgConfigDeps(self) - deps.generate() if self._tbbbind_explicit_hwloc: - hwloc_package_folder = self.dependencies["hwloc"].package_folder.replace("\\", "/") + hwloc_package_folder = self.dependencies["hwloc"].package_folder hwloc_lib_name = "hwloc.lib" if self.settings.os == "Windows" else "libhwloc.so" - toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_LIBRARY_PATH"] = os.path.join(hwloc_package_folder, "lib", hwloc_lib_name) - toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_INCLUDE_PATH"] = os.path.join(hwloc_package_folder, "include") + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_LIBRARY_PATH"] = \ + os.path.join(hwloc_package_folder, "lib", hwloc_lib_name).replace("\\", "/") + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_INCLUDE_PATH"] = \ + os.path.join(hwloc_package_folder, "include").replace("\\", "/") if self.settings.os == "Windows": - toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_DLL_PATH"] = os.path.join(hwloc_package_folder, "bin", "hwloc.dll") + toolchain.variables[f"CMAKE_HWLOC_{self._tbbbind_hwloc_version}_DLL_PATH"] = \ + os.path.join(hwloc_package_folder, "bin", "hwloc.dll").replace("\\", "/") toolchain.generate() + if self._tbbbind_build: + deps = PkgConfigDeps(self) + deps.generate() + def build(self): apply_conandata_patches(self) cmake = CMake(self) From f8266ff8f0b648960512afb302f09bd46e577f9d Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 29 Aug 2023 12:52:33 +0900 Subject: [PATCH 0448/1140] (#19471) ada: add version 2.6.4 --- recipes/ada/all/conandata.yml | 3 +++ recipes/ada/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index c93cb42b88d24d..1ffb1049ac57f3 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.4": + url: "https://github.com/ada-url/ada/archive/v2.6.4.tar.gz" + sha256: "5b488e9a7a700de5d40a749c96c4339bcc9c425e5f5406a0887b13e70bd90907" "2.6.2": url: "https://github.com/ada-url/ada/archive/v2.6.2.tar.gz" sha256: "425b8696a28a22d19ee7aa4516c26fc8ae3ab574870a9a74ef58ba8a345b822e" diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index cecfcc53ea282a..4b6a02c6d6d420 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.4": + folder: all "2.6.2": folder: all "2.6.0": From 4f8e2b225adbeec4b4bbc9989b0762cf8887bafe Mon Sep 17 00:00:00 2001 From: qwqbot Date: Tue, 29 Aug 2023 14:52:47 +0800 Subject: [PATCH 0449/1140] (#19473) msgpack-cxx: update boost/1.83 --- recipes/msgpack-cxx/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/msgpack-cxx/all/conanfile.py b/recipes/msgpack-cxx/all/conanfile.py index 0431bac108f83f..b2bcb90b0a576e 100644 --- a/recipes/msgpack-cxx/all/conanfile.py +++ b/recipes/msgpack-cxx/all/conanfile.py @@ -34,7 +34,7 @@ def layout(self): def requirements(self): if self.options.get_safe("use_boost", True): - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def package_id(self): self.info.clear() From 522a8f740a09a37a75ec02adf55b54b16cacb7a5 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Tue, 29 Aug 2023 11:33:25 +0400 Subject: [PATCH 0450/1140] (#19349) opencl-icd-loader: add OpenCL C++ headers as transitive dependency --- recipes/opencl-icd-loader/all/conanfile.py | 1 + recipes/opencl-icd-loader/all/test_package/test_package.c | 1 + 2 files changed, 2 insertions(+) diff --git a/recipes/opencl-icd-loader/all/conanfile.py b/recipes/opencl-icd-loader/all/conanfile.py index b7187e1a134cc0..ae7aae3d17794f 100644 --- a/recipes/opencl-icd-loader/all/conanfile.py +++ b/recipes/opencl-icd-loader/all/conanfile.py @@ -48,6 +48,7 @@ def layout(self): def requirements(self): self.requires(f"opencl-headers/{self.version}", transitive_headers=True) + self.requires(f"opencl-clhpp-headers/{self.version}", transitive_headers=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/opencl-icd-loader/all/test_package/test_package.c b/recipes/opencl-icd-loader/all/test_package/test_package.c index 4c923ce5886584..42b334ba331d45 100644 --- a/recipes/opencl-icd-loader/all/test_package/test_package.c +++ b/recipes/opencl-icd-loader/all/test_package/test_package.c @@ -1,3 +1,4 @@ +#define CL_TARGET_OPENCL_VERSION 120 #include int main() { From 969b025d3622285f1a6199edc0d4953f2bf5c63c Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 29 Aug 2023 11:04:23 +0200 Subject: [PATCH 0451/1140] (#19465) arrow: bump version of boost dependency --- recipes/arrow/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index abed7f510dbed9..cf876a25b31911 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -300,7 +300,7 @@ def requirements(self): if self.options.with_mimalloc: self.requires("mimalloc/1.7.6") if self.options.with_boost: - self.requires("boost/1.81.0") + self.requires("boost/1.82.0") if self.options.with_gflags: self.requires("gflags/2.2.2") if self.options.with_glog: From 3e44e653008f1575f228a6bf0cfd62db99dccece Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 29 Aug 2023 19:15:23 +0900 Subject: [PATCH 0452/1140] (#19457) zlib-ng: fix `with_optim` default value --- recipes/zlib-ng/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/zlib-ng/all/conanfile.py b/recipes/zlib-ng/all/conanfile.py index 2c536695c6f5e3..853a0a0f6a309e 100644 --- a/recipes/zlib-ng/all/conanfile.py +++ b/recipes/zlib-ng/all/conanfile.py @@ -34,7 +34,7 @@ class ZlibNgConan(ConanFile): "fPIC": True, "zlib_compat": False, "with_gzfileop": True, - "with_optim": False, + "with_optim": True, "with_new_strategies": True, "with_native_instructions": False, "with_reduced_mem": False, From c521d7b9fa8817850da0f8e575c0c883676b8ffb Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Tue, 29 Aug 2023 15:34:36 +0400 Subject: [PATCH 0453/1140] (#19452) onetbb: added pkgconf build dependency to find hwloc --- recipes/onetbb/all/conanfile.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index c06d17f237a247..bfc433ac097500 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -89,6 +89,10 @@ def requirements(self): if self._tbbbind_build: self.requires("hwloc/2.9.1") + def build_requirements(self): + if not self._tbbbind_explicit_hwloc and not self.conf.get("tools.gnu:pkg_config", check_type=str): + self.build_requires("pkgconf/1.9.3") + def layout(self): cmake_layout(self, src_folder="src") From b31af640bf50bebe1dd1b97531730ba79fbc280c Mon Sep 17 00:00:00 2001 From: Anton Date: Tue, 29 Aug 2023 12:34:07 +0000 Subject: [PATCH 0454/1140] (#19475) aggeom-agg: add version 2.7.1 --- recipes/aggeom-agg/all/conandata.yml | 3 +++ recipes/aggeom-agg/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/aggeom-agg/all/conandata.yml b/recipes/aggeom-agg/all/conandata.yml index 8b26697b0ef0d8..9203b7fc5e4241 100644 --- a/recipes/aggeom-agg/all/conandata.yml +++ b/recipes/aggeom-agg/all/conandata.yml @@ -2,3 +2,6 @@ sources: "2.6.1": url: "https://github.com/aggeom/agg-2.6/archive/refs/tags/agg-2.6.1.tar.gz" sha256: 685966f880f1c2aae19479b60525fafba8cbd88e4c62d1947767780df8f6a3d0 + "2.7.1": + url: "https://github.com/aggeom/agg-2.6/archive/refs/tags/agg-2.7.1.tar.gz" + sha256: 2174e55d7169502293e86f728d8698b5198dc7e42fbbda39e4d34c1411d1ac7a diff --git a/recipes/aggeom-agg/config.yml b/recipes/aggeom-agg/config.yml index cfb13334b8b03d..54947af157488b 100644 --- a/recipes/aggeom-agg/config.yml +++ b/recipes/aggeom-agg/config.yml @@ -1,3 +1,5 @@ versions: "2.6.1": folder: "all" + "2.7.1": + folder: "all" From cbd88a14d8d56d85bd275a715f73490de15cc183 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Tue, 29 Aug 2023 22:53:12 +0300 Subject: [PATCH 0455/1140] (#19484) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index a7f8c97edc459e..f39e87f6d648d2 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.14": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.14.tar.gz" + sha256: "b230f1a99a2a5f4f1f32748d52062276294b34d8254d4128193632e3a8ffaa4e" "2.0.13": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.13.tar.gz" sha256: "4e6cdcd54c5ce1e1ed9a97bd18ac5aeb7c15bb303193b4261058aef724fe9a41" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 3a7084f75ff201..8252adb0297679 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.14": + folder: all "2.0.13": folder: all "2.0.12": From 683a9c3ab4cf0ff4df4d6eb29e027947d5923925 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 07:33:09 +0900 Subject: [PATCH 0456/1140] (#19443) wasm-micro-runtime: add version 1.2.3 * wasm-micro-runtime: add version 1.2.3 * disable strip-all on apple-clang * disable strip on apple-clang * revert BUILD_SHARED_LIBS --- recipes/wasm-micro-runtime/all/conandata.yml | 7 ++ .../all/patches/1.2.3-0001-fix-cmake.patch | 88 +++++++++++++++++++ recipes/wasm-micro-runtime/config.yml | 2 + 3 files changed, 97 insertions(+) create mode 100644 recipes/wasm-micro-runtime/all/patches/1.2.3-0001-fix-cmake.patch diff --git a/recipes/wasm-micro-runtime/all/conandata.yml b/recipes/wasm-micro-runtime/all/conandata.yml index e6acc345307822..507fb63f458938 100644 --- a/recipes/wasm-micro-runtime/all/conandata.yml +++ b/recipes/wasm-micro-runtime/all/conandata.yml @@ -1,8 +1,15 @@ sources: + "1.2.3": + url: "https://github.com/bytecodealliance/wasm-micro-runtime/archive/refs/tags/WAMR-1.2.3.tar.gz" + sha256: "85057f788630dc1b8c371f5443cc192627175003a8ea63c491beaff29a338346" "1.2.2": url: "https://github.com/bytecodealliance/wasm-micro-runtime/archive/refs/tags/WAMR-1.2.2.tar.gz" sha256: "d328fc1e19c54cfdb4248b861de54b62977b9b85c0a40eaaeb9cd9b628c0c788" patches: + "1.2.3": + - patch_file: "patches/1.2.3-0001-fix-cmake.patch" + patch_description: "separate static and shasred build" + patch_type: "conan" "1.2.2": - patch_file: "patches/1.2.2-0001-fix-cmake.patch" patch_description: "separate static and shasred build" diff --git a/recipes/wasm-micro-runtime/all/patches/1.2.3-0001-fix-cmake.patch b/recipes/wasm-micro-runtime/all/patches/1.2.3-0001-fix-cmake.patch new file mode 100644 index 00000000000000..b67b2a33b5deab --- /dev/null +++ b/recipes/wasm-micro-runtime/all/patches/1.2.3-0001-fix-cmake.patch @@ -0,0 +1,88 @@ +diff --git a/a/CMakeLists.txt b/b/CMakeLists.txt +index fbea261..9f9892a 100644 +--- a/a/CMakeLists.txt ++++ b/b/CMakeLists.txt +@@ -108,17 +108,12 @@ endif () + set (WAMR_ROOT_DIR ${CMAKE_CURRENT_SOURCE_DIR}) + + # Set the strip command based on the system (GNU or Clang) +-if (CMAKE_STRIP) ++if (NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "AppleClang" AND CMAKE_STRIP) + set (CMAKE_STRIP_FLAGS "--strip-all") + endif () + + include (${WAMR_ROOT_DIR}/build-scripts/runtime_lib.cmake) + +-set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wformat -Wformat-security -Wshadow -Wno-unused-parameter") +-# set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wconversion -Wsign-conversion") +- +-set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra -Wformat -Wformat-security -Wno-unused") +- + if (WAMR_BUILD_TARGET MATCHES "X86_.*" OR WAMR_BUILD_TARGET STREQUAL "AMD_64") + if (NOT (CMAKE_C_COMPILER MATCHES ".*clang.*" OR CMAKE_C_COMPILER_ID MATCHES ".*Clang")) + set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -mindirect-branch-register") +@@ -135,11 +130,15 @@ endif () + + include (${SHARED_DIR}/utils/uncommon/shared_uncommon.cmake) + ++if (NOT BUILD_SHARED_LIBS) + # STATIC LIBRARY + add_library(iwasm_static STATIC ${WAMR_RUNTIME_LIB_SOURCE}) + set_target_properties (iwasm_static PROPERTIES OUTPUT_NAME vmlib) + target_include_directories(iwasm_static INTERFACE ${WAMR_ROOT_DIR}/core/iwasm/include) +-target_link_libraries (iwasm_static INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS} -lm -ldl -lpthread) ++target_link_libraries (iwasm_static INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS}) ++if(NOT MSVC) ++ target_link_libraries (iwasm_static INTERFACE -lm -ldl -lpthread) ++endif() + if (WAMR_BUILD_WASM_CACHE EQUAL 1) + target_link_libraries(iwasm_static INTERFACE boringssl_crypto) + endif () +@@ -147,19 +146,22 @@ endif () + install (TARGETS iwasm_static ARCHIVE DESTINATION lib) + + # If it's a Release build, strip the static library +-if (CMAKE_STRIP AND CMAKE_BUILD_TYPE STREQUAL "Release") ++if (0) + # Strip static library + message (STATUS "Stripping static library after build!") + add_custom_command (TARGET iwasm_static POST_BUILD + COMMAND ${CMAKE_STRIP} ${CMAKE_STRIP_FLAGS} $ + ) + endif () +- ++else() + # SHARED LIBRARY + add_library (iwasm_shared SHARED ${WAMR_RUNTIME_LIB_SOURCE}) + set_target_properties (iwasm_shared PROPERTIES OUTPUT_NAME iwasm) + target_include_directories(iwasm_shared INTERFACE ${WAMR_ROOT_DIR}/core/iwasm/include) +-target_link_libraries (iwasm_shared INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS} -lm -ldl -lpthread) ++target_link_libraries (iwasm_shared INTERFACE ${LLVM_AVAILABLE_LIBS} ${UV_A_LIBS}) ++if(NOT MSVC) ++ target_link_libraries (iwasm_shared INTERFACE -lm -ldl -lpthread) ++endif() + if (WAMR_BUILD_WASM_CACHE EQUAL 1) + target_link_libraries(iwasm_shared INTERFACE boringssl_crypto) + endif () +@@ -169,7 +171,7 @@ if (MINGW) + endif () + + install (TARGETS iwasm_shared LIBRARY DESTINATION lib) +- ++endif() + # HEADERS + install (FILES + ${WAMR_ROOT_DIR}/core/iwasm/include/wasm_c_api.h +@@ -177,6 +179,7 @@ install (FILES + ${WAMR_ROOT_DIR}/core/iwasm/include/lib_export.h + DESTINATION include) + ++if (NOT "${CMAKE_CXX_COMPILER_ID}" MATCHES "AppleClang" AND BUILD_SHARED_LIBS) + # If it's a Release build, strip the shared library + if (CMAKE_STRIP AND CMAKE_BUILD_TYPE STREQUAL "Release") + # Strip shared library +@@ -185,3 +188,4 @@ if (CMAKE_STRIP AND CMAKE_BUILD_TYPE STREQUAL "Release") + COMMAND ${CMAKE_STRIP} ${CMAKE_STRIP_FLAGS} $ + ) + endif () ++endif () diff --git a/recipes/wasm-micro-runtime/config.yml b/recipes/wasm-micro-runtime/config.yml index af40d9653a3783..6d9f399765e2d6 100644 --- a/recipes/wasm-micro-runtime/config.yml +++ b/recipes/wasm-micro-runtime/config.yml @@ -1,3 +1,5 @@ versions: + "1.2.3": + folder: all "1.2.2": folder: all From 2301b5f6bfc45d9aa5a236c506f26ed1f3ac7681 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 30 Aug 2023 07:32:49 +0200 Subject: [PATCH 0457/1140] (#19487) sqlpp11: fix import of Version --- recipes/sqlpp11/all/conanfile.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/recipes/sqlpp11/all/conanfile.py b/recipes/sqlpp11/all/conanfile.py index 9ada1d6896ced9..9b3a725b385595 100644 --- a/recipes/sqlpp11/all/conanfile.py +++ b/recipes/sqlpp11/all/conanfile.py @@ -1,9 +1,9 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.layout import basic_layout from conan.tools.files import get, copy -from conan import Version +from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os required_conan_version = ">=1.53.0" @@ -20,7 +20,6 @@ class Sqlpp11Conan(ConanFile): settings = "os", "arch", "compiler", "build_type" no_copy_source = True - @property def _min_cppstd(self): return 11 if Version(self.version) < "0.61" else 14 @@ -66,6 +65,4 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "sqlpp11::sqlpp11") # TODO: to remove in conan v2 once cmake_find_package_* generators removed - bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bindir)) - self.env_info.PATH.append(bindir) + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) From 57b28df83c2281b4feef8e91e018d21fb6d477a6 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 30 Aug 2023 08:09:05 +0200 Subject: [PATCH 0458/1140] (#19489) lefticus-tools: fix import of Version + add a layout * fix import of Version * add a layout --- recipes/lefticus-tools/all/conanfile.py | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/recipes/lefticus-tools/all/conanfile.py b/recipes/lefticus-tools/all/conanfile.py index b9179faa1d97b1..d3dbf33094acc5 100644 --- a/recipes/lefticus-tools/all/conanfile.py +++ b/recipes/lefticus-tools/all/conanfile.py @@ -1,9 +1,10 @@ from conan import ConanFile -from conan.tools.files import get, copy +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout from conan.tools.microsoft import is_msvc, check_min_vs -from conan.errors import ConanInvalidConfiguration -from conan import Version +from conan.tools.scm import Version import os @@ -33,6 +34,9 @@ def _compilers_minimum_version(self): "apple-clang": "14", } + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() From 1ad58e78a920a8695776fbdf8697f03f1608e8d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ra=C3=BAl=20Cumplido?= Date: Wed, 30 Aug 2023 08:30:10 +0200 Subject: [PATCH 0459/1140] (#19462) arrow: add version 13.0.0 * arrow: add version 13.0.0 * arrow: update minimum cmake version and patch cmake to use required version from conan * arrow: suggested fix adding build_requirements for CMake 3.16 * Revert back cmake_minimum_required --- recipes/arrow/all/conandata.yml | 3 +++ recipes/arrow/all/conanfile.py | 3 +++ recipes/arrow/config.yml | 2 ++ 3 files changed, 8 insertions(+) diff --git a/recipes/arrow/all/conandata.yml b/recipes/arrow/all/conandata.yml index 256a5f614578c5..5dcac7a820434e 100644 --- a/recipes/arrow/all/conandata.yml +++ b/recipes/arrow/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "13.0.0": + url: "https://www.apache.org/dyn/closer.lua/arrow/arrow-13.0.0/apache-arrow-13.0.0.tar.gz?action=download" + sha256: "35dfda191262a756be934eef8afee8d09762cad25021daa626eb249e251ac9e6" "12.0.1": url: "https://www.apache.org/dyn/closer.lua/arrow/arrow-12.0.1/apache-arrow-12.0.1.tar.gz?action=download" sha256: "3481c411393aa15c75e88d93cf8315faf7f43e180fe0790128d3840d417de858" diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index cf876a25b31911..a7f22fcf6eceef 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -527,6 +527,9 @@ def build(self): cmake.configure(build_script_folder=os.path.join(self.source_folder, "cpp")) cmake.build() + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") + def package(self): copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy(self, pattern="NOTICE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) diff --git a/recipes/arrow/config.yml b/recipes/arrow/config.yml index b6c86580b3492d..7a1c1ea27e611c 100644 --- a/recipes/arrow/config.yml +++ b/recipes/arrow/config.yml @@ -1,4 +1,6 @@ versions: + "13.0.0": + folder: all "12.0.1": folder: all "12.0.0": From a855d2677574777603fc69d3ab68317e6dcf4678 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 30 Aug 2023 09:31:14 +0200 Subject: [PATCH 0460/1140] (#19445) wil: add version 1.0.230824.2 --- recipes/wil/all/conandata.yml | 3 +++ recipes/wil/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/wil/all/conandata.yml b/recipes/wil/all/conandata.yml index 9253a5b752cf37..0c0fd9c9b3f6e4 100644 --- a/recipes/wil/all/conandata.yml +++ b/recipes/wil/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.230824.2": + url: "https://github.com/microsoft/wil/archive/refs/tags/v1.0.230824.2.tar.gz" + sha256: "15c6f90653fe91d2ab3c0c010735aee629c80519b4237611344f2e623f06aad2" "1.0.230629.1": url: "https://github.com/microsoft/wil/archive/refs/tags/v1.0.230629.1.tar.gz" sha256: "c0d9ad1f295e181aa28d7c9b219e7d530e6bc4b7533317be50e7eae760c8d63f" diff --git a/recipes/wil/config.yml b/recipes/wil/config.yml index 00c073f03a7a2b..98a5d552e5d6c0 100644 --- a/recipes/wil/config.yml +++ b/recipes/wil/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.230824.2": + folder: "all" "1.0.230629.1": folder: "all" "1.0.230411.1": From 792994b96816fe0a918c58cda3f1e2d603bd1949 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 30 Aug 2023 09:43:24 +0200 Subject: [PATCH 0461/1140] (#19455) nodejs: remove compiler from package id + add package_type * remove compiler from package id * add package_type --- recipes/nodejs/all/conanfile.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/nodejs/all/conanfile.py b/recipes/nodejs/all/conanfile.py index d08325293889af..c098d4eea47052 100644 --- a/recipes/nodejs/all/conanfile.py +++ b/recipes/nodejs/all/conanfile.py @@ -16,6 +16,7 @@ class NodejsConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://nodejs.org" license = "MIT" + package_type = "application" settings = "os", "arch", "compiler" no_copy_source = True short_paths = True @@ -40,6 +41,9 @@ def _glibc_version(self): self.run(cmd, buff) return str(re.search(r'GLIBC (\d{1,3}.\d{1,3})', buff.getvalue()).group(1)) + def package_id(self): + del self.info.settings.compiler + def validate(self): if not self.version in self.conan_data["sources"] or \ not str(self.settings.os) in self.conan_data["sources"][self.version] or \ From 54e66f87e71bc54dbed7cbd0b667b44ef45fe72a Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 16:56:44 +0900 Subject: [PATCH 0462/1140] (#19456) sqlitecpp: add version 3.3.1, add package_type * sqlitecpp: add version 3.3.1, update sqlite3, add package_type * revert sqlite3 --- recipes/sqlitecpp/all/conandata.yml | 3 +++ recipes/sqlitecpp/all/conanfile.py | 10 +++++----- recipes/sqlitecpp/config.yml | 2 ++ 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/recipes/sqlitecpp/all/conandata.yml b/recipes/sqlitecpp/all/conandata.yml index 9f7fc37611e768..a10675f0411088 100644 --- a/recipes/sqlitecpp/all/conandata.yml +++ b/recipes/sqlitecpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.3.1": + url: "https://github.com/SRombauts/SQLiteCpp/archive/3.3.1.tar.gz" + sha256: "71f990f9fb4b004533b6859ce40729af823b87fe691dd99ca084a7fd40db54b9" "3.3.0": url: "https://github.com/SRombauts/SQLiteCpp/archive/3.3.0.tar.gz" sha256: "4a37dd63cf91235ea2ef4494054700c144b3f96e93a330ef61ed53d106353e9c" diff --git a/recipes/sqlitecpp/all/conanfile.py b/recipes/sqlitecpp/all/conanfile.py index 3cb33ddd1e3dd8..836b5676e62e16 100644 --- a/recipes/sqlitecpp/all/conanfile.py +++ b/recipes/sqlitecpp/all/conanfile.py @@ -1,5 +1,5 @@ from conan import ConanFile -from conan.tools.files import copy, get, apply_conandata_patches, replace_in_file, rmdir, save +from conan.tools.files import copy, get, apply_conandata_patches, export_conandata_patches, replace_in_file, rmdir, save from conan.tools.scm import Version from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout @@ -14,10 +14,11 @@ class SQLiteCppConan(ConanFile): name = "sqlitecpp" description = "SQLiteCpp is a smart and easy to use C++ sqlite3 wrapper" - topics = ("sqlite", "sqlite3", "data-base") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/SRombauts/SQLiteCpp" - license = "MIT" + topics = ("sqlite", "sqlite3", "data-base") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -31,8 +32,7 @@ class SQLiteCppConan(ConanFile): } def export_sources(self): - for p in self.conan_data.get("patches", {}).get(self.version, []): - copy(self, p["patch_file"], self.recipe_folder, self.export_sources_folder) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": diff --git a/recipes/sqlitecpp/config.yml b/recipes/sqlitecpp/config.yml index 71f5731f373e29..b3381f7005ac85 100644 --- a/recipes/sqlitecpp/config.yml +++ b/recipes/sqlitecpp/config.yml @@ -1,4 +1,6 @@ versions: + "3.3.1": + folder: all "3.3.0": folder: all "3.2.1": From b4f1ebf63d1ddf693ec857a89b3aafa9a3948abe Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 30 Aug 2023 11:46:28 +0300 Subject: [PATCH 0463/1140] (#18656) kcp: migrate to Conan v2 * kcp: migrate to Conan v2 * kcp: simplify patches * kcp: fix shared builds on Windows * kcp: fix_apple_shared_install_name() --- recipes/kcp/all/CMakeLists.txt | 11 --- recipes/kcp/all/conandata.yml | 7 -- recipes/kcp/all/conanfile.py | 77 ++++++++++--------- .../0001-kcp-remove-add_library-STATIC.patch | 18 ----- recipes/kcp/all/test_package/CMakeLists.txt | 5 +- recipes/kcp/all/test_package/conanfile.py | 20 +++-- .../kcp/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/kcp/all/test_v1_package/conanfile.py | 16 ++++ 8 files changed, 82 insertions(+), 80 deletions(-) delete mode 100644 recipes/kcp/all/CMakeLists.txt delete mode 100644 recipes/kcp/all/patches/0001-kcp-remove-add_library-STATIC.patch create mode 100644 recipes/kcp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/kcp/all/test_v1_package/conanfile.py diff --git a/recipes/kcp/all/CMakeLists.txt b/recipes/kcp/all/CMakeLists.txt deleted file mode 100644 index 0feb437e184184..00000000000000 --- a/recipes/kcp/all/CMakeLists.txt +++ /dev/null @@ -1,11 +0,0 @@ -cmake_minimum_required(VERSION 3.4.0) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -if(WIN32 AND BUILD_SHARED_LIBS) - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) -endif() - -add_subdirectory(source_subfolder) diff --git a/recipes/kcp/all/conandata.yml b/recipes/kcp/all/conandata.yml index da8ca059669a33..4ecaaa44cfb1c9 100644 --- a/recipes/kcp/all/conandata.yml +++ b/recipes/kcp/all/conandata.yml @@ -5,10 +5,3 @@ sources: "1.7": url: "https://github.com/skywind3000/kcp/archive/1.7.tar.gz" sha256: "b4d26994d95599ab0c44e1f93002f9fda275094a879d66c192d79d596529199e" -patches: - "1.5": - - patch_file: "patches/0001-kcp-remove-add_library-STATIC.patch" - base_path: "source_subfolder" - "1.7": - - patch_file: "patches/0001-kcp-remove-add_library-STATIC.patch" - base_path: "source_subfolder" diff --git a/recipes/kcp/all/conanfile.py b/recipes/kcp/all/conanfile.py index ea23c3a999a55c..0146b7ee7c3cc8 100644 --- a/recipes/kcp/all/conanfile.py +++ b/recipes/kcp/all/conanfile.py @@ -1,17 +1,23 @@ -from conans import ConanFile, CMake, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, export_conandata_patches, get, rmdir, replace_in_file + +required_conan_version = ">=1.53.0" class KcpConan(ConanFile): name = "kcp" description = "A Fast and Reliable ARQ Protocol" - topics = ("conan", "kcp", "ARQ", "TCP", "protocol") - homepage = "https://github.com/skywind3000/kcp" - url = "https://github.com/conan-io/conan-center-index" license = "MIT" - exports_sources = "CMakeLists.txt", "patches/**" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/skywind3000/kcp" + topics = ("ARQ", "TCP", "protocol") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -20,18 +26,9 @@ class KcpConan(ConanFile): "shared": False, "fPIC": True, } - settings = "os", "arch", "compiler", "build_type" - generators = "cmake" - - _cmake = None - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -39,36 +36,46 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True + tc.variables["BUILD_TESTING"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() def _patch_sources(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) + # Fix shared builds on Windows + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + " STATIC", "") + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), + "ARCHIVE DESTINATION", + "RUNTIME DESTINATION bin\nARCHIVE DESTINATION") def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["kcp"] diff --git a/recipes/kcp/all/patches/0001-kcp-remove-add_library-STATIC.patch b/recipes/kcp/all/patches/0001-kcp-remove-add_library-STATIC.patch deleted file mode 100644 index b8c9f32e1e6583..00000000000000 --- a/recipes/kcp/all/patches/0001-kcp-remove-add_library-STATIC.patch +++ /dev/null @@ -1,18 +0,0 @@ ---- CMakeLists.txt -+++ CMakeLists.txt -@@ -5,12 +5,14 @@ - include(CTest) - include(GNUInstallDirs) - --add_library(kcp STATIC ikcp.c) -+add_library(kcp ikcp.c) - - install(FILES ikcp.h DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) - - install(TARGETS kcp - EXPORT kcp-targets -+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} -+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} - INCLUDES DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} - ) diff --git a/recipes/kcp/all/test_package/CMakeLists.txt b/recipes/kcp/all/test_package/CMakeLists.txt index d5b08913be93be..b15d2eca4c2a32 100644 --- a/recipes/kcp/all/test_package/CMakeLists.txt +++ b/recipes/kcp/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(kcp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/kcp/all/test_package/conanfile.py b/recipes/kcp/all/test_package/conanfile.py index f8eeed898d7bd1..ef5d7042163ecc 100644 --- a/recipes/kcp/all/test_package/conanfile.py +++ b/recipes/kcp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - self.run(os.path.join("bin", "test_package"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/kcp/all/test_v1_package/CMakeLists.txt b/recipes/kcp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/kcp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/kcp/all/test_v1_package/conanfile.py b/recipes/kcp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..f8eeed898d7bd1 --- /dev/null +++ b/recipes/kcp/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + self.run(os.path.join("bin", "test_package"), run_environment=True) From 41e8aed293abe8910fc78a80dd27578bf0ac3952 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 30 Aug 2023 11:22:21 +0200 Subject: [PATCH 0464/1140] (#19464) [bot] Update authorized users list (2023-08-28) --- .c3i/authorized_users.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index b68f4b3ff03987..40eb28806b2ca8 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1217,3 +1217,8 @@ authorized_users: - jwfallawuiuc - tgurriet - mgfernan +- chrisc66 +- KevDi +- XVilka +- DoomHammer +- cschreib From 26d01f8360943a73f7a1e32e3b94e09454fd65a5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 30 Aug 2023 11:43:58 +0200 Subject: [PATCH 0465/1140] (#17120) aws-crt-cpp: add missing interface definition if shared * add AWS_CRT_CPP_USE_IMPORT_EXPORT interface definition if shared * more elegant way to define target for legacy generators * add missing transitive headers * aws-c-common is a public dependency * fix traits --- recipes/aws-crt-cpp/all/conanfile.py | 70 ++++++++++++++++------------ 1 file changed, 40 insertions(+), 30 deletions(-) diff --git a/recipes/aws-crt-cpp/all/conanfile.py b/recipes/aws-crt-cpp/all/conanfile.py index 0b0f3153a28632..97c0f616bb653c 100644 --- a/recipes/aws-crt-cpp/all/conanfile.py +++ b/recipes/aws-crt-cpp/all/conanfile.py @@ -1,10 +1,11 @@ from conan import ConanFile -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir, save from conan.tools.build import check_min_cppstd from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout import os +import textwrap required_conan_version = ">=1.53.0" @@ -46,22 +47,23 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.8.2") + self.requires("aws-c-cal/0.5.13", transitive_headers=True) + self.requires("aws-c-common/0.8.2", transitive_headers=True) self.requires("aws-checksums/0.1.13") if Version(self.version) < "0.17.29": - self.requires("aws-c-io/0.10.20") - self.requires("aws-c-http/0.6.13") - self.requires("aws-c-auth/0.6.11") - self.requires("aws-c-s3/0.1.37") - self.requires("aws-c-mqtt/0.7.10") + self.requires("aws-c-auth/0.6.11", transitive_headers=True) self.requires("aws-c-event-stream/0.2.7") + self.requires("aws-c-http/0.6.13", transitive_headers=True) + self.requires("aws-c-io/0.10.20", transitive_headers=True) + self.requires("aws-c-mqtt/0.7.10", transitive_headers=True) + self.requires("aws-c-s3/0.1.37") else: - self.requires("aws-c-io/0.13.4") - self.requires("aws-c-http/0.6.22") - self.requires("aws-c-auth/0.6.17") - self.requires("aws-c-s3/0.1.49") - self.requires("aws-c-mqtt/0.7.12") + self.requires("aws-c-auth/0.6.17", transitive_headers=True) self.requires("aws-c-event-stream/0.2.15") + self.requires("aws-c-http/0.6.22", transitive_headers=True) + self.requires("aws-c-io/0.13.4", transitive_headers=True) + self.requires("aws-c-mqtt/0.7.12", transitive_headers=True) + self.requires("aws-c-s3/0.1.49") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -91,26 +93,34 @@ def package(self): cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "aws-crt-cpp")) + # TODO: to remove in conan v2 once legacy generators removed + self._create_cmake_module_alias_targets( + os.path.join(self.package_folder, self._module_file_rel_path), + {"AWS::aws-crt-cpp": "aws-crt-cpp::aws-crt-cpp"} + ) + + def _create_cmake_module_alias_targets(self, module_file, targets): + content = "" + for alias, aliased in targets.items(): + content += textwrap.dedent(f"""\ + if(TARGET {aliased} AND NOT TARGET {alias}) + add_library({alias} INTERFACE IMPORTED) + set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) + endif() + """) + save(self, module_file, content) + + @property + def _module_file_rel_path(self): + return os.path.join("lib", "cmake", f"conan-official-{self.name}-targets.cmake") + def package_info(self): self.cpp_info.set_property("cmake_file_name", "aws-crt-cpp") self.cpp_info.set_property("cmake_target_name", "AWS::aws-crt-cpp") - - self.cpp_info.components["aws-crt-cpp-lib"].names["cmake_find_package"] = "aws-crt-cpp" - self.cpp_info.components["aws-crt-cpp-lib"].names["cmake_find_package_multi"] = "aws-crt-cpp" - self.cpp_info.components["aws-crt-cpp-lib"].libs = ["aws-crt-cpp"] - self.cpp_info.components["aws-crt-cpp-lib"].requires = [ - "aws-c-event-stream::aws-c-event-stream-lib", - "aws-c-common::aws-c-common-lib", - "aws-c-io::aws-c-io-lib", - "aws-c-http::aws-c-http-lib", - "aws-c-auth::aws-c-auth-lib", - "aws-c-mqtt::aws-c-mqtt-lib", - "aws-c-s3::aws-c-s3-lib", - "aws-checksums::aws-checksums-lib" - ] + self.cpp_info.libs = ["aws-crt-cpp"] + if self.options.shared: + self.cpp_info.defines.append("AWS_CRT_CPP_USE_IMPORT_EXPORT") # TODO: to remove in conan v2 once cmake_find_package_* generators removed - self.cpp_info.filenames["cmake_find_package"] = "aws-crt-cpp" - self.cpp_info.filenames["cmake_find_package_multi"] = "aws-crt-cpp" - self.cpp_info.names["cmake_find_package"] = "AWS" - self.cpp_info.names["cmake_find_package_multi"] = "AWS" + self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] From 11bbd4feea4bd305b8149c9e8f4854b7f1025cd2 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 19:12:57 +0900 Subject: [PATCH 0466/1140] (#19432) xlsxio: update dependencies --- recipes/xlsxio/all/conanfile.py | 4 ++-- recipes/xlsxio/all/patches/0234_cmake.patch | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/xlsxio/all/conanfile.py b/recipes/xlsxio/all/conanfile.py index 55de1430b90bda..b5d3c01dc87ce2 100644 --- a/recipes/xlsxio/all/conanfile.py +++ b/recipes/xlsxio/all/conanfile.py @@ -58,9 +58,9 @@ def layout(self): def requirements(self): if self.options.with_libzip: - self.requires("libzip/1.9.2") + self.requires("libzip/1.10.1") elif Version(self.version) >= "0.2.34" and self.options.with_minizip_ng : - self.requires("minizip-ng/3.0.8") + self.requires("minizip-ng/4.0.1") else: self.requires("minizip/1.2.13") self.requires("expat/2.5.0") diff --git a/recipes/xlsxio/all/patches/0234_cmake.patch b/recipes/xlsxio/all/patches/0234_cmake.patch index 0000f8397c5c4b..ea858da988ead9 100644 --- a/recipes/xlsxio/all/patches/0234_cmake.patch +++ b/recipes/xlsxio/all/patches/0234_cmake.patch @@ -29,7 +29,7 @@ index bf4e9bf..f0d6a0e 100644 - FIND_PACKAGE(minizip${MINIZIP_NG_SUFFIX} REQUIRED) - SET(ANYZIP_INCLUDE_DIRS "${minizip-ng_DIR}/../../../include/minizip${MINIZIP_NG_SUFFIX}") - SET(ANYZIP_LIBRARIES minizip${MINIZIP_NG_SUFFIX}) -+ FIND_PACKAGE(minizip 3 REQUIRED) ++ FIND_PACKAGE(minizip REQUIRED) + IF(minizip_INCLUDE_DIRS) + SET(ANYZIP_INCLUDE_DIRS ${minizip_INCLUDE_DIRS}) + SET(ANYZIP_LIBRARIES ${minizip_LIBRARIES}) From 609bb042ec8bceda1cebb72559d18a0153e5138b Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 19:53:21 +0900 Subject: [PATCH 0467/1140] (#19434) c-blosc2: add version 2.10.2, update dependencies * c-blosc2: add version 2.10.2, update dependencies * rmdir lib/cmake * rmdir cmake --- recipes/c-blosc2/all/conandata.yml | 7 + recipes/c-blosc2/all/conanfile.py | 4 +- .../all/patches/2.10.2-0001-fix-cmake.patch | 139 ++++++++++++++++++ recipes/c-blosc2/config.yml | 2 + 4 files changed, 151 insertions(+), 1 deletion(-) create mode 100644 recipes/c-blosc2/all/patches/2.10.2-0001-fix-cmake.patch diff --git a/recipes/c-blosc2/all/conandata.yml b/recipes/c-blosc2/all/conandata.yml index 09b337eb1d3e7a..974c48eeac6987 100644 --- a/recipes/c-blosc2/all/conandata.yml +++ b/recipes/c-blosc2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.10.2": + url: "https://github.com/Blosc/c-blosc2/archive/v2.10.2.tar.gz" + sha256: "069785bc14c006c7dab40ea0c620bdf3eb8752663fd55c706d145bceabc2a31d" "2.10.0": url: "https://github.com/Blosc/c-blosc2/archive/v2.10.0.tar.gz" sha256: "cb7f7c0c62af78982140ecff21a2f3ca9ce6a0a1c02e314fcdce1a98da0fe231" @@ -24,6 +27,10 @@ sources: url: "https://github.com/Blosc/c-blosc2/archive/refs/tags/v2.2.0.tar.gz" sha256: "66f9977de26d6bc9ea1c0e623d873c3225e4fff709aa09b3335fd09d41d57c0e" patches: + "2.10.2": + - patch_file: "patches/2.10.2-0001-fix-cmake.patch" + patch_description: "use cci package" + patch_type: "conan" "2.10.0": - patch_file: "patches/2.10.0-0001-fix-cmake.patch" patch_description: "use cci package" diff --git a/recipes/c-blosc2/all/conanfile.py b/recipes/c-blosc2/all/conanfile.py index 3d06cc9c0ee524..9cfb0264ed537a 100644 --- a/recipes/c-blosc2/all/conanfile.py +++ b/recipes/c-blosc2/all/conanfile.py @@ -67,7 +67,7 @@ def requirements(self): if self.options.with_lz4: self.requires("lz4/1.9.4") if self.options.with_zlib in ["zlib-ng", "zlib-ng-compat"]: - self.requires("zlib-ng/2.1.2") + self.requires("zlib-ng/2.1.3") elif self.options.with_zlib == "zlib": self.requires("zlib/1.2.13") if self.options.with_zstd: @@ -132,6 +132,8 @@ def package(self): cmake = CMake(self) cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "cmake")) # Remove MS runtime files for dll_pattern_to_remove in ["concrt*.dll", "msvcp*.dll", "vcruntime*.dll"]: diff --git a/recipes/c-blosc2/all/patches/2.10.2-0001-fix-cmake.patch b/recipes/c-blosc2/all/patches/2.10.2-0001-fix-cmake.patch new file mode 100644 index 00000000000000..b530262f17fda2 --- /dev/null +++ b/recipes/c-blosc2/all/patches/2.10.2-0001-fix-cmake.patch @@ -0,0 +1,139 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 4b4fc6a..79d61da 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -152,26 +152,26 @@ if(BUILD_LITE) + endif() + + if(PREFER_EXTERNAL_LZ4) +- find_package(LZ4) ++ find_package(lz4) + else() + message(STATUS "Using LZ4 internal sources.") + endif() + + if(NOT DEACTIVATE_ZLIB) + if(PREFER_EXTERNAL_ZLIB) +- find_package(ZLIB_NG) +- if(ZLIB_NG_FOUND) ++ find_package(zlib_ng) ++ if(zlib_ng_FOUND) + set(HAVE_ZLIB_NG TRUE) + else() + find_package(ZLIB) + endif() + +- if(NOT (ZLIB_NG_FOUND OR ZLIB_FOUND)) ++ if(NOT (zlib_ng_FOUND OR ZLIB_FOUND)) + message(STATUS "No ZLIB found. Using ZLIB-NG internal sources.") + endif() + endif() + +- if(NOT (ZLIB_NG_FOUND OR ZLIB_FOUND)) ++ if(0) + message(STATUS "Using ZLIB-NG internal sources for ZLIB support.") + set(HAVE_ZLIB_NG TRUE) + add_definitions(-DZLIB_COMPAT) +@@ -192,8 +192,8 @@ endif() + + if(NOT DEACTIVATE_ZSTD) + if(PREFER_EXTERNAL_ZSTD) +- find_package(ZSTD) +- if(NOT ZSTD_FOUND) ++ find_package(zstd) ++ if(NOT zstd_FOUND) + message(STATUS "No ZSTD library found. Using internal sources.") + endif() + else() +diff --git a/blosc/CMakeLists.txt b/blosc/CMakeLists.txt +index b44b710..681705e 100644 +--- a/blosc/CMakeLists.txt ++++ b/blosc/CMakeLists.txt +@@ -79,15 +79,15 @@ set(INTERNAL_LIBS ${PROJECT_SOURCE_DIR}/internal-complibs) + # link dependencies + # "link" dependent targets via target_link_libraries (preferred) and + # manually add includes / libs for others +-if(LZ4_FOUND) ++if(lz4_FOUND) + if(BUILD_SHARED) +- target_include_directories(blosc2_shared PUBLIC ${LZ4_INCLUDE_DIR}) ++ target_include_directories(blosc2_shared PUBLIC ${lz4_INCLUDE_DIR}) + endif() + if(BUILD_STATIC) +- target_include_directories(blosc2_static PUBLIC ${LZ4_INCLUDE_DIR}) ++ target_include_directories(blosc2_static PUBLIC ${lz4_INCLUDE_DIR}) + endif() + if(BUILD_TESTS) +- target_include_directories(blosc_testing PUBLIC ${LZ4_INCLUDE_DIR}) ++ target_include_directories(blosc_testing PUBLIC ${lz4_INCLUDE_DIR}) + endif() + else() + set(LZ4_LOCAL_DIR ${INTERNAL_LIBS}/lz4-1.9.4) +@@ -138,18 +138,18 @@ if(NOT DEACTIVATE_ZLIB) + endif() + + if(NOT DEACTIVATE_ZSTD) +- if(ZSTD_FOUND) ++ if(zstd_FOUND) + if(BUILD_SHARED) +- target_include_directories(blosc2_shared PUBLIC ${ZSTD_INCLUDE_DIR}) +- target_link_libraries(blosc2_shared PUBLIC ${ZSTD_LIBRARY}) ++ target_include_directories(blosc2_shared PUBLIC ${zstd_INCLUDE_DIR}) ++ target_link_libraries(blosc2_shared PUBLIC ${zstd_LIBRARY}) + endif() + if(BUILD_STATIC) +- target_include_directories(blosc2_static PUBLIC ${ZSTD_INCLUDE_DIR}) +- target_link_libraries(blosc2_static PUBLIC ${ZSTD_LIBRARY}) ++ target_include_directories(blosc2_static PUBLIC ${zstd_INCLUDE_DIR}) ++ target_link_libraries(blosc2_static PUBLIC ${zstd_LIBRARY}) + endif() + if(BUILD_TESTS) +- target_include_directories(blosc_testing PUBLIC ${ZSTD_INCLUDE_DIR}) +- target_link_libraries(blosc_testing PUBLIC ${ZSTD_LIBRARY}) ++ target_include_directories(blosc_testing PUBLIC ${zstd_INCLUDE_DIR}) ++ target_link_libraries(blosc_testing PUBLIC ${zstd_LIBRARY}) + endif() + else() + set(ZSTD_LOCAL_DIR ${INTERNAL_LIBS}/zstd-1.5.5) +@@ -190,8 +190,8 @@ else() + set(LIBS ${LIBS} ${CMAKE_DL_LIBS}) + endif() + +-if(LZ4_FOUND) +- set(LIBS ${LIBS} ${LZ4_LIBRARY}) ++if(lz4_FOUND) ++ set(LIBS ${LIBS} ${lz4_LIBRARIES}) + else() + file(GLOB LZ4_FILES ${LZ4_LOCAL_DIR}/*.c) + list(APPEND SOURCES ${LZ4_FILES}) +@@ -199,8 +199,8 @@ else() + endif() + + if(NOT DEACTIVATE_ZLIB) +- if(ZLIB_NG_FOUND) +- set(LIBS ${LIBS} ${ZLIB_NG_LIBRARY}) ++ if(zlib_ng_FOUND) ++ set(LIBS ${LIBS} ${zlib_ng_LIBRARIES}) + elseif(ZLIB_FOUND) + set(LIBS ${LIBS} ${ZLIB_LIBRARIES}) + else() +@@ -212,8 +212,8 @@ if(NOT DEACTIVATE_ZLIB) + endif() + + if(NOT DEACTIVATE_ZSTD) +- if(ZSTD_FOUND) +- set(LIBS ${LIBS} ${ZSTD_LIBRARY}) ++ if(zstd_FOUND) ++ set(LIBS ${LIBS} ${zstd_LIBRARIES}) + else() + # Enable assembly code only when not using MSVC *and* x86 is there + if((NOT MSVC) AND COMPILER_SUPPORT_SSE2) # if SSE2 is here, this is an x86 platform +@@ -268,7 +268,7 @@ list(APPEND SOURCES + blosc/directories.c + blosc/blosc2-stdio.c + blosc/b2nd.c +- blosc/b2nd_utils.c ++ blosc/b2nd_utils.c + ) + if(NOT CMAKE_SYSTEM_PROCESSOR STREQUAL arm64) + if(COMPILER_SUPPORT_SSE2) diff --git a/recipes/c-blosc2/config.yml b/recipes/c-blosc2/config.yml index 94edc65e4565ad..42ffc68cfe344c 100644 --- a/recipes/c-blosc2/config.yml +++ b/recipes/c-blosc2/config.yml @@ -1,4 +1,6 @@ versions: + "2.10.2": + folder: all "2.10.0": folder: all "2.8.0": From 2b2cfd77dc31982370a89f21528623f38ab0f30e Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 20:58:56 +0900 Subject: [PATCH 0468/1140] (#19437) drogon: add version 1.8.6, fix compilation error on 1.8.5 with yaml-cpp --- recipes/drogon/all/conandata.yml | 10 +++ recipes/drogon/all/conanfile.py | 8 ++- .../1.8.5-0002-find-cci-packages.patch | 16 ++--- .../1.8.6-0002-find-cci-packages.patch | 71 +++++++++++++++++++ recipes/drogon/config.yml | 2 + 5 files changed, 96 insertions(+), 11 deletions(-) create mode 100644 recipes/drogon/all/patches/1.8.6-0002-find-cci-packages.patch diff --git a/recipes/drogon/all/conandata.yml b/recipes/drogon/all/conandata.yml index 5ff1403cfce784..d62ebab92171a2 100644 --- a/recipes/drogon/all/conandata.yml +++ b/recipes/drogon/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.6": + url: "https://github.com/drogonframework/drogon/archive/v1.8.6.tar.gz" + sha256: "ff02979f28047e97e19e36d1f363b3052b8122975fa8a379305d746dfe5fb004" "1.8.5": url: "https://github.com/drogonframework/drogon/archive/v1.8.5.tar.gz" sha256: "9469f99408c114bc1e89945a3a8dab4640ea6d8cb06e7d42f06c1dfda3f71d2a" @@ -18,6 +21,13 @@ sources: url: "https://github.com/drogonframework/drogon/archive/refs/tags/v1.7.5.tar.gz" sha256: "e2af7c55dcabafef16f26f5b3242692f5a2b54c19b7b626840bf9132d24766f6" patches: + "1.8.6": + - patch_file: "patches/1.8.5-0001-remove-shared-libs.patch" + patch_description: "remove shared libs option" + patch_type: "conan" + - patch_file: "patches/1.8.6-0002-find-cci-packages.patch" + patch_description: "Fix jsoncpp cmake target name" + patch_type: "conan" "1.8.5": - patch_file: "patches/1.8.5-0001-remove-shared-libs.patch" patch_description: "remove shared libs option" diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index fc1a2251f569c1..1cde167ffc5cc2 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -57,6 +57,8 @@ def export_sources(self): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) < "1.8.4": + del self.options.with_yaml_cpp def configure(self): if self.options.shared: @@ -128,8 +130,8 @@ def requirements(self): self.requires("sqlite3/3.42.0") if self.options.get_safe("with_redis"): self.requires("hiredis/1.2.0") - if self.options.with_yaml_cpp: - self.requires("yaml-cpp/0.7.0") + if self.options.get_safe("with_yaml_cpp", False): + self.requires("yaml-cpp/0.8.0") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -146,7 +148,7 @@ def generate(self): tc.variables["BUILD_DROGON_SHARED"] = self.options.shared tc.variables["BUILD_DOC"] = False tc.variables["BUILD_BROTLI"] = self.options.with_brotli - tc.variables["BUILD_YAML_CONFIG"] = self.options.with_yaml_cpp + tc.variables["BUILD_YAML_CONFIG"] = self.options.get_safe("with_yaml_cpp", False) tc.variables["BUILD_POSTGRESQL"] = self.options.get_safe("with_postgres", False) tc.variables["BUILD_POSTGRESQL_BATCH"] = self.options.get_safe("with_postgres_batch", False) tc.variables["BUILD_MYSQL"] = self.options.get_safe("with_mysql", False) diff --git a/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch b/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch index c0d5c051d80a78..8bf9e60842f932 100644 --- a/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch +++ b/recipes/drogon/all/patches/1.8.5-0002-find-cci-packages.patch @@ -1,5 +1,5 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index e3e7fcf..b82cb66 100755 +index e3e7fcf..d1032da 100755 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -198,9 +198,9 @@ else() @@ -15,15 +15,15 @@ index e3e7fcf..b82cb66 100755 # yamlcpp if(BUILD_YAML_CONFIG) -@@ -217,7 +217,7 @@ if(BUILD_YAML_CONFIG) +@@ -212,7 +212,7 @@ if(BUILD_YAML_CONFIG) + message(STATUS "yaml-cpp not used") + else() + message(STATUS "yaml-cpp found ") +- target_link_libraries(${PROJECT_NAME} PUBLIC ${YAML_CPP_LINK_LIBRARY}) ++ target_link_libraries(${PROJECT_NAME} PUBLIC yaml-cpp) + target_compile_definitions(${PROJECT_NAME} PUBLIC HAS_YAML_CPP) endif() else() - message(STATUS "yaml-cpp found ") -- target_link_libraries(${PROJECT_NAME} PUBLIC ${YAML_CPP_LIBRARIES}) -+ target_link_libraries(${PROJECT_NAME} PUBLIC yaml-cpp) - target_compile_definitions(${PROJECT_NAME} PUBLIC HAS_YAML_CPP) - endif() - else() @@ -442,7 +442,7 @@ if (BUILD_SQLITE) find_package(SQLite3 QUIET) find_package(unofficial-sqlite3 QUIET) diff --git a/recipes/drogon/all/patches/1.8.6-0002-find-cci-packages.patch b/recipes/drogon/all/patches/1.8.6-0002-find-cci-packages.patch new file mode 100644 index 00000000000000..3da404b88ccc2b --- /dev/null +++ b/recipes/drogon/all/patches/1.8.6-0002-find-cci-packages.patch @@ -0,0 +1,71 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a3ba35a..26fed2a 100755 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -198,9 +198,9 @@ else() + endif() + + # jsoncpp +-find_package(Jsoncpp REQUIRED) +-target_link_libraries(${PROJECT_NAME} PUBLIC Jsoncpp_lib) +-list(APPEND INCLUDE_DIRS_FOR_DYNAMIC_VIEW ${JSONCPP_INCLUDE_DIRS}) ++find_package(jsoncpp REQUIRED) ++target_link_libraries(${PROJECT_NAME} PUBLIC jsoncpp_lib) ++list(APPEND INCLUDE_DIRS_FOR_DYNAMIC_VIEW ${jsoncpp_INCLUDE_DIRS}) + + # yamlcpp + if(BUILD_YAML_CONFIG) +@@ -212,7 +212,7 @@ if(BUILD_YAML_CONFIG) + message(STATUS "yaml-cpp not used") + else() + message(STATUS "yaml-cpp found ") +- target_link_libraries(${PROJECT_NAME} PUBLIC ${YAML_CPP_LINK_LIBRARY}) ++ target_link_libraries(${PROJECT_NAME} PUBLIC yaml-cpp) + target_compile_definitions(${PROJECT_NAME} PUBLIC HAS_YAML_CPP) + endif() + else() +@@ -444,7 +444,7 @@ if (BUILD_SQLITE) + find_package(SQLite3 QUIET) + find_package(unofficial-sqlite3 QUIET) + if (SQLite3_FOUND) +- target_link_libraries(${PROJECT_NAME} PRIVATE SQLite3_lib) ++ target_link_libraries(${PROJECT_NAME} PRIVATE SQLite::SQLite3) + set(DROGON_FOUND_SQLite3 TRUE) + elseif (unofficial-sqlite3_FOUND) + target_link_libraries(${PROJECT_NAME} PRIVATE unofficial::sqlite3::sqlite3) +@@ -467,10 +467,10 @@ if (BUILD_SQLITE) + endif (BUILD_SQLITE) + + if (BUILD_REDIS) +- find_package(Hiredis) +- if (Hiredis_FOUND) ++ find_package(hiredis) ++ if (hiredis_FOUND) + add_definitions(-DUSE_REDIS) +- target_link_libraries(${PROJECT_NAME} PRIVATE Hiredis_lib) ++ target_link_libraries(${PROJECT_NAME} PRIVATE hiredis::hiredis) + set(DROGON_SOURCES + ${DROGON_SOURCES} + nosql_lib/redis/src/RedisClientImpl.cc +@@ -490,10 +490,10 @@ if (BUILD_REDIS) + nosql_lib/redis/src/SubscribeContext.h + nosql_lib/redis/src/RedisSubscriberImpl.h) + +- endif (Hiredis_FOUND) ++ endif () + endif (BUILD_REDIS) + +-if (NOT Hiredis_FOUND) ++if (NOT hiredis_FOUND) + set(DROGON_SOURCES + ${DROGON_SOURCES} + lib/src/RedisClientSkipped.cc +@@ -502,7 +502,7 @@ if (NOT Hiredis_FOUND) + set(private_headers + ${private_headers} + lib/src/RedisClientManager.h) +-endif (NOT Hiredis_FOUND) ++endif () + + if (BUILD_TESTING) + add_subdirectory(nosql_lib/redis/tests) diff --git a/recipes/drogon/config.yml b/recipes/drogon/config.yml index bf708bafce8a97..62f17e07b2e955 100644 --- a/recipes/drogon/config.yml +++ b/recipes/drogon/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.6": + folder: "all" "1.8.5": folder: "all" "1.8.4": From 9080ff11d6f8014b4a508fb919d3ef6f9c29dd35 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 21:51:49 +0900 Subject: [PATCH 0469/1140] (#19441) dbg-macro: add version 0.5.0 --- recipes/dbg-macro/all/conandata.yml | 7 +++++-- recipes/dbg-macro/all/conanfile.py | 26 ++++++++++++++++---------- recipes/dbg-macro/config.yml | 2 ++ 3 files changed, 23 insertions(+), 12 deletions(-) diff --git a/recipes/dbg-macro/all/conandata.yml b/recipes/dbg-macro/all/conandata.yml index 695393e722d3f4..4beffe08cb1f1f 100644 --- a/recipes/dbg-macro/all/conandata.yml +++ b/recipes/dbg-macro/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.5.0": + url: "https://github.com/sharkdp/dbg-macro/archive/v0.5.0.tar.gz" + sha256: "dac4907aadf39dbd9eac279a214c59ad30af6c0c3d585688242f73cb1a9ce243" "0.4.0": - sha256: e44a1206fbfd1d3dc8ad649f387df479d288b08c80cf2f1239ccb4e26148d781 - url: https://github.com/sharkdp/dbg-macro/archive/v0.4.0.tar.gz + url: "https://github.com/sharkdp/dbg-macro/archive/v0.4.0.tar.gz" + sha256: "e44a1206fbfd1d3dc8ad649f387df479d288b08c80cf2f1239ccb4e26148d781" diff --git a/recipes/dbg-macro/all/conanfile.py b/recipes/dbg-macro/all/conanfile.py index 5955544e24b0db..c4b00757159daa 100644 --- a/recipes/dbg-macro/all/conanfile.py +++ b/recipes/dbg-macro/all/conanfile.py @@ -9,7 +9,6 @@ required_conan_version = ">=1.52.0" - class DbgMacroConan(ConanFile): name = "dbg-macro" description = "A dbg(...) macro for C++" @@ -17,11 +16,20 @@ class DbgMacroConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/sharkdp/dbg-macro" topics = ("debugging", "macro", "pretty-printing", "header-only") - package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "8", + } + def layout(self): basic_layout(self, src_folder="src") @@ -30,15 +38,13 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe('cppstd'): - check_min_cppstd(self, 17) - - min_versions = { - "gcc": 8 - } + check_min_cppstd(self, self._min_cppstd) - compiler = self.settings.compiler - if str(compiler) in min_versions and Version(compiler.version) < min_versions[str(compiler)]: - raise ConanInvalidConfiguration("dbg-macro requires C++17 which your compiler does not support.") + 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) diff --git a/recipes/dbg-macro/config.yml b/recipes/dbg-macro/config.yml index da269653d6e6bc..49f293dbf19712 100644 --- a/recipes/dbg-macro/config.yml +++ b/recipes/dbg-macro/config.yml @@ -1,3 +1,5 @@ versions: + "0.5.0": + folder: "all" "0.4.0": folder: "all" From 71967a0558009446af91f15deba61d5180c13a1b Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 22:10:20 +0900 Subject: [PATCH 0470/1140] (#19449) clickhouse-cpp: enable `with_openssl` options * clickhouse-cpp: enable `enable_benchmark` and `with_openssl` options * remove `enable_benchmark` option * remove patches * remove patch functions --- recipes/clickhouse-cpp/all/conanfile.py | 69 +++++++++---------- .../all/test_package/CMakeLists.txt | 5 +- 2 files changed, 33 insertions(+), 41 deletions(-) diff --git a/recipes/clickhouse-cpp/all/conanfile.py b/recipes/clickhouse-cpp/all/conanfile.py index 442d24123399e2..df83d233feb8a1 100644 --- a/recipes/clickhouse-cpp/all/conanfile.py +++ b/recipes/clickhouse-cpp/all/conanfile.py @@ -10,39 +10,24 @@ class ClickHouseCppConan(ConanFile): name = "clickhouse-cpp" - homepage = "https://github.com/ClickHouse/clickhouse-cpp" - url = "https://github.com/conan-io/conan-center-index" description = "ClickHouse C++ API" license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ClickHouse/clickhouse-cpp" topics = ("database", "db", "clickhouse") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], - "enable_benchmark": [True, False], - "with_openssl": [True, False] + "with_openssl": [True, False], } default_options = { "shared": False, "fPIC": True, - "enable_benchmark": False, - "with_openssl": False + "with_openssl": False, } - def requirements(self): - - self.requires("lz4/1.9.4") - - self.requires("abseil/20230125.3", transitive_headers=True) - - self.requires("cityhash/cci.20130801") - if self.options.with_openssl: - self.requires("openssl/[>=1.1 <4]") - - def build_requirements(self): - if self.options.enable_benchmark: - self.requires("benchmark/1.8.0") - @property def _min_cppstd(self): return "17" @@ -58,17 +43,9 @@ def _compilers_minimum_version(self): @property def _requires_compiler_rt(self): - return self.settings.compiler == "clang" and (( self.settings.compiler.libcxx in ["libstdc++", "libstdc++11"] and not self.options.shared) or self.settings.compiler.libcxx == "libc++" ) - - def validate(self): - if self.settings.compiler.get_safe("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++17, which your compiler does not support.") - if self.settings.os == "Windows" and self.options.shared: - raise ConanInvalidConfiguration("f{self.ref} does not support shared library on Windows.") - # look at https://github.com/ClickHouse/clickhouse-cpp/pull/226 + return self.settings.compiler == "clang" and \ + ((self.settings.compiler.libcxx in ["libstdc++", "libstdc++11"] and not self.options.shared) or \ + self.settings.compiler.libcxx == "libc++") def config_options(self): if self.settings.os == "Windows": @@ -81,15 +58,30 @@ def configure(self): def layout(self): cmake_layout(self, src_folder="src") + def requirements(self): + self.requires("lz4/1.9.4") + self.requires("abseil/20230125.3", transitive_headers=True) + self.requires("cityhash/cci.20130801") + if self.options.with_openssl: + self.requires("openssl/[>=1.1 <4]") + + def validate(self): + if self.settings.compiler.get_safe("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.") + if self.settings.os == "Windows" and self.options.shared: + raise ConanInvalidConfiguration(f"{self.ref} does not support shared library on Windows.") + # look at https://github.com/ClickHouse/clickhouse-cpp/pull/226 + def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) - tc.variables["BUILD_BENCHMARK"] = self.options.enable_benchmark tc.cache_variables["BUILD_SHARED_LIBS"] = self.options.shared - tc.variables["WITH_OPENSSL"] = self.options.with_openssl + tc.cache_variables["WITH_OPENSSL"] = self.options.with_openssl tc.cache_variables["WITH_SYSTEM_ABSEIL"] = True tc.cache_variables["WITH_SYSTEM_LZ4"] = True tc.cache_variables["WITH_SYSTEM_CITYHASH"] = True @@ -118,10 +110,11 @@ def package_info(self): self.cpp_info.sharedlinkflags = ldflags self.cpp_info.system_libs.append("gcc_s") + if self.settings.os == 'Windows': + self.cpp_info.system_libs = ['ws2_32', 'wsock32'] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "clickhouse-cpp" self.cpp_info.filenames["cmake_find_package_multi"] = "clickhouse-cpp" self.cpp_info.names["cmake_find_package"] = "clickhouse-cpp-lib" self.cpp_info.names["cmake_find_package_multi"] = "clickhouse-cpp-lib" - - if self.settings.os == 'Windows': - self.cpp_info.system_libs = ['ws2_32', 'wsock32'] diff --git a/recipes/clickhouse-cpp/all/test_package/CMakeLists.txt b/recipes/clickhouse-cpp/all/test_package/CMakeLists.txt index b042c5663ae081..ede8071f6e7444 100644 --- a/recipes/clickhouse-cpp/all/test_package/CMakeLists.txt +++ b/recipes/clickhouse-cpp/all/test_package/CMakeLists.txt @@ -4,6 +4,5 @@ project(test_package LANGUAGES CXX) find_package(clickhouse-cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE clickhouse-cpp-lib::clickhouse-cpp-lib ) - -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE clickhouse-cpp-lib::clickhouse-cpp-lib) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) From 2c90241e93734b102aa7aeefd761463620cef99e Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 30 Aug 2023 22:53:49 +0900 Subject: [PATCH 0471/1140] (#19481) libheif: add version 1.16.2, update dependencies * libheif: add version 1.16.2, update dependencies * revert CXX STANDARD for 1.16.2 --- recipes/libheif/all/conandata.yml | 5 ++ recipes/libheif/all/conanfile.py | 7 +-- .../all/patches/0001-cmake_1.16.2.patch | 48 +++++++++++++++++++ recipes/libheif/config.yml | 2 + 4 files changed, 59 insertions(+), 3 deletions(-) create mode 100644 recipes/libheif/all/patches/0001-cmake_1.16.2.patch diff --git a/recipes/libheif/all/conandata.yml b/recipes/libheif/all/conandata.yml index c5668b6d3c93a0..3ec98d8c37e22d 100644 --- a/recipes/libheif/all/conandata.yml +++ b/recipes/libheif/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.16.2": + url: "https://github.com/strukturag/libheif/releases/download/v1.16.2/libheif-1.16.2.tar.gz" + sha256: "7f97e4205c0bd9f9b8560536c8bd2e841d1c9a6d610401eb3eb87ed9cdfe78ea" "1.13.0": url: "https://github.com/strukturag/libheif/releases/download/v1.13.0/libheif-1.13.0.tar.gz" sha256: "c20ae01bace39e89298f6352f1ff4a54b415b33b9743902da798e8a1e51d7ca1" @@ -12,6 +15,8 @@ sources: url: "https://github.com/strukturag/libheif/releases/download/v1.9.1/libheif-1.9.1.tar.gz" sha256: "5f65ca2bd2510eed4e13bdca123131c64067e9dd809213d7aef4dc5e37948bca" patches: + "1.16.2": + - patch_file: "patches/0001-cmake_1.16.2.patch" "1.13.0": - patch_file: "patches/0001-cmake_1.13.0.patch" "1.12.0": diff --git a/recipes/libheif/all/conanfile.py b/recipes/libheif/all/conanfile.py index 55d521d49ca387..912d662dba19ef 100644 --- a/recipes/libheif/all/conanfile.py +++ b/recipes/libheif/all/conanfile.py @@ -50,13 +50,13 @@ def layout(self): def requirements(self): if self.options.with_libde265: - self.requires("libde265/1.0.9") + self.requires("libde265/1.0.12") if self.options.with_x265: self.requires("libx265/3.4") if self.options.with_libaomav1: - self.requires("libaom-av1/3.5.0") + self.requires("libaom-av1/3.6.1") if self.options.with_dav1d: - self.requires("dav1d/1.0.0") + self.requires("dav1d/1.2.1") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -73,6 +73,7 @@ def generate(self): tc.variables["WITH_RAV1E"] = False tc.variables["WITH_DAV1D"] = self.options.with_dav1d tc.variables["WITH_EXAMPLES"] = False + tc.variables["WITH_GDK_PIXBUF"] = False tc.generate() deps = CMakeDeps(self) deps.generate() diff --git a/recipes/libheif/all/patches/0001-cmake_1.16.2.patch b/recipes/libheif/all/patches/0001-cmake_1.16.2.patch new file mode 100644 index 00000000000000..27432951605509 --- /dev/null +++ b/recipes/libheif/all/patches/0001-cmake_1.16.2.patch @@ -0,0 +1,48 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index de15948..589eab5 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -41,7 +41,7 @@ set(CMAKE_CXX_EXTENSIONS OFF) + + set(CMAKE_VISIBILITY_INLINES_HIDDEN 1) + +-set(CMAKE_POSITION_INDEPENDENT_CODE ON) ++# set(CMAKE_POSITION_INDEPENDENT_CODE ON) + + # Create the compile command database for clang by default + set(CMAKE_EXPORT_COMPILE_COMMANDS ON) +@@ -54,7 +54,7 @@ if (has_potentially_evaluated_expression) + add_definitions(-Wno-error=potentially-evaluated-expression) + endif() + +-LIST (APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/modules") ++# LIST (APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake/modules") + + option(ENABLE_PLUGIN_LOADING "Support loading of plugins" ON) + set(PLUGIN_DIRECTORY "${CMAKE_INSTALL_FULL_LIBDIR}/libheif" CACHE STRING "Plugin install directory") +@@ -88,11 +88,11 @@ macro(plugin_option variableName packageName displayName displayType defaultPlug + unset(msg) + endmacro() + +-plugin_option(LIBDE265 LIBDE265 "libde265" "HEIC decoder" OFF) +-plugin_option(X265 X265 "x265" "HEIC encoder" OFF) +-plugin_option(DAV1D DAV1D "Dav1d" "AVIF decoder" OFF) +-plugin_option(AOM_ENCODER AOM "aom" "AVIF encoder" OFF) +-plugin_option(AOM_DECODER AOM "aom" "AVIF decoder" OFF) ++plugin_option(LIBDE265 libde265 "libde265" "HEIC decoder" OFF) ++plugin_option(X265 libx265 "x265" "HEIC encoder" OFF) ++plugin_option(DAV1D dav1d "Dav1d" "AVIF decoder" OFF) ++plugin_option(AOM_ENCODER libaom-av1 "aom" "AVIF encoder" OFF) ++plugin_option(AOM_DECODER libaom-av1 "aom" "AVIF decoder" OFF) + plugin_option(SvtEnc SvtEnc "Svt-av1" "AVIF encoder" ON) + plugin_option(RAV1E RAV1E "Rav1e" "AVIF encoder" ON) + +@@ -219,7 +219,7 @@ if (WITH_GDK_PIXBUF) + add_subdirectory (gdk-pixbuf) + endif() + +-add_subdirectory (gnome) ++#add_subdirectory (gnome) + + + # --- packaging (source code) diff --git a/recipes/libheif/config.yml b/recipes/libheif/config.yml index 1b1bac20e2e23c..887a8fb56ade32 100644 --- a/recipes/libheif/config.yml +++ b/recipes/libheif/config.yml @@ -1,4 +1,6 @@ versions: + "1.16.2": + folder: all "1.13.0": folder: all "1.12.0": From afc52e7200b8f6ac9830c740f70294f15230f7ad Mon Sep 17 00:00:00 2001 From: trns1997 <17682846+trns1997@users.noreply.github.com> Date: Wed, 30 Aug 2023 16:52:38 +0200 Subject: [PATCH 0472/1140] (#19482) kickcat: add version v2-alpha4 --- recipes/kickcat/all/conandata.yml | 3 +++ recipes/kickcat/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/kickcat/all/conandata.yml b/recipes/kickcat/all/conandata.yml index 19c0f19034affa..f0a390ebfac916 100644 --- a/recipes/kickcat/all/conandata.yml +++ b/recipes/kickcat/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "v2-alpha4": + url: "https://github.com/Siviuze/KickCAT/archive/refs/tags/v2-alpha4.zip" + sha256: "483a374f77808cb35823652eb37c5ab864a3f12a1c3a957d3315c319ca0ec528" "v2-alpha3": url: "https://github.com/Siviuze/KickCAT/archive/refs/tags/v2-alpha3.zip" sha256: "dadd8518c3232162b7455fdcd837578120ece5a42c3bc2701147a68cbee60da4" diff --git a/recipes/kickcat/config.yml b/recipes/kickcat/config.yml index 7990d533925c9b..e031f21fd364ad 100644 --- a/recipes/kickcat/config.yml +++ b/recipes/kickcat/config.yml @@ -1,3 +1,5 @@ versions: + "v2-alpha4": + folder: all "v2-alpha3": folder: all From fc909b33f7976b7e3eead23c8a1f473452c48f63 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 30 Aug 2023 17:32:13 +0200 Subject: [PATCH 0473/1140] (#19486) fruit: fix import of Version + add package_type + bump boost + remove deprecated option use_boost * fix import of Version * add package_type * bump boost * remove deprecated option use_boost * sort versions --- recipes/fruit/all/conanfile.py | 27 ++++++++++++--------------- recipes/fruit/config.yml | 8 ++++---- 2 files changed, 16 insertions(+), 19 deletions(-) diff --git a/recipes/fruit/all/conanfile.py b/recipes/fruit/all/conanfile.py index 39e570bb06b3ac..9ad222d0dcc889 100644 --- a/recipes/fruit/all/conanfile.py +++ b/recipes/fruit/all/conanfile.py @@ -3,11 +3,12 @@ import tarfile from fnmatch import fnmatch -from conan import ConanFile, Version +from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, download, export_conandata_patches, get +from conan.tools.scm import Version required_conan_version = ">=1.53.0" @@ -19,16 +20,18 @@ class FruitConan(ConanFile): homepage = "https://github.com/google/fruit" license = "Apache-2.0" topics = ("injection", "framework") - settings = "os", "compiler", "build_type", "arch" - options = {"shared": [True, False], - "use_boost": [True, False, "deprecated"], - "with_boost": [True, False], - "fPIC": [True, False]} + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_boost": [True, False], + } default_options = { "shared": False, - "use_boost": "deprecated", + "fPIC": True, "with_boost": True, - "fPIC": True} + } def export_sources(self): export_conandata_patches(self) @@ -37,22 +40,16 @@ def config_options(self): if self.settings.os == "Windows": self.options.rm_safe("fPIC") - def package_id(self): - del self.info.options.use_boost - def configure(self): if self.options.shared: self.options.rm_safe("fPIC") - if self.options.use_boost != "deprecated": - self.output.warn("use_boost option is deprecated, use the option with_boost instead.") - self.options.with_boost = self.options.use_boost def layout(self): cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_boost: - self.requires("boost/1.80.0") + self.requires("boost/1.83.0") def validate(self): if self.settings.compiler.cppstd: diff --git a/recipes/fruit/config.yml b/recipes/fruit/config.yml index 684a4c74b25420..63afa5b5e5a827 100644 --- a/recipes/fruit/config.yml +++ b/recipes/fruit/config.yml @@ -1,11 +1,11 @@ versions: - "3.4.0": + "3.7.1": folder: all - "3.5.0": + "3.7.0": folder: all "3.6.0": folder: all - "3.7.0": + "3.5.0": folder: all - "3.7.1": + "3.4.0": folder: all From b4168bed9731b447500fe699bdea89c09bc94ee6 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Wed, 30 Aug 2023 19:11:47 +0300 Subject: [PATCH 0474/1140] (#19492) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index f39e87f6d648d2..08359be96706f4 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.15": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.15.tar.gz" + sha256: "53c4a65bb178afde91ae2360072f65a44ae7572a25912a3fe96aeaa6ac86ef27" "2.0.14": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.14.tar.gz" sha256: "b230f1a99a2a5f4f1f32748d52062276294b34d8254d4128193632e3a8ffaa4e" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 8252adb0297679..f9a27817ba4352 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.15": + folder: all "2.0.14": folder: all "2.0.13": From da682703bcf8c3c0e8d9f2fe0b4989fc64c8a973 Mon Sep 17 00:00:00 2001 From: Sergey Bobrenok Date: Thu, 31 Aug 2023 01:12:33 +0300 Subject: [PATCH 0475/1140] (#19507) libcap/2.69: Bump version --- recipes/libcap/all/conandata.yml | 10 ++++++++++ recipes/libcap/config.yml | 2 ++ 2 files changed, 12 insertions(+) diff --git a/recipes/libcap/all/conandata.yml b/recipes/libcap/all/conandata.yml index 5d119b718f418b..16d2439fd2b120 100644 --- a/recipes/libcap/all/conandata.yml +++ b/recipes/libcap/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.69": + url: "https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-2.69.tar.xz" + sha256: "f311f8f3dad84699d0566d1d6f7ec943a9298b28f714cae3c931dfd57492d7eb" "2.68": url: "https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-2.68.tar.xz" sha256: "90be3b6d41be5f81ae4b03ec76012b0d27c829293684f6c05b65d5f9cce724b2" @@ -30,6 +33,13 @@ sources: url: "https://www.kernel.org/pub/linux/libs/security/linux-privs/libcap2/libcap-2.45.tar.xz" sha256: "d66639f765c0e10557666b00f519caf0bd07a95f867dddaee131cd284fac3286" patches: + "2.69": + - patch_file: "patches/2.57/0001-libcap-Remove-hardcoded-fPIC.patch" + patch_description: "allow to configure fPIC option from conan recipe" + patch_type: "conan" + - patch_file: "patches/2.57/0002-Make.Rules-Make-compile-tools-configurable.patch" + patch_description: "allow to override compiler via environment variables" + patch_type: "conan" "2.68": - patch_file: "patches/2.57/0001-libcap-Remove-hardcoded-fPIC.patch" patch_description: "allow to configure fPIC option from conan recipe" diff --git a/recipes/libcap/config.yml b/recipes/libcap/config.yml index 24a13cbb3bd22e..9ca623681ce664 100644 --- a/recipes/libcap/config.yml +++ b/recipes/libcap/config.yml @@ -1,4 +1,6 @@ versions: + "2.69": + folder: all "2.68": folder: all "2.66": From 907b07884a22f3e41d17755c4332f450f0f3c168 Mon Sep 17 00:00:00 2001 From: Gregor Jasny Date: Thu, 31 Aug 2023 09:59:15 +0200 Subject: [PATCH 0476/1140] (#19503) ccache: add version 4.8.3 --- recipes/ccache/all/conandata.yml | 7 +++++++ recipes/ccache/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/ccache/all/conandata.yml b/recipes/ccache/all/conandata.yml index 1eab23f47e9eba..ca431f6e0685ba 100644 --- a/recipes/ccache/all/conandata.yml +++ b/recipes/ccache/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.8.3": + url: "https://github.com/ccache/ccache/releases/download/v4.8.3/ccache-4.8.3.tar.xz" + sha256: "e47374c810b248cfca3665ee1d86c7c763ffd68d9944bc422d9c1872611f2b11" "4.8.2": url: "https://github.com/ccache/ccache/releases/download/v4.8.2/ccache-4.8.2.tar.xz" sha256: "3d3fb3f888a5b16c4fa7ee5214cca76348afd6130e8443de5f6f2424f2076a49" @@ -12,6 +15,10 @@ sources: url: "https://github.com/ccache/ccache/releases/download/v4.7.4/ccache-4.7.4.tar.xz" sha256: "df0c64d15d3efaf0b4f6837dd6b1467e40eeaaa807db25ce79c3a08a46a84e36" patches: + "4.8.3": + - patch_file: "patches/4.8-cmake-msvc-runtime.patch" + patch_description: "fixup MSVC runtime" + patch_type: "conan" "4.8.2": - patch_file: "patches/4.8-cmake-msvc-runtime.patch" patch_description: "fixup MSVC runtime" diff --git a/recipes/ccache/config.yml b/recipes/ccache/config.yml index a08cbff67b8116..98dd3df9a94deb 100644 --- a/recipes/ccache/config.yml +++ b/recipes/ccache/config.yml @@ -1,4 +1,6 @@ versions: + "4.8.3": + folder: all "4.8.2": folder: all "4.8.1": From 71d7e4baa5ce4af619876ad45011a80d0d76631c Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 31 Aug 2023 18:33:02 +0900 Subject: [PATCH 0477/1140] (#19405) glaze: add version 1.4.0, remove older versions with patch file --- recipes/glaze/all/conandata.yml | 14 ++-------- recipes/glaze/all/conanfile.py | 22 ++------------- .../patches/0.2.0-0001-use-cci-frozen.patch | 28 ------------------- recipes/glaze/all/test_package/CMakeLists.txt | 3 -- recipes/glaze/config.yml | 6 ++-- 5 files changed, 8 insertions(+), 65 deletions(-) delete mode 100644 recipes/glaze/all/patches/0.2.0-0001-use-cci-frozen.patch diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index b43003828dbc64..31bad0f747cccd 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.4.0": + url: "https://github.com/stephenberry/glaze/archive/v1.4.0.tar.gz" + sha256: "301c831e2476529bfa1ea24d87011186da91644830bdf57e1ed99bc7f6326989" "1.3.6": url: "https://github.com/stephenberry/glaze/archive/v1.3.6.tar.gz" sha256: "c339f036a96fef72f9b8542d6a1e2ecb4bd3fa5d3d09a206da5e844765d2b6c3" @@ -23,14 +26,3 @@ sources: "1.1.2": url: "https://github.com/stephenberry/glaze/archive/v1.1.2.tar.gz" sha256: "ee22d55b7f40d63f510a41f22765cb24e9e70d312978bad4eb9c94c7ba2fe58c" - "0.3.6": - url: "https://github.com/stephenberry/glaze/archive/v0.3.6.tar.gz" - sha256: "bc87d4fd458f0634a146d6f4c902a952b66c3f718c3e20f680b99066224b51a1" - "0.2.2": - url: "https://github.com/stephenberry/glaze/archive/v0.2.2.tar.gz" - sha256: "d0d2edcc546b0ebb4bedaeedfb4a54aa678a6fdffa6b20dd6b252ef6325a9e75" -patches: - "0.2.2": - - patch_file: "patches/0.2.0-0001-use-cci-frozen.patch" - patch_description: "use cci's frozen" - patch_type: "conan" diff --git a/recipes/glaze/all/conanfile.py b/recipes/glaze/all/conanfile.py index 41a166e34e3ca8..7d6155afba73cc 100644 --- a/recipes/glaze/all/conanfile.py +++ b/recipes/glaze/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches +from conan.tools.files import get, copy from conan.tools.build import check_min_cppstd from conan.tools.scm import Version from conan.tools.layout import basic_layout @@ -17,6 +17,7 @@ class GlazeConan(ConanFile): topics = ("json", "memory", "header-only") package_type = "header-library" settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _min_cppstd(self): @@ -28,26 +29,13 @@ def _compilers_minimum_version(self): "Visual Studio": "17" if Version(self.version) >= "1.3.3" else "16", "msvc": "193" if Version(self.version) >= "1.3.3" else "192", "gcc": "12", - "clang": "12" if Version(self.version) > "1.0.0" else "13", + "clang": "12", "apple-clang": "13.1", } - def export_sources(self): - export_conandata_patches(self) - def layout(self): basic_layout(self, src_folder="src") - def requirements(self): - if Version(self.version) < "0.2.4": - self.requires("fmt/10.0.0") - self.requires("frozen/1.1.1") - self.requires("nanorange/cci.20200706") - if Version(self.version) < "0.2.3": - self.requires("fast_float/5.2.0") - if "0.1.5" <= Version(self.version) < "0.2.3": - self.requires("dragonbox/1.1.3") - def package_id(self): self.info.clear() @@ -64,15 +52,11 @@ def validate(self): def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build(self): - apply_conandata_patches(self) - def package(self): copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy( self, pattern="*.hpp", - excludes="glaze/frozen/*.hpp" if Version(self.version) < "0.2.4" else "", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include"), ) diff --git a/recipes/glaze/all/patches/0.2.0-0001-use-cci-frozen.patch b/recipes/glaze/all/patches/0.2.0-0001-use-cci-frozen.patch deleted file mode 100644 index 01b0c786fa02b1..00000000000000 --- a/recipes/glaze/all/patches/0.2.0-0001-use-cci-frozen.patch +++ /dev/null @@ -1,28 +0,0 @@ -diff --git a/include/glaze/core/common.hpp b/include/glaze/core/common.hpp -index aed6ce6..6cf4ace 100644 ---- a/include/glaze/core/common.hpp -+++ b/include/glaze/core/common.hpp -@@ -12,8 +12,8 @@ - #include - #include - --#include "glaze/frozen/string.hpp" --#include "glaze/frozen/unordered_map.hpp" -+#include "frozen/string.h" -+#include "frozen/unordered_map.h" - - #include "glaze/core/context.hpp" - #include "glaze/core/meta.hpp" -diff --git a/include/glaze/util/hash_map.hpp b/include/glaze/util/hash_map.hpp -index eaaec57..ae75ee2 100644 ---- a/include/glaze/util/hash_map.hpp -+++ b/include/glaze/util/hash_map.hpp -@@ -4,7 +4,7 @@ - #include - #include - --#include "glaze/frozen/random.hpp" -+#include "frozen/random.h" - #include "glaze/util/string_cmp.hpp" - - namespace glz diff --git a/recipes/glaze/all/test_package/CMakeLists.txt b/recipes/glaze/all/test_package/CMakeLists.txt index 11ef3b807bd40a..4811c5114c3c22 100644 --- a/recipes/glaze/all/test_package/CMakeLists.txt +++ b/recipes/glaze/all/test_package/CMakeLists.txt @@ -6,6 +6,3 @@ find_package(glaze REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE glaze::glaze) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20) -if(glaze_VERSION VERSION_LESS "1.0.0") - target_compile_definitions(${PROJECT_NAME} PRIVATE GLAZE_USE_EXCEPTION) -endif() diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index a37f70afd642ac..c479b0a04fbd07 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.4.0": + folder: all "1.3.6": folder: all "1.3.5": @@ -15,7 +17,3 @@ versions: folder: all "1.1.2": folder: all - "0.3.6": - folder: all - "0.2.2": - folder: all From 3b17e69bb4e5601a850b6e006e44775e690bac33 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 31 Aug 2023 13:13:23 +0200 Subject: [PATCH 0478/1140] (#19428) onnx/all: bump protobuf & remove old versions * onnx/all: bump protobuf * onnx: remove older versions * recipe simplification following old versions removal * fix build requirement * use for tool_requires("protobuf/") --- recipes/onnx/all/conandata.yml | 22 ---------------- recipes/onnx/all/conanfile.py | 19 ++++---------- ...-fix-concurrent-proto3-remove-1.11.0.patch | 11 -------- ...1-fix-concurrent-proto3-remove-1.8.1.patch | 11 -------- ...1-fix-concurrent-proto3-remove-1.9.0.patch | 11 -------- ...002-msvc-no-warnings-as-errors-1.8.1.patch | 26 ------------------- ...002-msvc-no-warnings-as-errors-1.9.0.patch | 26 ------------------- recipes/onnx/config.yml | 8 ------ 8 files changed, 5 insertions(+), 129 deletions(-) delete mode 100644 recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.11.0.patch delete mode 100644 recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.8.1.patch delete mode 100644 recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.9.0.patch delete mode 100644 recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.8.1.patch delete mode 100644 recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.9.0.patch diff --git a/recipes/onnx/all/conandata.yml b/recipes/onnx/all/conandata.yml index 5f05c1310659aa..c1a55ff6669fd6 100644 --- a/recipes/onnx/all/conandata.yml +++ b/recipes/onnx/all/conandata.yml @@ -11,28 +11,6 @@ sources: "1.12.0": url: "https://github.com/onnx/onnx/archive/refs/tags/v1.12.0.tar.gz" sha256: "052ad3d5dad358a33606e0fc89483f8150bb0655c99b12a43aa58b5b7f0cc507" - "1.11.0": - url: "https://github.com/onnx/onnx/archive/refs/tags/v1.11.0.tar.gz" - sha256: "a20f2d9df805b16ac75ab4da0a230d3d1c304127d719e5c66a4e6df514e7f6c0" - "1.10.2": - url: "https://github.com/onnx/onnx/archive/refs/tags/v1.10.2.tar.gz" - sha256: "520b3aa34272cc215e2eb41385f58adf01750d88858d4722563edca8410c5dc9" - "1.9.0": - url: "https://github.com/onnx/onnx/archive/v1.9.0.tar.gz" - sha256: "61d459a5f30604cabec352574119a6685dfd43bfa757cfbff52be9471d5b8ea0" - "1.8.1": - url: "https://github.com/onnx/onnx/archive/v1.8.1.tar.gz" - sha256: "0054c7eeed97e8ee43921c3f944b0450782a081d910a14b3b6e662bc87065192" patches: "1.12.0": - patch_file: "patches/0001-fix-concurrent-proto3-remove-1.12.0.patch" - "1.11.0": - - patch_file: "patches/0001-fix-concurrent-proto3-remove-1.11.0.patch" - "1.10.2": - - patch_file: "patches/0001-fix-concurrent-proto3-remove-1.9.0.patch" - "1.9.0": - - patch_file: "patches/0001-fix-concurrent-proto3-remove-1.9.0.patch" - - patch_file: "patches/0002-msvc-no-warnings-as-errors-1.9.0.patch" - "1.8.1": - - patch_file: "patches/0001-fix-concurrent-proto3-remove-1.8.1.patch" - - patch_file: "patches/0002-msvc-no-warnings-as-errors-1.8.1.patch" diff --git a/recipes/onnx/all/conanfile.py b/recipes/onnx/all/conanfile.py index ddc3a6ff03194e..7d2738dc5a86a0 100644 --- a/recipes/onnx/all/conanfile.py +++ b/recipes/onnx/all/conanfile.py @@ -10,7 +10,7 @@ import os import textwrap -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.60.0 <2.0 || >=2.0.6" class OnnxConan(ConanFile): @@ -40,19 +40,12 @@ def _min_cppstd(self): return 17 return 11 - @property - def _protobuf_version(self): - # onnx < 1.9.0 doesn't support protobuf >= 3.18 - return "3.21.9" if Version(self.version) >= "1.9.0" else "3.17.1" - def export_sources(self): export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - if Version(self.version) < "1.9.0": - del self.options.disable_static_registration def configure(self): if self.options.shared: @@ -62,7 +55,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires(f"protobuf/{self._protobuf_version}", run=not cross_building(self), transitive_headers=True, transitive_libs=True) + self.requires("protobuf/3.21.12", run=not cross_building(self), transitive_headers=True, transitive_libs=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -72,7 +65,7 @@ def validate(self): def build_requirements(self): if hasattr(self, "settings_build") and cross_building(self): - self.tool_requires(f"protobuf/{self._protobuf_version}") + self.tool_requires("protobuf/") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -99,8 +92,7 @@ def generate(self): tc.variables["ONNX_VERIFY_PROTO3"] = Version(self.dependencies.host["protobuf"].ref.version).major == "3" if is_msvc(self): tc.variables["ONNX_USE_MSVC_STATIC_RUNTIME"] = is_msvc_static_runtime(self) - if Version(self.version) >= "1.9.0": - tc.variables["ONNX_DISABLE_STATIC_REGISTRATION"] = self.options.get_safe('disable_static_registration') + tc.variables["ONNX_DISABLE_STATIC_REGISTRATION"] = self.options.get_safe('disable_static_registration') tc.generate() deps = CMakeDeps(self) deps.generate() @@ -177,8 +169,7 @@ def _onnx_components(self): } } ) - if Version(self.version) >= "1.11.0": - components["libonnx"]["defines"].append("__STDC_FORMAT_MACROS") + components["libonnx"]["defines"].append("__STDC_FORMAT_MACROS") return components def package_info(self): diff --git a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.11.0.patch b/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.11.0.patch deleted file mode 100644 index 5ecbd144c4919a..00000000000000 --- a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.11.0.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/onnx/gen_proto.py -+++ b/onnx/gen_proto.py -@@ -165,7 +165,7 @@ def convert(stem, package_name, output, do_onnx_ml=False, lite=False, protoc_pat - porto3_dir = os.path.dirname(proto3) - base_dir = os.path.dirname(porto3_dir) - gen_proto3_code(protoc_path, proto3, base_dir, base_dir, base_dir) -- pb3_files = glob.glob(os.path.join(porto3_dir, '*.proto3.*')) -+ pb3_files = glob.glob(os.path.join(porto3_dir, '{}.proto3.*'.format(proto_base))) - for pb3_file in pb3_files: - print("Removing {}".format(pb3_file)) - os.remove(pb3_file) diff --git a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.8.1.patch b/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.8.1.patch deleted file mode 100644 index 2d1317c302c936..00000000000000 --- a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.8.1.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/onnx/gen_proto.py -+++ b/onnx/gen_proto.py -@@ -166,7 +166,7 @@ def convert(stem, package_name, output, do_onnx_ml=False, lite=False, protoc_pat - porto3_dir = os.path.dirname(proto3) - base_dir = os.path.dirname(porto3_dir) - gen_proto3_code(protoc_path, proto3, base_dir, base_dir, base_dir) -- pb3_files = glob.glob(os.path.join(porto3_dir, '*.proto3.*')) -+ pb3_files = glob.glob(os.path.join(porto3_dir, '{}.proto3.*'.format(proto_base))) - for pb3_file in pb3_files: - print("Removing {}".format(pb3_file)) - os.remove(pb3_file) diff --git a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.9.0.patch b/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.9.0.patch deleted file mode 100644 index 181c708c8d374e..00000000000000 --- a/recipes/onnx/all/patches/0001-fix-concurrent-proto3-remove-1.9.0.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/onnx/gen_proto.py -+++ b/onnx/gen_proto.py -@@ -169,7 +169,7 @@ def convert(stem, package_name, output, do_onnx_ml=False, lite=False, protoc_pat - porto3_dir = os.path.dirname(proto3) - base_dir = os.path.dirname(porto3_dir) - gen_proto3_code(protoc_path, proto3, base_dir, base_dir, base_dir) -- pb3_files = glob.glob(os.path.join(porto3_dir, '*.proto3.*')) -+ pb3_files = glob.glob(os.path.join(porto3_dir, '{}.proto3.*'.format(proto_base))) - for pb3_file in pb3_files: - print("Removing {}".format(pb3_file)) - os.remove(pb3_file) diff --git a/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.8.1.patch b/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.8.1.patch deleted file mode 100644 index b701fb66947d1c..00000000000000 --- a/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.8.1.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -454,7 +454,6 @@ if(BUILD_ONNX_PYTHON) - target_link_libraries(onnx_cpp2py_export PRIVATE ${PYTHON_LIBRARIES}) - target_compile_options(onnx_cpp2py_export - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing - # value to bool 'true' or 'false' - # (performance warning) -@@ -514,7 +513,6 @@ endif() - if(MSVC) - target_compile_options(onnx_proto - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing value - # to bool 'true' or 'false' - # (performance warning) -@@ -532,7 +530,6 @@ if(MSVC) - ${EXTRA_FLAGS}) - target_compile_options(onnx - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing value - # to bool 'true' or 'false' - # (performance warning) diff --git a/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.9.0.patch b/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.9.0.patch deleted file mode 100644 index 1ff241f73aca7a..00000000000000 --- a/recipes/onnx/all/patches/0002-msvc-no-warnings-as-errors-1.9.0.patch +++ /dev/null @@ -1,26 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -485,7 +485,6 @@ if(BUILD_ONNX_PYTHON) - target_link_libraries(onnx_cpp2py_export PRIVATE ${PYTHON_LIBRARIES}) - target_compile_options(onnx_cpp2py_export - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing - # value to bool 'true' or 'false' - # (performance warning) -@@ -545,7 +544,6 @@ endif() - if(MSVC) - target_compile_options(onnx_proto - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing value - # to bool 'true' or 'false' - # (performance warning) -@@ -563,7 +561,6 @@ if(MSVC) - ${EXTRA_FLAGS}) - target_compile_options(onnx - PRIVATE /MP -- /WX - /wd4800 # disable warning type' : forcing value - # to bool 'true' or 'false' - # (performance warning) diff --git a/recipes/onnx/config.yml b/recipes/onnx/config.yml index cfdc9b9959f822..ae05002493f072 100644 --- a/recipes/onnx/config.yml +++ b/recipes/onnx/config.yml @@ -7,11 +7,3 @@ versions: folder: all "1.12.0": folder: all - "1.11.0": - folder: all - "1.10.2": - folder: all - "1.9.0": - folder: all - "1.8.1": - folder: all From 3ee01afa020ef3db07ad93b4eea41fbb6410d2cb Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 31 Aug 2023 15:18:59 +0200 Subject: [PATCH 0479/1140] (#19513) nss 3.93 --- recipes/nss/all/conandata.yml | 3 +++ recipes/nss/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/nss/all/conandata.yml b/recipes/nss/all/conandata.yml index a7c913155a8245..f10905ebbaa04d 100644 --- a/recipes/nss/all/conandata.yml +++ b/recipes/nss/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.93": + url: "https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_93_RTM/src/nss-3.93.tar.gz" + sha256: "15f54bb72048eb105f8c0e936a04b899e74c3db9a19bbc1e00acee2af9476a8a" "3.92": url: "https://ftp.mozilla.org/pub/security/nss/releases/NSS_3_92_RTM/src/nss-3.92.tar.gz" sha256: "3db192d6e882039af02ae7eaf3217ed114bb7ad83414c646772ab8021e24a254" diff --git a/recipes/nss/config.yml b/recipes/nss/config.yml index 467e717cc1ff4a..82fff1e6a41ec5 100644 --- a/recipes/nss/config.yml +++ b/recipes/nss/config.yml @@ -1,4 +1,6 @@ versions: + "3.93": + folder: all "3.92": folder: all "3.91": From 63cc96210e0f21c714e8189fca29378f9e09e17c Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Thu, 31 Aug 2023 20:52:31 +0400 Subject: [PATCH 0480/1140] (#19525) onetbb: added 2021.10.0 version --- recipes/onetbb/all/conandata.yml | 3 +++ recipes/onetbb/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/onetbb/all/conandata.yml b/recipes/onetbb/all/conandata.yml index 880145b4a46b00..4839476518f75e 100644 --- a/recipes/onetbb/all/conandata.yml +++ b/recipes/onetbb/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2021.10.0": + url: "https://github.com/oneapi-src/oneTBB/archive/refs/tags/v2021.10.0.tar.gz" + sha256: "487023a955e5a3cc6d3a0d5f89179f9b6c0ae7222613a7185b0227ba0c83700b" "2021.9.0": url: "https://github.com/oneapi-src/oneTBB/archive/refs/tags/v2021.9.0.tar.gz" sha256: "1ce48f34dada7837f510735ff1172f6e2c261b09460e3bf773b49791d247d24e" diff --git a/recipes/onetbb/config.yml b/recipes/onetbb/config.yml index 7a33bda288759f..39b37264743028 100644 --- a/recipes/onetbb/config.yml +++ b/recipes/onetbb/config.yml @@ -1,4 +1,6 @@ versions: + "2021.10.0": + folder: all "2021.9.0": folder: all "2021.8.0": From 344b9e54f9460f7c9a00c59ddd6c532c41aed351 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Thu, 31 Aug 2023 20:10:27 +0200 Subject: [PATCH 0481/1140] (#19037) [libnice] Fix cmake_layout import error MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix import error Signed-off-by: Uilian Ries * use version range for openssl Signed-off-by: Uilian Ries * Revert "use version range for openssl" This reverts commit f9d9f380e59762da7907c7be5925e94b3aedd078. * nice/agent.h exposes glib-object.h Signed-off-by: Uilian Ries * add transitive libs Signed-off-by: Uilian Ries * add fix_apple_shared_install_name Signed-off-by: Uilian Ries * Update recipes/libnice/all/conanfile.py * Update recipes/libnice/all/conanfile.py * Update recipes/libnice/all/conanfile.py * libnice requires Conan 1.60.0 or higher * Update recipes/libnice/all/conanfile.py * Update recipes/libnice/all/conanfile.py --------- Signed-off-by: Uilian Ries Co-authored-by: Rubén Rincón Blanco --- recipes/libnice/all/conanfile.py | 15 +++++++++------ recipes/libnice/all/test_package/conanfile.py | 3 +-- recipes/libnice/all/test_v1_package/conanfile.py | 6 ++---- 3 files changed, 12 insertions(+), 12 deletions(-) diff --git a/recipes/libnice/all/conanfile.py b/recipes/libnice/all/conanfile.py index 5fd9fcdbbc036c..22dc5eaaf2efa6 100644 --- a/recipes/libnice/all/conanfile.py +++ b/recipes/libnice/all/conanfile.py @@ -5,8 +5,10 @@ from conan.tools.layout import basic_layout from conan.tools.gnu import PkgConfigDeps from conan.tools.microsoft import is_msvc_static_runtime +from conan.tools.apple import fix_apple_shared_install_name from conan.errors import ConanInvalidConfiguration +required_conan_version = ">=1.60.0 <2 || >=2.0.6" class LibniceConan(ConanFile): name = "libnice" @@ -59,16 +61,16 @@ def validate(self): "-o glib/*:shared=True with static runtime is not supported") def requirements(self): - self.requires("glib/2.75.2") + self.requires("glib/2.77.2", transitive_headers=True, transitive_libs=True) if self.options.crypto_library == "openssl": - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1.1 <4]") if self.options.with_gstreamer: - self.requires("gstreamer/1.19.2") + self.requires("gstreamer/1.22.3") def build_requirements(self): - self.tool_requires("meson/1.0.0") - self.tool_requires("pkgconf/1.9.3") - self.tool_requires("glib/2.75.2") # for glib-mkenums + self.tool_requires("meson/1.2.1") + self.tool_requires("pkgconf/1.9.5") + self.tool_requires("glib/") # for glib-mkenums if self.options.with_introspection: self.tool_requires("gobject-introspection/1.72.0") @@ -107,6 +109,7 @@ def package(self): if not self.options.shared: with chdir(self, os.path.join(self.package_folder, "lib")): rename(self, "libnice.a", "nice.lib") + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["nice"] diff --git a/recipes/libnice/all/test_package/conanfile.py b/recipes/libnice/all/test_package/conanfile.py index 22dd4e9d14ebe5..a91756abf0bec7 100644 --- a/recipes/libnice/all/test_package/conanfile.py +++ b/recipes/libnice/all/test_package/conanfile.py @@ -1,7 +1,6 @@ import os from conan import ConanFile -from conan.tools.cmake import CMake -from conan.tools.layout import cmake_layout +from conan.tools.cmake import CMake, cmake_layout from conan.tools.build import can_run diff --git a/recipes/libnice/all/test_v1_package/conanfile.py b/recipes/libnice/all/test_v1_package/conanfile.py index 8c9580d2d52b25..ecf464197e0a59 100644 --- a/recipes/libnice/all/test_v1_package/conanfile.py +++ b/recipes/libnice/all/test_v1_package/conanfile.py @@ -1,7 +1,5 @@ import os -from conan import ConanFile -from conans import CMake -from conan.tools.build import can_run +from conans import ConanFile, CMake, tools class LibniceTestConan(ConanFile): @@ -14,6 +12,6 @@ def build(self): cmake.build() def test(self): - if can_run(self): + if not tools.cross_building(self): bin_path = os.path.join("bin", "example") self.run(bin_path, run_environment=True) From 0bfa426a615560baae2438f83b79811644e9f0db Mon Sep 17 00:00:00 2001 From: Sergey Bobrenok Date: Fri, 1 Sep 2023 01:50:57 +0300 Subject: [PATCH 0482/1140] (#19537) sdbus-cpp/1.3.0: Bump version --- recipes/sdbus-cpp/all/conandata.yml | 3 +++ recipes/sdbus-cpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sdbus-cpp/all/conandata.yml b/recipes/sdbus-cpp/all/conandata.yml index 4c4e5beb4bad04..97d55c77fac397 100644 --- a/recipes/sdbus-cpp/all/conandata.yml +++ b/recipes/sdbus-cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.0": + url: "https://github.com/Kistler-Group/sdbus-cpp/archive/v1.3.0.tar.gz" + sha256: "d44f59abdd64d8f1ca3af7db58bc6518cb081fc9ff16285c3d75a68f5c073d10" "1.2.0": url: "https://github.com/Kistler-Group/sdbus-cpp/archive/v1.2.0.tar.gz" sha256: "7f7231904abb6a996b8c18ddc5fb50078ef5dff5191649abf9f127aff41d24e9" diff --git a/recipes/sdbus-cpp/config.yml b/recipes/sdbus-cpp/config.yml index 027c0dc56075dc..a48eafa88431d0 100644 --- a/recipes/sdbus-cpp/config.yml +++ b/recipes/sdbus-cpp/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.0": + folder: all "1.2.0": folder: all "1.1.0": From c90396a0fc843d4da82f73fe85307b572ed62107 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Fri, 1 Sep 2023 09:35:17 +0300 Subject: [PATCH 0483/1140] (#19542) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 08359be96706f4..7275b589730d9f 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.16": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.16.tar.gz" + sha256: "9da7cd02883c2f4d4a2371cda4c195ebc02f57bb673ef948b88a256f3db55724" "2.0.15": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.15.tar.gz" sha256: "53c4a65bb178afde91ae2360072f65a44ae7572a25912a3fe96aeaa6ac86ef27" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index f9a27817ba4352..e6e6297a347208 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.16": + folder: all "2.0.15": folder: all "2.0.14": From 8eea987f350f638ae0ed9067b19598a39bcf8e4a Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 1 Sep 2023 10:03:14 +0200 Subject: [PATCH 0484/1140] (#19534) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index afef60a60fac71..cc3af6a6bc8c26 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -65,6 +65,7 @@ required_for_references: - aws-c-s3 - aws-c-sdkutils - aws-checksums +- aws-crt-cpp - aws-kvs-pic - aws-libfabric - b2 @@ -478,6 +479,7 @@ required_for_references: - kainjow-mustache - kaitai_struct_cpp_stl_runtime - kangaru +- kcp - kdbindings - keychain - khrplatform From d70ff0b99ce2850d8f32ccaa123018d7ca05e5da Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 1 Sep 2023 11:22:55 +0200 Subject: [PATCH 0485/1140] (#19539) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index cc3af6a6bc8c26..f2268ad3f7dbb5 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -583,6 +583,7 @@ required_for_references: - libnfnetlink - libnfs - libnghttp2 +- libnice - libnl - libnoise - libnop From d0f0b6178f9466e3b0ebbefd094dc00ee4133159 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 2 Sep 2023 03:33:05 +0900 Subject: [PATCH 0486/1140] (#19550) highway: add version 1.0.7 --- recipes/highway/all/conandata.yml | 3 +++ recipes/highway/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/highway/all/conandata.yml b/recipes/highway/all/conandata.yml index 0f97a2fe01fc88..710781f517c657 100644 --- a/recipes/highway/all/conandata.yml +++ b/recipes/highway/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.7": + url: "https://github.com/google/highway/archive/1.0.7.tar.gz" + sha256: "5434488108186c170a5e2fca5e3c9b6ef59a1caa4d520b008a9b8be6b8abe6c5" "1.0.6": url: "https://github.com/google/highway/archive/1.0.6.tar.gz" sha256: "d89664a045a41d822146e787bceeefbf648cc228ce354f347b18f2b419e57207" diff --git a/recipes/highway/config.yml b/recipes/highway/config.yml index e978e314cb0cd2..51114d87501db4 100644 --- a/recipes/highway/config.yml +++ b/recipes/highway/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.7": + folder: all "1.0.6": folder: all "1.0.5": From cdeed60c0851827e35ff74eba0d4def4ed9145b6 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 1 Sep 2023 21:12:07 +0200 Subject: [PATCH 0487/1140] (#19527) pkgconf 2.0.2 --- recipes/pkgconf/all/conandata.yml | 5 +++++ recipes/pkgconf/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/pkgconf/all/conandata.yml b/recipes/pkgconf/all/conandata.yml index 9d79648be05d08..cf574fc35a1d54 100644 --- a/recipes/pkgconf/all/conandata.yml +++ b/recipes/pkgconf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.2": + url: "https://distfiles.ariadne.space/pkgconf/pkgconf-2.0.2.tar.xz" + sha256: "ea5a25ef8f251eb5377ec0e21c75fb61894433cfbdbf0b2559ba33e4c2664401" "1.9.5": url: "https://distfiles.ariadne.space/pkgconf/pkgconf-1.9.5.tar.xz" sha256: "1ac1656debb27497563036f7bffc281490f83f9b8457c0d60bcfb638fb6b6171" @@ -12,6 +15,8 @@ sources: url: "https://distfiles.ariadne.space/pkgconf/pkgconf-1.7.3.tar.xz" sha256: "b846aea51cf696c3392a0ae58bef93e2e72f8e7073ca6ad1ed8b01c85871f9c0" patches: + "2.0.2": + - patch_file: "patches/1.9.3-0003-PKG_CONF_PATH-allow-colon+semicolon-separator.patch" "1.9.5": - patch_file: "patches/1.9.3-0003-PKG_CONF_PATH-allow-colon+semicolon-separator.patch" "1.9.3": diff --git a/recipes/pkgconf/config.yml b/recipes/pkgconf/config.yml index 04e2163e1ba778..e17ebc77d55fac 100644 --- a/recipes/pkgconf/config.yml +++ b/recipes/pkgconf/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.2": + folder: "all" "1.9.5": folder: "all" "1.9.3": From ee72892861189d3158ee3bd3278c93ec36ef6a7b Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 2 Sep 2023 00:13:19 +0200 Subject: [PATCH 0488/1140] (#19543) graphene/all: bump deps * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * graphene/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * Update conanfile.py --- recipes/graphene/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/graphene/all/conanfile.py b/recipes/graphene/all/conanfile.py index 39254a6f16cdfb..46dfcff7c1fdfa 100644 --- a/recipes/graphene/all/conanfile.py +++ b/recipes/graphene/all/conanfile.py @@ -51,7 +51,7 @@ def layout(self): def requirements(self): if self.options.with_glib: - self.requires("glib/2.76.2") + self.requires("glib/2.77.0") def validate(self): if self.settings.compiler == "gcc": @@ -70,9 +70,9 @@ def validate(self): ) def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", default=False): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 51edc2a31cc01b8071be8ee7f81483dad41003fe Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 2 Sep 2023 00:49:21 +0200 Subject: [PATCH 0489/1140] (#19528) glib 2.77.3 --- recipes/glib/all/conandata.yml | 3 +++ recipes/glib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glib/all/conandata.yml b/recipes/glib/all/conandata.yml index 0dd31b0d40a5ba..ec38114b48cbc0 100644 --- a/recipes/glib/all/conandata.yml +++ b/recipes/glib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.77.3": + url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.3.tar.xz" + sha256: "1753f963bb680b28a83d6e2095f63d0d4b94244675bcd2603850b2ebc1ac6a61" "2.77.2": url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.2.tar.xz" sha256: "16279739e4d30ec47be3e82909f5aeaaa41a8206bae3bead10a23fb2deff02a6" diff --git a/recipes/glib/config.yml b/recipes/glib/config.yml index 808c4e2fcb441e..1a21f71ff22892 100644 --- a/recipes/glib/config.yml +++ b/recipes/glib/config.yml @@ -1,4 +1,6 @@ versions: + "2.77.3": + folder: all "2.77.2": folder: all "2.77.1": From 22e6c43eeee9635c2093991235b34a3a36ef1f2a Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sat, 2 Sep 2023 08:42:37 +0200 Subject: [PATCH 0490/1140] (#19555) Add changelog 01 Sep 2023 Signed-off-by: Uilian Ries --- docs/changelog.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 3cf79f8d613275..8eadac2df61397 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,9 @@ # Changelog +### 01-Sep-2023 - 19:58 CEST + +- [fix] Use Unix separators for Windows folder path when creating CI workspace + ### 17-Aug-2023 - 11:42 CEST - [fix] Fix type error when catching generic exceptions in Jenkins From 4ffb55b871c1f839b7074e56836bded563b523d7 Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Sat, 2 Sep 2023 00:11:55 -0700 Subject: [PATCH 0491/1140] (#19536) cmake: add 3.27.4 --- recipes/cmake/binary/conandata.yml | 19 +++++++++++++++++++ recipes/cmake/config.yml | 2 ++ 2 files changed, 21 insertions(+) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index a778631e96cbaf..afcf32ce814612 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.4": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.4-linux-aarch64.tar.gz" + sha256: "45538d394bd4ef2a423fa78dff5cad16bcf437a4a6dc655e999177170632b039" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.4-linux-x86_64.tar.gz" + sha256: "186c53121cf6ef4e48b51e88690e6ef84f268611064a42e5a2e829c3d6b2efde" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.4-macos10.10-universal.tar.gz" + sha256: "1fa092bad6daf9715c6d72ff766813fd3423427696042a74f2208a2b4704ac1c" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.4-windows-arm64.zip" + sha256: "6c1df7ad85ed902ad615cd0c05bca0d3c9c3f67b3980ca9dd2e39b0821d50937" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.4-windows-x86_64.zip" + sha256: "e5e060756444d0b2070328a8821c1ceb62bd6d267aae61bfff06f96c7ec943a6" "3.27.1": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 4a1e12b81255fd..94869f2ceea826 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -1,4 +1,6 @@ versions: + "3.27.4": + folder: "binary" "3.27.1": folder: "binary" "3.27.0": From 7bdd38b95d62a670113f718fa055ae83e3bfb0d9 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 2 Sep 2023 22:31:47 +0900 Subject: [PATCH 0492/1140] (#19559) c-blosc: add version 1.21.5 --- recipes/c-blosc/all/conandata.yml | 7 +++++++ recipes/c-blosc/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/c-blosc/all/conandata.yml b/recipes/c-blosc/all/conandata.yml index d2e82d3ed6ffbf..a47eb694abb4af 100644 --- a/recipes/c-blosc/all/conandata.yml +++ b/recipes/c-blosc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.21.5": + url: "https://github.com/Blosc/c-blosc/archive/v1.21.5.tar.gz" + sha256: "32e61961bbf81ffea6ff30e9d70fca36c86178afd3e3cfa13376adec8c687509" "1.21.4": url: "https://github.com/Blosc/c-blosc/archive/v1.21.4.tar.gz" sha256: "e72bd03827b8564bbb3dc3ea0d0e689b4863871ce3861d946f2efd7a186ecf3e" @@ -27,6 +30,10 @@ sources: url: "https://github.com/Blosc/c-blosc/archive/v1.17.1.tar.gz" sha256: "19a6948b579c27e8ac440b4f077f99fc90e7292b1d9cb896bec0fd781d68fba2" patches: + "1.21.5": + - patch_file: "patches/cmake-dependencies-1.21.4+.patch" + patch_description: "use cci package" + patch_type: "conan" "1.21.4": - patch_file: "patches/cmake-dependencies-1.21.4+.patch" patch_description: "use cci package" diff --git a/recipes/c-blosc/config.yml b/recipes/c-blosc/config.yml index 0bea6e6e853db9..cd2301b24b5b42 100644 --- a/recipes/c-blosc/config.yml +++ b/recipes/c-blosc/config.yml @@ -1,4 +1,6 @@ versions: + "1.21.5": + folder: all "1.21.4": folder: all "1.21.3": From 15218ee2780caf319ec91365bb553a69f43af55d Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sat, 2 Sep 2023 17:02:48 +0200 Subject: [PATCH 0493/1140] (#19522) [docs] Change conan v2 feedback message * change conan v2 feedback message Signed-off-by: Uilian Ries * ping conan-io/barbarians Signed-off-by: Uilian Ries * Update .c3i/config_v2.yml Co-authored-by: Daniel --------- Signed-off-by: Uilian Ries Co-authored-by: Daniel --- .c3i/config_v2.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index 1f13510578fc9d..6ce21e93668a5c 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -46,9 +46,9 @@ tasks: update_labels: false user_feedback: title: "Conan v2 pipeline" - description: "> **Note**: Conan v2 builds may be required once they are on the [v2 ready](https://github.com/conan-io/conan-center-index/blob/master/.c3i/conan_v2_ready_references.yml) list" + description: "> **Note**: Conan v2 builds are now mandatory. Please read our [discussion](https://github.com/conan-io/conan-center-index/discussions/19104) about it." regression: "> **Regression**: Conan v2 builds are mandatory and they are required for the PR to be merged, because this recipe worked with Conan v2 previously." - text_on_failure: "The v2 pipeline failed. Please, review the errors and note this will be required for pull requests to be merged in the near future." + text_on_failure: "The v2 pipeline failed. Please, review the errors and note this is required for pull requests to be merged. In case this recipe is still not ported to Conan 2.x, please, ping `@conan-io/barbarians` on the PR and we will help you." collapse_on_success: false collapse_on_failure: true list_packages: From db455b53940290448d0be430bae93b7becbb0b76 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Sat, 2 Sep 2023 19:42:18 +0200 Subject: [PATCH 0494/1140] (#19560) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index f2268ad3f7dbb5..7b84a12bb8b2a9 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -278,6 +278,7 @@ required_for_references: - elfio - embree3 - emio +- emsdk - enet - enhex-generic_serialization - enhex-strong_type From 831edb42d4fc14e024ee4ad2f22bf7f0f4a5143a Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Sat, 2 Sep 2023 20:02:27 +0200 Subject: [PATCH 0495/1140] (#19459) [docs] Add section about Docker images used by CCI Signed-off-by: Uilian Ries --- docs/developing_recipes_locally.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/docs/developing_recipes_locally.md b/docs/developing_recipes_locally.md index e34902537f2b67..9c54954e8a98d4 100644 --- a/docs/developing_recipes_locally.md +++ b/docs/developing_recipes_locally.md @@ -221,6 +221,29 @@ If you are working with packages that have system dependencies that are managed docker run -e CONAN_SYSREQUIRES_MODE=enabled conanio/gcc11-ubuntu16.04 conan install fmt/9.0.0@ -if build --build missing -c tools.system.package_manager:mode=install -c tools.system.package_manager:sudo=yes ``` +#### Docker build images used by ConanCenterIndex + +The Conan Center Index uses [Conan Docker Tools](https://github.com/conan-io/conan-docker-tools/) to build packages in a variety of environments. All images are hosted in [Docker Hub](https://hub.docker.com/u/conanio). The relation of the images with the build configurations is available according to the Conan configuration, as `node_labels.Linux`, for instance: + + +```yaml +node_labels: + Linux: + x86_64: + "gcc": + default: "linux_gcc_${compiler.version}" + "11": "linux_gcc_${compiler.version}_ubuntu16.04" + "clang": + default: "linux_clang_${compiler.version}_ubuntu16.04" + "11": "linux_clang_${compiler.version}" +``` + +The configuration files are located in the folder [../.c3i](../.c3i). Currently are the files [config_v1.yml](../.c3i/config_v1.yml) and [config_v2.yml](../.c3i/config_v2.yml). The configuration file `config_v1.yml` is used by the Conan 1.0 client, while `config_v2.yml` is used by the Conan 2.0 client. + +The label `linux` refers to any Docker image, while `gcc_${compiler.version}` refers to GCC + a compiler version. For example, `linux_gcc_10` refers to the image `conanio/gcc10`. +The suffix `_ubuntu16.04` refers to the base image used by the Docker image, in this case, `ubuntu16.04`. So, `"11": "linux_gcc_${compiler.version}_ubuntu16.04"` means that the image `conanio/gcc11-ubuntu16.04`. Thus, all GCC versions use `conanio/gcc`, except for the GCC 11, which uses `conanio/gcc11-ubuntu16.04`. The same applies to Clang. + + ## Using Conan 2.0 Everything you need to know about the methods, commands line, outputs can be found in the From b4f452f78601b76c244ebcb6729a018d48014908 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 03:23:12 +0900 Subject: [PATCH 0496/1140] (#16273) hyperscan: add version 5.4.2 * hyperscan: add version 5.4.1 * update 5.4.2 * workround dependencies error * update boost * disable -Werror flag * disable unit on msvc in 5.4.2 * disable build examples * update boost/1.83.0 --- recipes/hyperscan/all/conandata.yml | 14 +- recipes/hyperscan/all/conanfile.py | 4 +- ...cmake.patch => 5.4.0-0001-fix-cmake.patch} | 13 +- ...h => 5.4.0-0002-use-ue2-make_unique.patch} | 0 .../all/patches/5.4.2-0001-fix-cmake.patch | 282 ++++++ .../5.4.2-0002-use-ue2-make_unique.patch | 875 ++++++++++++++++++ .../hyperscan/all/test_package/conanfile.py | 6 +- recipes/hyperscan/config.yml | 2 + 8 files changed, 1191 insertions(+), 5 deletions(-) rename recipes/hyperscan/all/patches/{0001-fix-cmake.patch => 5.4.0-0001-fix-cmake.patch} (96%) rename recipes/hyperscan/all/patches/{0002-use-ue2-make_unique.patch => 5.4.0-0002-use-ue2-make_unique.patch} (100%) create mode 100644 recipes/hyperscan/all/patches/5.4.2-0001-fix-cmake.patch create mode 100644 recipes/hyperscan/all/patches/5.4.2-0002-use-ue2-make_unique.patch diff --git a/recipes/hyperscan/all/conandata.yml b/recipes/hyperscan/all/conandata.yml index b46d4ac06c6166..e3925c18673ce7 100644 --- a/recipes/hyperscan/all/conandata.yml +++ b/recipes/hyperscan/all/conandata.yml @@ -1,12 +1,22 @@ sources: + "5.4.2": + url: "https://github.com/intel/hyperscan/archive/v5.4.2.tar.gz" + sha256: "32b0f24b3113bbc46b6bfaa05cf7cf45840b6b59333d078cc1f624e4c40b2b99" "5.4.0": url: "https://github.com/intel/hyperscan/archive/v5.4.0.tar.gz" sha256: "e51aba39af47e3901062852e5004d127fa7763b5dbbc16bcca4265243ffa106f" patches: + "5.4.2": + - patch_file: "patches/5.4.2-0001-fix-cmake.patch" + patch_description: "modify cmake files to build with conan" + patch_type: "conan" + - patch_file: "patches/5.4.2-0002-use-ue2-make_unique.patch" + patch_description: "add ue2:: prefix to make_unique for name collision" + patch_type: "portability" "5.4.0": - - patch_file: "patches/0001-fix-cmake.patch" + - patch_file: "patches/5.4.0-0001-fix-cmake.patch" patch_description: "modify cmake files to build with conan" patch_type: "conan" - - patch_file: "patches/0002-use-ue2-make_unique.patch" + - patch_file: "patches/5.4.0-0002-use-ue2-make_unique.patch" patch_description: "add ue2:: prefix to make_unique for name collision" patch_type: "portability" diff --git a/recipes/hyperscan/all/conanfile.py b/recipes/hyperscan/all/conanfile.py index 5e30dac82fb957..8ccc3f01da9594 100644 --- a/recipes/hyperscan/all/conanfile.py +++ b/recipes/hyperscan/all/conanfile.py @@ -16,6 +16,7 @@ class HyperscanConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.hyperscan.io" topics = ("regex", "regular expressions") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -57,7 +58,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") if self.options.build_chimera: self.requires("pcre/8.45") @@ -88,6 +89,7 @@ def generate(self): tc.variables["BUILD_AVX512"] = self.options.build_avx512 tc.variables["FAT_RUNTIME"] = self.options.fat_runtime tc.variables["BUILD_CHIMERA"] = self.options.build_chimera + tc.variables["BUILD_EXAMPLES"] = False if self.options.dump_support != "auto": tc.variables["DUMP_SUPPORT"] = self.options.dump_support tc.generate() diff --git a/recipes/hyperscan/all/patches/0001-fix-cmake.patch b/recipes/hyperscan/all/patches/5.4.0-0001-fix-cmake.patch similarity index 96% rename from recipes/hyperscan/all/patches/0001-fix-cmake.patch rename to recipes/hyperscan/all/patches/5.4.0-0001-fix-cmake.patch index 872966c197543c..ab66becd930f5b 100644 --- a/recipes/hyperscan/all/patches/0001-fix-cmake.patch +++ b/recipes/hyperscan/all/patches/5.4.0-0001-fix-cmake.patch @@ -1,5 +1,5 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 8bc6077..0fbed25 100644 +index 8bc6077..2dfdf29 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,7 +6,7 @@ set (HS_MINOR_VERSION 4) @@ -40,6 +40,17 @@ index 8bc6077..0fbed25 100644 OUTPUT_VARIABLE BUILD_DATE OUTPUT_STRIP_TRAILING_WHITESPACE) else () +@@ -242,8 +242,8 @@ else() + if (NOT RELEASE_BUILD) + # -Werror is most useful during development, don't potentially break + # release builds +- set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -Werror") +- set(EXTRA_CXX_FLAGS "${EXTRA_CXX_FLAGS} -Werror") ++ #set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -Werror") ++ #set(EXTRA_CXX_FLAGS "${EXTRA_CXX_FLAGS} -Werror") + endif() + + if (DISABLE_ASSERTS) @@ -326,7 +326,7 @@ if (CMAKE_SYSTEM_NAME MATCHES "Linux") message (STATUS "Building the fat runtime requires the Unix Makefiles generator, or Ninja with CMake v3.0 or higher") set (FAT_RUNTIME_REQUISITES FALSE) diff --git a/recipes/hyperscan/all/patches/0002-use-ue2-make_unique.patch b/recipes/hyperscan/all/patches/5.4.0-0002-use-ue2-make_unique.patch similarity index 100% rename from recipes/hyperscan/all/patches/0002-use-ue2-make_unique.patch rename to recipes/hyperscan/all/patches/5.4.0-0002-use-ue2-make_unique.patch diff --git a/recipes/hyperscan/all/patches/5.4.2-0001-fix-cmake.patch b/recipes/hyperscan/all/patches/5.4.2-0001-fix-cmake.patch new file mode 100644 index 00000000000000..87c26ae4533b62 --- /dev/null +++ b/recipes/hyperscan/all/patches/5.4.2-0001-fix-cmake.patch @@ -0,0 +1,282 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 7757916..6f05b5b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -6,7 +6,7 @@ set (HS_MINOR_VERSION 4) + set (HS_PATCH_VERSION 2) + set (HS_VERSION ${HS_MAJOR_VERSION}.${HS_MINOR_VERSION}.${HS_PATCH_VERSION}) + +-set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) ++list(APPEND CMAKE_MODULE_PATH "${PROJECT_SOURCE_DIR}/cmake") + include(CheckCCompilerFlag) + include(CheckCXXCompilerFlag) + include(CheckCXXSymbolExists) +@@ -17,8 +17,8 @@ INCLUDE (CheckLibraryExists) + INCLUDE (CheckSymbolExists) + include (CMakeDependentOption) + include (GNUInstallDirs) +-include (${CMAKE_MODULE_PATH}/platform.cmake) +-include (${CMAKE_MODULE_PATH}/ragel.cmake) ++include (platform) ++include (ragel) + + find_package(PkgConfig QUIET) + +@@ -69,7 +69,7 @@ include_directories(${PROJECT_SOURCE_DIR}/src) + include_directories(${PROJECT_BINARY_DIR}) + include_directories(SYSTEM include) + +-include (${CMAKE_MODULE_PATH}/boost.cmake) ++include (boost) + + # -- make this work? set(python_ADDITIONAL_VERSIONS 2.7 2.6) + find_package(PythonInterp) +@@ -84,7 +84,7 @@ endif() + # allow for reproducible builds - python for portability + if (DEFINED ENV{SOURCE_DATE_EPOCH}) + execute_process( +- COMMAND "${PYTHON}" "${CMAKE_MODULE_PATH}/formatdate.py" "$ENV{SOURCE_DATE_EPOCH}" ++ COMMAND "${PYTHON}" "${PROJECT_SOURCE_DIR}/cmake/formatdate.py" "$ENV{SOURCE_DATE_EPOCH}" + OUTPUT_VARIABLE BUILD_DATE + OUTPUT_STRIP_TRAILING_WHITESPACE) + else () +@@ -242,8 +242,8 @@ else() + if (NOT RELEASE_BUILD) + # -Werror is most useful during development, don't potentially break + # release builds +- set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -Werror") +- set(EXTRA_CXX_FLAGS "${EXTRA_CXX_FLAGS} -Werror") ++ #set(EXTRA_C_FLAGS "${EXTRA_C_FLAGS} -Werror") ++ #set(EXTRA_CXX_FLAGS "${EXTRA_CXX_FLAGS} -Werror") + endif() + + if (DISABLE_ASSERTS) +@@ -326,7 +326,7 @@ if (CMAKE_SYSTEM_NAME MATCHES "Linux") + message (STATUS "Building the fat runtime requires the Unix Makefiles generator, or Ninja with CMake v3.0 or higher") + set (FAT_RUNTIME_REQUISITES FALSE) + else() +- include (${CMAKE_MODULE_PATH}/attrib.cmake) ++ include (attrib) + if (NOT HAS_C_ATTR_IFUNC) + message(STATUS "Compiler does not support ifunc attribute, cannot build fat runtime") + set (FAT_RUNTIME_REQUISITES FALSE) +@@ -337,7 +337,7 @@ if (CMAKE_SYSTEM_NAME MATCHES "Linux") + CMAKE_DEPENDENT_OPTION(FAT_RUNTIME "Build a library that supports multiple microarchitectures" ${RELEASE_BUILD} "FAT_RUNTIME_REQUISITES" OFF) + endif () + +-include (${CMAKE_MODULE_PATH}/arch.cmake) ++include (arch) + + # testing a builtin takes a little more work + CHECK_C_SOURCE_COMPILES("void *aa_test(void *x) { return __builtin_assume_aligned(x, 16);}\nint main(void) { return 0; }" HAVE_CC_BUILTIN_ASSUME_ALIGNED) +@@ -477,7 +477,6 @@ else() + set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS}") + endif() + +-add_subdirectory(util) + add_subdirectory(doc/dev-reference) + + if (NOT WIN32) +@@ -486,7 +485,7 @@ if (NOT WIN32) + set(PCRE_REQUIRED_MAJOR_VERSION 8) + set(PCRE_REQUIRED_MINOR_VERSION 41) + set(PCRE_REQUIRED_VERSION ${PCRE_REQUIRED_MAJOR_VERSION}.${PCRE_REQUIRED_MINOR_VERSION}) +-include (${CMAKE_MODULE_PATH}/pcre.cmake) ++include (pcre) + if (NOT CORRECT_PCRE_VERSION) + message(STATUS "PCRE ${PCRE_REQUIRED_VERSION} or above not found") + endif() +@@ -496,17 +495,19 @@ if (CORRECT_PCRE_VERSION AND PCRE_BUILD_SOURCE AND BUILD_STATIC_LIBS) + set(BUILD_CHIMERA TRUE) + endif() + ++if(0) + add_subdirectory(unit) + if (EXISTS ${CMAKE_SOURCE_DIR}/tools/CMakeLists.txt) + add_subdirectory(tools) + endif() +-if (EXISTS ${CMAKE_SOURCE_DIR}/chimera/CMakeLists.txt AND BUILD_CHIMERA) ++endif() ++if (EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/chimera/CMakeLists.txt AND BUILD_CHIMERA) + add_subdirectory(chimera) + endif() + endif() + + # do substitutions +-configure_file(${CMAKE_MODULE_PATH}/config.h.in ${PROJECT_BINARY_DIR}/config.h) ++configure_file(${PROJECT_SOURCE_DIR}/cmake/config.h.in ${PROJECT_BINARY_DIR}/config.h) + configure_file(src/hs_version.h.in ${PROJECT_BINARY_DIR}/hs_version.h) + + if (NOT WIN32) +@@ -519,7 +520,7 @@ if (NOT WIN32) + endforeach() + + configure_file(libhs.pc.in libhs.pc @ONLY) # only replace @ quoted vars +- install(FILES ${CMAKE_BINARY_DIR}/libhs.pc ++ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/libhs.pc + DESTINATION "${CMAKE_INSTALL_LIBDIR}/pkgconfig") + endif() + +@@ -538,7 +539,7 @@ if (WIN32) + set(PCRE_REQUIRED_MAJOR_VERSION 8) + set(PCRE_REQUIRED_MINOR_VERSION 41) + set(PCRE_REQUIRED_VERSION ${PCRE_REQUIRED_MAJOR_VERSION}.${PCRE_REQUIRED_MINOR_VERSION}) +-include (${CMAKE_MODULE_PATH}/pcre.cmake) ++include (pcre) + if (NOT CORRECT_PCRE_VERSION) + message(STATUS "PCRE ${PCRE_REQUIRED_VERSION} or above not found") + endif() +@@ -548,10 +549,12 @@ if (CORRECT_PCRE_VERSION AND PCRE_BUILD_SOURCE AND BUILD_STATIC_LIBS) + set(BUILD_CHIMERA TRUE) + endif() + ++if(0) + add_subdirectory(unit) + if (EXISTS ${CMAKE_SOURCE_DIR}/tools/CMakeLists.txt) + add_subdirectory(tools) + endif() ++endif() + if (EXISTS ${CMAKE_SOURCE_DIR}/chimera/CMakeLists.txt AND BUILD_CHIMERA) + add_subdirectory(chimera) + endif() +@@ -562,14 +565,14 @@ set(RAGEL_C_FLAGS "-Wno-unused") + endif() + + set_source_files_properties( +- ${CMAKE_BINARY_DIR}/src/parser/Parser.cpp ++ ${CMAKE_CURRENT_BINARY_DIR}/src/parser/Parser.cpp + PROPERTIES + COMPILE_FLAGS "${RAGEL_C_FLAGS}") + + ragelmaker(src/parser/Parser.rl) + + set_source_files_properties( +- ${CMAKE_BINARY_DIR}/src/parser/control_verbs.cpp ++ ${CMAKE_CURRENT_BINARY_DIR}/src/parser/control_verbs.cpp + PROPERTIES + COMPILE_FLAGS "${RAGEL_C_FLAGS}") + +@@ -1230,28 +1233,28 @@ else (FAT_RUNTIME) + list(APPEND RUNTIME_LIBS $) + set_target_properties(hs_exec_core2 PROPERTIES + COMPILE_FLAGS "-march=core2" +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} core2 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} core2 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + + add_library(hs_exec_corei7 OBJECT ${hs_exec_SRCS}) + list(APPEND RUNTIME_LIBS $) + set_target_properties(hs_exec_corei7 PROPERTIES + COMPILE_FLAGS "-march=corei7" +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} corei7 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} corei7 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + + add_library(hs_exec_avx2 OBJECT ${hs_exec_SRCS} ${hs_exec_avx2_SRCS}) + list(APPEND RUNTIME_LIBS $) + set_target_properties(hs_exec_avx2 PROPERTIES + COMPILE_FLAGS "-march=core-avx2" +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx2 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx2 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + if (BUILD_AVX512) + add_library(hs_exec_avx512 OBJECT ${hs_exec_SRCS} ${hs_exec_avx2_SRCS}) + list(APPEND RUNTIME_LIBS $) + set_target_properties(hs_exec_avx512 PROPERTIES + COMPILE_FLAGS "${SKYLAKE_FLAG}" +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + endif (BUILD_AVX512) + if (BUILD_AVX512VBMI) +@@ -1259,7 +1262,7 @@ else (FAT_RUNTIME) + list(APPEND RUNTIME_LIBS $) + set_target_properties(hs_exec_avx512vbmi PROPERTIES + COMPILE_FLAGS "${ICELAKE_FLAG}" +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512vbmi ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512vbmi ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + endif (BUILD_AVX512VBMI) + +@@ -1294,14 +1297,14 @@ else (FAT_RUNTIME) + set_target_properties(hs_exec_shared_core2 PROPERTIES + COMPILE_FLAGS "-march=core2" + POSITION_INDEPENDENT_CODE TRUE +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} core2 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} core2 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + add_library(hs_exec_shared_corei7 OBJECT ${hs_exec_SRCS}) + list(APPEND RUNTIME_SHLIBS $) + set_target_properties(hs_exec_shared_corei7 PROPERTIES + COMPILE_FLAGS "-march=corei7" + POSITION_INDEPENDENT_CODE TRUE +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} corei7 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} corei7 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + add_library(hs_exec_shared_avx2 OBJECT ${hs_exec_SRCS} ${hs_exec_avx2_SRCS}) + list(APPEND RUNTIME_SHLIBS $) +@@ -1317,7 +1320,7 @@ else (FAT_RUNTIME) + set_target_properties(hs_exec_shared_avx512 PROPERTIES + COMPILE_FLAGS "${SKYLAKE_FLAG}" + POSITION_INDEPENDENT_CODE TRUE +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512 ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512 ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + endif (BUILD_AVX512) + if (BUILD_AVX512VBMI) +@@ -1326,7 +1329,7 @@ else (FAT_RUNTIME) + set_target_properties(hs_exec_shared_avx512vbmi PROPERTIES + COMPILE_FLAGS "${ICELAKE_FLAG}" + POSITION_INDEPENDENT_CODE TRUE +- RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512vbmi ${CMAKE_MODULE_PATH}/keep.syms.in" ++ RULE_LAUNCH_COMPILE "${BUILD_WRAPPER} avx512vbmi ${PROJECT_SOURCE_DIR}/cmake/keep.syms.in" + ) + endif (BUILD_AVX512VBMI) + add_library(hs_exec_common_shared OBJECT +diff --git a/chimera/ch_database.h b/chimera/ch_database.h +index 28bde86..33cda9d 100644 +--- a/chimera/ch_database.h ++++ b/chimera/ch_database.h +@@ -38,7 +38,6 @@ extern "C" + { + #endif + +-#define PCRE_STATIC + #include + + #include "ch_compile.h" // for CH_MODE_ flags +diff --git a/cmake/pcre.cmake b/cmake/pcre.cmake +index e0acda5..0f9e8ac 100644 +--- a/cmake/pcre.cmake ++++ b/cmake/pcre.cmake +@@ -50,14 +50,10 @@ if (PCRE_BUILD_SOURCE) + set(PCRE_INCLUDE_DIRS ${PCRE_SOURCE} ${PROJECT_BINARY_DIR}/pcre) + set(PCRE_LDFLAGS -L"${LIBDIR}" -lpcre) + else () +- # pkgconf should save us +- find_package(PkgConfig) +- pkg_check_modules(PCRE libpcre>=${PCRE_REQUIRED_VERSION}) +- if (PCRE_FOUND) ++ # conan should save us ++ find_package(pcre) ++ if(pcre_FOUND AND (pcre_VERSION VERSION_GREATER_EQUAL PCRE_REQUIRED_VERSION)) + set(CORRECT_PCRE_VERSION TRUE) +- message(STATUS "PCRE version ${PCRE_REQUIRED_VERSION} or above") +- else () +- message(STATUS "PCRE version ${PCRE_REQUIRED_VERSION} or above not found") +- return () +- endif () ++ set(PCRE_LDFLAGS "pcre::pcre") ++ endif() + endif (PCRE_BUILD_SOURCE) +diff --git a/tools/CMakeLists.txt b/tools/CMakeLists.txt +index 6ca3fd8..73c299d 100644 +--- a/tools/CMakeLists.txt ++++ b/tools/CMakeLists.txt +@@ -1,3 +1,6 @@ ++# Tools are not installed ++return () ++ + find_package(Threads) + + # remove some warnings diff --git a/recipes/hyperscan/all/patches/5.4.2-0002-use-ue2-make_unique.patch b/recipes/hyperscan/all/patches/5.4.2-0002-use-ue2-make_unique.patch new file mode 100644 index 00000000000000..7c24368a9f0e10 --- /dev/null +++ b/recipes/hyperscan/all/patches/5.4.2-0002-use-ue2-make_unique.patch @@ -0,0 +1,875 @@ +diff --git a/src/nfa/castlecompile.cpp b/src/nfa/castlecompile.cpp +index 5884ebb..1af6cd2 100644 +--- a/src/nfa/castlecompile.cpp ++++ b/src/nfa/castlecompile.cpp +@@ -281,7 +281,7 @@ vector> checkExclusion(u32 &streamStateSize, + size_t total = 0; + while (lower < trigSize) { + vector vertices; +- unique_ptr cg = make_unique(); ++ unique_ptr cg = ue2::make_unique(); + + vector> min_reset_dist; + size_t upper = min(lower + CLIQUE_GRAPH_MAX_SIZE, trigSize); +diff --git a/src/nfagraph/ng_equivalence.cpp b/src/nfagraph/ng_equivalence.cpp +index a42a0ac..9b1f072 100644 +--- a/src/nfagraph/ng_equivalence.cpp ++++ b/src/nfagraph/ng_equivalence.cpp +@@ -269,7 +269,7 @@ vector> getVertexInfos(const NGHolder &g) { + vertex_map.resize(num_verts); + + for (auto v : vertices_range(g)) { +- infos.push_back(make_unique(v, g)); ++ infos.push_back(ue2::make_unique(v, g)); + vertex_map[g[v].index] = infos.back().get(); + } + +@@ -516,7 +516,7 @@ void mergeClass(vector> &infos, NGHolder &g, + g[new_v].reports.clear(); /* populated as we pull in succs */ + + // store this vertex in our global vertex list +- infos.push_back(make_unique(new_v, g)); ++ infos.push_back(ue2::make_unique(new_v, g)); + VertexInfo *new_vertex_info = infos.back().get(); + + NFAVertex new_v_eod = NGHolder::null_vertex(); +@@ -525,7 +525,7 @@ void mergeClass(vector> &infos, NGHolder &g, + if (require_separate_eod_vertex(cur_class_vertices, g)) { + new_v_eod = clone_vertex(g, old_v); + g[new_v_eod].reports.clear(); +- infos.push_back(make_unique(new_v_eod, g)); ++ infos.push_back(ue2::make_unique(new_v_eod, g)); + new_vertex_info_eod = infos.back().get(); + } + +diff --git a/src/nfagraph/ng_violet.cpp b/src/nfagraph/ng_violet.cpp +index ba6b350..106b900 100644 +--- a/src/nfagraph/ng_violet.cpp ++++ b/src/nfagraph/ng_violet.cpp +@@ -375,7 +375,7 @@ void getSimpleRoseLiterals(const NGHolder &g, bool seeking_anchored, + + DEBUG_PRINTF("candidate is a candidate\n"); + scores[v] = score; +- lit_info[v] = make_unique(v, s, anchored); ++ lit_info[v] = ue2::make_unique(v, s, anchored); + } + + /* try to filter out cases where appending some characters produces worse +@@ -531,7 +531,7 @@ void getRegionRoseLiterals(const NGHolder &g, bool seeking_anchored, + } + + DEBUG_PRINTF("candidate is a candidate\n"); +- lits->push_back(make_unique(vv, s, anchored)); ++ lits->push_back(ue2::make_unique(vv, s, anchored)); + } + } + +@@ -1848,7 +1848,7 @@ static + unique_ptr make_chain(u32 count) { + assert(count); + +- auto rv = make_unique(NFA_INFIX); ++ auto rv = ue2::make_unique(NFA_INFIX); + + NGHolder &h = *rv; + +diff --git a/src/rose/rose_build_add.cpp b/src/rose/rose_build_add.cpp +index aa043fa..f680dbb 100644 +--- a/src/rose/rose_build_add.cpp ++++ b/src/rose/rose_build_add.cpp +@@ -1802,7 +1802,7 @@ bool RoseBuildImpl::addOutfix(const NGHolder &h, const raw_som_dfa &haig) { + + bool RoseBuildImpl::addOutfix(const raw_puff &rp) { + if (!mpv_outfix) { +- mpv_outfix = make_unique(MpvProto()); ++ mpv_outfix = ue2::make_unique(MpvProto()); + } + + auto *mpv = mpv_outfix->mpv(); +@@ -1827,7 +1827,7 @@ bool RoseBuildImpl::addOutfix(const raw_puff &rp) { + bool RoseBuildImpl::addChainTail(const raw_puff &rp, u32 *queue_out, + u32 *event_out) { + if (!mpv_outfix) { +- mpv_outfix = make_unique(MpvProto()); ++ mpv_outfix = ue2::make_unique(MpvProto()); + } + + auto *mpv = mpv_outfix->mpv(); +diff --git a/src/rose/rose_build_anchored.cpp b/src/rose/rose_build_anchored.cpp +index 8ea07c9..1f918bb 100644 +--- a/src/rose/rose_build_anchored.cpp ++++ b/src/rose/rose_build_anchored.cpp +@@ -249,7 +249,7 @@ unique_ptr populate_holder(const simple_anchored_info &sai, + const flat_set &exit_ids) { + DEBUG_PRINTF("populating holder for ^.{%u,%u}%s\n", sai.min_bound, + sai.max_bound, dumpString(sai.literal).c_str()); +- auto h_ptr = make_unique(); ++ auto h_ptr = ue2::make_unique(); + NGHolder &h = *h_ptr; + auto ends = addDotsToGraph(h, h.start, sai.min_bound, sai.max_bound, + CharReach::dot()); +diff --git a/src/rose/rose_build_exclusive.cpp b/src/rose/rose_build_exclusive.cpp +index 6a5a710..966c908 100644 +--- a/src/rose/rose_build_exclusive.cpp ++++ b/src/rose/rose_build_exclusive.cpp +@@ -280,7 +280,7 @@ void findCliques(const map> &exclusiveGroups, + } + // Construct the exclusivity graph + map vertex_map; +- unique_ptr cg = make_unique(); ++ unique_ptr cg = ue2::make_unique(); + + // Add vertices representing infixes/suffixes + for (const auto &e : exclusiveGroups) { +diff --git a/src/rose/rose_build_program.cpp b/src/rose/rose_build_program.cpp +index 96c95db..81d605b 100644 +--- a/src/rose/rose_build_program.cpp ++++ b/src/rose/rose_build_program.cpp +@@ -95,7 +95,7 @@ OffsetMap makeOffsetMap(const RoseProgram &program, u32 *total_len) { + } + + RoseProgram::RoseProgram() { +- prog.push_back(make_unique()); ++ prog.push_back(ue2::make_unique()); + } + + RoseProgram::~RoseProgram() = default; +@@ -297,28 +297,28 @@ void addEnginesEodProgram(u32 eodNfaIterOffset, RoseProgram &program) { + } + + RoseProgram block; +- block.add_before_end(make_unique(eodNfaIterOffset)); ++ block.add_before_end(ue2::make_unique(eodNfaIterOffset)); + program.add_block(move(block)); + } + + void addSuffixesEodProgram(RoseProgram &program) { + RoseProgram block; +- block.add_before_end(make_unique()); ++ block.add_before_end(ue2::make_unique()); + program.add_block(move(block)); + } + + void addMatcherEodProgram(RoseProgram &program) { + RoseProgram block; +- block.add_before_end(make_unique()); ++ block.add_before_end(ue2::make_unique()); + program.add_block(move(block)); + } + + void addFlushCombinationProgram(RoseProgram &program) { +- program.add_before_end(make_unique()); ++ program.add_before_end(ue2::make_unique()); + } + + void addLastFlushCombinationProgram(RoseProgram &program) { +- program.add_before_end(make_unique()); ++ program.add_before_end(ue2::make_unique()); + } + + static +@@ -342,11 +342,11 @@ void makeRoleCheckLeftfix(const RoseBuildImpl &build, + + unique_ptr ri; + if (is_prefix) { +- ri = make_unique(lni.queue, build.g[v].left.lag, ++ ri = ue2::make_unique(lni.queue, build.g[v].left.lag, + build.g[v].left.leftfix_report, + end_inst); + } else { +- ri = make_unique(lni.queue, build.g[v].left.lag, ++ ri = ue2::make_unique(lni.queue, build.g[v].left.lag, + build.g[v].left.leftfix_report, + end_inst); + } +@@ -384,7 +384,7 @@ void makeAnchoredLiteralDelay(const RoseBuildImpl &build, + u32 anch_id = prog_build.anchored_programs.at(lit_id); + + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(groups, anch_id, end_inst); ++ auto ri = ue2::make_unique(groups, anch_id, end_inst); + program.add_before_end(move(ri)); + } + +@@ -393,7 +393,7 @@ void makeDedupe(const ReportManager &rm, const Report &report, + RoseProgram &program) { + const auto *end_inst = program.end_instruction(); + auto ri = +- make_unique(report.quashSom, rm.getDkey(report), ++ ue2::make_unique(report.quashSom, rm.getDkey(report), + report.offsetAdjust, end_inst); + program.add_before_end(move(ri)); + } +@@ -402,7 +402,7 @@ static + void makeDedupeSom(const ReportManager &rm, const Report &report, + RoseProgram &program) { + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(report.quashSom, ++ auto ri = ue2::make_unique(report.quashSom, + rm.getDkey(report), + report.offsetAdjust, end_inst); + program.add_before_end(move(ri)); +@@ -428,7 +428,7 @@ void makeCatchup(const ReportManager &rm, bool needs_catchup, + return; + } + +- program.add_before_end(make_unique()); ++ program.add_before_end(ue2::make_unique()); + } + + static +@@ -511,12 +511,12 @@ void addLogicalSetRequired(const Report &report, ReportManager &rm, + return; + } + // set matching status of current lkey +- auto risl = make_unique(report.lkey, ++ auto risl = ue2::make_unique(report.lkey, + report.offsetAdjust); + program.add_before_end(move(risl)); + // set current lkey's corresponding ckeys active, pending to check + for (auto ckey : rm.getRelateCKeys(report.lkey)) { +- auto risc = make_unique(ckey); ++ auto risc = ue2::make_unique(ckey); + program.add_before_end(move(risc)); + } + } +@@ -532,7 +532,7 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + + // Handle min/max offset checks. + if (report.minOffset > 0 || report.maxOffset < MAX_OFFSET) { +- auto ri = make_unique(report.minOffset, ++ auto ri = ue2::make_unique(report.minOffset, + report.maxOffset, end_inst); + report_block.add_before_end(move(ri)); + } +@@ -540,7 +540,7 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + // If this report has an exhaustion key, we can check it in the program + // rather than waiting until we're in the callback adaptor. + if (report.ekey != INVALID_EKEY) { +- auto ri = make_unique(report.ekey, end_inst); ++ auto ri = ue2::make_unique(report.ekey, end_inst); + report_block.add_before_end(move(ri)); + } + +@@ -548,7 +548,7 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + // calculated. + if (isExternalSomReport(report) && + report.type != EXTERNAL_CALLBACK_SOM_PASS) { +- auto ri = make_unique(); ++ auto ri = ue2::make_unique(); + writeSomOperation(report, &ri->som); + report_block.add_before_end(move(ri)); + } +@@ -556,13 +556,13 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + // Min length constraint. + if (report.minLength > 0) { + assert(build.hasSom); +- auto ri = make_unique( ++ auto ri = ue2::make_unique( + report.offsetAdjust, report.minLength, end_inst); + report_block.add_before_end(move(ri)); + } + + if (report.quashSom) { +- report_block.add_before_end(make_unique()); ++ report_block.add_before_end(ue2::make_unique()); + } + + switch (report.type) { +@@ -578,7 +578,7 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + if (needs_dedupe) { + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.quashSom, build.rm.getDkey(report), + report.onmatch, report.offsetAdjust, end_inst)); + } else { +@@ -587,7 +587,7 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + } else { + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.onmatch, report.offsetAdjust)); + } + } +@@ -597,28 +597,28 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + } + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.onmatch, report.offsetAdjust, report.ekey)); + } else { + report_block.add_before_end( +- make_unique(report.ekey)); ++ ue2::make_unique(report.ekey)); + } + } + } else { // has_som + makeDedupeSom(build.rm, report, report_block); + if (report.ekey == INVALID_EKEY) { + if (!report.quiet) { +- report_block.add_before_end(make_unique( ++ report_block.add_before_end(ue2::make_unique( + report.onmatch, report.offsetAdjust)); + } + } else { + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.onmatch, report.offsetAdjust, report.ekey)); + } else { + report_block.add_before_end( +- make_unique(report.ekey)); ++ ue2::make_unique(report.ekey)); + } + } + } +@@ -639,17 +639,17 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + addFlushCombinationProgram(report_block); + } + if (has_som) { +- auto ri = make_unique(); ++ auto ri = ue2::make_unique(); + writeSomOperation(report, &ri->som); + report_block.add_before_end(move(ri)); + } else { +- auto ri = make_unique(); ++ auto ri = ue2::make_unique(); + writeSomOperation(report, &ri->som); + report_block.add_before_end(move(ri)); + } + break; + case INTERNAL_ROSE_CHAIN: { +- report_block.add_before_end(make_unique( ++ report_block.add_before_end(ue2::make_unique( + report.onmatch, report.topSquashDistance)); + break; + } +@@ -663,17 +663,17 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + makeDedupeSom(build.rm, report, report_block); + if (report.ekey == INVALID_EKEY) { + if (!report.quiet) { +- report_block.add_before_end(make_unique( ++ report_block.add_before_end(ue2::make_unique( + report.onmatch, report.offsetAdjust)); + } + } else { + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.onmatch, report.offsetAdjust, report.ekey)); + } else { + report_block.add_before_end( +- make_unique(report.ekey)); ++ ue2::make_unique(report.ekey)); + } + } + addLogicalSetRequired(report, build.rm, report_block); +@@ -685,17 +685,17 @@ void makeReport(const RoseBuildImpl &build, const ReportID id, + makeDedupeSom(build.rm, report, report_block); + if (report.ekey == INVALID_EKEY) { + if (!report.quiet) { +- report_block.add_before_end(make_unique( ++ report_block.add_before_end(ue2::make_unique( + report.onmatch, report.offsetAdjust)); + } + } else { + if (!report.quiet) { + report_block.add_before_end( +- make_unique( ++ ue2::make_unique( + report.onmatch, report.offsetAdjust, report.ekey)); + } else { + report_block.add_before_end( +- make_unique(report.ekey)); ++ ue2::make_unique(report.ekey)); + } + } + addLogicalSetRequired(report, build.rm, report_block); +@@ -722,11 +722,11 @@ void makeRoleReports(const RoseBuildImpl &build, + assert(contains(leftfix_info, v)); + const left_build_info &lni = leftfix_info.at(v); + program.add_before_end( +- make_unique(lni.queue, g[v].left.lag)); ++ ue2::make_unique(lni.queue, g[v].left.lag)); + report_som = true; + } else if (g[v].som_adjust) { + program.add_before_end( +- make_unique(g[v].som_adjust)); ++ ue2::make_unique(g[v].som_adjust)); + report_som = true; + } + +@@ -748,7 +748,7 @@ void makeRoleSetState(const unordered_map &roleStateIndices, + if (it == end(roleStateIndices)) { + return; + } +- program.add_before_end(make_unique(it->second)); ++ program.add_before_end(ue2::make_unique(it->second)); + } + + static +@@ -772,7 +772,7 @@ void makePushDelayedInstructions(const RoseLiteralMap &literals, + }); + + for (const auto &ri : delay_instructions) { +- program.add_before_end(make_unique(ri)); ++ program.add_before_end(ue2::make_unique(ri)); + } + } + +@@ -801,10 +801,10 @@ void makeCheckLiteralInstruction(const rose_literal_id &lit, + const auto *end_inst = program.end_instruction(); + unique_ptr ri; + if (lit.s.any_nocase()) { +- ri = make_unique(lit.s.get_string(), ++ ri = ue2::make_unique(lit.s.get_string(), + end_inst); + } else { +- ri = make_unique(lit.s.get_string(), ++ ri = ue2::make_unique(lit.s.get_string(), + end_inst); + } + program.add_before_end(move(ri)); +@@ -820,10 +820,10 @@ void makeCheckLiteralInstruction(const rose_literal_id &lit, + const auto *end_inst = program.end_instruction(); + unique_ptr ri; + if (lit.s.any_nocase()) { +- ri = make_unique(lit.s.get_string(), ++ ri = ue2::make_unique(lit.s.get_string(), + end_inst); + } else { +- ri = make_unique(lit.s.get_string(), end_inst); ++ ri = ue2::make_unique(lit.s.get_string(), end_inst); + } + program.add_before_end(move(ri)); + } +@@ -840,7 +840,7 @@ void makeRoleCheckNotHandled(ProgramBuild &prog_build, RoseVertex v, + } + + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(handled_key, end_inst); ++ auto ri = ue2::make_unique(handled_key, end_inst); + program.add_before_end(move(ri)); + } + +@@ -889,7 +889,7 @@ void makeRoleCheckBounds(const RoseBuildImpl &build, RoseVertex v, + + const auto *end_inst = program.end_instruction(); + program.add_before_end( +- make_unique(min_bound, max_bound, end_inst)); ++ ue2::make_unique(min_bound, max_bound, end_inst)); + } + + static +@@ -924,7 +924,7 @@ void makeRoleGroups(const RoseGraph &g, ProgramBuild &prog_build, + return; + } + +- program.add_before_end(make_unique(groups)); ++ program.add_before_end(ue2::make_unique(groups)); + } + + static +@@ -968,7 +968,7 @@ bool makeRoleByte(const vector &look, RoseProgram &program) { + s32 checkbyte_offset = verify_s32(entry.offset); + DEBUG_PRINTF("CHECK BYTE offset=%d\n", checkbyte_offset); + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(andmask_u8, cmpmask_u8, flip, ++ auto ri = ue2::make_unique(andmask_u8, cmpmask_u8, flip, + checkbyte_offset, end_inst); + program.add_before_end(move(ri)); + return true; +@@ -1000,7 +1000,7 @@ bool makeRoleMask(const vector &look, RoseProgram &program) { + DEBUG_PRINTF("CHECK MASK and_mask=%llx cmp_mask=%llx\n", + and_mask, cmp_mask); + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(and_mask, cmp_mask, neg_mask, ++ auto ri = ue2::make_unique(and_mask, cmp_mask, neg_mask, + base_offset, end_inst); + program.add_before_end(move(ri)); + return true; +@@ -1055,7 +1055,7 @@ bool makeRoleMask32(const vector &look, + DEBUG_PRINTF("base_offset %d\n", base_offset); + + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(and_mask, cmp_mask, neg_mask, ++ auto ri = ue2::make_unique(and_mask, cmp_mask, neg_mask, + base_offset, end_inst); + program.add_before_end(move(ri)); + return true; +@@ -1098,7 +1098,7 @@ bool makeRoleMask64(const vector &look, + DEBUG_PRINTF("base_offset %d\n", base_offset); + + const auto *end_inst = program.end_instruction(); +- auto ri = make_unique(and_mask, cmp_mask, neg_mask, ++ auto ri = ue2::make_unique(and_mask, cmp_mask, neg_mask, + base_offset, end_inst); + program.add_before_end(move(ri)); + return true; +@@ -1235,7 +1235,7 @@ makeCheckShufti16x8(u32 offset_range, u8 bucket_idx, + copy(hi_mask.begin(), hi_mask.begin() + 16, nib_mask.begin() + 16); + copy(bucket_select_mask.begin(), bucket_select_mask.begin() + 16, + bucket_select_mask_16.begin()); +- return make_unique ++ return ue2::make_unique + (nib_mask, bucket_select_mask_16, + neg_mask & 0xffff, base_offset, end_inst); + } +@@ -1255,7 +1255,7 @@ makeCheckShufti32x8(u32 offset_range, u8 bucket_idx, + array lo_mask_16; + copy(hi_mask.begin(), hi_mask.begin() + 16, hi_mask_16.begin()); + copy(lo_mask.begin(), lo_mask.begin() + 16, lo_mask_16.begin()); +- return make_unique ++ return ue2::make_unique + (hi_mask_16, lo_mask_16, bucket_select_mask, + neg_mask, base_offset, end_inst); + } +@@ -1277,7 +1277,7 @@ makeCheckShufti16x16(u32 offset_range, u8 bucket_idx, + bucket_select_mask_32.begin()); + copy(bucket_select_mask_hi.begin(), bucket_select_mask_hi.begin() + 16, + bucket_select_mask_32.begin() + 16); +- return make_unique ++ return ue2::make_unique + (hi_mask, lo_mask, bucket_select_mask_32, + neg_mask & 0xffff, base_offset, end_inst); + } +@@ -1294,7 +1294,7 @@ makeCheckShufti32x16(u32 offset_range, u8 bucket_idx, + return nullptr; + } + +- return make_unique ++ return ue2::make_unique + (hi_mask, lo_mask, bucket_select_mask_hi, + bucket_select_mask_lo, neg_mask, base_offset, end_inst); + } +@@ -1321,7 +1321,7 @@ makeCheckShufti64x8(u32 offset_range, u8 bucket_idx, + copy(lo_mask.begin(), lo_mask.begin() + 16, lo_mask_64.begin() + 32); + copy(lo_mask.begin(), lo_mask.begin() + 16, lo_mask_64.begin() + 48); + +- return make_unique ++ return ue2::make_unique + (hi_mask_64, lo_mask_64, bucket_select_mask, + neg_mask, base_offset, end_inst); + } +@@ -1361,7 +1361,7 @@ makeCheckShufti64x16(u32 offset_range, u8 bucket_idx, + copy(lo_mask.begin() + 16, lo_mask.begin() + 32, lo_mask_2.begin() + 32); + copy(lo_mask.begin() + 16, lo_mask.begin() + 32, lo_mask_2.begin() + 48); + +- return make_unique ++ return ue2::make_unique + (hi_mask_1, hi_mask_2, lo_mask_1, lo_mask_2, bucket_select_mask_hi, + bucket_select_mask_lo, neg_mask, base_offset, end_inst); + } +@@ -1486,7 +1486,7 @@ void makeLookaroundInstruction(const vector &look, + if (look.size() == 1) { + s8 offset = look.begin()->offset; + const CharReach &reach = look.begin()->reach; +- auto ri = make_unique(offset, reach, ++ auto ri = ue2::make_unique(offset, reach, + program.end_instruction()); + program.add_before_end(move(ri)); + return; +@@ -1508,7 +1508,7 @@ void makeLookaroundInstruction(const vector &look, + return; + } + +- auto ri = make_unique(look, ++ auto ri = ue2::make_unique(look, + program.end_instruction()); + program.add_before_end(move(ri)); + } +@@ -1584,7 +1584,7 @@ void makeCheckLitEarlyInstruction(const RoseBuildImpl &build, u32 lit_id, + + DEBUG_PRINTF("adding lit early check, min_offset=%u\n", min_offset); + const auto *end = prog.end_instruction(); +- prog.add_before_end(make_unique(min_offset, end)); ++ prog.add_before_end(ue2::make_unique(min_offset, end)); + } + + static +@@ -1595,7 +1595,7 @@ void makeGroupCheckInstruction(const RoseBuildImpl &build, u32 lit_id, + if (!info.group_mask) { + return; + } +- prog.add_before_end(make_unique(info.group_mask)); ++ prog.add_before_end(ue2::make_unique(info.group_mask)); + } + + static +@@ -1762,7 +1762,7 @@ bool makeRoleMultipathShufti(const vector> &multi_look, + copy(begin(lo_mask), begin(lo_mask) + 16, nib_mask.begin()); + copy(begin(hi_mask), begin(hi_mask) + 16, nib_mask.begin() + 16); + +- auto ri = make_unique ++ auto ri = ue2::make_unique + (nib_mask, bucket_select_lo, data_select_mask, hi_bits_mask, + lo_bits_mask, neg_mask, base_offset, last_start, end_inst); + program.add_before_end(move(ri)); +@@ -1771,20 +1771,20 @@ bool makeRoleMultipathShufti(const vector> &multi_look, + assert(!(hi_bits_mask & ~0xffffffffULL)); + assert(!(lo_bits_mask & ~0xffffffffULL)); + if (bit_index <= 8) { +- auto ri = make_unique ++ auto ri = ue2::make_unique + (hi_mask, lo_mask, bucket_select_lo, data_select_mask, + hi_bits_mask, lo_bits_mask, neg_mask, base_offset, + last_start, end_inst); + program.add_before_end(move(ri)); + } else { +- auto ri = make_unique ++ auto ri = ue2::make_unique + (hi_mask, lo_mask, bucket_select_hi, bucket_select_lo, + data_select_mask, hi_bits_mask, lo_bits_mask, neg_mask, + base_offset, last_start, end_inst); + program.add_before_end(move(ri)); + } + } else { +- auto ri = make_unique ++ auto ri = ue2::make_unique + (hi_mask, lo_mask, bucket_select_lo, data_select_mask, + hi_bits_mask, lo_bits_mask, neg_mask, base_offset, + last_start, end_inst); +@@ -1856,7 +1856,7 @@ void makeRoleMultipathLookaround(const vector> &multi_look, + ordered_look.emplace_back(multi_entry); + } + +- auto ri = make_unique(move(ordered_look), ++ auto ri = ue2::make_unique(move(ordered_look), + last_start, start_mask, + program.end_instruction()); + program.add_before_end(move(ri)); +@@ -1932,7 +1932,7 @@ void makeRoleSuffix(const RoseBuildImpl &build, + event = MQE_TOP; + } + +- prog.add_before_end(make_unique(queue, event)); ++ prog.add_before_end(ue2::make_unique(queue, event)); + } + + static +@@ -1945,7 +1945,7 @@ void addInfixTriggerInstructions(vector triggers, + }); + for (const auto &ti : triggers) { + prog.add_before_end( +- make_unique(ti.cancel, ti.queue, ti.event)); ++ ue2::make_unique(ti.cancel, ti.queue, ti.event)); + } + } + +@@ -2039,7 +2039,7 @@ static + void addCheckOnlyEodInstruction(RoseProgram &prog) { + DEBUG_PRINTF("only at eod\n"); + const auto *end_inst = prog.end_instruction(); +- prog.add_before_end(make_unique(end_inst)); ++ prog.add_before_end(ue2::make_unique(end_inst)); + } + + static +@@ -2164,7 +2164,7 @@ void makeGroupSquashInstruction(const RoseBuildImpl &build, u32 lit_id, + DEBUG_PRINTF("squashes 0x%llx\n", info.group_mask); + assert(info.group_mask); + /* Note: group_mask is negated. */ +- prog.add_before_end(make_unique(~info.group_mask)); ++ prog.add_before_end(ue2::make_unique(~info.group_mask)); + } + + namespace { +@@ -2209,7 +2209,7 @@ RoseProgram assembleProgramBlocks(vector &&blocks_in) { + * only set if a state has been. */ + if (!prog.empty() && reads_work_done_flag(block)) { + RoseProgram clear_block; +- clear_block.add_before_end(make_unique()); ++ clear_block.add_before_end(ue2::make_unique()); + prog.add_block(move(clear_block)); + } + +@@ -2369,7 +2369,7 @@ void makeCatchupMpv(const ReportManager &rm, bool needs_mpv_catchup, + return; + } + +- program.add_before_end(make_unique()); ++ program.add_before_end(ue2::make_unique()); + } + + RoseProgram makeReportProgram(const RoseBuildImpl &build, +@@ -2402,7 +2402,7 @@ RoseProgram makeBoundaryProgram(const RoseBuildImpl &build, + void addIncludedJumpProgram(RoseProgram &program, u32 child_offset, + u8 squash) { + RoseProgram block; +- block.add_before_end(make_unique(child_offset, ++ block.add_before_end(ue2::make_unique(child_offset, + squash)); + program.add_block(move(block)); + } +@@ -2413,7 +2413,7 @@ void addPredBlockSingle(u32 pred_state, RoseProgram &pred_block, + // Prepend an instruction to check the pred state is on. + const auto *end_inst = pred_block.end_instruction(); + pred_block.insert(begin(pred_block), +- make_unique(pred_state, end_inst)); ++ ue2::make_unique(pred_state, end_inst)); + program.add_block(move(pred_block)); + } + +@@ -2428,7 +2428,7 @@ void addPredBlocksAny(map &pred_blocks, u32 num_states, + } + + const RoseInstruction *end_inst = sparse_program.end_instruction(); +- auto ri = make_unique(num_states, keys, end_inst); ++ auto ri = ue2::make_unique(num_states, keys, end_inst); + sparse_program.add_before_end(move(ri)); + + RoseProgram &block = pred_blocks.begin()->second; +@@ -2451,14 +2451,14 @@ void addPredBlocksMulti(map &pred_blocks, + vector> jump_table; + + // BEGIN instruction. +- auto ri_begin = make_unique(num_states, end_inst); ++ auto ri_begin = ue2::make_unique(num_states, end_inst); + RoseInstrSparseIterBegin *begin_inst = ri_begin.get(); + sparse_program.add_before_end(move(ri_begin)); + + // NEXT instructions, one per pred program. + u32 prev_key = pred_blocks.begin()->first; + for (auto it = next(begin(pred_blocks)); it != end(pred_blocks); ++it) { +- auto ri = make_unique(prev_key, begin_inst, ++ auto ri = ue2::make_unique(prev_key, begin_inst, + end_inst); + sparse_program.add_before_end(move(ri)); + prev_key = it->first; +@@ -2539,7 +2539,7 @@ void applyFinalSpecialisation(RoseProgram &program) { + auto it = next(program.rbegin()); + if (auto *ri = dynamic_cast(it->get())) { + DEBUG_PRINTF("replacing REPORT with FINAL_REPORT\n"); +- program.replace(it, make_unique( ++ program.replace(it, ue2::make_unique( + ri->onmatch, ri->offset_adjust)); + } + } +diff --git a/src/rose/rose_in_util.cpp b/src/rose/rose_in_util.cpp +index 9fe47c2..6fa56d1 100644 +--- a/src/rose/rose_in_util.cpp ++++ b/src/rose/rose_in_util.cpp +@@ -93,7 +93,7 @@ private: + + unique_ptr cloneRoseGraph(const RoseInGraph &ig) { + assert(hasCorrectlyNumberedVertices(ig)); +- unique_ptr out = make_unique(); ++ unique_ptr out = ue2::make_unique(); + + unordered_map> graph_map; + unordered_map> haig_map; +diff --git a/src/smallwrite/smallwrite_build.cpp b/src/smallwrite/smallwrite_build.cpp +index ea89669..fc4e5cb 100644 +--- a/src/smallwrite/smallwrite_build.cpp ++++ b/src/smallwrite/smallwrite_build.cpp +@@ -680,7 +680,7 @@ unique_ptr buildDfa(LitTrie &trie, bool nocase) { + // Construct DFA states in BFS order. + const auto state_ids = makeStateMap(trie, ordering); + +- auto rdfa = make_unique(NFA_OUTFIX); ++ auto rdfa = ue2::make_unique(NFA_OUTFIX); + + // Calculate alphabet. + array unalpha; +diff --git a/tools/hsbench/main.cpp b/tools/hsbench/main.cpp +index 22becbd..4c671c0 100644 +--- a/tools/hsbench/main.cpp ++++ b/tools/hsbench/main.cpp +@@ -1043,7 +1043,7 @@ void runBenchmark(const Engine &db, + int HS_CDECL main(int argc, char *argv[]) { + unique_ptr grey; + #if !defined(RELEASE_BUILD) +- grey = make_unique(); ++ grey = ue2::make_unique(); + #endif + setlocale(LC_ALL, ""); // use the user's locale + +diff --git a/tools/hscheck/main.cpp b/tools/hscheck/main.cpp +index 197087b..bdecab8 100644 +--- a/tools/hscheck/main.cpp ++++ b/tools/hscheck/main.cpp +@@ -664,7 +664,7 @@ int HS_CDECL main(int argc, char **argv) { + num_of_threads = max(1u, std::thread::hardware_concurrency()); + + #if !defined(RELEASE_BUILD) +- g_grey = make_unique(); ++ g_grey = ue2::make_unique(); + #endif + processArgs(argc, argv, g_grey); + +diff --git a/tools/hscollider/GraphTruth.cpp b/tools/hscollider/GraphTruth.cpp +index 0b67b11..e43beb1 100644 +--- a/tools/hscollider/GraphTruth.cpp ++++ b/tools/hscollider/GraphTruth.cpp +@@ -134,7 +134,7 @@ void CNGInfo::compile() { + auto pl = ue2::make_unique(); + pl->parseLogicalCombination(id, re.c_str(), ~0U, 0, ~0ULL); + pl->logicalKeyRenumber(); +- cng = make_unique(move(pl)); ++ cng = ue2::make_unique(move(pl)); + return; + } + +@@ -193,7 +193,7 @@ void CNGInfo::compile() { + } + } + +- cng = make_unique(move(g), move(rm)); ++ cng = ue2::make_unique(move(g), move(rm)); + } catch (CompileError &e) { + throw NGCompileFailure(e.reason); + } catch (NGUnsupportedFailure &e) { +@@ -257,7 +257,7 @@ unique_ptr GraphTruth::preprocess(unsigned id, + } + } + +- auto cngi = make_unique(id, m_expr); ++ auto cngi = ue2::make_unique(id, m_expr); + cngi->utf8 = hs_flags & HS_FLAG_UTF8; + cngi->highlander = highlander; + cngi->prefilter = prefilter; +diff --git a/tools/hscollider/GroundTruth.cpp b/tools/hscollider/GroundTruth.cpp +index a267306..d9293dc 100644 +--- a/tools/hscollider/GroundTruth.cpp ++++ b/tools/hscollider/GroundTruth.cpp +@@ -331,7 +331,7 @@ GroundTruth::compile(unsigned id, bool no_callouts) { + int errloc = 0; + int errcode = 0; + +- unique_ptr compiled = make_unique(); ++ unique_ptr compiled = ue2::make_unique(); + compiled->utf8 = flags & PCRE_UTF8; + compiled->highlander = highlander; + compiled->prefilter = prefilter; +diff --git a/tools/hscollider/main.cpp b/tools/hscollider/main.cpp +index afa6ef5..c85526e 100644 +--- a/tools/hscollider/main.cpp ++++ b/tools/hscollider/main.cpp +@@ -1606,7 +1606,7 @@ void generateTests(CorporaSource &corpora_src, const ExpressionMap &exprMap, + max_generator_queue_len); + vector> generators; + for (size_t i = 0; i < numGeneratorThreads; i++) { +- auto c = make_unique(i, testq, corpq, corpora_src); ++ auto c = ue2::make_unique(i, testq, corpq, corpora_src); + c->start(); + generators.push_back(move(c)); + } +diff --git a/util/ng_corpus_generator.cpp b/util/ng_corpus_generator.cpp +index f796cd4..1613082 100644 +--- a/util/ng_corpus_generator.cpp ++++ b/util/ng_corpus_generator.cpp +@@ -200,7 +200,7 @@ void findPaths(const NGHolder &g, CorpusProperties &cProps, + if (boost::next(ai) == ae) { + new_path = std::move(p); + } else { +- new_path = make_unique(*p); ++ new_path = ue2::make_unique(*p); + } + + new_path->push_back(v); diff --git a/recipes/hyperscan/all/test_package/conanfile.py b/recipes/hyperscan/all/test_package/conanfile.py index f5c91753bcba3d..5e1749b052fcf1 100644 --- a/recipes/hyperscan/all/test_package/conanfile.py +++ b/recipes/hyperscan/all/test_package/conanfile.py @@ -9,6 +9,8 @@ class TestPackageConan(ConanFile): generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" + _with_chimera = False + def layout(self): cmake_layout(self) @@ -20,6 +22,8 @@ def generate(self): tc.variables["BUILD_CHIMERA"] = self.dependencies["hyperscan"].options.build_chimera tc.generate() + self._with_chimera = self.dependencies["hyperscan"].options.build_chimera + def build(self): cmake = CMake(self) cmake.configure() @@ -30,6 +34,6 @@ def test(self): bin_path = os.path.join(self.cpp.build.bindirs[0], "hs_example") self.run(bin_path, env="conanrun") - if self.options["hyperscan"].build_chimera: + if self._with_chimera: bin_path = os.path.join(self.cpp.build.bindirs[0], "ch_example") self.run(bin_path, env="conanrun") diff --git a/recipes/hyperscan/config.yml b/recipes/hyperscan/config.yml index d02161efd202ba..4915e863cdb5a4 100644 --- a/recipes/hyperscan/config.yml +++ b/recipes/hyperscan/config.yml @@ -1,3 +1,5 @@ versions: + "5.4.2": + folder: all "5.4.0": folder: all From 4c7939bc4f74883779b8a6a3b6e5472c70140744 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 2 Sep 2023 22:06:20 +0300 Subject: [PATCH 0497/1140] (#18663) enkits: migrate to Conan v2 * enkits: migrate to Conan v2 * enkits: restore VirtualRunEnv in test_package * enkits: add m --- recipes/enkits/all/CMakeLists.txt | 7 -- recipes/enkits/all/conandata.yml | 10 --- recipes/enkits/all/conanfile.py | 74 ++++++++++--------- .../patches/cmake-install-lib-location.patch | 5 -- .../enkits/all/test_package/CMakeLists.txt | 9 +-- recipes/enkits/all/test_package/conanfile.py | 22 ++++-- .../enkits/all/test_v1_package/CMakeLists.txt | 8 ++ .../enkits/all/test_v1_package/conanfile.py | 16 ++++ 8 files changed, 85 insertions(+), 66 deletions(-) delete mode 100644 recipes/enkits/all/CMakeLists.txt delete mode 100644 recipes/enkits/all/patches/cmake-install-lib-location.patch create mode 100644 recipes/enkits/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/enkits/all/test_v1_package/conanfile.py diff --git a/recipes/enkits/all/CMakeLists.txt b/recipes/enkits/all/CMakeLists.txt deleted file mode 100644 index c986d294c75479..00000000000000 --- a/recipes/enkits/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/enkits/all/conandata.yml b/recipes/enkits/all/conandata.yml index 9604c7fcf2b728..197355c129edc9 100644 --- a/recipes/enkits/all/conandata.yml +++ b/recipes/enkits/all/conandata.yml @@ -8,13 +8,3 @@ sources: "1.8": url: "https://github.com/dougbinks/enkiTS/archive/v1.8.zip" sha256: "b96d8d439502d52f9dc419539b12b588df10750f4631ad5518586f7048cdfaef" -patches: - "1.11": - - patch_file: "patches/cmake-install-lib-location.patch" - base_path: "source_subfolder" - "1.10": - - patch_file: "patches/cmake-install-lib-location.patch" - base_path: "source_subfolder" - "1.8": - - patch_file: "patches/cmake-install-lib-location.patch" - base_path: "source_subfolder" diff --git a/recipes/enkits/all/conanfile.py b/recipes/enkits/all/conanfile.py index 3a8bf5c9e920b0..6149fad91345f3 100644 --- a/recipes/enkits/all/conanfile.py +++ b/recipes/enkits/all/conanfile.py @@ -1,18 +1,22 @@ import os -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, export_conandata_patches, get, replace_in_file + +required_conan_version = ">=1.53.0" + class EnkiTSConan(ConanFile): name = "enkits" description = "A permissively licensed C and C++ Task Scheduler for creating parallel programs." - topics = ("conan", "c", "thread", "multithreading", "scheduling", "enkits", "gamedev") + license = "Zlib" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/dougbinks/enkiTS" - license = "Zlib" - settings = "os", "arch", "compiler", "build_type" - - exports_sources = "CMakeLists.txt", "patches/*" - generators = "cmake" + topics = ("c", "thread", "multithreading", "scheduling", "gamedev") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -22,11 +26,8 @@ class EnkiTSConan(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -34,37 +35,44 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "enkiTS-" + self.version - os.rename(extracted_dir, self._source_subfolder) - - def _configure_cmake(self): - if not self._cmake: - self._cmake = CMake(self) - self._cmake.definitions["ENKITS_INSTALL"] = True - self._cmake.definitions["ENKITS_BUILD_EXAMPLES"] = False - self._cmake.definitions["ENKITS_BUILD_SHARED"] = self.options.shared - self._cmake.configure() - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["ENKITS_INSTALL"] = True + tc.variables["ENKITS_BUILD_EXAMPLES"] = False + tc.variables["ENKITS_BUILD_SHARED"] = self.options.shared + tc.generate() + + def _patch_sources(self): + replace_in_file( + self, + os.path.join(self.source_folder, "CMakeLists.txt"), + 'install(TARGETS enkiTS DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/enkiTS")', + "install(TARGETS enkiTS ARCHIVE LIBRARY RUNTIME)", + ) def build(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) - cmake = self._configure_cmake() + self._patch_sources() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="License.txt", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "License.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): self.cpp_info.libs = ["enkiTS"] - + if self.options.shared: self.cpp_info.defines.append("ENKITS_DLL=1") - if self.settings.os == "Linux": - self.cpp_info.system_libs = ["pthread"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m", "pthread"] diff --git a/recipes/enkits/all/patches/cmake-install-lib-location.patch b/recipes/enkits/all/patches/cmake-install-lib-location.patch deleted file mode 100644 index 0a43979813c180..00000000000000 --- a/recipes/enkits/all/patches/cmake-install-lib-location.patch +++ /dev/null @@ -1,5 +0,0 @@ ---- CMakeLists.txt -+++ CMakeLists.txt -@@ -63,1 +63,1 @@ -- install(TARGETS enkiTS DESTINATION "${CMAKE_INSTALL_PREFIX}/lib/enkiTS") -+ install(TARGETS enkiTS ARCHIVE LIBRARY RUNTIME) diff --git a/recipes/enkits/all/test_package/CMakeLists.txt b/recipes/enkits/all/test_package/CMakeLists.txt index 33ae887aa6aea3..2c29974d552845 100644 --- a/recipes/enkits/all/test_package/CMakeLists.txt +++ b/recipes/enkits/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(enkits REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE enkits::enkits) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/enkits/all/test_package/conanfile.py b/recipes/enkits/all/test_package/conanfile.py index 32e9e0cb58ab64..ef5d7042163ecc 100644 --- a/recipes/enkits/all/test_package/conanfile.py +++ b/recipes/enkits/all/test_package/conanfile.py @@ -1,9 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/enkits/all/test_v1_package/CMakeLists.txt b/recipes/enkits/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/enkits/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/enkits/all/test_v1_package/conanfile.py b/recipes/enkits/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..910ae60d104386 --- /dev/null +++ b/recipes/enkits/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +import os +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From e1aa944277a1546bf918ff4eb2e2e364ac539b38 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 2 Sep 2023 22:48:42 +0300 Subject: [PATCH 0498/1140] (#18688) qdbm: migrate to Conan v2 * qdbm: migrate to Conan v2 * qdbm: move DLLs from lib to bin * qdbm: restore VirtualRunEnv in test_package --- recipes/qdbm/all/CMakeLists.txt | 15 +--- recipes/qdbm/all/conandata.yml | 2 +- recipes/qdbm/all/conanfile.py | 73 ++++++++++--------- recipes/qdbm/all/test_package/CMakeLists.txt | 5 +- recipes/qdbm/all/test_package/conanfile.py | 22 ++++-- recipes/qdbm/all/test_package/test_package.c | 10 +-- .../qdbm/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/qdbm/all/test_v1_package/conanfile.py | 18 +++++ 8 files changed, 88 insertions(+), 65 deletions(-) create mode 100644 recipes/qdbm/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/qdbm/all/test_v1_package/conanfile.py diff --git a/recipes/qdbm/all/CMakeLists.txt b/recipes/qdbm/all/CMakeLists.txt index 39427c2f3ccc36..1f080a697bce55 100644 --- a/recipes/qdbm/all/CMakeLists.txt +++ b/recipes/qdbm/all/CMakeLists.txt @@ -1,11 +1,7 @@ -cmake_minimum_required(VERSION 3.1) - +cmake_minimum_required(VERSION 3.12) project(qdbm_wrapper VERSION "${CONAN_qdbm_VERSION}" LANGUAGES C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS KEEP_RPATHS) - -set(QDBM_SRC_DIR ${PROJECT_SOURCE_DIR}/source_subfolder) +set(QDBM_SRC_DIR ${CMAKE_CURRENT_LIST_DIR}/src) # ---- Dependencies ---- @@ -65,12 +61,7 @@ set_target_properties( include(GNUInstallDirs) -install( - TARGETS qdbm - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" - LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" - ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" -) +install(TARGETS qdbm) install( FILES diff --git a/recipes/qdbm/all/conandata.yml b/recipes/qdbm/all/conandata.yml index c04a6ca2954e60..bd41a3e5c73fa9 100644 --- a/recipes/qdbm/all/conandata.yml +++ b/recipes/qdbm/all/conandata.yml @@ -1,4 +1,4 @@ sources: "1.8.78": sha256: "b466fe730d751e4bfc5900d1f37b0fb955f2826ac456e70012785e012cdcb73e" - url: http://fallabs.com/qdbm/qdbm-1.8.78.tar.gz + url: "https://dbmx.net/qdbm/qdbm-1.8.78.tar.gz" diff --git a/recipes/qdbm/all/conanfile.py b/recipes/qdbm/all/conanfile.py index 476d0ec62783b6..4341f35ed3bb7d 100644 --- a/recipes/qdbm/all/conanfile.py +++ b/recipes/qdbm/all/conanfile.py @@ -1,17 +1,22 @@ -from conans import ConanFile, CMake, tools -import functools +import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rename + +required_conan_version = ">=1.53.0" class QDBMConan(ConanFile): name = "qdbm" description = "QDBM is a library of routines for managing a database." - url = "https://github.com/conan-io/conan-center-index" - homepage = "http://fallabs.com/qdbm/" - topics = ("qdbm", "database", "db") license = "LGPL-2.1-or-later" - settings = ("os", "arch", "compiler", "build_type") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://dbmx.net/qdbm/" + topics = ("database", "db") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -27,53 +32,53 @@ class QDBMConan(ConanFile): "with_zlib": True, } - generators = "cmake", "cmake_find_package" - exports_sources = "CMakeLists.txt" - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - del self.options.with_pthread + self.options.rm_safe("with_pthread") def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_iconv: - self.requires("libiconv/1.16") + self.requires("libiconv/1.17") if self.options.with_zlib: - self.requires("zlib/1.2.12") + self.requires("zlib/1.2.13") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["CONAN_qdbm_VERSION"] = self.version - cmake.definitions["MYICONV"] = self.options.with_iconv - cmake.definitions["MYZLIB"] = self.options.with_zlib - cmake.definitions["MYPTHREAD"] = self.options\ - .get_safe("with_pthread", False) - cmake.configure() - return cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CONAN_qdbm_VERSION"] = self.version + tc.variables["MYICONV"] = self.options.with_iconv + tc.variables["MYZLIB"] = self.options.with_zlib + tc.variables["MYPTHREAD"] = self.options.get_safe("with_pthread", False) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.libs = ["qdbm"] diff --git a/recipes/qdbm/all/test_package/CMakeLists.txt b/recipes/qdbm/all/test_package/CMakeLists.txt index ea1c210104fb13..5c076c42369f78 100644 --- a/recipes/qdbm/all/test_package/CMakeLists.txt +++ b/recipes/qdbm/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS KEEP_RPATHS) - find_package(qdbm REQUIRED CONFIG) add_executable(test_package test_package.c) diff --git a/recipes/qdbm/all/test_package/conanfile.py b/recipes/qdbm/all/test_package/conanfile.py index ec80e0c5cc1345..ef5d7042163ecc 100644 --- a/recipes/qdbm/all/test_package/conanfile.py +++ b/recipes/qdbm/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools - class TestPackageConan(ConanFile): - settings = ("os", "compiler", "build_type", "arch") - generators = ("cmake", "cmake_find_package_multi") + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/qdbm/all/test_package/test_package.c b/recipes/qdbm/all/test_package/test_package.c index 68bad9e85cf152..3d79beba622577 100644 --- a/recipes/qdbm/all/test_package/test_package.c +++ b/recipes/qdbm/all/test_package/test_package.c @@ -1,12 +1,8 @@ #include #include -int main(int argc, char const* argv[]) +int main() { - (void)argc; - (void)argv; - - cbfree(NULL); - - return 0; + cbfree(NULL); + return 0; } diff --git a/recipes/qdbm/all/test_v1_package/CMakeLists.txt b/recipes/qdbm/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/qdbm/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/qdbm/all/test_v1_package/conanfile.py b/recipes/qdbm/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..ec80e0c5cc1345 --- /dev/null +++ b/recipes/qdbm/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = ("os", "compiler", "build_type", "arch") + generators = ("cmake", "cmake_find_package_multi") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 4a14a01b3dcf5ab0877370c567c5801eece7580d Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Sat, 2 Sep 2023 22:30:04 +0200 Subject: [PATCH 0499/1140] (#18906) lzip/*: Updated recipe for conan 2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * lzip: Updated recipe for conan 2.0 * Minor edits --------- Co-authored-by: Rubén Rincón Blanco --- recipes/lzip/all/conandata.yml | 27 +++-- recipes/lzip/all/conanfile.py | 109 ++++++------------ .../all/patches/1.21-0001-any-compiler.patch | 81 +++++++++---- .../all/patches/1.22-0001-any-compiler.patch | 88 +++++++++++--- .../all/patches/1.23-0001-any-compiler.patch | 78 +++++++++++++ recipes/lzip/all/test_package/conanfile.py | 68 +++++++---- recipes/lzip/config.yml | 2 + 7 files changed, 310 insertions(+), 143 deletions(-) create mode 100644 recipes/lzip/all/patches/1.23-0001-any-compiler.patch diff --git a/recipes/lzip/all/conandata.yml b/recipes/lzip/all/conandata.yml index 2b81d53f9b8e13..f3b143bd6541bd 100644 --- a/recipes/lzip/all/conandata.yml +++ b/recipes/lzip/all/conandata.yml @@ -1,20 +1,23 @@ sources: + "1.23": + url: + - "http://download.savannah.gnu.org/releases/lzip/lzip-1.23.tar.gz" + - "https://download-mirror.savannah.gnu.org/releases/lzip/lzip-1.23.tar.gz" + sha256: "4792c047ddf15ef29d55ba8e68a1a21e0cb7692d87ecdf7204419864582f280d" "1.22": - url: [ - "http://download.savannah.gnu.org/releases/lzip/lzip-1.22.tar.gz", - "https://download-mirror.savannah.gnu.org/releases/lzip/lzip-1.22.tar.gz", - ] + url: + - "http://download.savannah.gnu.org/releases/lzip/lzip-1.22.tar.gz" + - "https://download-mirror.savannah.gnu.org/releases/lzip/lzip-1.22.tar.gz" sha256: "c3342d42e67139c165b8b128d033b5c96893a13ac5f25933190315214e87a948" "1.21": - url: [ - "http://download.savannah.gnu.org/releases/lzip/lzip-1.21.tar.gz", - "https://download-mirror.savannah.gnu.org/releases/lzip/lzip-1.21.tar.gz", - ] + url: + - "http://download.savannah.gnu.org/releases/lzip/lzip-1.21.tar.gz" + - "https://download-mirror.savannah.gnu.org/releases/lzip/lzip-1.21.tar.gz" sha256: "e48b5039d3164d670791f9c5dbaa832bf2df080cb1fbb4f33aa7b3300b670d8b" patches: + "1.23": + - patch_file: "patches/1.23-0001-any-compiler.patch" "1.22": - - base_path: "source_subfolder" - patch_file: "patches/1.22-0001-any-compiler.patch" + - patch_file: "patches/1.22-0001-any-compiler.patch" "1.21": - - base_path: "source_subfolder" - patch_file: "patches/1.21-0001-any-compiler.patch" + - patch_file: "patches/1.21-0001-any-compiler.patch" diff --git a/recipes/lzip/all/conanfile.py b/recipes/lzip/all/conanfile.py index 96c8fbac3cb58f..3a29086521b1e0 100644 --- a/recipes/lzip/all/conanfile.py +++ b/recipes/lzip/all/conanfile.py @@ -1,102 +1,59 @@ -from conans import AutoToolsBuildEnvironment, CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration -import contextlib +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.files import copy, get, replace_in_file, rmdir, patch, apply_conandata_patches, export_conandata_patches +from conan.tools.layout import basic_layout import os -import textwrap -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" class LzipConan(ConanFile): name = "lzip" description = "Lzip is a lossless data compressor with a user interface similar to the one of gzip or bzip2" - topics = ("lzip", "compressor", "lzma") license = "GPL-v2-or-later" - homepage = "https://www.nongnu.org/lzip/" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.nongnu.org/lzip/" + topics = ("compressor", "lzma") + package_type = "application" settings = "os", "arch", "compiler", "build_type" - exports_sources = "patches/**" - - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _settings_build(self): - return getattr(self, "settings_build", self.settings) + def export_sources(self): + export_conandata_patches(self) - def build_requirements(self): - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): - self.build_requires("msys2/cci.latest") + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.compiler == "Visual Studio": - raise ConanInvalidConfiguration("Visual Studio is not supported") + if self.settings.os == "Windows" and self.settings.compiler != "gcc": + raise ConanInvalidConfiguration("Only gcc supported for windows builds") def package_id(self): del self.info.settings.compiler - - def _detect_compilers(self): - tools.rmdir("detectdir") - tools.mkdir("detectdir") - with tools.chdir("detectdir"): - tools.save("CMakeLists.txt", textwrap.dedent("""\ - cmake_minimum_required(VERSION 2.8) - project(test C CXX) - message(STATUS "CC=${CMAKE_C_COMPILER}") - message(STATUS "CXX=${CMAKE_CXX_COMPILER}") - file(WRITE cc.txt "${CMAKE_C_COMPILER}") - file(WRITE cxx.txt "${CMAKE_CXX_COMPILER}") - """)) - CMake(self).configure(source_folder="detectdir", build_folder="detectdir") - cc = tools.load("cc.txt").strip() - cxx = tools.load("cxx.txt").strip() - return cc, cxx + del self.info.settings.build_type def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - @contextlib.contextmanager - def _build_context(self): - env = {} - cc, cxx = self._detect_compilers() - if not tools.get_env("CC"): - env["CC"] = cc - if not tools.get_env("CXX"): - env["CXX"] = cxx - with tools.environment_append(env): - yield + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) - conf_args = [ - ] - self._autotools.configure(args=conf_args, configure_dir=self._source_subfolder) - return self._autotools + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - with self._build_context(): - autotools = self._configure_autotools() - autotools.make() + apply_conandata_patches(self) - def package(self): - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - with self._build_context(): - autotools = self._configure_autotools() - with tools.environment_append({"CONAN_CPU_COUNT": "1"}): - autotools.install() + autotools = Autotools(self) + autotools.configure() + autotools.make() - tools.rmdir(os.path.join(self.package_folder, "share")) + def package(self): + copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + autotools = Autotools(self) + autotools.install(target="install-bin") def package_info(self): - bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_path)) - self.env_info.PATH.append(bin_path) + self.cpp_info.includedirs = [] + self.cpp_info.libdirs = [] + + bindir = os.path.join(self.package_folder, "bin") + self.runenv_info.prepend_path("PATH", bindir) diff --git a/recipes/lzip/all/patches/1.21-0001-any-compiler.patch b/recipes/lzip/all/patches/1.21-0001-any-compiler.patch index 68dcb6f524644e..594395a65c8c36 100644 --- a/recipes/lzip/all/patches/1.21-0001-any-compiler.patch +++ b/recipes/lzip/all/patches/1.21-0001-any-compiler.patch @@ -1,25 +1,66 @@ ---- configure -+++ configure -@@ -21,7 +21,7 @@ +--- configure 2018-12-31 23:47:09.000000000 +0100 ++++ configure 2023-08-20 17:40:14.170994800 +0200 +@@ -9,6 +9,7 @@ + pkgversion=1.21 + progname=lzip + srctrigger=doc/${pkgname}.texi ++extension= + + # clear some things potentially inherited from environment. + LC_ALL=C +@@ -20,7 +21,7 @@ + datarootdir='$(prefix)/share' infodir='$(datarootdir)/info' mandir='$(datarootdir)/man' -CXX=g++ --CPPFLAGS= --CXXFLAGS='-Wall -W -O2' --LDFLAGS= -+#CXX=g++ -+#CPPFLAGS= -+#CXXFLAGS='-Wall -W -O2' -+#LDFLAGS= ++CXX="${CXX:-g++}" + CPPFLAGS= + CXXFLAGS='-Wall -W -O2' + LDFLAGS= +@@ -118,6 +119,19 @@ + fi + done + ++rm -f dummy* ++cat << EOT > dummy.c ++int main(int argc, char ** argv) { ++ return 0; ++} ++EOT ++ ++${CXX} -o dummy dummy.c ++ ++if [ -f dummy.exe ] ; then ++ extension=".exe" ++fi ++ + # Find the source files, if location was not specified. + srcdirtext= + if [ -z "${srcdir}" ] ; then +@@ -158,6 +172,7 @@ + echo "creating Makefile" + echo "VPATH = ${srcdir}" + echo "prefix = ${prefix}" ++echo "executable extension = ${extension}" + echo "exec_prefix = ${exec_prefix}" + echo "bindir = ${bindir}" + echo "datarootdir = ${datarootdir}" +@@ -179,6 +194,7 @@ + pkgname = ${pkgname} + pkgversion = ${pkgversion} + progname = ${progname} ++extension = ${extension} + VPATH = ${srcdir} + prefix = ${prefix} + exec_prefix = ${exec_prefix} +--- Makefile.in 2018-03-21 13:21:16.000000000 +0100 ++++ Makefile.in 2023-08-20 17:32:44.011055100 +0200 +@@ -64,7 +64,7 @@ -@@ -28,8 +28,8 @@ - # checking whether we are using GNU C++. - /bin/sh -c "${CXX} --version" > /dev/null 2>&1 || - { -- CXX=c++ -- CXXFLAGS=-O2 -+ echo "hello" # CXX=c++ -+ echo "hello" # CXXFLAGS=-O2 - } + install-bin : all + if [ ! -d "$(DESTDIR)$(bindir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(bindir)" ; fi +- $(INSTALL_PROGRAM) ./$(progname) "$(DESTDIR)$(bindir)/$(progname)" ++ $(INSTALL_PROGRAM) ./$(progname)$(extension) "$(DESTDIR)$(bindir)/$(progname)$(extension)" - # Loop over all args + install-bin-strip : all + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install-bin diff --git a/recipes/lzip/all/patches/1.22-0001-any-compiler.patch b/recipes/lzip/all/patches/1.22-0001-any-compiler.patch index 50311f5627b8cb..9388ec1d5dc3da 100644 --- a/recipes/lzip/all/patches/1.22-0001-any-compiler.patch +++ b/recipes/lzip/all/patches/1.22-0001-any-compiler.patch @@ -1,18 +1,78 @@ ---- configure -+++ configure -@@ -24,7 +24,7 @@ +--- configure 2021-01-01 14:06:33.000000000 +0100 ++++ configure 2023-08-20 17:48:10.569541300 +0200 +@@ -9,6 +9,7 @@ + pkgversion=1.22 + progname=lzip + srctrigger=doc/${pkgname}.texi ++extension= + + # clear some things potentially inherited from environment. + LC_ALL=C +@@ -23,7 +24,7 @@ + build=no check=no installdir= -CXX=g++ --CPPFLAGS= --CXXFLAGS='-Wall -W -O2' --LDFLAGS= -+#CXX=g++ -+#CPPFLAGS= -+#CXXFLAGS='-Wall -W -O2' -+#LDFLAGS= ++CXX="${CXX:-g++}" + CPPFLAGS= + CXXFLAGS='-Wall -W -O2' + LDFLAGS= +@@ -125,6 +126,19 @@ + fi + done + ++rm -f dummy* ++cat << EOT > dummy.c ++int main(int argc, char ** argv) { ++ return 0; ++} ++EOT ++ ++${CXX} -o dummy dummy.c ++ ++if [ -f dummy.exe ] ; then ++ extension=".exe" ++fi ++ + # Find the source files, if location was not specified. + srcdirtext= + if [ -z "${srcdir}" ] ; then +@@ -161,9 +175,9 @@ + "${srcdir}/testsuite/check.sh" "${srcdir}/testsuite" ${pkgversion} || exit 1 + fi + if [ -n "${installdir}" ] ; then +- echo "installing ${progname} in ${installdir}" ++ echo "installing ${progname}${extension} in ${installdir}" + [ -d "${installdir}" ] || mkdir -p "${installdir}" || exit 1 +- cp -fp ${progname} "${installdir}/${progname}" || exit 1 ++ cp -fp "${progname}${extension}" "${installdir}/${progname}${extension}" || exit 1 + fi + exit 0 + fi +@@ -188,6 +202,7 @@ + echo "creating Makefile" + echo "VPATH = ${srcdir}" + echo "prefix = ${prefix}" ++echo "executable extension = ${extension}" + echo "exec_prefix = ${exec_prefix}" + echo "bindir = ${bindir}" + echo "datarootdir = ${datarootdir}" +@@ -209,6 +224,7 @@ + pkgname = ${pkgname} + pkgversion = ${pkgversion} + progname = ${progname} ++extension = ${extension} + VPATH = ${srcdir} + prefix = ${prefix} + exec_prefix = ${exec_prefix} +--- Makefile.in 2020-05-02 00:06:48.000000000 +0200 ++++ Makefile.in 2023-08-20 17:46:52.265608300 +0200 +@@ -64,7 +64,7 @@ + + install-bin : all + if [ ! -d "$(DESTDIR)$(bindir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(bindir)" ; fi +- $(INSTALL_PROGRAM) ./$(progname) "$(DESTDIR)$(bindir)/$(progname)" ++ $(INSTALL_PROGRAM) ./$(progname)$(extension) "$(DESTDIR)$(bindir)/$(progname)$(extension)" -@@ -31,2 +31,2 @@ - # checking whether we are using GNU C++. --/bin/sh -c "${CXX} --version" > /dev/null 2>&1 || { CXX=c++ ; CXXFLAGS=-O2 ; } -+# /bin/sh -c "${CXX} --version" > /dev/null 2>&1 || { CXX=c++ ; CXXFLAGS=-O2 ; } + install-bin-strip : all + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install-bin diff --git a/recipes/lzip/all/patches/1.23-0001-any-compiler.patch b/recipes/lzip/all/patches/1.23-0001-any-compiler.patch new file mode 100644 index 00000000000000..ad4c3f5cc843d1 --- /dev/null +++ b/recipes/lzip/all/patches/1.23-0001-any-compiler.patch @@ -0,0 +1,78 @@ +--- configure 2022-01-22 01:11:01.000000000 +0100 ++++ configure 2023-08-20 17:51:18.537172800 +0200 +@@ -9,6 +9,7 @@ + pkgversion=1.23 + progname=lzip + srctrigger=doc/${pkgname}.texi ++extension= + + # clear some things potentially inherited from environment. + LC_ALL=C +@@ -23,7 +24,7 @@ + build=no + check=no + installdir= +-CXX=g++ ++CXX="${CXX:-g++}" + CPPFLAGS= + CXXFLAGS='-Wall -W -O2' + LDFLAGS= +@@ -125,6 +126,19 @@ + fi + done + ++rm -f dummy* ++cat << EOT > dummy.c ++int main(int argc, char ** argv) { ++ return 0; ++} ++EOT ++ ++${CXX} -o dummy dummy.c ++ ++if [ -f dummy.exe ] ; then ++ extension=".exe" ++fi ++ + # Find the source files, if location was not specified. + srcdirtext= + if [ -z "${srcdir}" ] ; then +@@ -161,9 +175,9 @@ + "${srcdir}/testsuite/check.sh" "${srcdir}/testsuite" ${pkgversion} || exit 1 + fi + if [ -n "${installdir}" ] ; then +- echo "installing ${progname} in ${installdir}" ++ echo "installing ${progname}${extension} in ${installdir}" + [ -d "${installdir}" ] || mkdir -p "${installdir}" || exit 1 +- cp -fp ${progname} "${installdir}/${progname}" || exit 1 ++ cp -fp "${progname}${extension}" "${installdir}/${progname}${extension}" || exit 1 + fi + exit 0 + fi +@@ -188,6 +202,7 @@ + echo "creating Makefile" + echo "VPATH = ${srcdir}" + echo "prefix = ${prefix}" ++echo "executable extension = ${extension}" + echo "exec_prefix = ${exec_prefix}" + echo "bindir = ${bindir}" + echo "datarootdir = ${datarootdir}" +@@ -209,6 +224,7 @@ + pkgname = ${pkgname} + pkgversion = ${pkgversion} + progname = ${progname} ++extension = ${extension} + VPATH = ${srcdir} + prefix = ${prefix} + exec_prefix = ${exec_prefix} +--- Makefile.in 2021-10-07 01:01:07.000000000 +0200 ++++ Makefile.in 2023-08-20 17:18:35.382705100 +0200 +@@ -64,7 +64,7 @@ + + install-bin : all + if [ ! -d "$(DESTDIR)$(bindir)" ] ; then $(INSTALL_DIR) "$(DESTDIR)$(bindir)" ; fi +- $(INSTALL_PROGRAM) ./$(progname) "$(DESTDIR)$(bindir)/$(progname)" ++ $(INSTALL_PROGRAM) ./$(progname)$(extension) "$(DESTDIR)$(bindir)/$(progname)$(extension)" + + install-bin-strip : all + $(MAKE) INSTALL_PROGRAM='$(INSTALL_PROGRAM) -s' install-bin diff --git a/recipes/lzip/all/test_package/conanfile.py b/recipes/lzip/all/test_package/conanfile.py index 84ae9d8826de5c..16e19ad7002bc9 100644 --- a/recipes/lzip/all/test_package/conanfile.py +++ b/recipes/lzip/all/test_package/conanfile.py @@ -1,27 +1,53 @@ -from conans import ConanFile, tools -from conans.errors import ConanException +from conan import ConanFile +from conan.errors import ConanException +from conan.tools.build import can_run +from conan.tools.files import rm, save, check_sha256 import os -import shutil - +from io import StringIO class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" + generators = "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) def test(self): - if not tools.cross_building(self, skip_x64_x86=True): - lzip = os.path.join(self.deps_cpp_info["lzip"].bin_paths[0], "lzip") - self.run("{} --version".format(lzip)) - - shutil.copy(os.path.join(self.source_folder, "conanfile.py"), - "conanfile.py") - - sha256_original = tools.sha256sum("conanfile.py") - self.run("{} conanfile.py".format(lzip), run_environment=True) - if not os.path.exists("conanfile.py.lz"): - raise ConanException("conanfile.py.lz does not exist") - if os.path.exists("conanfile.py"): - raise ConanException("copied conanfile.py should not exist anymore") - - self.run("{} -d conanfile.py.lz".format(lzip), run_environment=True) - if tools.sha256sum("conanfile.py") != sha256_original: - raise ConanException("sha256 from extracted conanfile.py does not match original") + if not can_run(self): + return + + cmd_output = StringIO() + self.run(f"lzip --version", cmd_output, env="conanrun") + + #Create input test file + input_file_sha256 = "6a7ef9d581b577bbe8415d69ccc2549287eb99b5d856a213df742f8b89986a6a" + input_file = "input.txt" + if os.path.exists(input_file): + rm(self, input_file, ".") + + save(self, input_file, "Klaus is king!") + + #Ensure output test file does not exist + output_file = input_file + ".lz" + if os.path.exists(output_file): + rm(self, output_file, ".") + + #Zip the input file + self.run(f"lzip {input_file}", env="conanrun") + if not os.path.exists(f"{output_file}"): + raise ConanException(f"{output_file} does not exist") + + if os.path.exists(f"{input_file}"): + raise ConanException(f"{input_file} does exist") + + #Unzip the input file + self.run(f"lzip -d {output_file}", env="conanrun") + if os.path.exists(f"{output_file}"): + raise ConanException(f"{output_file} does not exist") + + if not os.path.exists(f"{input_file}"): + raise ConanException(f"{input_file} does exist") + + #Compare checksum of unzipped file with expected value + check_sha256(self, input_file, input_file_sha256) diff --git a/recipes/lzip/config.yml b/recipes/lzip/config.yml index e027a6bc18156f..fe52638d1ec863 100644 --- a/recipes/lzip/config.yml +++ b/recipes/lzip/config.yml @@ -1,4 +1,6 @@ versions: + "1.23": + folder: "all" "1.22": folder: "all" "1.21": From e3d536544449d8edb7babc92ebf57692cbfc79bd Mon Sep 17 00:00:00 2001 From: qwqbot Date: Sun, 3 Sep 2023 04:50:28 +0800 Subject: [PATCH 0500/1140] (#19022) intx: fix minimum compiler required to clang13 & gcc11 --- recipes/intx/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/intx/all/conanfile.py b/recipes/intx/all/conanfile.py index 7d3e3dcf60652b..fcbc0174dcfbbb 100644 --- a/recipes/intx/all/conanfile.py +++ b/recipes/intx/all/conanfile.py @@ -30,8 +30,8 @@ def _compilers_minimum_version(self): return { "Visual Studio": "16", "msvc": "192", - "gcc": "12", - "clang": "15", + "gcc": "11", + "clang": "13", "apple-clang": "14.1", } From d54e8f10241a0ea73f993bf1227a45be262c601b Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 06:14:27 +0900 Subject: [PATCH 0501/1140] (#19515) octo-logger-cpp: support conan v2, update fmt/10.1.1, add package_type --- recipes/octo-logger-cpp/all/conandata.yml | 12 ++--- recipes/octo-logger-cpp/all/conanfile.py | 52 ++++++++++--------- .../all/test_package/CMakeLists.txt | 8 +-- .../all/test_package/conanfile.py | 18 +++---- recipes/octo-logger-cpp/config.yml | 4 +- 5 files changed, 49 insertions(+), 45 deletions(-) diff --git a/recipes/octo-logger-cpp/all/conandata.yml b/recipes/octo-logger-cpp/all/conandata.yml index 035fe6943e2027..29be2c16d0289b 100644 --- a/recipes/octo-logger-cpp/all/conandata.yml +++ b/recipes/octo-logger-cpp/all/conandata.yml @@ -1,10 +1,10 @@ sources: - "1.1.0": - sha256: 69057ab2f0ba0754dc6dce1f27c6f1fd9ad1e97c828779a801273bb3e9123e4e - url: https://github.com/ofiriluz/octo-logger-cpp/archive/refs/tags/v1.1.0.tar.gz - "1.2.0": - sha256: 54381d6dbc80c6be6d8b9e087a4b55fae6ff5d07c3c2399bc7e1c94252260bf2 - url: https://github.com/ofiriluz/octo-logger-cpp/archive/refs/tags/v1.2.0.tar.gz "1.4.0": url: "https://github.com/ofiriluz/octo-logger-cpp/archive/v1.4.0.tar.gz" sha256: "6aacbab0e57917a935e0f9741e52a57ecac21785ba49aaafec5775030208a153" + "1.2.0": + url: "https://github.com/ofiriluz/octo-logger-cpp/archive/refs/tags/v1.2.0.tar.gz" + sha256: "54381d6dbc80c6be6d8b9e087a4b55fae6ff5d07c3c2399bc7e1c94252260bf2" + "1.1.0": + url: "https://github.com/ofiriluz/octo-logger-cpp/archive/refs/tags/v1.1.0.tar.gz" + sha256: "69057ab2f0ba0754dc6dce1f27c6f1fd9ad1e97c828779a801273bb3e9123e4e" diff --git a/recipes/octo-logger-cpp/all/conanfile.py b/recipes/octo-logger-cpp/all/conanfile.py index cdb8df5c161d22..042c94eec1f926 100644 --- a/recipes/octo-logger-cpp/all/conanfile.py +++ b/recipes/octo-logger-cpp/all/conanfile.py @@ -4,6 +4,7 @@ from conan.tools.build import check_min_cppstd from conan.errors import ConanInvalidConfiguration from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc import os required_conan_version = ">=1.50.0" @@ -11,19 +12,24 @@ class OctoLoggerCPPConan(ConanFile): name = "octo-logger-cpp" + description = "CPP Stream based logging library" license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/ofiriluz/octo-logger-cpp" - description = "Octo logger library" - topics = ("logging", "cpp") - settings = "os", "compiler", "build_type", "arch" + topics = ("logging", "stream", "syslog", "cloudwatch") + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" options = { - "with_aws": [True, False] + "with_aws": [True, False], } default_options = { - "with_aws": False + "with_aws": False, } + @property + def _min_cppstd(self): + return 17 + @property def _compilers_minimum_version(self): return { @@ -56,37 +62,32 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.info.settings.compiler.cppstd: - check_min_cppstd(self, "17") - + if self.info.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration( - f"{self.name} requires C++17, which your compiler does not support." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - else: - self.output.warn(f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17.") if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": - raise ConanInvalidConfiguration(f"{self.name} does not support clang with libc++. Use libstdc++ instead.") - if self.settings.compiler == "Visual Studio" and self.settings.compiler.runtime in ["MTd", "MT"]: - raise ConanInvalidConfiguration(f"{self.name} does not support MSVC MT/MTd configurations, only MD/MDd is supported") + raise ConanInvalidConfiguration(f"{self.ref} does not support clang with libc++. Use libstdc++ instead.") + if is_msvc(self) and self.settings.compiler.runtime in ["MTd", "MT"]: + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC MT/MTd configurations, only MD/MDd is supported") if self.options.get_safe("with_aws"): if not self.dependencies["aws-sdk-cpp"].options.logs: - raise ConanInvalidConfiguration(f"{self.name} requires the option aws-sdk-cpp:logs=True") - + raise ConanInvalidConfiguration(f"{self.ref} requires the option aws-sdk-cpp:logs=True") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def requirements(self): - self.requires("fmt/9.0.0") + self.requires("fmt/10.1.1", transitive_headers=True) if self.options.get_safe("with_aws"): self.requires("nlohmann_json/3.11.2") self.requires("aws-sdk-cpp/1.9.234") def build_requirements(self): - self.build_requires("cmake/3.24.0") + self.tool_requires("cmake/[>=3.16 <4]") def build(self): cmake = CMake(self) @@ -99,16 +100,19 @@ def package(self): cmake.install() def package_info(self): + self.cpp_info.libs = ["octo-logger-cpp"] + self.cpp_info.set_property("cmake_file_name", "octo-logger-cpp") self.cpp_info.set_property("cmake_target_name", "octo::octo-logger-cpp") self.cpp_info.set_property("pkg_config_name", "octo-logger-cpp") - self.cpp_info.libs = ["octo-logger-cpp"] - self.cpp_info.names["cmake_find_package"] = "octo-logger-cpp" - self.cpp_info.names["cmake_find_package_multi"] = "octo-logger-cpp" - self.cpp_info.names["pkg_config"] = "octo-logger-cpp" self.cpp_info.requires = ["fmt::fmt"] if self.options.get_safe("with_aws"): self.cpp_info.requires.extend([ "nlohmann_json::nlohmann_json", "aws-sdk-cpp::monitoring" ]) + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "octo-logger-cpp" + self.cpp_info.names["cmake_find_package_multi"] = "octo-logger-cpp" + self.cpp_info.names["pkg_config"] = "octo-logger-cpp" diff --git a/recipes/octo-logger-cpp/all/test_package/CMakeLists.txt b/recipes/octo-logger-cpp/all/test_package/CMakeLists.txt index 4cdb390261544d..f7d178a90b8eed 100644 --- a/recipes/octo-logger-cpp/all/test_package/CMakeLists.txt +++ b/recipes/octo-logger-cpp/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(octo-logger-cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} octo::octo-logger-cpp) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE octo::octo-logger-cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/octo-logger-cpp/all/test_package/conanfile.py b/recipes/octo-logger-cpp/all/test_package/conanfile.py index 696c343fa84f41..ef5d7042163ecc 100644 --- a/recipes/octo-logger-cpp/all/test_package/conanfile.py +++ b/recipes/octo-logger-cpp/all/test_package/conanfile.py @@ -1,17 +1,16 @@ -from conans import ConanFile -from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan import ConanFile from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -required_conan_version = ">=1.43.0" class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "CMakeDeps", "VirtualRunEnv" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" - def generate(self): - tc = CMakeToolchain(self) - tc.generate() + def requirements(self): + self.requires(self.tested_reference_str) def layout(self): cmake_layout(self) @@ -23,4 +22,5 @@ def build(self): def test(self): if can_run(self): - self.run(os.path.join(self.cpp.build.bindirs[0], "test_package"), env="conanrun") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/octo-logger-cpp/config.yml b/recipes/octo-logger-cpp/config.yml index 14adddf7ca35b4..1f90fb4ad7af40 100644 --- a/recipes/octo-logger-cpp/config.yml +++ b/recipes/octo-logger-cpp/config.yml @@ -1,7 +1,7 @@ versions: - "1.1.0": + "1.4.0": folder: "all" "1.2.0": folder: "all" - "1.4.0": + "1.1.0": folder: "all" From bdecf1312630e8e7f4376fffa6c151d29777af55 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Sat, 2 Sep 2023 23:50:53 +0200 Subject: [PATCH 0502/1140] (#19524) earcut: fix target name --- recipes/earcut/all/conanfile.py | 10 ++++++++++ recipes/earcut/all/test_package/CMakeLists.txt | 4 ++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/recipes/earcut/all/conanfile.py b/recipes/earcut/all/conanfile.py index 23791142acadb5..9ff1959d206ffe 100644 --- a/recipes/earcut/all/conanfile.py +++ b/recipes/earcut/all/conanfile.py @@ -68,5 +68,15 @@ def package(self): copy(self, "LICENSE", self.source_folder, os.path.join(self.package_folder, "licenses")) + def package_info(self): + self.cpp_info.set_property("cmake_file_name", "earcut_hpp") + self.cpp_info.set_property("cmake_target_name", "earcut_hpp::earcut_hpp") + + # TODO: to remove in conan v2 once cmake_find_package* generators removed + self.cpp_info.filenames["cmake_find_package"] = "earcut_hpp" + self.cpp_info.filenames["cmake_find_package_multi"] = "earcut_hpp" + self.cpp_info.names["cmake_find_package"] = "earcut_hpp" + self.cpp_info.names["cmake_find_package_multi"] = "earcut_hpp" + def package_id(self): self.info.clear() diff --git a/recipes/earcut/all/test_package/CMakeLists.txt b/recipes/earcut/all/test_package/CMakeLists.txt index 4a460cc9a3c999..a6d943d9266685 100644 --- a/recipes/earcut/all/test_package/CMakeLists.txt +++ b/recipes/earcut/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.1) project(test_package LANGUAGES CXX) -find_package(earcut REQUIRED CONFIG) +find_package(earcut_hpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} example.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE earcut::earcut) +target_link_libraries(${PROJECT_NAME} PRIVATE earcut_hpp::earcut_hpp) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) From 5c8c6f60ab2926e9efc776c7802bb2e61b892233 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Sun, 3 Sep 2023 00:30:26 +0200 Subject: [PATCH 0503/1140] (#19526) troldal-zippy: fix "package requires C++17 support. The current compiler Visual Studio 16 does not support it", add msvc compiler support, bump deps --- recipes/troldal-zippy/all/conanfile.py | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/recipes/troldal-zippy/all/conanfile.py b/recipes/troldal-zippy/all/conanfile.py index c1f661d53497de..999217a8ec5a52 100644 --- a/recipes/troldal-zippy/all/conanfile.py +++ b/recipes/troldal-zippy/all/conanfile.py @@ -4,6 +4,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get +from conan.tools.microsoft import check_min_vs, is_msvc from conan.tools.layout import basic_layout from conan.tools.scm import Version @@ -29,7 +30,6 @@ def _minimum_cpp_standard(self): @property def _minimum_compilers_version(self): return { - "Visual Studio": "17", "gcc": "7", "clang": "6", "apple-clang": "10", @@ -42,7 +42,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("miniz/2.2.0") + self.requires("miniz/3.0.2") def package_id(self): self.info.clear() @@ -50,15 +50,18 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._minimum_cpp_standard) - min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) - if not min_version: - self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") + if is_msvc(self): + check_min_vs(self, "192") else: - if Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration( - f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" - f" {self.settings.compiler} {self.settings.compiler.version} does not support it." - ) + min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) + if not min_version: + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") + else: + if Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" + f" {self.settings.compiler} {self.settings.compiler.version} does not support it." + ) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From b7593c5619972d3afe6bac396d2d9fc8c16bc66b Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 07:52:15 +0900 Subject: [PATCH 0504/1140] (#19540) brotli: add version 1.1.0, add patch description * brotli: add version 1.1.0, add patch desscription * remove CMAKE_MACOS_RPATH --- recipes/brotli/all/conandata.yml | 23 +++++++++++---- recipes/brotli/all/conanfile.py | 8 +++--- ...t-props.patch => 1.0.7-target-props.patch} | 0 ...t-props.patch => 1.0.9-target-props.patch} | 0 .../all/patches/1.1.0-target-props.patch | 28 +++++++++++++++++++ .../brotli/all/test_package/CMakeLists.txt | 2 +- recipes/brotli/config.yml | 2 ++ 7 files changed, 52 insertions(+), 11 deletions(-) rename recipes/brotli/all/patches/{0001-target-props.patch => 1.0.7-target-props.patch} (100%) rename recipes/brotli/all/patches/{0002-target-props.patch => 1.0.9-target-props.patch} (100%) create mode 100644 recipes/brotli/all/patches/1.1.0-target-props.patch diff --git a/recipes/brotli/all/conandata.yml b/recipes/brotli/all/conandata.yml index c664dae35678ec..35c9587456f430 100644 --- a/recipes/brotli/all/conandata.yml +++ b/recipes/brotli/all/conandata.yml @@ -1,12 +1,23 @@ sources: + "1.1.0": + url: "https://github.com/google/brotli/archive/v1.1.0.tar.gz" + sha256: "e720a6ca29428b803f4ad165371771f5398faba397edf6778837a18599ea13ff" "1.0.9": - url: https://github.com/google/brotli/archive/v1.0.9.tar.gz - sha256: f9e8d81d0405ba66d181529af42a3354f838c939095ff99930da6aa9cdf6fe46 + url: "https://github.com/google/brotli/archive/v1.0.9.tar.gz" + sha256: "f9e8d81d0405ba66d181529af42a3354f838c939095ff99930da6aa9cdf6fe46" "1.0.7": - url: https://github.com/google/brotli/archive/v1.0.7.tar.gz - sha256: 4c61bfb0faca87219ea587326c467b95acb25555b53d1a421ffa3c8a9296ee2c + url: "https://github.com/google/brotli/archive/v1.0.7.tar.gz" + sha256: "4c61bfb0faca87219ea587326c467b95acb25555b53d1a421ffa3c8a9296ee2c" patches: + "1.1.0": + - patch_file: "patches/1.1.0-target-props.patch" + patch_description: "add target properties, disable command build" + patch_type: "conan" "1.0.9": - - patch_file: "patches/0002-target-props.patch" + - patch_file: "patches/1.0.9-target-props.patch" + patch_description: "add target properties, disable command build, separate shared and static build" + patch_type: "conan" "1.0.7": - - patch_file: "patches/0001-target-props.patch" + - patch_file: "patches/1.0.7-target-props.patch" + patch_description: "add target properties, disable command build, separate shared and static build" + patch_type: "conan" diff --git a/recipes/brotli/all/conanfile.py b/recipes/brotli/all/conanfile.py index 5ba9ac6bd939f9..7e93d9903056df 100644 --- a/recipes/brotli/all/conanfile.py +++ b/recipes/brotli/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +from conan.tools.scm import Version import os required_conan_version = ">=1.53.0" @@ -9,11 +10,10 @@ class BrotliConan(ConanFile): name = "brotli" description = "Brotli compression format" - topics = ("brotli", "compression") + license = "MIT", url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/google/brotli" - license = "MIT", - + topics = ("brotli", "compression") package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -125,6 +125,6 @@ def package_info(self): def _get_decorated_lib(self, name): libname = name - if not self.options.shared: + if Version(self.version) < "1.1.0" and not self.options.shared: libname += "-static" return libname diff --git a/recipes/brotli/all/patches/0001-target-props.patch b/recipes/brotli/all/patches/1.0.7-target-props.patch similarity index 100% rename from recipes/brotli/all/patches/0001-target-props.patch rename to recipes/brotli/all/patches/1.0.7-target-props.patch diff --git a/recipes/brotli/all/patches/0002-target-props.patch b/recipes/brotli/all/patches/1.0.9-target-props.patch similarity index 100% rename from recipes/brotli/all/patches/0002-target-props.patch rename to recipes/brotli/all/patches/1.0.9-target-props.patch diff --git a/recipes/brotli/all/patches/1.1.0-target-props.patch b/recipes/brotli/all/patches/1.1.0-target-props.patch new file mode 100644 index 00000000000000..df1e483759f2e6 --- /dev/null +++ b/recipes/brotli/all/patches/1.1.0-target-props.patch @@ -0,0 +1,28 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 61378cd..4de317b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -112,7 +112,6 @@ elseif(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD") + add_definitions(-DOS_FREEBSD) + elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") + add_definitions(-DOS_MACOSX) +- set(CMAKE_MACOS_RPATH TRUE) + set(CMAKE_INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib") + endif() + +@@ -171,14 +170,10 @@ endif() + # Build the brotli executable + add_executable(brotli c/tools/brotli.c) + target_link_libraries(brotli ${BROTLI_LIBRARIES}) ++set_target_properties(brotli PROPERTIES EXCLUDE_FROM_ALL ON EXCLUDE_FROM_DEFAULT ON) + + # Installation + if(NOT BROTLI_BUNDLED_MODE) +- install( +- TARGETS brotli +- RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" +- ) +- + install( + TARGETS ${BROTLI_LIBRARIES_CORE} + ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" diff --git a/recipes/brotli/all/test_package/CMakeLists.txt b/recipes/brotli/all/test_package/CMakeLists.txt index 8339b11b6d1f4a..00f09fcd401222 100644 --- a/recipes/brotli/all/test_package/CMakeLists.txt +++ b/recipes/brotli/all/test_package/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.1) -project(test_package) +project(test_package LANGUAGES CXX) find_package(brotli REQUIRED CONFIG) diff --git a/recipes/brotli/config.yml b/recipes/brotli/config.yml index 39d54f0009ed08..f4b59633d9f839 100644 --- a/recipes/brotli/config.yml +++ b/recipes/brotli/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.0": + folder: all "1.0.9": folder: all "1.0.7": From d2c3d2b28ecc95cb5684437d259051dab8133329 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 08:32:14 +0900 Subject: [PATCH 0505/1140] (#19558) mcap: update zstd/1.5.5, add package_type --- recipes/mcap/all/conanfile.py | 3 ++- recipes/mcap/all/test_package/conanfile.py | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/recipes/mcap/all/conanfile.py b/recipes/mcap/all/conanfile.py index 0ea0db2622ab8f..1089c7a6c48f9b 100644 --- a/recipes/mcap/all/conanfile.py +++ b/recipes/mcap/all/conanfile.py @@ -19,6 +19,7 @@ class McapConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/foxglove/mcap" topics = ("serialization", "deserialization", "recording", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" @property @@ -48,7 +49,7 @@ def layout(self): def requirements(self): self.requires("lz4/1.9.4") - self.requires("zstd/1.5.4") + self.requires("zstd/1.5.5") if Version(self.version) < "0.1.1": self.requires("fmt/9.1.0") diff --git a/recipes/mcap/all/test_package/conanfile.py b/recipes/mcap/all/test_package/conanfile.py index 615cc1d54ffccc..8749556609d862 100644 --- a/recipes/mcap/all/test_package/conanfile.py +++ b/recipes/mcap/all/test_package/conanfile.py @@ -7,7 +7,8 @@ class TestPackageConan(ConanFile): settings = ("os", "arch", "compiler", "build_type") generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" - + test_type = "explicit" + def layout(self): cmake_layout(self) From b08dd4c49f5ea899071dbddc3792348c924b4a9d Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 09:12:32 +0900 Subject: [PATCH 0506/1140] (#19562) mppp: update dependencies --- recipes/mppp/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/mppp/all/conanfile.py b/recipes/mppp/all/conanfile.py index 7fed2f8affb271..42fab736847a00 100644 --- a/recipes/mppp/all/conanfile.py +++ b/recipes/mppp/all/conanfile.py @@ -61,15 +61,15 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("gmp/6.2.1", transitive_headers=True) + self.requires("gmp/6.3.0", transitive_headers=True) if self.options.with_mpfr: self.requires("mpfr/4.2.0") if self.options.with_mpc: self.requires("mpc/1.2.0") if self.options.with_boost: - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") if self.options.get_safe("with_fmt"): - self.requires("fmt/10.1.0", transitive_headers=True) + self.requires("fmt/10.1.1", transitive_headers=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): From a1c3440d91756aa54d2fde7586290def5b31ac28 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 09:50:19 +0900 Subject: [PATCH 0507/1140] (#19564) arsenalgear: update boost/1.8.30 --- recipes/arsenalgear/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/arsenalgear/all/conanfile.py b/recipes/arsenalgear/all/conanfile.py index 2eafb85d1f49a0..3c60d7e171cb39 100644 --- a/recipes/arsenalgear/all/conanfile.py +++ b/recipes/arsenalgear/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): def requirements(self): if Version(self.version) < "2.0.0": - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") if self.settings.os in ["Linux", "Macos"]: # exprtk is used in public header of arsenalgear # https://github.com/JustWhit3/arsenalgear-cpp/blob/v1.2.2/include/math.hpp From 58eef0a36742cb9a4b947922d6e1417e5e7cab87 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 16:10:43 +0900 Subject: [PATCH 0508/1140] (#19567) jinja2cpp: update dependencies --- recipes/jinja2cpp/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/jinja2cpp/all/conanfile.py b/recipes/jinja2cpp/all/conanfile.py index c40b675dc715af..8026c45b97a606 100644 --- a/recipes/jinja2cpp/all/conanfile.py +++ b/recipes/jinja2cpp/all/conanfile.py @@ -56,7 +56,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") self.requires("expected-lite/0.6.3", transitive_headers=True) self.requires("optional-lite/3.5.0", transitive_headers=True) self.requires("rapidjson/cci.20220822") @@ -66,7 +66,7 @@ def requirements(self): self.requires("fmt/6.2.1") # not compatible with fmt >= 7.0.0 else: self.requires("nlohmann_json/3.11.2") - self.requires("fmt/10.1.0") + self.requires("fmt/10.1.1") def validate(self): if self.settings.compiler.get_safe("cppstd"): From d5e031e94160466e6199738e2117e9c4465c03b4 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 3 Sep 2023 16:53:57 +0900 Subject: [PATCH 0509/1140] (#19569) websocketpp: update dependencies --- recipes/websocketpp/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/websocketpp/all/conanfile.py b/recipes/websocketpp/all/conanfile.py index 2e4962181cae1c..fc666b73d6c250 100644 --- a/recipes/websocketpp/all/conanfile.py +++ b/recipes/websocketpp/all/conanfile.py @@ -40,9 +40,9 @@ def requirements(self): self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) if self.options.asio == "standalone": - self.requires("asio/1.27.0", transitive_headers=True) + self.requires("asio/1.28.1", transitive_headers=True) elif self.options.asio == "boost": - self.requires("boost/1.81.0", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) def package_id(self): self.info.clear() From 9007c80031d40f6269cb021d60cc5457a416a23b Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 00:14:33 +0900 Subject: [PATCH 0510/1140] (#19572) cpprestsdk: update boost/1.83.0 --- recipes/cpprestsdk/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cpprestsdk/all/conanfile.py b/recipes/cpprestsdk/all/conanfile.py index 9f8dbc8d6fec8b..0383ff59b8cacf 100644 --- a/recipes/cpprestsdk/all/conanfile.py +++ b/recipes/cpprestsdk/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") self.requires("openssl/[>=1.1 <4]") if self.options.with_compression: self.requires("zlib/1.2.13") From c43245e4b3203b35febaf424010ecdb71711acc7 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 01:33:36 +0900 Subject: [PATCH 0511/1140] (#19575) fakeit: update dependencies --- recipes/fakeit/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/fakeit/all/conanfile.py b/recipes/fakeit/all/conanfile.py index 790c00d882ca36..3676955b84f0fe 100644 --- a/recipes/fakeit/all/conanfile.py +++ b/recipes/fakeit/all/conanfile.py @@ -34,11 +34,11 @@ def layout(self): def requirements(self): if self.options.integration == "boost": - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") elif self.options.integration == "catch": self.requires("catch2/3.4.0") elif self.options.integration == "gtest": - self.requires("gtest/1.13.0") + self.requires("gtest/1.14.0") elif self.options.integration == "qtest": self.requires("qt/6.3.0") elif self.options.integration == "standalone": From 993c0b5cbd66263ce736423acb97a8e5190276f7 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Mon, 4 Sep 2023 10:07:22 +0200 Subject: [PATCH 0512/1140] (#18219) libarchive: fix msvc build and bump deps * fix * fix msvc build patch * backport fix msvc build patch --- recipes/libarchive/all/conandata.yml | 5 +- recipes/libarchive/all/conanfile.py | 7 +- .../all/patches/0001-3.6.2-zlib-winapi.patch | 9 +- .../all/patches/0003-3.4.0-cmake.patch | 41 +++++ .../all/patches/0003-3.4.3-cmake.patch | 49 ++++++ .../all/patches/0003-3.5.1-cmake.patch | 142 ++++++++++++++++++ .../all/patches/0003-3.5.2-cmake.patch | 41 +++++ .../all/patches/0003-3.6.0-cmake.patch | 41 +++++ .../all/patches/0003-3.6.2-cmake.patch | 41 +++-- .../0005-3.6.2-try-compile-cmakedeps.patch | 20 ++- .../all/patches/0006-fix-msvc-build.patch | 48 ++++++ 11 files changed, 411 insertions(+), 33 deletions(-) create mode 100644 recipes/libarchive/all/patches/0003-3.5.1-cmake.patch create mode 100644 recipes/libarchive/all/patches/0006-fix-msvc-build.patch diff --git a/recipes/libarchive/all/conandata.yml b/recipes/libarchive/all/conandata.yml index 9a164839a427bb..3853b8ec0aa668 100644 --- a/recipes/libarchive/all/conandata.yml +++ b/recipes/libarchive/all/conandata.yml @@ -31,6 +31,9 @@ patches: - patch_file: "patches/0005-3.6.2-try-compile-cmakedeps.patch" patch_description: "Patch try_compile check to work with imported CMake targets from Conan packages" patch_type: "conan" + - patch_file: "patches/0006-fix-msvc-build.patch" + patch_description: "Fix MSVC build" + patch_type: "conan" "3.6.1": - patch_file: "patches/0001-3.6.0-zlib-winapi.patch" patch_description: "Remove broken ZLIB WINAPI check" @@ -62,7 +65,7 @@ patches: - patch_file: "patches/0001-3.4.3-zlib-winapi.patch" patch_description: "Remove broken ZLIB WINAPI check" patch_type: "portability" - - patch_file: "patches/0003-3.4.3-cmake.patch" + - patch_file: "patches/0003-3.5.1-cmake.patch" patch_description: "Make CMake cooperate with Conan" patch_type: "conan" "3.4.3": diff --git a/recipes/libarchive/all/conanfile.py b/recipes/libarchive/all/conanfile.py index 7b3f2cc70c9d01..c6970f8d631a8b 100644 --- a/recipes/libarchive/all/conanfile.py +++ b/recipes/libarchive/all/conanfile.py @@ -85,13 +85,13 @@ def requirements(self): if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.with_libxml2: - self.requires("libxml2/2.10.4") + self.requires("libxml2/2.11.4") if self.options.with_expat: self.requires("expat/2.5.0") if self.options.with_iconv: self.requires("libiconv/1.17") if self.options.with_pcreposix: - self.requires("pcre/8.45") + self.requires("pcre/10.42") if self.options.with_nettle: self.requires("nettle/3.8.1") if self.options.with_openssl: @@ -154,6 +154,9 @@ def generate(self): if Version(self.version) >= "3.4.2": tc.variables["ENABLE_MBEDTLS"] = self.options.with_mbedtls tc.variables["ENABLE_XATTR"] = self.options.with_xattr + # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012 + if is_msvc(self): + tc.cache_variables["CMAKE_TRY_COMPILE_CONFIGURATION"] = str(self.settings.build_type) tc.generate() def build(self): diff --git a/recipes/libarchive/all/patches/0001-3.6.2-zlib-winapi.patch b/recipes/libarchive/all/patches/0001-3.6.2-zlib-winapi.patch index 62dd3ef8198757..9e88323972df92 100644 --- a/recipes/libarchive/all/patches/0001-3.6.2-zlib-winapi.patch +++ b/recipes/libarchive/all/patches/0001-3.6.2-zlib-winapi.patch @@ -2,7 +2,7 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt index 713e3bc..2315da5 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -430,14 +430,7 @@ IF(ZLIB_FOUND) +@@ -430,14 +430,14 @@ IF(ZLIB_FOUND) INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR}) LIST(APPEND ADDITIONAL_LIBS ${ZLIB_LIBRARIES}) IF(WIN32 AND NOT CYGWIN) @@ -14,6 +14,13 @@ index 713e3bc..2315da5 100644 - RUNS - "#include \nint main() {uLong f = zlibCompileFlags(); return (f&(1U<<10))?0:-1; }" - ZLIB_WINAPI) ++ ++ ++ ++ ++ ++ ++ + set(ZLIB_WINAPI yes) IF(ZLIB_WINAPI) ADD_DEFINITIONS(-DZLIB_WINAPI) diff --git a/recipes/libarchive/all/patches/0003-3.4.0-cmake.patch b/recipes/libarchive/all/patches/0003-3.4.0-cmake.patch index 7b724f1fba1643..7b34085f1a3a25 100644 --- a/recipes/libarchive/all/patches/0003-3.4.0-cmake.patch +++ b/recipes/libarchive/all/patches/0003-3.4.0-cmake.patch @@ -56,6 +56,47 @@ index 4ffd0930..01e8592c 100644 FIND_PACKAGE(OpenSSL) IF(OPENSSL_FOUND) SET(HAVE_LIBCRYPTO 1) +@@ -1316,7 +1316,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1348,11 +1348,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1364,10 +1364,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt index ec775bb4..8ef2d620 100644 --- a/libarchive/CMakeLists.txt diff --git a/recipes/libarchive/all/patches/0003-3.4.3-cmake.patch b/recipes/libarchive/all/patches/0003-3.4.3-cmake.patch index 5c46b58290b772..45a9561474f8e2 100644 --- a/recipes/libarchive/all/patches/0003-3.4.3-cmake.patch +++ b/recipes/libarchive/all/patches/0003-3.4.3-cmake.patch @@ -56,6 +56,55 @@ index 6013d9e6..125b1cb3 100644 FIND_PACKAGE(OpenSSL) IF(OPENSSL_FOUND) SET(HAVE_LIBCRYPTO 1) +@@ -1349,7 +1349,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1371,6 +1371,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(strchr HAVE_STRCHR) + CHECK_FUNCTION_EXISTS_GLIBC(strdup HAVE_STRDUP) + CHECK_FUNCTION_EXISTS_GLIBC(strerror HAVE_STRERROR) + CHECK_FUNCTION_EXISTS_GLIBC(strncpy_s HAVE_STRNCPY_S) ++CHECK_FUNCTION_EXISTS_GLIBC(strnlen HAVE_STRNLEN) + CHECK_FUNCTION_EXISTS_GLIBC(strrchr HAVE_STRRCHR) + CHECK_FUNCTION_EXISTS_GLIBC(symlink HAVE_SYMLINK) + CHECK_FUNCTION_EXISTS_GLIBC(timegm HAVE_TIMEGM) +@@ -1381,11 +1382,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1398,10 +1399,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt index 9389bbc9..76e0b5c7 100644 --- a/libarchive/CMakeLists.txt diff --git a/recipes/libarchive/all/patches/0003-3.5.1-cmake.patch b/recipes/libarchive/all/patches/0003-3.5.1-cmake.patch new file mode 100644 index 00000000000000..181a183093fc3e --- /dev/null +++ b/recipes/libarchive/all/patches/0003-3.5.1-cmake.patch @@ -0,0 +1,142 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 256b966e..30c42967 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -6,7 +6,7 @@ endif() + # + PROJECT(libarchive C) + # +-SET(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/build/cmake") ++list(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/build/cmake") + if(NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY) + set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${libarchive_BINARY_DIR}/bin) + endif() +@@ -418,7 +418,7 @@ IF(ZLIB_FOUND) + SET(HAVE_LIBZ 1) + SET(HAVE_ZLIB_H 1) + INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR}) +- LIST(APPEND ADDITIONAL_LIBS ${ZLIB_LIBRARIES}) ++ LIST(APPEND ADDITIONAL_LIBS ZLIB::ZLIB) + IF(WIN32 AND NOT CYGWIN) + set(ZLIB_WINAPI yes) + IF(ZLIB_WINAPI) +@@ -480,7 +480,7 @@ IF(LIBLZMA_FOUND) + SET(HAVE_LIBLZMA 1) + SET(HAVE_LZMA_H 1) + CMAKE_PUSH_CHECK_STATE() +- SET(CMAKE_REQUIRED_INCLUDES ${LIBLZMA_INCLUDE_DIR}) ++ SET(CMAKE_REQUIRED_INCLUDES ${LIBLZMA_INCLUDE_DIRS}) + SET(CMAKE_REQUIRED_LIBRARIES ${LIBLZMA_LIBRARIES}) + INCLUDE_DIRECTORIES(${LIBLZMA_INCLUDE_DIRS}) + LIST(APPEND ADDITIONAL_LIBS ${LIBLZMA_LIBRARIES}) +@@ -497,7 +497,7 @@ IF(LIBLZMA_FOUND) + ELSE(LIBLZMA_FOUND) + # LZMA not found and will not be used. + ENDIF(LIBLZMA_FOUND) +-MARK_AS_ADVANCED(CLEAR LIBLZMA_INCLUDE_DIR) ++MARK_AS_ADVANCED(CLEAR LIBLZMA_INCLUDE_DIRS) + MARK_AS_ADVANCED(CLEAR LIBLZMA_LIBRARY) + + # +@@ -567,7 +567,7 @@ IF(ENABLE_LZ4) + ENDIF (LZ4_INCLUDE_DIR) + + FIND_PATH(LZ4_INCLUDE_DIR lz4.h) +- FIND_LIBRARY(LZ4_LIBRARY NAMES lz4 liblz4) ++ FIND_LIBRARY(LZ4_LIBRARY NAMES lz4 liblz4 lz4_static liblz4_static) + INCLUDE(FindPackageHandleStandardArgs) + FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZ4 DEFAULT_MSG LZ4_LIBRARY LZ4_INCLUDE_DIR) + ELSE(ENABLE_LZ4) +@@ -783,7 +783,7 @@ ENDIF(ENABLE_NETTLE) + # Find OpenSSL + # (Except on Mac, where OpenSSL is deprecated.) + # +-IF(ENABLE_OPENSSL AND NOT CMAKE_SYSTEM_NAME MATCHES "Darwin") ++IF(ENABLE_OPENSSL) + FIND_PACKAGE(OpenSSL) + IF(OPENSSL_FOUND) + SET(HAVE_LIBCRYPTO 1) +@@ -1349,7 +1349,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1382,11 +1382,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1399,10 +1399,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + +diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt +index 9389bbc9..76e0b5c7 100644 +--- a/libarchive/CMakeLists.txt ++++ b/libarchive/CMakeLists.txt +@@ -236,11 +236,15 @@ ELSEIF(ARCHIVE_ACL_SUNOS) + ENDIF() + + # Libarchive is a shared library ++if (BUILD_SHARED_LIBS) ++ + ADD_LIBRARY(archive SHARED ${libarchive_SOURCES} ${include_HEADERS}) + TARGET_INCLUDE_DIRECTORIES(archive PUBLIC .) + TARGET_LINK_LIBRARIES(archive ${ADDITIONAL_LIBS}) + SET_TARGET_PROPERTIES(archive PROPERTIES SOVERSION ${SOVERSION}) + ++else() ++ + # archive_static is a static library + ADD_LIBRARY(archive_static STATIC ${libarchive_SOURCES} ${include_HEADERS}) + TARGET_LINK_LIBRARIES(archive_static ${ADDITIONAL_LIBS}) +@@ -250,13 +254,21 @@ SET_TARGET_PROPERTIES(archive_static PROPERTIES COMPILE_DEFINITIONS + IF(NOT WIN32 OR CYGWIN) + SET_TARGET_PROPERTIES(archive_static PROPERTIES OUTPUT_NAME archive) + ENDIF(NOT WIN32 OR CYGWIN) ++endif() + + IF(ENABLE_INSTALL) + # How to install the libraries +- INSTALL(TARGETS archive archive_static ++ if (BUILD_SHARED_LIBS) ++ INSTALL(TARGETS archive ++ RUNTIME DESTINATION bin ++ LIBRARY DESTINATION lib ++ ARCHIVE DESTINATION lib) ++ else() ++ INSTALL(TARGETS archive_static + RUNTIME DESTINATION bin + LIBRARY DESTINATION lib + ARCHIVE DESTINATION lib) ++ endif() + INSTALL_MAN(${libarchive_MANS}) + INSTALL(FILES ${include_HEADERS} DESTINATION include) + ENDIF() diff --git a/recipes/libarchive/all/patches/0003-3.5.2-cmake.patch b/recipes/libarchive/all/patches/0003-3.5.2-cmake.patch index 5584b5f1606bc0..46955b7f8f7ce1 100644 --- a/recipes/libarchive/all/patches/0003-3.5.2-cmake.patch +++ b/recipes/libarchive/all/patches/0003-3.5.2-cmake.patch @@ -56,6 +56,47 @@ index e0359b51..3927a742 100644 FIND_PACKAGE(OpenSSL) IF(OPENSSL_FOUND) SET(HAVE_LIBCRYPTO 1) +@@ -1350,7 +1350,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1383,11 +1383,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1400,10 +1400,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt index e1d76a51..792b26b3 100644 --- a/libarchive/CMakeLists.txt diff --git a/recipes/libarchive/all/patches/0003-3.6.0-cmake.patch b/recipes/libarchive/all/patches/0003-3.6.0-cmake.patch index 436c8194e3e4dc..3c89010df2abab 100644 --- a/recipes/libarchive/all/patches/0003-3.6.0-cmake.patch +++ b/recipes/libarchive/all/patches/0003-3.6.0-cmake.patch @@ -56,6 +56,47 @@ index 646e5ce7..9bca273f 100644 FIND_PACKAGE(OpenSSL) IF(OPENSSL_FOUND) SET(HAVE_LIBCRYPTO 1) +@@ -1357,7 +1357,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1390,11 +1390,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1407,10 +1407,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt index e1d76a51..713c6496 100644 --- a/libarchive/CMakeLists.txt diff --git a/recipes/libarchive/all/patches/0003-3.6.2-cmake.patch b/recipes/libarchive/all/patches/0003-3.6.2-cmake.patch index 80d49396aac872..aca2961950d2df 100644 --- a/recipes/libarchive/all/patches/0003-3.6.2-cmake.patch +++ b/recipes/libarchive/all/patches/0003-3.6.2-cmake.patch @@ -1,5 +1,5 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 2315da5..1d8de96 100644 +index a4a9284a..f5dbccac 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -9,7 +9,7 @@ endif() @@ -18,9 +18,9 @@ index 2315da5..1d8de96 100644 - LIST(APPEND ADDITIONAL_LIBS ${ZLIB_LIBRARIES}) + LIST(APPEND ADDITIONAL_LIBS ZLIB::ZLIB) IF(WIN32 AND NOT CYGWIN) - set(ZLIB_WINAPI yes) - IF(ZLIB_WINAPI) -@@ -490,7 +490,7 @@ IF(LIBLZMA_FOUND) + + +@@ -497,7 +497,7 @@ IF(LIBLZMA_FOUND) SET(HAVE_LIBLZMA 1) SET(HAVE_LZMA_H 1) CMAKE_PUSH_CHECK_STATE() @@ -29,7 +29,7 @@ index 2315da5..1d8de96 100644 SET(CMAKE_REQUIRED_LIBRARIES ${LIBLZMA_LIBRARIES}) INCLUDE_DIRECTORIES(${LIBLZMA_INCLUDE_DIRS}) LIST(APPEND ADDITIONAL_LIBS ${LIBLZMA_LIBRARIES}) -@@ -507,7 +507,7 @@ IF(LIBLZMA_FOUND) +@@ -514,7 +514,7 @@ IF(LIBLZMA_FOUND) ELSE(LIBLZMA_FOUND) # LZMA not found and will not be used. ENDIF(LIBLZMA_FOUND) @@ -38,7 +38,7 @@ index 2315da5..1d8de96 100644 MARK_AS_ADVANCED(CLEAR LIBLZMA_LIBRARY) # -@@ -577,7 +577,7 @@ IF(ENABLE_LZ4) +@@ -584,7 +584,7 @@ IF(ENABLE_LZ4) ENDIF (LZ4_INCLUDE_DIR) FIND_PATH(LZ4_INCLUDE_DIR lz4.h) @@ -47,7 +47,7 @@ index 2315da5..1d8de96 100644 INCLUDE(FindPackageHandleStandardArgs) FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZ4 DEFAULT_MSG LZ4_LIBRARY LZ4_INCLUDE_DIR) ELSE(ENABLE_LZ4) -@@ -799,7 +799,7 @@ ENDIF(ENABLE_NETTLE) +@@ -806,7 +806,7 @@ ENDIF(ENABLE_NETTLE) # Find OpenSSL # (Except on Mac, where OpenSSL is deprecated.) # @@ -57,46 +57,41 @@ index 2315da5..1d8de96 100644 IF(OPENSSL_FOUND) SET(HAVE_LIBCRYPTO 1) diff --git a/libarchive/CMakeLists.txt b/libarchive/CMakeLists.txt -index ff7ade0..1438819 100644 +index ff7ade00..8c867130 100644 --- a/libarchive/CMakeLists.txt +++ b/libarchive/CMakeLists.txt -@@ -243,11 +243,14 @@ ELSEIF(ARCHIVE_ACL_SUNOS) +@@ -242,13 +242,13 @@ ELSEIF(ARCHIVE_ACL_SUNOS) + LIST(APPEND libarchive_SOURCES archive_disk_acl_sunos.c) ENDIF() - # Libarchive is a shared library +-# Libarchive is a shared library +if (BUILD_SHARED_LIBS) ADD_LIBRARY(archive SHARED ${libarchive_SOURCES} ${include_HEADERS}) TARGET_INCLUDE_DIRECTORIES(archive PUBLIC .) TARGET_LINK_LIBRARIES(archive ${ADDITIONAL_LIBS}) SET_TARGET_PROPERTIES(archive PROPERTIES SOVERSION ${SOVERSION}) +-# archive_static is a static library +else() -+ - # archive_static is a static library ADD_LIBRARY(archive_static STATIC ${libarchive_SOURCES} ${include_HEADERS}) TARGET_LINK_LIBRARIES(archive_static ${ADDITIONAL_LIBS}) -@@ -257,13 +260,21 @@ SET_TARGET_PROPERTIES(archive_static PROPERTIES COMPILE_DEFINITIONS + SET_TARGET_PROPERTIES(archive_static PROPERTIES COMPILE_DEFINITIONS +@@ -257,13 +257,13 @@ SET_TARGET_PROPERTIES(archive_static PROPERTIES COMPILE_DEFINITIONS IF(NOT WIN32 OR CYGWIN) SET_TARGET_PROPERTIES(archive_static PROPERTIES OUTPUT_NAME archive) ENDIF(NOT WIN32 OR CYGWIN) +- +endif() - IF(ENABLE_INSTALL) - # How to install the libraries +- # How to install the libraries - INSTALL(TARGETS archive archive_static - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib) + if (BUILD_SHARED_LIBS) -+ INSTALL(TARGETS archive -+ RUNTIME DESTINATION bin -+ LIBRARY DESTINATION lib -+ ARCHIVE DESTINATION lib) ++ INSTALL(TARGETS archive RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib) + else() -+ INSTALL(TARGETS archive_static -+ RUNTIME DESTINATION bin -+ LIBRARY DESTINATION lib -+ ARCHIVE DESTINATION lib) ++ INSTALL(TARGETS archive_static RUNTIME DESTINATION bin LIBRARY DESTINATION lib ARCHIVE DESTINATION lib) + endif() INSTALL_MAN(${libarchive_MANS}) INSTALL(FILES ${include_HEADERS} DESTINATION include) diff --git a/recipes/libarchive/all/patches/0005-3.6.2-try-compile-cmakedeps.patch b/recipes/libarchive/all/patches/0005-3.6.2-try-compile-cmakedeps.patch index 4bca48088c19b8..69e42f1f5678b4 100644 --- a/recipes/libarchive/all/patches/0005-3.6.2-try-compile-cmakedeps.patch +++ b/recipes/libarchive/all/patches/0005-3.6.2-try-compile-cmakedeps.patch @@ -1,27 +1,35 @@ diff --git a/CMakeLists.txt b/CMakeLists.txt -index 1d8de96f..d54975b7 100644 +index f5dbccac..ea7ff16a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -829,6 +829,8 @@ ENDIF(NOT OPENSSL_FOUND) +@@ -830,12 +830,11 @@ IF(NOT OPENSSL_FOUND) + ENDIF(NOT OPENSSL_FOUND) + + # +-# How to prove that CRYPTO functions, which have several names on various +-# platforms, just see if archive_digest.c can compile and link against +-# required libraries. # MACRO(CHECK_CRYPTO ALGORITHMS IMPLEMENTATION) - FOREACH(ALGORITHM ${ALGORITHMS}) +- FOREACH(ALGORITHM ${ALGORITHMS}) ++ FOREACH(ALGORITHM ${ALGORITHMS}) + include(CMakePushCheckState) + cmake_push_check_state() IF(NOT ARCHIVE_CRYPTO_${ALGORITHM}) STRING(TOLOWER "${ALGORITHM}" lower_algorithm) STRING(TOUPPER "${ALGORITHM}" algorithm) -@@ -849,8 +851,7 @@ MACRO(CHECK_CRYPTO ALGORITHMS IMPLEMENTATION) +@@ -856,8 +855,8 @@ MACRO(CHECK_CRYPTO ALGORITHMS IMPLEMENTATION) IF ("${IMPLEMENTATION}" MATCHES "^OPENSSL$" AND OPENSSL_FOUND) SET(TRY_CRYPTO_REQUIRED_INCLUDES "${TRY_CRYPTO_REQUIRED_INCLUDES};${OPENSSL_INCLUDE_DIR}") - SET(TRY_CRYPTO_REQUIRED_LIBS - "-DLINK_LIBRARIES:STRING=${OPENSSL_LIBRARIES}") -+ set(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_LIBRARIES}) ++ set(CMAKE_REQUIRED_LIBRARIES ++ ${OPENSSL_LIBRARIES}) ELSEIF("${IMPLEMENTATION}" MATCHES "^MBEDTLS$" AND MBEDTLS_FOUND) SET(TRY_CRYPTO_REQUIRED_INCLUDES "${TRY_CRYPTO_REQUIRED_INCLUDES};${MBEDTLS_INCLUDE_DIRS}") -@@ -927,6 +928,7 @@ main(int argc, char **argv) +@@ -934,6 +933,7 @@ main(int argc, char **argv) ENDIF ("${IMPLEMENTATION}" MATCHES "^OPENSSL$" AND OPENSSL_FOUND) ENDIF (ARCHIVE_CRYPTO_${ALGORITHM}_${IMPLEMENTATION}) ENDIF(NOT ARCHIVE_CRYPTO_${ALGORITHM}) diff --git a/recipes/libarchive/all/patches/0006-fix-msvc-build.patch b/recipes/libarchive/all/patches/0006-fix-msvc-build.patch new file mode 100644 index 00000000000000..c0903cf80cf947 --- /dev/null +++ b/recipes/libarchive/all/patches/0006-fix-msvc-build.patch @@ -0,0 +1,48 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 713e3bc5..9bc36214 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1374,7 +1374,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++set(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1407,11 +1407,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++set(HAVE_WCRTOMB 1) ++set(HAVE_WCSCMP 1) ++set(HAVE_WCSCPY 1) ++set(HAVE_WCSLEN 1) ++set(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_ctime64_s HAVE__CTIME64_S) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) +@@ -1424,10 +1424,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++set(HAVE_VPRINTF 1) ++set(HAVE_WMEMCMP 1) ++set(HAVE_WMEMCPY 1) ++set(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + +-- +2.33.0.windows.1 + From 831f49bbe136439335aa1f909dc7e3a01e1514c6 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 4 Sep 2023 10:43:00 +0200 Subject: [PATCH 0513/1140] (#19570) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 7b84a12bb8b2a9..2c10e53b02ccaa 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -282,6 +282,7 @@ required_for_references: - enet - enhex-generic_serialization - enhex-strong_type +- enkits - entityx - entt - enum-flags @@ -428,6 +429,7 @@ required_for_references: - http_parser - hunspell - hwloc +- hyperscan - icecream-cpp - icu - id3v2lib @@ -682,6 +684,7 @@ required_for_references: - lz4 - lzfse - lzham +- lzip - lzma_sdk - lzo - m4 @@ -795,6 +798,7 @@ required_for_references: - objectbox - objectbox-generator - observer-ptr-lite +- octo-logger-cpp - octomap - odbc - ode @@ -920,6 +924,7 @@ required_for_references: - pybind11_json - pystring - qcbor +- qdbm - qhull - qpdf - qpoases From 75a1eaf261645aace885188aae97a8df76936fb4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 4 Sep 2023 12:06:24 +0300 Subject: [PATCH 0514/1140] (#17575) embag: add new recipe * embag: add new recipe * embag: set min cxx_standard to 11 * embag: add missing 'm' system lib * embag: bump min c++ std to 14 * embag: fix a portability bug * embag: drop test_v1_package * embag: transitive_libs not required for boost * embag: get rid of patch, add review suggestion * embag: revert to using a patch Otherwise would need to add /Zc:__cplusplus to exported cxxflags. * embag: get rid of the patch --- recipes/embag/all/CMakeLists.txt | 33 +++++++ recipes/embag/all/conandata.yml | 4 + recipes/embag/all/conanfile.py | 91 +++++++++++++++++++ recipes/embag/all/test_package/CMakeLists.txt | 8 ++ recipes/embag/all/test_package/conanfile.py | 26 ++++++ .../embag/all/test_package/test_package.cpp | 18 ++++ recipes/embag/config.yml | 3 + 7 files changed, 183 insertions(+) create mode 100644 recipes/embag/all/CMakeLists.txt create mode 100644 recipes/embag/all/conandata.yml create mode 100644 recipes/embag/all/conanfile.py create mode 100644 recipes/embag/all/test_package/CMakeLists.txt create mode 100644 recipes/embag/all/test_package/conanfile.py create mode 100644 recipes/embag/all/test_package/test_package.cpp create mode 100644 recipes/embag/config.yml diff --git a/recipes/embag/all/CMakeLists.txt b/recipes/embag/all/CMakeLists.txt new file mode 100644 index 00000000000000..6638694bdd2b66 --- /dev/null +++ b/recipes/embag/all/CMakeLists.txt @@ -0,0 +1,33 @@ +cmake_minimum_required(VERSION 3.15) +project(embag LANGUAGES CXX) + +find_package(Boost REQUIRED COMPONENTS iostreams headers) +find_package(lz4 REQUIRED CONFIG) +find_package(BZip2 REQUIRED CONFIG) + +file(GLOB_RECURSE embag_SOURCES "lib/*.cc") +add_library(embag ${embag_SOURCES}) +set_target_properties(embag PROPERTIES + # embag does not export any symbols otherwise + WINDOWS_EXPORT_ALL_SYMBOLS ON +) +target_compile_features(embag PUBLIC cxx_std_14) +target_link_libraries(embag PUBLIC + Boost::iostreams + Boost::headers + lz4::lz4 + BZip2::BZip2 +) + +if (MSVC) + # For a #if __cplusplus < 201402L check in lib/util.h + target_compile_options(embag PRIVATE /Zc:__cplusplus) +endif() + +install(TARGETS embag) +install(DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}/lib/ + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/embag + FILES_MATCHING + PATTERN "*.h" + PATTERN "*.hpp" +) diff --git a/recipes/embag/all/conandata.yml b/recipes/embag/all/conandata.yml new file mode 100644 index 00000000000000..6df20cbf9a5ef0 --- /dev/null +++ b/recipes/embag/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.0.42": + url: "https://github.com/embarktrucks/embag/archive/refs/tags/0.0.42.tar.gz" + sha256: "60b22ba9355528040046b7e2c3ee968798ad5773a9eb7a1d13cf33dc47e2adec" diff --git a/recipes/embag/all/conanfile.py b/recipes/embag/all/conanfile.py new file mode 100644 index 00000000000000..3d3e19b6eb19bb --- /dev/null +++ b/recipes/embag/all/conanfile.py @@ -0,0 +1,91 @@ +import os + +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import get, copy, rm +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" + + +class EmbagConan(ConanFile): + name = "embag" + description = "Schema and dependency free ROS bag reader" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/embarktrucks/embag" + topics = ("rosbag", "ros", "robotics") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 14 + + def export_sources(self): + copy(self, "CMakeLists.txt", + src=self.recipe_folder, + dst=os.path.join(self.export_sources_folder, "src")) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + # INFO: embag.h includes boost/variant.hpp + self.requires("boost/1.82.0", transitive_headers=True) + # INFO: decompression.h includes lz4frame.h + self.requires("lz4/1.9.4", transitive_headers=True) + # INFO: ros_bag_types.h includes bzlib.h + self.requires("bzip2/1.0.8", transitive_headers=True) + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) + cmake.install() + rm(self, "*.pdb", self.package_folder, recursive=True) + + def package_info(self): + self.cpp_info.libs = ["embag"] + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] + if is_msvc(self): + # For a #if __cplusplus < 201402L check in lib/util.h, which is a public header + self.cpp_info.cxxflags.append("/Zc:__cplusplus") diff --git a/recipes/embag/all/test_package/CMakeLists.txt b/recipes/embag/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..27b09cd59a9016 --- /dev/null +++ b/recipes/embag/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(embag REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE embag::embag) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/embag/all/test_package/conanfile.py b/recipes/embag/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/embag/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/embag/all/test_package/test_package.cpp b/recipes/embag/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..c8563d402b2b7b --- /dev/null +++ b/recipes/embag/all/test_package/test_package.cpp @@ -0,0 +1,18 @@ +#include +#include + +#include + +int main() { + Embag::View view{}; + // Do not load any bag file for testing + // view.addBag("xyz.bag"); + const auto start_time = view.getStartTime(); + const auto end_time = view.getEndTime(); + std::cout << "Start time is " << start_time.secs + start_time.nsecs * 1e-9 << std::endl; + std::cout << "End time is " << end_time.secs + end_time.nsecs * 1e-9 << std::endl; + for (const auto &message : view.getMessages()) { + message->print(); + } + return EXIT_SUCCESS; +} diff --git a/recipes/embag/config.yml b/recipes/embag/config.yml new file mode 100644 index 00000000000000..97f7bce9d3b04c --- /dev/null +++ b/recipes/embag/config.yml @@ -0,0 +1,3 @@ +versions: + "0.0.42": + folder: all From 83323f29d132234f89093d1a82c4c1152a149f93 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 4 Sep 2023 11:42:34 +0200 Subject: [PATCH 0515/1140] (#19580) [bot] Update list of references (prod-v2/ListPackages) From d267231eae08809383946e93f5126bc81140e779 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Mon, 4 Sep 2023 12:04:22 +0200 Subject: [PATCH 0516/1140] (#19514) [onetbb] Bump dependencies Signed-off-by: Uilian Ries --- recipes/onetbb/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index bfc433ac097500..742e204c36a4f2 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -87,11 +87,11 @@ def configure(self): def requirements(self): if self._tbbbind_build: - self.requires("hwloc/2.9.1") + self.requires("hwloc/2.9.2") def build_requirements(self): if not self._tbbbind_explicit_hwloc and not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.build_requires("pkgconf/1.9.3") + self.build_requires("pkgconf/1.9.5") def layout(self): cmake_layout(self, src_folder="src") From 7ad5865d7093db9c2a950b285b21313504992c1e Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 19:54:58 +0900 Subject: [PATCH 0517/1140] (#19410) wt: update dependencies Co-authored-by: Carlos Zoido --- recipes/wt/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/wt/all/conanfile.py b/recipes/wt/all/conanfile.py index 630f87115fd109..23c11c902b6f8b 100644 --- a/recipes/wt/all/conanfile.py +++ b/recipes/wt/all/conanfile.py @@ -102,9 +102,9 @@ def requirements(self): if self.options.with_ssl: self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_sqlite"): - self.requires("sqlite3/3.42.0") + self.requires("sqlite3/3.43.0") if self.options.get_safe("with_mysql"): - self.requires("libmysqlclient/8.0.34", transitive_headers=True, transitive_libs=True) + self.requires("libmysqlclient/8.1.0", transitive_headers=True, transitive_libs=True) if self.options.get_safe("with_postgres"): self.requires("libpq/15.4", transitive_headers=True, transitive_libs=True) if self.options.get_safe("with_mssql") and self.settings.os != "Windows": From 418edacc791b0d90012e0742b96c5f7aa26da1e5 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 20:53:49 +0900 Subject: [PATCH 0518/1140] (#19574) cubicinterpolation: update dependencies, remove unused file --- recipes/cubicinterpolation/all/CMakeLists.txt | 7 ------- recipes/cubicinterpolation/all/conanfile.py | 15 ++++++--------- .../all/test_package/CMakeLists.txt | 6 +++--- recipes/cubicinterpolation/config.yml | 2 +- 4 files changed, 10 insertions(+), 20 deletions(-) delete mode 100644 recipes/cubicinterpolation/all/CMakeLists.txt diff --git a/recipes/cubicinterpolation/all/CMakeLists.txt b/recipes/cubicinterpolation/all/CMakeLists.txt deleted file mode 100644 index 0ed622c3eb5d7a..00000000000000 --- a/recipes/cubicinterpolation/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATH) - -add_subdirectory("source_subfolder") diff --git a/recipes/cubicinterpolation/all/conanfile.py b/recipes/cubicinterpolation/all/conanfile.py index 722cbaa5424a18..2525795c99b747 100644 --- a/recipes/cubicinterpolation/all/conanfile.py +++ b/recipes/cubicinterpolation/all/conanfile.py @@ -11,10 +11,10 @@ class CubicInterpolationConan(ConanFile): name = "cubicinterpolation" - homepage = "https://github.com/MaxSac/cubic_interpolation" + description = "Leightweight interpolation library based on boost and eigen." license = "MIT" + homepage = "https://github.com/MaxSac/cubic_interpolation" url = "https://github.com/conan-io/conan-center-index" - description = "Leightweight interpolation library based on boost and eigen." topics = ("interpolation", "splines", "cubic", "bicubic", "boost", "eigen3") package_type = "library" settings = "os", "arch", "compiler", "build_type" @@ -27,8 +27,6 @@ class CubicInterpolationConan(ConanFile): "fPIC": True, } - _cmake = None - def export_sources(self): export_conandata_patches(self) @@ -45,15 +43,14 @@ def layout(self): def requirements(self): # TODO: update boost dependency as soon as we deprecate conan1.x (see discussion in #11207) - self.requires("boost/1.75.0") - self.requires("eigen/3.3.9") + self.requires("boost/1.83.0") + self.requires("eigen/3.4.0") @property def _required_boost_components(self): return ["filesystem", "math", "serialization"] def validate(self): - miss_boost_required_comp = any(getattr(self.dependencies["boost"].options, f"without_{boost_comp}", True) for boost_comp in self._required_boost_components) if self.dependencies["boost"].options.header_only or miss_boost_required_comp: raise ConanInvalidConfiguration( @@ -64,7 +61,7 @@ def validate(self): if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, "14") - if not check_min_vs(self, 192, raise_invalid=False): + if not check_min_vs(self, 192, raise_invalid=False): raise ConanInvalidConfiguration(f"{self.ref} currently Visual Studio < 2019 not yet supported in this recipe. Contributions are welcome") if is_msvc(self) and self.options.shared: @@ -74,7 +71,7 @@ def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): - tc = CMakeToolchain(self) + tc = CMakeToolchain(self) tc.variables["BUILD_EXAMPLE"] = False tc.variables["BUILD_DOCUMENTATION"] = False tc.generate() diff --git a/recipes/cubicinterpolation/all/test_package/CMakeLists.txt b/recipes/cubicinterpolation/all/test_package/CMakeLists.txt index b98fa443a53683..0ce4681457d9e3 100644 --- a/recipes/cubicinterpolation/all/test_package/CMakeLists.txt +++ b/recipes/cubicinterpolation/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.8) project(test_package LANGUAGES CXX) find_package(CubicInterpolation REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} CubicInterpolation::CubicInterpolation) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 14) +target_link_libraries(${PROJECT_NAME} PRIVATE CubicInterpolation::CubicInterpolation) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/cubicinterpolation/config.yml b/recipes/cubicinterpolation/config.yml index 5185d65a2df905..5c83127c63d755 100644 --- a/recipes/cubicinterpolation/config.yml +++ b/recipes/cubicinterpolation/config.yml @@ -1,6 +1,6 @@ versions: "0.1.5": - folder: all + folder: all "0.1.4": folder: all "0.1.3": From 0b0d82d651416b828d31fcd116c61d6e459a667a Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 22:12:17 +0900 Subject: [PATCH 0519/1140] (#19556) luau: add version 0.593, remove older versions, make static-library --- recipes/luau/all/conandata.yml | 59 +------------------ recipes/luau/all/conanfile.py | 34 ++--------- .../all/patches/0.536-0001-fix-cmake.patch | 23 -------- .../all/patches/0.552-0001-fix-cmake.patch | 23 -------- .../all/patches/0.568-0001-fix-cmake.patch | 35 ----------- .../all/patches/0.572-0001-fix-cmake.patch | 23 -------- recipes/luau/config.yml | 8 +-- 7 files changed, 10 insertions(+), 195 deletions(-) delete mode 100644 recipes/luau/all/patches/0.536-0001-fix-cmake.patch delete mode 100644 recipes/luau/all/patches/0.552-0001-fix-cmake.patch delete mode 100644 recipes/luau/all/patches/0.568-0001-fix-cmake.patch delete mode 100644 recipes/luau/all/patches/0.572-0001-fix-cmake.patch diff --git a/recipes/luau/all/conandata.yml b/recipes/luau/all/conandata.yml index ce7fa7f71284a0..8561d42700a294 100644 --- a/recipes/luau/all/conandata.yml +++ b/recipes/luau/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.593": + url: "https://github.com/Roblox/luau/archive/0.593.tar.gz" + sha256: "1cbe4390ef71bb0f2210853978c900974aa02fab73de92b6e18e7bb10dd0e3c1" "0.589": url: "https://github.com/Roblox/luau/archive/0.589.tar.gz" sha256: "dc4489de52dbf29cd3d04d78c1112f812e04a03b68d57585749260ba791e65ed" @@ -20,68 +23,12 @@ sources: "0.558": url: "https://github.com/Roblox/luau/archive/0.558.tar.gz" sha256: "3484adddb18872700e033f5917af44d90c266f9e0fff2fac21aec1061f472a06" - "0.556": - url: "https://github.com/Roblox/luau/archive/0.556.tar.gz" - sha256: "dc72f91f4e866a2b25f7608e062c91c84e92a2e5611026e9789f127c3caf39f6" - "0.552": - url: "https://github.com/Roblox/luau/archive/0.552.tar.gz" - sha256: "c638aee88010197d7e6f22e592fa12360e38a69f54ed91980b11ac0f89676db5" - "0.548": - url: "https://github.com/Roblox/luau/archive/0.548.tar.gz" - sha256: "1ec0aa919955aaa2d88dbef115801681d3b4dbfa7a276435a03d20230918659c" patches: - "0.589": - - patch_file: "patches/0.572-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - "0.582": - - patch_file: "patches/0.572-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - "0.577": - - patch_file: "patches/0.572-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - "0.572": - - patch_file: "patches/0.572-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - "0.568": - - patch_file: "patches/0.568-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" "0.563": - - patch_file: "patches/0.552-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - patch_file: "patches/0.536-0002-rename-lerp.patch" patch_description: "rename lerp function to avoid name conflict" patch_type: "portability" "0.558": - - patch_file: "patches/0.552-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" - "0.556": - - patch_file: "patches/0.552-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" - "0.552": - - patch_file: "patches/0.552-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - - patch_file: "patches/0.536-0002-rename-lerp.patch" - patch_description: "rename lerp function to avoid name conflict" - patch_type: "portability" - "0.548": - - patch_file: "patches/0.536-0001-fix-cmake.patch" - patch_description: "enable shared build" - patch_type: "portability" - patch_file: "patches/0.536-0002-rename-lerp.patch" patch_description: "rename lerp function to avoid name conflict" patch_type: "portability" diff --git a/recipes/luau/all/conanfile.py b/recipes/luau/all/conanfile.py index fe153e150679e6..643eab7b931701 100644 --- a/recipes/luau/all/conanfile.py +++ b/recipes/luau/all/conanfile.py @@ -1,7 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.microsoft import is_msvc -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, replace_in_file +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy from conan.tools.build import check_min_cppstd from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout @@ -17,18 +16,14 @@ class LuauConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://luau-lang.org/" topics = ("lua", "scripting", "typed", "embed") - package_type = "library" + package_type = "static-library" settings = "os", "arch", "compiler", "build_type" options = { - "shared": [False, True], - "fPIC": [True, False], "with_cli": [True, False], "with_web": [True, False], "native_code_gen": [True, False], } default_options = { - "shared": False, - "fPIC": True, "with_cli": False, "with_web": False, "native_code_gen": False, @@ -41,7 +36,7 @@ def _minimum_cpp_standard(self): @property def _compilers_minimum_version(self): return { - "gcc": "8" if Version(self.version) < "0.549" else "9", + "gcc": "9", "clang": "7", "apple-clang": "12", "Visual Studio": "15", @@ -52,16 +47,6 @@ def export_sources(self): copy(self, "CMakeLists.txt", self.recipe_folder, self.export_sources_folder) export_conandata_patches(self) - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC - - def configure(self): - if self.options.shared: - self.options.rm_safe("fPIC") - if Version(self.version) < "0.549": - del self.options.native_code_gen - def layout(self): cmake_layout(self, src_folder="src") @@ -74,9 +59,6 @@ def validate(self): f"{self.ref} requires C++{self._minimum_cpp_standard}, which your compiler does not support." ) - if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration(f"{self.ref} does not support shared build in MSVC") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -87,17 +69,12 @@ def generate(self): tc.variables["LUAU_BUILD_WEB"] = self.options.with_web tc.variables["LUAU_WERROR"] = False tc.variables["LUAU_STATIC_CRT"] = False - if Version(self.version) >= "0.549": - tc.variables["LUAU_NATIVE"] = self.options.native_code_gen + tc.variables["LUAU_NATIVE"] = self.options.native_code_gen tc.variables["LUAU_SRC_DIR"] = self.source_folder.replace("\\", "/") tc.generate() def _patch_sources(self): apply_conandata_patches(self) - if Version(self.version) >= "0.548" and self.options.shared: - replace_in_file(self, os.path.join(self.source_folder, "VM", "include", "luaconf.h"), - "#define LUAI_FUNC __attribute__((visibility(\"hidden\"))) extern", - "#define LUAI_FUNC extern") def build(self): self._patch_sources() @@ -139,8 +116,7 @@ def package_info(self): self.cpp_info.components["CodeGen"].libs = ["Luau.CodeGen"] self.cpp_info.components["CodeGen"].set_property("cmake_target_name", "Luau::CodeGen") self.cpp_info.components["CodeGen"].requires = ["Ast"] - if Version(self.version) >= "0.548": - self.cpp_info.components["CodeGen"].requires.append("VM") + self.cpp_info.components["CodeGen"].requires.append("VM") if self.options.with_cli: bin_path = os.path.join(self.package_folder, "bin") diff --git a/recipes/luau/all/patches/0.536-0001-fix-cmake.patch b/recipes/luau/all/patches/0.536-0001-fix-cmake.patch deleted file mode 100644 index 00dcf666172050..00000000000000 --- a/recipes/luau/all/patches/0.536-0001-fix-cmake.patch +++ /dev/null @@ -1,23 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 9200634..c1cca12 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -21,12 +21,12 @@ endif() - - project(Luau LANGUAGES CXX C) - add_library(Luau.Common INTERFACE) --add_library(Luau.Ast STATIC) --add_library(Luau.Compiler STATIC) --add_library(Luau.Analysis STATIC) --add_library(Luau.CodeGen STATIC) --add_library(Luau.VM STATIC) --add_library(isocline STATIC) -+add_library(Luau.Ast) -+add_library(Luau.Compiler) -+add_library(Luau.Analysis) -+add_library(Luau.CodeGen) -+add_library(Luau.VM) -+add_library(isocline) - - if(LUAU_BUILD_CLI) - add_executable(Luau.Repl.CLI) diff --git a/recipes/luau/all/patches/0.552-0001-fix-cmake.patch b/recipes/luau/all/patches/0.552-0001-fix-cmake.patch deleted file mode 100644 index aaff66adb45b9b..00000000000000 --- a/recipes/luau/all/patches/0.552-0001-fix-cmake.patch +++ /dev/null @@ -1,23 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 05d701e..4c73783 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -22,12 +22,12 @@ endif() - - project(Luau LANGUAGES CXX C) - add_library(Luau.Common INTERFACE) --add_library(Luau.Ast STATIC) --add_library(Luau.Compiler STATIC) --add_library(Luau.Analysis STATIC) --add_library(Luau.CodeGen STATIC) --add_library(Luau.VM STATIC) --add_library(isocline STATIC) -+add_library(Luau.Ast) -+add_library(Luau.Compiler) -+add_library(Luau.Analysis) -+add_library(Luau.CodeGen) -+add_library(Luau.VM) -+add_library(isocline) - - if(LUAU_BUILD_CLI) - add_executable(Luau.Repl.CLI) diff --git a/recipes/luau/all/patches/0.568-0001-fix-cmake.patch b/recipes/luau/all/patches/0.568-0001-fix-cmake.patch deleted file mode 100644 index 9901376bd09eac..00000000000000 --- a/recipes/luau/all/patches/0.568-0001-fix-cmake.patch +++ /dev/null @@ -1,35 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 6e15e5f..63be1e1 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -24,12 +24,12 @@ endif() - - project(Luau LANGUAGES CXX C) - add_library(Luau.Common INTERFACE) --add_library(Luau.Ast STATIC) --add_library(Luau.Compiler STATIC) --add_library(Luau.Analysis STATIC) --add_library(Luau.CodeGen STATIC) --add_library(Luau.VM STATIC) --add_library(isocline STATIC) -+add_library(Luau.Ast) -+add_library(Luau.Compiler) -+add_library(Luau.Analysis) -+add_library(Luau.CodeGen) -+add_library(Luau.VM) -+add_library(isocline) - - if(LUAU_BUILD_CLI) - add_executable(Luau.Repl.CLI) -diff --git a/Sources.cmake b/Sources.cmake -index 6e0a32e..53d77c6 100644 ---- a/Sources.cmake -+++ b/Sources.cmake -@@ -84,6 +84,7 @@ target_sources(Luau.CodeGen PRIVATE - CodeGen/src/CodeBlockUnwind.cpp - CodeGen/src/CodeGen.cpp - CodeGen/src/CodeGenUtils.cpp -+ CodeGen/src/CodeGenA64.cpp - CodeGen/src/CodeGenX64.cpp - CodeGen/src/EmitBuiltinsX64.cpp - CodeGen/src/EmitCommonX64.cpp diff --git a/recipes/luau/all/patches/0.572-0001-fix-cmake.patch b/recipes/luau/all/patches/0.572-0001-fix-cmake.patch deleted file mode 100644 index 24acb8d334fb95..00000000000000 --- a/recipes/luau/all/patches/0.572-0001-fix-cmake.patch +++ /dev/null @@ -1,23 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 6e15e5f..63be1e1 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -24,12 +24,12 @@ endif() - - project(Luau LANGUAGES CXX C) - add_library(Luau.Common INTERFACE) --add_library(Luau.Ast STATIC) --add_library(Luau.Compiler STATIC) --add_library(Luau.Analysis STATIC) --add_library(Luau.CodeGen STATIC) --add_library(Luau.VM STATIC) --add_library(isocline STATIC) -+add_library(Luau.Ast) -+add_library(Luau.Compiler) -+add_library(Luau.Analysis) -+add_library(Luau.CodeGen) -+add_library(Luau.VM) -+add_library(isocline) - - if(LUAU_BUILD_CLI) - add_executable(Luau.Repl.CLI) diff --git a/recipes/luau/config.yml b/recipes/luau/config.yml index da348c98224536..ce328e74955788 100644 --- a/recipes/luau/config.yml +++ b/recipes/luau/config.yml @@ -1,4 +1,6 @@ versions: + "0.593": + folder: all "0.589": folder: all "0.582": @@ -13,9 +15,3 @@ versions: folder: all "0.558": folder: all - "0.556": - folder: all - "0.552": - folder: all - "0.548": - folder: all From 3e931f9307ad58d37ff8340a69ed70bc9fcac083 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Mon, 4 Sep 2023 16:22:18 +0200 Subject: [PATCH 0520/1140] (#19523) [config] Conan v2 ready references is no longer required * Conan v2 ready references is no longer required Signed-off-by: Uilian Ries * Revert "Conan v2 ready references is no longer required" This reverts commit e9200c64730bedb150ec9a56ee1eb81f8191a634. * Remove regression validation Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Daniel --- .c3i/config_v1.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index c28c0345e0824e..bc6adc07ba3705 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -41,7 +41,6 @@ tasks: - name: "license/cla" - name: "continuous-integration/jenkins/pr-merge" - name: "c3i/conan-v2/pr-merge" - required_for_references: "conan_v2_ready_references.yml" build_single_reference: package_id_cache_type: "none" timeout_minutes: 600 From 2b82a559fdbe0887d0c54808f5993b68ee56f5ed Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 4 Sep 2023 23:51:22 +0900 Subject: [PATCH 0521/1140] (#19274) zlib: add version 1.3, add patch_descriptions * zlib: add version 1.3 * remove patch file for xcode12 --- recipes/zlib/all/conandata.yml | 22 ++++- .../0002-gzguts-xcode12-compile-fix.patch | 27 ------ .../0003-gzguts-fix-widechar-condition.patch | 4 +- .../zlib/all/patches/1.3/0001-fix-cmake.patch | 92 +++++++++++++++++++ .../1.3/0002-gzguts-xcode12-compile-fix.patch | 15 +++ recipes/zlib/config.yml | 2 + 6 files changed, 129 insertions(+), 33 deletions(-) delete mode 100644 recipes/zlib/all/patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch create mode 100644 recipes/zlib/all/patches/1.3/0001-fix-cmake.patch create mode 100644 recipes/zlib/all/patches/1.3/0002-gzguts-xcode12-compile-fix.patch diff --git a/recipes/zlib/all/conandata.yml b/recipes/zlib/all/conandata.yml index 4da75436b4d71c..bcebfb9b13b6d3 100644 --- a/recipes/zlib/all/conandata.yml +++ b/recipes/zlib/all/conandata.yml @@ -1,4 +1,9 @@ sources: + "1.3": + url: + - "https://zlib.net/fossils/zlib-1.3.tar.gz" + - "https://github.com/madler/zlib/releases/download/v1.3/zlib-1.3.tar.gz" + sha256: "ff0ba4c292013dbc27530b3a81e1f9a813cd39de01ca5e0f8bf355702efa593e" "1.2.13": url: - "https://zlib.net/fossils/zlib-1.2.13.tar.gz" @@ -11,12 +16,18 @@ sources: url: "https://zlib.net/fossils/zlib-1.2.11.tar.gz" sha256: "c3e5e9fdd5004dcb542feda5ee4f0ff0744628baf8ed2dd5d66f8ca1197cb1a1" patches: + "1.3": + - patch_file: "patches/1.3/0001-fix-cmake.patch" + patch_description: "separate static/shared builds, disable debug suffix, disable building examples" + patch_type: "conan" "1.2.13": - patch_file: "patches/1.2.13/0001-Fix-cmake.patch" - - patch_file: "patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch" + patch_description: "separate static/shared builds, disable debug suffix, disable building examples" + patch_type: "conan" "1.2.12": - patch_file: "patches/1.2.x/0001-fix-cmake.patch" - - patch_file: "patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch" + patch_description: "separate static/shared builds, disable debug suffix, disable building examples" + patch_type: "conan" - patch_file: "patches/1.2.x/0004-Fix-a-bug-when-getting-a-gzip-header-extra-field-wit.patch" patch_description: "CVE-2022-37434: Fix a bug when getting a gzip header extra field with inflate()" patch_type: "vulnerability" @@ -29,6 +40,9 @@ patches: sha256: "cdd69eb3251728b1875c8ecae6427b50aa750b4045ef984ab79b6c07b7e6dd3a" "1.2.11": - patch_file: "patches/1.2.x/0001-fix-cmake.patch" - - patch_file: "patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch" - # https://github.com/madler/zlib/issues/268 + patch_description: "separate static/shared builds, disable debug suffix, disable building examples" + patch_type: "conan" - patch_file: "patches/1.2.x/0003-gzguts-fix-widechar-condition.patch" + patch_description: "fix condition for WIDECHAR usage" + patch_type: "portability" + patch_source: "https://github.com/madler/zlib/issues/268" diff --git a/recipes/zlib/all/patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch b/recipes/zlib/all/patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch deleted file mode 100644 index 3f81a6f53a2485..00000000000000 --- a/recipes/zlib/all/patches/1.2.x/0002-gzguts-xcode12-compile-fix.patch +++ /dev/null @@ -1,27 +0,0 @@ -From 4ff188d490445fe7bad629a94d5bf4b641d4ab8d Mon Sep 17 00:00:00 2001 -From: Tim Blechmann -Date: Thu, 2 Jul 2020 12:04:38 +0800 -Subject: [PATCH] xcode12 compile fix - ---- - gzguts.h | 4 ++++ - 1 file changed, 4 insertions(+) - -diff --git a/gzguts.h b/gzguts.h -index 990a4d2..c78cb40 100644 ---- a/gzguts.h -+++ b/gzguts.h -@@ -26,6 +26,10 @@ - # include - #endif - -+#ifdef __APPLE__ -+#include -+#endif -+ - #ifndef _POSIX_SOURCE - # define _POSIX_SOURCE - #endif --- -2.27.0 - diff --git a/recipes/zlib/all/patches/1.2.x/0003-gzguts-fix-widechar-condition.patch b/recipes/zlib/all/patches/1.2.x/0003-gzguts-fix-widechar-condition.patch index 56b3fbe76ce8eb..3de4978c306617 100644 --- a/recipes/zlib/all/patches/1.2.x/0003-gzguts-fix-widechar-condition.patch +++ b/recipes/zlib/all/patches/1.2.x/0003-gzguts-fix-widechar-condition.patch @@ -1,8 +1,8 @@ diff --git a/gzguts.h b/gzguts.h -index c78cb40..4e9ec4f 100644 +index 990a4d2..6378d46 100644 --- a/gzguts.h +++ b/gzguts.h -@@ -43,7 +43,7 @@ +@@ -39,7 +39,7 @@ # include #endif diff --git a/recipes/zlib/all/patches/1.3/0001-fix-cmake.patch b/recipes/zlib/all/patches/1.3/0001-fix-cmake.patch new file mode 100644 index 00000000000000..b2aa69d0684cf8 --- /dev/null +++ b/recipes/zlib/all/patches/1.3/0001-fix-cmake.patch @@ -0,0 +1,92 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 7f1b69f..618ea02 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -57,7 +57,6 @@ endif() + check_include_file(unistd.h Z_HAVE_UNISTD_H) + + if(MSVC) +- set(CMAKE_DEBUG_POSTFIX "d") + add_definitions(-D_CRT_SECURE_NO_DEPRECATE) + add_definitions(-D_CRT_NONSTDC_NO_DEPRECATE) + include_directories(${CMAKE_CURRENT_SOURCE_DIR}) +@@ -120,7 +119,7 @@ set(ZLIB_SRCS + zutil.c + ) + +-if(NOT MINGW) ++if(MSVC) + set(ZLIB_DLL_SRCS + win32/zlib1.rc # If present will override custom build rule below. + ) +@@ -131,7 +130,7 @@ file(READ ${CMAKE_CURRENT_SOURCE_DIR}/zlib.h _zlib_h_contents) + string(REGEX REPLACE ".*#define[ \t]+ZLIB_VERSION[ \t]+\"([-0-9A-Za-z.]+)\".*" + "\\1" ZLIB_FULL_VERSION ${_zlib_h_contents}) + +-if(MINGW) ++if(WIN32 AND NOT MSVC) + # This gets us DLL resource information when compiling on MinGW. + if(NOT CMAKE_RC_COMPILER) + set(CMAKE_RC_COMPILER windres.exe) +@@ -145,12 +144,16 @@ if(MINGW) + -o ${CMAKE_CURRENT_BINARY_DIR}/zlib1rc.obj + -i ${CMAKE_CURRENT_SOURCE_DIR}/win32/zlib1.rc) + set(ZLIB_DLL_SRCS ${CMAKE_CURRENT_BINARY_DIR}/zlib1rc.obj) +-endif(MINGW) ++endif() + ++if(BUILD_SHARED_LIBS) + add_library(zlib SHARED ${ZLIB_SRCS} ${ZLIB_DLL_SRCS} ${ZLIB_PUBLIC_HDRS} ${ZLIB_PRIVATE_HDRS}) + add_library(zlibstatic STATIC ${ZLIB_SRCS} ${ZLIB_PUBLIC_HDRS} ${ZLIB_PRIVATE_HDRS}) + set_target_properties(zlib PROPERTIES DEFINE_SYMBOL ZLIB_DLL) + set_target_properties(zlib PROPERTIES SOVERSION 1) ++else() ++add_library(zlib STATIC ${ZLIB_SRCS} ${ZLIB_ASMS} ${ZLIB_PUBLIC_HDRS} ${ZLIB_PRIVATE_HDRS}) ++endif() + + if(NOT CYGWIN) + # This property causes shared libraries on Linux to have the full version +@@ -163,19 +166,24 @@ if(NOT CYGWIN) + set_target_properties(zlib PROPERTIES VERSION ${ZLIB_FULL_VERSION}) + endif() + +-if(UNIX) ++if(WIN32 AND NOT MINGW) ++ if(BUILD_SHARED_LIBS) ++ set_target_properties(zlib PROPERTIES ARCHIVE_OUTPUT_NAME zdll) ++ endif() ++else() + # On unix-like platforms the library is almost always called libz +- set_target_properties(zlib zlibstatic PROPERTIES OUTPUT_NAME z) ++ set_target_properties(zlib PROPERTIES OUTPUT_NAME z) + if(NOT APPLE) + set_target_properties(zlib PROPERTIES LINK_FLAGS "-Wl,--version-script,\"${CMAKE_CURRENT_SOURCE_DIR}/zlib.map\"") + endif() +-elseif(BUILD_SHARED_LIBS AND WIN32) ++endif() ++if(BUILD_SHARED_LIBS AND WIN32) + # Creates zlib1.dll when building shared library version +- set_target_properties(zlib PROPERTIES SUFFIX "1.dll") ++ set_target_properties(zlib PROPERTIES PREFIX "" RUNTIME_OUTPUT_NAME "zlib1") + endif() + + if(NOT SKIP_INSTALL_LIBRARIES AND NOT SKIP_INSTALL_ALL ) +- install(TARGETS zlib zlibstatic ++ install(TARGETS zlib + RUNTIME DESTINATION "${INSTALL_BIN_DIR}" + ARCHIVE DESTINATION "${INSTALL_LIB_DIR}" + LIBRARY DESTINATION "${INSTALL_LIB_DIR}" ) +@@ -193,7 +201,7 @@ endif() + #============================================================================ + # Example binaries + #============================================================================ +- ++if(0) + add_executable(example test/example.c) + target_link_libraries(example zlib) + add_test(example example) +@@ -211,3 +219,4 @@ if(HAVE_OFF64_T) + target_link_libraries(minigzip64 zlib) + set_target_properties(minigzip64 PROPERTIES COMPILE_FLAGS "-D_FILE_OFFSET_BITS=64") + endif() ++endif() diff --git a/recipes/zlib/all/patches/1.3/0002-gzguts-xcode12-compile-fix.patch b/recipes/zlib/all/patches/1.3/0002-gzguts-xcode12-compile-fix.patch new file mode 100644 index 00000000000000..d299f4962fa59d --- /dev/null +++ b/recipes/zlib/all/patches/1.3/0002-gzguts-xcode12-compile-fix.patch @@ -0,0 +1,15 @@ +diff --git a/gzguts.h b/gzguts.h +index f937504..c4654b5 100644 +--- a/gzguts.h ++++ b/gzguts.h +@@ -25,6 +25,10 @@ + # include + #endif + ++#ifdef __APPLE__ ++#include ++#endif ++ + #ifndef _POSIX_SOURCE + # define _POSIX_SOURCE + #endif diff --git a/recipes/zlib/config.yml b/recipes/zlib/config.yml index 351c06f68201f8..132003f7c53b57 100644 --- a/recipes/zlib/config.yml +++ b/recipes/zlib/config.yml @@ -1,4 +1,6 @@ versions: + "1.3": + folder: all "1.2.13": folder: all "1.2.12": From 6767d0248fbf27488a8d30fa3e547d9603227556 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 5 Sep 2023 13:10:37 +0900 Subject: [PATCH 0522/1140] (#19531) benchmark: add version 1.8.3 --- recipes/benchmark/all/conandata.yml | 3 +++ recipes/benchmark/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/benchmark/all/conandata.yml b/recipes/benchmark/all/conandata.yml index 91541bdc04e27f..8a3c24a77b927d 100644 --- a/recipes/benchmark/all/conandata.yml +++ b/recipes/benchmark/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.3": + url: "https://github.com/google/benchmark/archive/refs/tags/v1.8.3.tar.gz" + sha256: "6bc180a57d23d4d9515519f92b0c83d61b05b5bab188961f36ac7b06b0d9e9ce" "1.8.2": url: "https://github.com/google/benchmark/archive/refs/tags/v1.8.2.tar.gz" sha256: "2aab2980d0376137f969d92848fbb68216abb07633034534fc8c65cc4e7a0e93" diff --git a/recipes/benchmark/config.yml b/recipes/benchmark/config.yml index b76259067bc586..f3ed1f1e957435 100644 --- a/recipes/benchmark/config.yml +++ b/recipes/benchmark/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.3": + folder: all "1.8.2": folder: all "1.8.1": From 5d928297d5ea3491713728af5b441c5a7bc49e2c Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 5 Sep 2023 16:53:21 +0900 Subject: [PATCH 0523/1140] (#19563) mpfr: add version 4.2.1, update dependenies --- recipes/mpfr/all/conandata.yml | 19 +++++++++++++------ recipes/mpfr/all/conanfile.py | 8 ++++---- recipes/mpfr/all/test_package/conanfile.py | 1 + recipes/mpfr/config.yml | 2 ++ 4 files changed, 20 insertions(+), 10 deletions(-) diff --git a/recipes/mpfr/all/conandata.yml b/recipes/mpfr/all/conandata.yml index 53fa206c24da17..bdecd0395c37de 100644 --- a/recipes/mpfr/all/conandata.yml +++ b/recipes/mpfr/all/conandata.yml @@ -1,14 +1,21 @@ sources: + "4.2.1": + url: "https://ftp.gnu.org/gnu/mpfr/mpfr-4.2.1.tar.gz" + sha256: "116715552bd966c85b417c424db1bbdf639f53836eb361549d1f8d6ded5cb4c6" "4.2.0": - sha256: f1cc1c6bb14d18f0c61cc416e083f5e697b6e0e3cf9630b9b33e8e483fc960f0 - url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.2.0.tar.gz + url: "https://ftp.gnu.org/gnu/mpfr/mpfr-4.2.0.tar.gz" + sha256: "f1cc1c6bb14d18f0c61cc416e083f5e697b6e0e3cf9630b9b33e8e483fc960f0" "4.1.0": - sha256: 3127fe813218f3a1f0adf4e8899de23df33b4cf4b4b3831a5314f78e65ffa2d6 - url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.1.0.tar.gz + url: "https://ftp.gnu.org/gnu/mpfr/mpfr-4.1.0.tar.gz" + sha256: "3127fe813218f3a1f0adf4e8899de23df33b4cf4b4b3831a5314f78e65ffa2d6" "4.0.2": - sha256: ae26cace63a498f07047a784cd3b0e4d010b44d2b193bab82af693de57a19a78 - url: https://ftp.gnu.org/gnu/mpfr/mpfr-4.0.2.tar.gz + url: "https://ftp.gnu.org/gnu/mpfr/mpfr-4.0.2.tar.gz" + sha256: "ae26cace63a498f07047a784cd3b0e4d010b44d2b193bab82af693de57a19a78" patches: + "4.2.1": + - patch_file: "patches/4.2.0-0002-windows-header-dll.patch" + patch_description: "Windows header DLL" + patch_type: "portability" "4.2.0": - patch_file: "patches/4.2.0-0002-windows-header-dll.patch" patch_description: "Windows header DLL" diff --git a/recipes/mpfr/all/conanfile.py b/recipes/mpfr/all/conanfile.py index 0356da09ec7fb0..e163c514a2dea6 100644 --- a/recipes/mpfr/all/conanfile.py +++ b/recipes/mpfr/all/conanfile.py @@ -17,13 +17,13 @@ class MpfrConan(ConanFile): name = "mpfr" - package_type = "library" description = "The MPFR library is a C library for multiple-precision floating-point computations with " \ "correct rounding" - topics = ("mpfr", "multiprecision", "math", "mathematics") + license = "LGPL-3.0-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.mpfr.org/" - license = "LGPL-3.0-or-later" + topics = ("multiprecision", "math", "mathematics") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -54,7 +54,7 @@ def configure(self): def requirements(self): if self.options.exact_int == "gmp": - self.requires("gmp/6.2.1", transitive_headers=True) + self.requires("gmp/6.3.0", transitive_headers=True) elif self.options.exact_int == "mpir": self.requires("mpir/3.0.0") diff --git a/recipes/mpfr/all/test_package/conanfile.py b/recipes/mpfr/all/test_package/conanfile.py index c56e8a6249e69a..a63e741acf6714 100644 --- a/recipes/mpfr/all/test_package/conanfile.py +++ b/recipes/mpfr/all/test_package/conanfile.py @@ -7,6 +7,7 @@ class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" def layout(self): cmake_layout(self) diff --git a/recipes/mpfr/config.yml b/recipes/mpfr/config.yml index 217c84a76cc940..f3d9d2b90378db 100644 --- a/recipes/mpfr/config.yml +++ b/recipes/mpfr/config.yml @@ -1,4 +1,6 @@ versions: + "4.2.1": + folder: all "4.2.0": folder: all "4.1.0": From a1a5972f3e9ece3ec748c4866508ff2138d48cce Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 5 Sep 2023 11:28:52 +0300 Subject: [PATCH 0524/1140] (#18765) llvm-openmp: migrate to Conan v2 * llvm-openmp: migrate to Conan v2 * llvm-openmp: export missing CFLAGS * llvm-openmp: restore VirtualRunEnv in test_package * llvm-openmp: fix test_v1_package --- recipes/llvm-openmp/all/CMakeLists.txt | 7 - recipes/llvm-openmp/all/conandata.yml | 7 - recipes/llvm-openmp/all/conanfile.py | 134 +++++++++--------- .../all/test_package/CMakeLists.txt | 14 +- .../llvm-openmp/all/test_package/conanfile.py | 22 ++- .../all/test_package/test_package.c | 25 ++++ .../all/test_package/test_package.cpp | 3 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 18 +++ 9 files changed, 146 insertions(+), 92 deletions(-) delete mode 100644 recipes/llvm-openmp/all/CMakeLists.txt create mode 100644 recipes/llvm-openmp/all/test_package/test_package.c create mode 100644 recipes/llvm-openmp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/llvm-openmp/all/test_v1_package/conanfile.py diff --git a/recipes/llvm-openmp/all/CMakeLists.txt b/recipes/llvm-openmp/all/CMakeLists.txt deleted file mode 100644 index 61f3d3b039e2bb..00000000000000 --- a/recipes/llvm-openmp/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory("source_subfolder") diff --git a/recipes/llvm-openmp/all/conandata.yml b/recipes/llvm-openmp/all/conandata.yml index 499e8f40e5c344..eebc958f499eb6 100644 --- a/recipes/llvm-openmp/all/conandata.yml +++ b/recipes/llvm-openmp/all/conandata.yml @@ -17,20 +17,13 @@ sources: patches: "12.0.1": - patch_file: "patches/0001-disable-build-testing_12.0.1.patch" - base_path: "source_subfolder" - patch_file: "patches/0002-disable-omp-target_12.0.1.patch" - base_path: "source_subfolder" "11.1.0": - patch_file: "patches/0001-disable-build-testing_11.1.0.patch" - base_path: "source_subfolder" - patch_file: "patches/0003-fix-armv8-build_11.1.0.patch" - base_path: "source_subfolder" "10.0.0": - patch_file: "patches/0001-disable-build-testing_10.0.0.patch" - base_path: "source_subfolder" "9.0.1": - patch_file: "patches/0001-disable-build-testing.patch" - base_path: "source_subfolder" "8.0.1": - patch_file: "patches/0001-disable-build-testing.patch" - base_path: "source_subfolder" diff --git a/recipes/llvm-openmp/all/conanfile.py b/recipes/llvm-openmp/all/conanfile.py index 4f1ee354a647ea..11666c28d78a07 100644 --- a/recipes/llvm-openmp/all/conanfile.py +++ b/recipes/llvm-openmp/all/conanfile.py @@ -1,10 +1,14 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -import functools import textwrap -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, replace_in_file, save +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" class LLVMOpenMpConan(ConanFile): @@ -16,81 +20,83 @@ class LLVMOpenMpConan(ConanFile): "in Fortran and C/C++ programs. This is the LLVM " "implementation.") license = "Apache-2.0 WITH LLVM-exception" - topics = ("conan", "llvm", "openmp", "parallelism") - homepage = "https://github.com/llvm/llvm-project/tree/master/openmp" url = "https://github.com/conan-io/conan-center-index" - settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], - "fPIC": [True, False]} - default_options = {"shared": False, - "fPIC": True} - generators = "cmake" + homepage = "https://github.com/llvm/llvm-project/tree/master/openmp" + topics = ("llvm", "openmp", "parallelism") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def _supports_compiler(self): - supported_compilers_by_os = \ - {"Linux": ["clang", "gcc", "intel"], - "Macos": ["apple-clang", "clang", "gcc", "intel"], - "Windows": ["intel"]} + supported_compilers_by_os = { + "Linux": ["clang", "gcc", "intel-cc"], + "Macos": ["apple-clang", "clang", "gcc", "intel-cc"], + "Windows": ["intel-cc"], + } the_compiler, the_os = self.settings.compiler.value, self.settings.os.value return the_compiler in supported_compilers_by_os.get(the_os, []) def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") if not self._supports_compiler(): raise ConanInvalidConfiguration("llvm-openmp doesn't support compiler: {} on OS: {}.". format(self.settings.compiler, self.settings.os)) + + def layout(self): + cmake_layout(self, src_folder="src") + def validate(self): if ( - tools.Version(self.version) <= "10.0.0" - and self.settings.os == "Macos" + Version(self.version) <= "10.0.0" + and is_apple_os(self) and self.settings.arch == "armv8" ): raise ConanInvalidConfiguration("ARM v8 not supported") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = "openmp-{}.src".format(self.version) - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["OPENMP_STANDALONE_BUILD"] = True + tc.variables["LIBOMP_ENABLE_SHARED"] = self.options.shared + if self.settings.os in ["Linux", "FreeBSD"]: + tc.variables["OPENMP_ENABLE_LIBOMPTARGET"] = self.options.shared + tc.generate() - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["OPENMP_STANDALONE_BUILD"] = True - cmake.definitions["LIBOMP_ENABLE_SHARED"] = self.options.shared - if self.settings.os == "Linux": - cmake.definitions["OPENMP_ENABLE_LIBOMPTARGET"] = self.options.shared - cmake.configure() - return cmake + def _patch_sources(self): + apply_conandata_patches(self) + replace_in_file(self,os.path.join(self.source_folder, "runtime", "CMakeLists.txt"), + "add_subdirectory(test)", "") def build(self): self._patch_sources() - tools.replace_in_file(os.path.join(self._source_subfolder, "runtime/CMakeLists.txt"), - "add_subdirectory(test)", "") - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE.txt", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE.txt", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() # TODO: to remove in conan v2 once cmake_find_package* generators removed @@ -98,44 +104,44 @@ def package(self): os.path.join(self.package_folder, self._module_file_rel_path), { "OpenMP::OpenMP_C": "OpenMP::OpenMP", - "OpenMP::OpenMP_CXX": "OpenMP::OpenMP" - } + "OpenMP::OpenMP_CXX": "OpenMP::OpenMP", + }, ) - @staticmethod - def _create_cmake_module_alias_targets(module_file, targets): + def _create_cmake_module_alias_targets(self, module_file, targets): content = "" for alias, aliased in targets.items(): - content += textwrap.dedent("""\ + content += textwrap.dedent(f"""\ if(TARGET {aliased} AND NOT TARGET {alias}) add_library({alias} INTERFACE IMPORTED) set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) endif() - """.format(alias=alias, aliased=aliased)) - tools.save(module_file, content) + """) + save(self, module_file, content) @property def _module_file_rel_path(self): - return os.path.join("lib", "cmake", "conan-official-{}-targets.cmake".format(self.name)) + return os.path.join("lib", "cmake", f"conan-official-{self.name}-targets.cmake") def package_info(self): self.cpp_info.set_property("cmake_file_name", "OpenMP") self.cpp_info.set_property("cmake_target_name", "OpenMP::OpenMP") self.cpp_info.set_property("cmake_target_aliases", ["OpenMP::OpenMP_C", "OpenMP::OpenMP_CXX"]) + if self.settings.compiler in ("clang", "apple-clang"): + self.cpp_info.cxxflags = ["-Xpreprocessor", "-fopenmp"] + elif self.settings.compiler == "gcc": + self.cpp_info.cxxflags = ["-fopenmp"] + elif self.settings.compiler == "intel-cc": + self.cpp_info.cxxflags = ["/Qopenmp"] if self.settings.os == "Windows" else ["-Qopenmp"] + self.cpp_info.cflags = self.cpp_info.cxxflags + self.cpp_info.libs = ["omp"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["dl", "m", "pthread", "rt"] + # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.names["cmake_find_package"] = "OpenMP" self.cpp_info.names["cmake_find_package_multi"] = "OpenMP" - self.cpp_info.builddirs.append(os.path.join(self.package_folder, 'lib', 'cmake')) + self.cpp_info.builddirs.append(os.path.join(self.package_folder, "lib", "cmake")) self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - - if self.settings.compiler in ("clang", "apple-clang"): - self.cpp_info.cxxflags = ["-Xpreprocessor", "-fopenmp"] - elif self.settings.compiler == 'gcc': - self.cpp_info.cxxflags = ["-fopenmp"] - elif self.settings.compiler == 'intel': - self.cpp_info.cxxflags = ["/Qopenmp"] if self.settings.os == 'Windows' else ["-Qopenmp"] - self.cpp_info.libs = tools.collect_libs(self) - if self.settings.os == "Linux": - self.cpp_info.system_libs = ["dl", "m", "pthread", "rt"] diff --git a/recipes/llvm-openmp/all/test_package/CMakeLists.txt b/recipes/llvm-openmp/all/test_package/CMakeLists.txt index 2d9a8574cc4d42..491aa7ec1f5d35 100644 --- a/recipes/llvm-openmp/all/test_package/CMakeLists.txt +++ b/recipes/llvm-openmp/all/test_package/CMakeLists.txt @@ -1,10 +1,10 @@ -cmake_minimum_required(VERSION 3.1) -project(PackageTest CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(PackageTest CXX C) find_package(OpenMP CONFIG REQUIRED) -add_executable(test_package test_package.cpp) -target_link_libraries(test_package OpenMP::OpenMP_CXX) +add_executable(test_package_cxx test_package.cpp) +target_link_libraries(test_package_cxx OpenMP::OpenMP_CXX) + +add_executable(test_package_c test_package.c) +target_link_libraries(test_package_c OpenMP::OpenMP_C) diff --git a/recipes/llvm-openmp/all/test_package/conanfile.py b/recipes/llvm-openmp/all/test_package/conanfile.py index 5ac3af772bdc06..b9c17185d658e4 100644 --- a/recipes/llvm-openmp/all/test_package/conanfile.py +++ b/recipes/llvm-openmp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class LLVMOpenMpTestConan(ConanFile): +class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,7 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + for executable in ["test_package_cxx", "test_package_c"]: + bin_path = os.path.join(self.cpp.build.bindir, executable) + self.run(bin_path, env="conanrun") diff --git a/recipes/llvm-openmp/all/test_package/test_package.c b/recipes/llvm-openmp/all/test_package/test_package.c new file mode 100644 index 00000000000000..103d724f00fcde --- /dev/null +++ b/recipes/llvm-openmp/all/test_package/test_package.c @@ -0,0 +1,25 @@ +#include + +#include + +int main() +{ + int num_threads = omp_get_num_procs(); + if (num_threads < 5) + num_threads = 5; + omp_set_num_threads(num_threads); + int actual_number; + #pragma omp parallel + { + #pragma omp single + { + actual_number = omp_get_num_threads(); + } + } + if(actual_number != num_threads){ + printf("Something went wrong. Expecting %d threads but found %d.\n", num_threads, actual_number); + printf("There are probably missing compiler flags.\n"); + return 1; + } + return 0; +} diff --git a/recipes/llvm-openmp/all/test_package/test_package.cpp b/recipes/llvm-openmp/all/test_package/test_package.cpp index f6316471238aab..b602ec5a096c91 100644 --- a/recipes/llvm-openmp/all/test_package/test_package.cpp +++ b/recipes/llvm-openmp/all/test_package/test_package.cpp @@ -1,4 +1,5 @@ #include + #include int main() @@ -15,7 +16,7 @@ int main() } if(actual_number != num_threads){ std::cout << "Something went wrong. Expecting " << num_threads << " threads but found " << actual_number << ".\n"; - std::cout << "There are probably missing compiler flags.\n" ; + std::cout << "There are probably missing compiler flags.\n"; return 1; } return 0; diff --git a/recipes/llvm-openmp/all/test_v1_package/CMakeLists.txt b/recipes/llvm-openmp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/llvm-openmp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/llvm-openmp/all/test_v1_package/conanfile.py b/recipes/llvm-openmp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..b6e98e149af122 --- /dev/null +++ b/recipes/llvm-openmp/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake, tools +import os + + +class LLVMOpenMpTestConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + for executable in ["test_package_cxx", "test_package_c"]: + bin_path = os.path.join("bin", executable) + self.run(bin_path, run_environment=True) From 1a4f91c08e57a891c1a604b2afbd68740397634d Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 5 Sep 2023 18:11:21 +0900 Subject: [PATCH 0525/1140] (#19577) csvmonkey: update boost/1.83.0, add package_type --- recipes/csvmonkey/all/conanfile.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/csvmonkey/all/conanfile.py b/recipes/csvmonkey/all/conanfile.py index 49542ed86e55ce..821a19ed460963 100644 --- a/recipes/csvmonkey/all/conanfile.py +++ b/recipes/csvmonkey/all/conanfile.py @@ -14,7 +14,8 @@ class CSVMONEKYConan(ConanFile): license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/dw/csvmonkey/" - topics = ("csv-parser", "header-only", "vectorized") + topics = ("csv-parser", "header-only", "vectorized", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" options = { "with_spirit": [True, False], @@ -33,7 +34,7 @@ def layout(self): def requirements(self): if self.options.with_spirit: - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") def package_id(self): self.info.clear() From a75c478ec82baa8f264eee9376a856177e96706b Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 5 Sep 2023 11:42:29 +0200 Subject: [PATCH 0526/1140] (#19594) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 2c10e53b02ccaa..5cf53d60ba1e6a 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -276,6 +276,7 @@ required_for_references: - egl-headers - eigen - elfio +- embag - embree3 - emio - emsdk From 3d1b277af3d27a68813f4c2243bb152ecefe09b0 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 5 Sep 2023 12:03:10 +0200 Subject: [PATCH 0527/1140] (#19561) [docs] Regenerate tables of contents Co-authored-by: conan-center-bot --- docs/developing_recipes_locally.md | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/developing_recipes_locally.md b/docs/developing_recipes_locally.md index 9c54954e8a98d4..f80ba1e6286cb5 100644 --- a/docs/developing_recipes_locally.md +++ b/docs/developing_recipes_locally.md @@ -22,6 +22,7 @@ This file is intended to provide all the commands you need to run in order to be * [Yamlschema](#yamlschema) * [Testing the different `test__package`](#testing-the-different-test__package) * [Testing more environments](#testing-more-environments) + * [Docker build images used by ConanCenterIndex](#docker-build-images-used-by-conancenterindex) * [Using Conan 2.0](#using-conan-20) * [Installing Conan 2.0 beta](#installing-conan-20-beta) * [Trying it out](#trying-it-out) From ae63c81bc9f773dd84cd55e7c6f86faa06e679d7 Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 5 Sep 2023 12:22:37 +0200 Subject: [PATCH 0528/1140] (#19597) [changelog] Add changelog 31-August-2023 --- docs/changelog.md | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/docs/changelog.md b/docs/changelog.md index 8eadac2df61397..1511b584ab7db2 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -2,22 +2,30 @@ ### 01-Sep-2023 - 19:58 CEST -- [fix] Use Unix separators for Windows folder path when creating CI workspace +- [fix] Use Unix separators for Windows folder path when creating CI workspace. -### 17-Aug-2023 - 11:42 CEST +### 31-August-2023 - 12:57 CEST + +- [feature] Support specific PR number for Automatic Merge. +- [feature] Use temporary folder for build workspace. +- [fix] Rename BuildSingleReference folder to bsr to overcome Windows long path. +- [fix] Remove graph info from logs to avoid long loading. +- [fix] Remove deprecated search index for Conan Center. + +### 17-August-2023 - 11:42 CEST - [fix] Fix type error when catching generic exceptions in Jenkins - [fix] Bump dependencies no longer allow version range - [feature] Show recipe revision on the pull-request summary table -### 04-Aug-2023 - 10:26 CEST +### 04-August-2023 - 10:26 CEST - [feature] Enable Conan 2.0.8 - [feature] Enable Conan 1.60.2 - [feature] Update Jenkins server version - [hotfix] Better error management when having CI build timeout -### 19-Jul-2023 - 09:45 CEST +### 19-July-2023 - 09:45 CEST - [fix] Fix message processing if no message is passed. - [fix] Fix automatic merge priority to follow the correct PR order. From cca52d3da5d991bb3253b9adad43b05b8bfab287 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 5 Sep 2023 15:29:55 +0300 Subject: [PATCH 0529/1140] (#18751) uchardet: migrate to Conan v2 * uchardet: migrate to Conan v2 * uchardet: add fix_apple_shared_install_name() * uchardet: move DLLs from lib to bin * uchardet: restore VirtualRunEnv in test_package --- recipes/uchardet/all/CMakeLists.txt | 7 -- recipes/uchardet/all/conanfile.py | 103 ++++++++++-------- .../uchardet/all/test_package/CMakeLists.txt | 6 +- .../uchardet/all/test_package/conanfile.py | 19 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../uchardet/all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 96 insertions(+), 64 deletions(-) delete mode 100644 recipes/uchardet/all/CMakeLists.txt create mode 100644 recipes/uchardet/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/uchardet/all/test_v1_package/conanfile.py diff --git a/recipes/uchardet/all/CMakeLists.txt b/recipes/uchardet/all/CMakeLists.txt deleted file mode 100644 index a17cdee90b0356..00000000000000 --- a/recipes/uchardet/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.12) -project(cmake_wrapper) - -include("conanbuildinfo.cmake") -conan_basic_setup(KEEP_RPATH) - -add_subdirectory("source_subfolder") diff --git a/recipes/uchardet/all/conanfile.py b/recipes/uchardet/all/conanfile.py index bb92e982496c40..6163692ad75f83 100644 --- a/recipes/uchardet/all/conanfile.py +++ b/recipes/uchardet/all/conanfile.py @@ -1,18 +1,27 @@ -from conans import ConanFile, CMake, tools import os -import functools -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, replace_in_file, rmdir, rename + +required_conan_version = ">=1.53.0" class UchardetConan(ConanFile): name = "uchardet" + description = ( + "uchardet is an encoding detector library, which takes a " + "sequence of bytes in an unknown character encoding and " + "attempts to determine the encoding of the text. " + "Returned encoding names are iconv-compatible." + ) + license = "MPL-1.1" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/freedesktop/uchardet" - description = "uchardet is an encoding detector library, which takes a sequence of bytes in an unknown character encoding and attempts to determine the encoding of the text. Returned encoding names are iconv-compatible." - topics = "encoding", "detector" - license = "MPL-1.1" + topics = ("encoding", "detector") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -25,79 +34,77 @@ class UchardetConan(ConanFile): "check_sse2": True, } - exports_sources = ["CMakeLists.txt"] - generators = "cmake", "cmake_find_package" - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) def config_options(self): if self._settings_build not in ("x86", "x86_64"): - del self.options.check_sse2 + self.options.rm_safe("check_sse2") if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CHECK_SSE2"] = self.options.get_safe("check_sse2", False) + tc.variables["BUILD_BINARY"] = False + tc.variables["BUILD_STATIC"] = not self.options.shared + tc.generate() def _patch_sources(self): # the following fixes that apply to uchardet version 0.0.7 # fix broken cmake - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), + replace_in_file( + self, + os.path.join(self.source_folder, "CMakeLists.txt"), "${CMAKE_BINARY_DIR}", - "${CMAKE_CURRENT_BINARY_DIR}") + "${CMAKE_CURRENT_BINARY_DIR}", + ) # fix problem with mac os - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), - 'string(TOLOWER ${CMAKE_SYSTEM_PROCESSOR} TARGET_ARCHITECTURE)', - 'string(TOLOWER "${CMAKE_SYSTEM_PROCESSOR}" TARGET_ARCHITECTURE)') + replace_in_file( + self, + os.path.join(self.source_folder, "CMakeLists.txt"), + "string(TOLOWER ${CMAKE_SYSTEM_PROCESSOR} TARGET_ARCHITECTURE)", + 'string(TOLOWER "${CMAKE_SYSTEM_PROCESSOR}" TARGET_ARCHITECTURE)', + ) # disable building tests - tools.replace_in_file(os.path.join(self._source_subfolder, "CMakeLists.txt"), + replace_in_file( + self, + os.path.join(self.source_folder, "CMakeLists.txt"), "add_subdirectory(test)", - "#add_subdirectory(test)") - - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["CHECK_SSE2"] = self.options.get_safe("check_sse2", False) - cmake.definitions["BUILD_BINARY"] = False - cmake.definitions["BUILD_STATIC"] = False # disable building static libraries when self.options.shared is True - cmake.configure(build_folder=self._build_subfolder) - return cmake + "#add_subdirectory(test)", + ) def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.rmdir(os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) + fix_apple_shared_install_name(self) + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): - self.cpp_info.set_property("cmake_file_name", "uchardet") - self.cpp_info.set_property("cmake_target_name", "uchardet") self.cpp_info.set_property("pkg_config_name", "libuchardet") - - self.cpp_info.names["cmake_find_package"] = "uchardet" - self.cpp_info.names["cmake_find_package_multi"] = "uchardet" - self.cpp_info.names["pkgconfig"] = "libuchardet" self.cpp_info.libs = ["uchardet"] if self.options.shared: self.cpp_info.defines.append("UCHARDET_SHARED") diff --git a/recipes/uchardet/all/test_package/CMakeLists.txt b/recipes/uchardet/all/test_package/CMakeLists.txt index a726e6f66a3bd2..6dbcda3f32f3ca 100644 --- a/recipes/uchardet/all/test_package/CMakeLists.txt +++ b/recipes/uchardet/all/test_package/CMakeLists.txt @@ -1,12 +1,10 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) + set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) set(CMAKE_CXX_EXTENSIONS OFF) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(uchardet REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/uchardet/all/test_package/conanfile.py b/recipes/uchardet/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/uchardet/all/test_package/conanfile.py +++ b/recipes/uchardet/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/uchardet/all/test_v1_package/CMakeLists.txt b/recipes/uchardet/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/uchardet/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/uchardet/all/test_v1_package/conanfile.py b/recipes/uchardet/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/uchardet/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 3d711235cc40263dcbc41b32857aa686a88b54f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 5 Sep 2023 17:42:37 +0200 Subject: [PATCH 0530/1140] (#19588) [docs] Add `zlib` and `libcurl` to the list of allowed version ranges * Add zlib and sqlite3 to the list of allowed verison ranges * Sqlite3 -> libcurl * Swap 2.1 for 1.2, oops --- docs/adding_packages/dependencies.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/docs/adding_packages/dependencies.md b/docs/adding_packages/dependencies.md index a45c6c0f3c31c6..c421b0a9d9f678 100644 --- a/docs/adding_packages/dependencies.md +++ b/docs/adding_packages/dependencies.md @@ -174,15 +174,18 @@ for consumer, we do impose some limits on Conan features to provide a smoother f * [`python_requires`](https://docs.conan.io/1/reference/conanfile/other.html#python-requires) are not allowed. ### Version Ranges - + Version ranges are a useful Conan feature, [documentation here](https://docs.conan.io/2/tutorial/versioning/version_ranges.html). With the introduction of Conan 2.0, we are currently working to allow the use of version ranges and are allowing this for a handful of dependencies. Currently, these are: * OpenSSL: `[>=1.1 <4]` for libraries known to be compatible with OpenSSL 1.x and 3.x -* CMake: `[>3.XX <4]`, where `3.XX` is the minimum version of CMake required by the relevant build scripts. +* CMake: `[>3.XX <4]`, where `3.XX` is the minimum version of CMake required by the relevant build scripts +* Zlib: `[>=1.X.Y <2]`, where `1.X.Y` is the minimum version of Zlib required, starting from `1.2.10` +* Libcurl: `[>=X.YY <9]`, where `X.YY` is the minimum version of Libcurl required, starting from `7.78` + -> **Warning**: With Conan 1.x, [version ranges](https://docs.conan.io/1/versioning/version_ranges.html) adhere to a much more strict sematic version spec, +> **Warning**: With Conan 1.x, [version ranges](https://docs.conan.io/1/versioning/version_ranges.html) adhere to a much more strict sematic version spec, > OpenSSL 1.1.x does not follow this so the client will not resolve to that range and will pick a 3.x version. In order to select a lower version you > can user the defunct `--require-override openssl/1.1.1t@` from the command line, or override from the recipe with `self.requires(openssl/1.1.1t, override=True)` > to ensure a lower version is picked. From 697552e8c3b2e5de83cab85cb83a03005d41886d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 6 Sep 2023 09:42:41 +0200 Subject: [PATCH 0531/1140] (#19585) [bot] Update authorized users list (2023-09-04) --- .c3i/authorized_users.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 40eb28806b2ca8..56fdf9df94977a 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1222,3 +1222,7 @@ authorized_users: - XVilka - DoomHammer - cschreib +- AleksandraVolosevich-TomTom +- p-groarke +- Kalixio +- temap From 226788690ace823b25b1c4581f5e95d9cc116d59 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 6 Sep 2023 17:14:03 +0900 Subject: [PATCH 0532/1140] (#19541) glaze: add version 1.4.1 * glaze: add version 1.4.1 * support LICENCE file name modification * use wildcard on copying license file Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/glaze/all/conandata.yml | 3 +++ recipes/glaze/all/conanfile.py | 2 +- recipes/glaze/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index 31bad0f747cccd..98ea7dc8d11505 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.4.1": + url: "https://github.com/stephenberry/glaze/archive/v1.4.1.tar.gz" + sha256: "fae4188004d383f79225db26e41060aaae9a3eff92da7637aa467749e9590ee6" "1.4.0": url: "https://github.com/stephenberry/glaze/archive/v1.4.0.tar.gz" sha256: "301c831e2476529bfa1ea24d87011186da91644830bdf57e1ed99bc7f6326989" diff --git a/recipes/glaze/all/conanfile.py b/recipes/glaze/all/conanfile.py index 7d6155afba73cc..e7b18eb1c3589d 100644 --- a/recipes/glaze/all/conanfile.py +++ b/recipes/glaze/all/conanfile.py @@ -53,7 +53,7 @@ def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, pattern="LICENSE*", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy( self, pattern="*.hpp", diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index c479b0a04fbd07..73f9b337cba86e 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.4.1": + folder: all "1.4.0": folder: all "1.3.6": From baef5725b50e3bc7fbab413416f19ceffa381dd4 Mon Sep 17 00:00:00 2001 From: xyz1001 Date: Wed, 6 Sep 2023 16:51:31 +0800 Subject: [PATCH 0533/1140] (#19583) fix TRACY_ONLY_IPV4 not work and add new option * fix TRACY_ONLY_IPV4 not work * tracy: add new option for version greater than 0.9 --- recipes/tracy/all/conanfile.py | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/recipes/tracy/all/conanfile.py b/recipes/tracy/all/conanfile.py index bdb852b534295c..a056814ff01654 100644 --- a/recipes/tracy/all/conanfile.py +++ b/recipes/tracy/all/conanfile.py @@ -2,6 +2,7 @@ from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import copy, get, rmdir +from conan.tools.scm import Version import os required_conan_version = ">=1.53.0" @@ -25,7 +26,7 @@ class TracyConan(ConanFile): "no_callstack_inlines": ([True, False], False), "only_localhost": ([True, False], False), "no_broadcast": ([True, False], False), - "only_ipv": ([True, False], False), + "only_ipv4": ([True, False], False), "no_code_transfer": ([True, False], False), "no_context_switch": ([True, False], False), "no_exit": ([True, False], False), @@ -35,6 +36,10 @@ class TracyConan(ConanFile): "no_frame_image": ([True, False], False), "no_system_tracing": ([True, False], False), "delayed_init": ([True, False], False), + "manual_lifetime": ([True, False], False), + "fibers": ([True, False], False), + "no_crash_handler": ([True, False], False), + "timer_fallback": ([True, False], False), } options = { "shared": [True, False], @@ -51,6 +56,17 @@ def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) < "0.9": + self.options.rm_safe("manual_lifetime") + self.options.rm_safe("fibers") + self.options.rm_safe("no_crash_handler") + self.options.rm_safe("timer_fallback") + + del self._tracy_options["manual_lifetime"] + del self._tracy_options["fibers"] + del self._tracy_options["no_crash_handler"] + del self._tracy_options["timer_fallback"] + def configure(self): if self.options.shared: self.options.rm_safe("fPIC") From 87aa601c9f69609c171b8e292e1ff4510044b2ae Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 6 Sep 2023 11:22:24 +0200 Subject: [PATCH 0534/1140] (#19613) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 5cf53d60ba1e6a..7491fb37d05f18 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -668,6 +668,7 @@ required_for_references: - linux-syscall-support - litehtml - llhttp +- llvm-openmp - lmdb - lodepng - log.c @@ -1115,6 +1116,7 @@ required_for_references: - type_safe - tz - ua-nodeset +- uchardet - uni-algo - unicorn - unity From 8b49cbc1ff3983ea12e0d8aa29964e94c0fafbd7 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 6 Sep 2023 18:54:22 +0900 Subject: [PATCH 0535/1140] (#19587) libnghttp2: add version 1.56.0, update boost/1.83.0, remove older versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libnghttp2: add version 1.56.0, update boost/1.83.0 * remove older versions --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libnghttp2/all/conandata.yml | 15 +++------------ recipes/libnghttp2/all/conanfile.py | 8 +++----- recipes/libnghttp2/config.yml | 6 ++---- 3 files changed, 8 insertions(+), 21 deletions(-) diff --git a/recipes/libnghttp2/all/conandata.yml b/recipes/libnghttp2/all/conandata.yml index 16a85daa582800..241b93e58b1d36 100644 --- a/recipes/libnghttp2/all/conandata.yml +++ b/recipes/libnghttp2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.56.0": + url: "https://github.com/nghttp2/nghttp2/archive/v1.56.0.tar.gz" + sha256: "63dd705b524eec3c843b8e4e24914600a30c2804a113e8e5baeeb9695d09590a" "1.55.1": url: "https://github.com/nghttp2/nghttp2/archive/v1.55.1.tar.gz" sha256: "b89dece5bc3382b82c22db8dc8d1e062258cb7af8e4ad55278fa7149645a588d" @@ -23,12 +26,6 @@ sources: "1.48.0": url: "https://github.com/nghttp2/nghttp2/releases/download/v1.48.0/nghttp2-1.48.0.tar.xz" sha256: "47d8f30ee4f1bc621566d10362ca1b3ac83a335c63da7144947c806772d016e4" - "1.47.0": - url: "https://github.com/nghttp2/nghttp2/releases/download/v1.47.0/nghttp2-1.47.0.tar.xz" - sha256: "68271951324554c34501b85190f22f2221056db69f493afc3bbac8e7be21e7cc" - "1.46.0": - url: "https://github.com/nghttp2/nghttp2/releases/download/v1.46.0/nghttp2-1.46.0.tar.xz" - sha256: "1a68cc4a5732afb735baf50aaac3cb3a6771e49f744bd5db6c49ab5042f12a43" patches: "1.49.0": - patch_file: "patches/fix-findJemalloc.cmake" @@ -36,9 +33,3 @@ patches: "1.48.0": - patch_file: "patches/fix-findJemalloc.cmake" - patch_file: "patches/fix-findLibevent.cmake" - "1.47.0": - - patch_file: "patches/fix-findJemalloc.cmake" - - patch_file: "patches/fix-findLibevent.cmake" - "1.46.0": - - patch_file: "patches/fix-findJemalloc.cmake" - - patch_file: "patches/fix-findLibevent.cmake" diff --git a/recipes/libnghttp2/all/conanfile.py b/recipes/libnghttp2/all/conanfile.py index b7976951f311e5..00a7398f662464 100644 --- a/recipes/libnghttp2/all/conanfile.py +++ b/recipes/libnghttp2/all/conanfile.py @@ -15,10 +15,10 @@ class Nghttp2Conan(ConanFile): name = "libnghttp2" description = "HTTP/2 C Library and tools" - topics = ("http", "http2") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://nghttp2.org" - license = "MIT" + topics = ("http", "http2") package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -73,7 +73,7 @@ def requirements(self): if self.options.with_hpack: self.requires("jansson/2.14") if self.options.get_safe("with_asio"): - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def validate(self): if self.options.get_safe("with_asio") and is_msvc(self): @@ -97,8 +97,6 @@ def generate(self): # disable unneeded auto-picked dependencies tc.variables["WITH_LIBXML2"] = False tc.variables["WITH_JEMALLOC"] = self.options.get_safe("with_jemalloc", False) - if Version(self.version) < "1.47.0": - tc.variables["WITH_SPDYLAY"] = False if Version(self.version) < "1.52.0": tc.variables["ENABLE_ASIO_LIB"] = self.options.with_asio if is_apple_os(self): diff --git a/recipes/libnghttp2/config.yml b/recipes/libnghttp2/config.yml index 80c7ccd82ad1ff..1bcc72d765fd28 100644 --- a/recipes/libnghttp2/config.yml +++ b/recipes/libnghttp2/config.yml @@ -1,4 +1,6 @@ versions: + "1.56.0": + folder: all "1.55.1": folder: all "1.55.0": @@ -15,7 +17,3 @@ versions: folder: all "1.48.0": folder: all - "1.47.0": - folder: all - "1.46.0": - folder: all From 4abe94c7417ecf564bf673ef63867581d9b04aef Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 6 Sep 2023 19:53:33 +0900 Subject: [PATCH 0536/1140] (#19590) dacap-clip: add version 1.6, add package_type --- recipes/dacap-clip/all/conandata.yml | 3 +++ recipes/dacap-clip/all/conanfile.py | 17 ++++++++--------- .../dacap-clip/all/test_package/CMakeLists.txt | 4 ++-- recipes/dacap-clip/config.yml | 2 ++ 4 files changed, 15 insertions(+), 11 deletions(-) diff --git a/recipes/dacap-clip/all/conandata.yml b/recipes/dacap-clip/all/conandata.yml index daa1ee060995e7..19103af57600db 100644 --- a/recipes/dacap-clip/all/conandata.yml +++ b/recipes/dacap-clip/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.6": + url: "https://github.com/dacap/clip/archive/refs/tags/v1.6.tar.gz" + sha256: "fc37319775ec1b6a75475b46696f5014418d90676359b96b894f646241dcbb7e" "1.5": url: "https://github.com/dacap/clip/archive/refs/tags/v1.5.tar.gz" sha256: "8f6f8a427075a09011fafbb75bfdbf1213e4492a13cff4a70975aab361c99382" diff --git a/recipes/dacap-clip/all/conanfile.py b/recipes/dacap-clip/all/conanfile.py index e2bd672a9b3d1b..c4021d403c55f7 100644 --- a/recipes/dacap-clip/all/conanfile.py +++ b/recipes/dacap-clip/all/conanfile.py @@ -8,7 +8,7 @@ from conan.tools.apple import is_apple_os from conan.tools.build import check_min_cppstd -required_conan_version = ">=1.51.3" +required_conan_version = ">=1.53.0" class DacapClipConan(ConanFile): name = "dacap-clip" @@ -17,6 +17,7 @@ class DacapClipConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/dacap/clip/" topics = ("clipboard", "copy", "paste") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -29,8 +30,9 @@ class DacapClipConan(ConanFile): "with_png": True, } - def export_sources(self): - copy(self, "CMakeLists.txt", self.recipe_folder, self.export_sources_folder) + @property + def _min_cppstd(self): + return 11 def config_options(self): if self.settings.os == "Windows": @@ -38,10 +40,7 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass + self.options.rm_safe("fPIC") if self.settings.os not in ["Linux", "FreeBSD"]: del self.options.with_png @@ -56,12 +55,12 @@ def requirements(self): def validate(self): if self.info.settings.compiler.cppstd: - check_min_cppstd(self, 11) + check_min_cppstd(self, self._min_cppstd) if is_msvc(self) and self.info.settings.build_type == "Debug" and self.info.options.shared == True: raise ConanInvalidConfiguration(f"{self.ref} doesn't support MSVC debug shared build (now).") def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root=True, destination=self.source_folder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): toolchain = CMakeToolchain(self) diff --git a/recipes/dacap-clip/all/test_package/CMakeLists.txt b/recipes/dacap-clip/all/test_package/CMakeLists.txt index 63e11b22a301b2..39137234722695 100644 --- a/recipes/dacap-clip/all/test_package/CMakeLists.txt +++ b/recipes/dacap-clip/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.8) -project(test_package CXX) +project(test_package LANGUAGES CXX) find_package(clip REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} clip::clip) +target_link_libraries(${PROJECT_NAME} PRIVATE clip::clip) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/dacap-clip/config.yml b/recipes/dacap-clip/config.yml index 84f49b28508708..68f5d1fe1295a3 100644 --- a/recipes/dacap-clip/config.yml +++ b/recipes/dacap-clip/config.yml @@ -1,3 +1,5 @@ versions: + "1.6": + folder: "all" "1.5": folder: "all" From 7e6490b82ccd324d4856c8ca617dbc151436ca3c Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 6 Sep 2023 20:31:22 +0900 Subject: [PATCH 0537/1140] (#19595) libtins: add version 4.5, update boost --- recipes/libtins/all/conandata.yml | 3 +++ recipes/libtins/all/conanfile.py | 4 ++-- recipes/libtins/all/test_package/CMakeLists.txt | 2 +- recipes/libtins/config.yml | 2 ++ 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/recipes/libtins/all/conandata.yml b/recipes/libtins/all/conandata.yml index d565c818eeabe6..ee42178c90b269 100644 --- a/recipes/libtins/all/conandata.yml +++ b/recipes/libtins/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.5": + url: "https://github.com/mfontanini/libtins/archive/v4.5.tar.gz" + sha256: "6ff5fe1ada10daef8538743dccb9c9b3e19d05d028ffdc24838e62ff3fc55841" "4.4": url: "https://github.com/mfontanini/libtins/archive/v4.4.tar.gz" sha256: "ff0121b4ec070407e29720c801b7e1a972042300d37560a62c57abadc9635634" diff --git a/recipes/libtins/all/conanfile.py b/recipes/libtins/all/conanfile.py index 7bca8b98f2ebbd..d5656f7267688e 100644 --- a/recipes/libtins/all/conanfile.py +++ b/recipes/libtins/all/conanfile.py @@ -3,7 +3,7 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, replace_in_file, rm, rmdir +from conan.tools.files import copy, get, rm, rmdir required_conan_version = ">=1.53.0" @@ -63,7 +63,7 @@ def requirements(self): # Used in two public headers: # - https://github.com/mfontanini/libtins/blob/v4.4/include/tins/tcp_ip/ack_tracker.h#L38 # - https://github.com/mfontanini/libtins/blob/v4.4/include/tins/tcp_ip/stream.h#L48 - self.requires("boost/1.81.0", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) if self.options.with_wpa2: self.requires("openssl/[>=1.1 <4]") diff --git a/recipes/libtins/all/test_package/CMakeLists.txt b/recipes/libtins/all/test_package/CMakeLists.txt index 94a84063fcb9ff..9df74f0fcf532f 100644 --- a/recipes/libtins/all/test_package/CMakeLists.txt +++ b/recipes/libtins/all/test_package/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.15) -project(test_package CXX) +project(test_package LANGUAGES CXX) find_package(libtins REQUIRED CONFIG) diff --git a/recipes/libtins/config.yml b/recipes/libtins/config.yml index ce55c187fafe1c..a962f30c14fe9e 100644 --- a/recipes/libtins/config.yml +++ b/recipes/libtins/config.yml @@ -1,4 +1,6 @@ versions: + "4.5": + folder: all "4.4": folder: all "4.3": From a558cc01d606fbdcc89d6a80c49463cead05cd82 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 6 Sep 2023 15:06:07 +0300 Subject: [PATCH 0538/1140] (#18196) avahi: add package_type, set cmake_target_name, pkg_config_name * avahi: add package_type, set cmake_target_name, pkg_config_name * avahi: restore test_v1_package * avahi: bump deps * avahi: remove redundant cmake_target_name for components * avahi: improve os detection * avahi: bump deps * fix conan 2 --------- Co-authored-by: ericLemanissier --- recipes/avahi/all/conanfile.py | 46 ++++++++++--------- recipes/avahi/all/test_package/CMakeLists.txt | 2 +- .../avahi/all/test_v1_package/CMakeLists.txt | 2 +- 3 files changed, 27 insertions(+), 23 deletions(-) diff --git a/recipes/avahi/all/conanfile.py b/recipes/avahi/all/conanfile.py index 828f628b5ac414..a5da3d9b034e37 100644 --- a/recipes/avahi/all/conanfile.py +++ b/recipes/avahi/all/conanfile.py @@ -1,7 +1,8 @@ import os from conan import ConanFile -from conan.tools.env import Environment, VirtualBuildEnv +from conan.tools.build import can_run +from conan.tools.env import Environment, VirtualBuildEnv, VirtualRunEnv from conan.tools.files import copy, get, rmdir, rm from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain, PkgConfigDeps from conan.tools.layout import basic_layout @@ -19,42 +20,43 @@ class AvahiConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/lathiat/avahi" license = "LGPL-2.1-only" - settings = "os", "arch", "compiler", "build_type" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False] + "fPIC": [True, False], } default_options = { "shared": False, - "fPIC": True + "fPIC": True, } + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glib/2.75.2") + self.requires("glib/2.77.1") self.requires("expat/2.5.0") self.requires("libdaemon/0.14") - self.requires("dbus/1.15.2") - self.requires("gdbm/1.19") + self.requires("dbus/1.15.6") + self.requires("gdbm/1.23") self.requires("libevent/2.1.12") - def build_requirements(self): - self.tool_requires("glib/2.75.2") - if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") - def validate(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration(f"{self.ref} only supports Linux.") - def configure(self): - if self.options.shared: - self.options.rm_safe("fPIC") - self.settings.rm_safe("compiler.cppstd") - self.settings.rm_safe("compiler.libcxx") + def build_requirements(self): + self.tool_requires("glib/") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -62,6 +64,8 @@ def source(self): def generate(self): virtual_build_env = VirtualBuildEnv(self) virtual_build_env.generate() + if can_run(self): + VirtualRunEnv(self).generate(scope="build") tc = AutotoolsToolchain(self) tc.configure_args.append("--enable-compat-libdns_sd") tc.configure_args.append("--disable-gtk3") @@ -70,7 +74,7 @@ def generate(self): tc.configure_args.append("--disable-python") tc.configure_args.append("--disable-qt5") tc.configure_args.append("--with-systemdsystemunitdir=/lib/systemd/system") - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: tc.configure_args.append("ac_cv_func_setproctitle=no") tc.generate() AutotoolsDeps(self).generate() @@ -98,9 +102,9 @@ def package(self): def package_info(self): for lib in ("client", "common", "core", "glib", "gobject", "libevent", "compat-libdns_sd"): avahi_lib = f"avahi-{lib}" + self.cpp_info.components[lib].set_property("pkg_config_name", avahi_lib) self.cpp_info.components[lib].names["cmake_find_package"] = lib self.cpp_info.components[lib].names["cmake_find_package_multi"] = lib - self.cpp_info.components[lib].names["pkg_config"] = avahi_lib self.cpp_info.components[lib].libs = [avahi_lib] self.cpp_info.components[lib].includedirs = [os.path.join("include", avahi_lib)] self.cpp_info.components["compat-libdns_sd"].libs = ["dns_sd"] @@ -115,9 +119,9 @@ def package_info(self): for app in ("autoipd", "browse", "daemon", "dnsconfd", "publish", "resolve", "set-host-name"): avahi_app = f"avahi-{app}" + self.cpp_info.components[app].set_property("pkg_config_name", avahi_app) self.cpp_info.components[app].names["cmake_find_package"] = app self.cpp_info.components[app].names["cmake_find_package_multi"] = app - self.cpp_info.components[app].names["pkg_config"] = avahi_app self.cpp_info.components["autoipd"].requires = ["libdaemon::libdaemon"] self.cpp_info.components["browse"].requires = ["client", "gdbm::gdbm"] diff --git a/recipes/avahi/all/test_package/CMakeLists.txt b/recipes/avahi/all/test_package/CMakeLists.txt index fce015c3405a96..a844c8e02eaa3a 100644 --- a/recipes/avahi/all/test_package/CMakeLists.txt +++ b/recipes/avahi/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(Avahi CONFIG REQUIRED) diff --git a/recipes/avahi/all/test_v1_package/CMakeLists.txt b/recipes/avahi/all/test_v1_package/CMakeLists.txt index 925ecbe19e448d..91630d79f4abb3 100644 --- a/recipes/avahi/all/test_v1_package/CMakeLists.txt +++ b/recipes/avahi/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) From a1f99f3aa7308ff4f94a44780c40237c2d106851 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 6 Sep 2023 15:27:46 +0300 Subject: [PATCH 0539/1140] (#18691) libb2: migrate to Conan v2 * libb2: migrate to Conan v2 * libb2: move DLLs from lib to bin * libb2: restore VirtualRunEnv in test_package --- recipes/libb2/all/CMakeLists.txt | 52 +++++----- recipes/libb2/all/conanfile.py | 96 +++++++++++-------- recipes/libb2/all/test_package/CMakeLists.txt | 7 +- recipes/libb2/all/test_package/conanfile.py | 24 +++-- .../libb2/all/test_v1_package/CMakeLists.txt | 8 ++ .../libb2/all/test_v1_package/conanfile.py | 16 ++++ 6 files changed, 126 insertions(+), 77 deletions(-) create mode 100644 recipes/libb2/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libb2/all/test_v1_package/conanfile.py diff --git a/recipes/libb2/all/CMakeLists.txt b/recipes/libb2/all/CMakeLists.txt index ba9b7e9e279482..ff47fce826321a 100644 --- a/recipes/libb2/all/CMakeLists.txt +++ b/recipes/libb2/all/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.12) project(b2 C) -include("conanbuildinfo.cmake") -conan_basic_setup() - if(WIN32 AND BUILD_SHARED_LIBS AND MSVC) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() @@ -11,38 +8,37 @@ endif() option(USE_SSE "Optimized for speed on CPUs supporting SSE2, SSSE3, SSE4.1, AVX, or XOP" OFF) option(USE_NEON "Optimiced for arm CPUs" OFF) +set(src ${CMAKE_CURRENT_LIST_DIR}/src) + if (USE_NEON) message(STATUS "Using neon sources") - set(SOURCE_FILES source_subfolder/neon/blake2b-neon.c - source_subfolder/neon/blake2bp.c - source_subfolder/neon/blake2s-neon.c - source_subfolder/neon/blake2xb.c - source_subfolder/neon/blake2sp.c - source_subfolder/neon/blake2xs.c) + set(SOURCE_FILES ${src}/neon/blake2b-neon.c + ${src}/neon/blake2bp.c + ${src}/neon/blake2s-neon.c + ${src}/neon/blake2xb.c + ${src}/neon/blake2sp.c + ${src}/neon/blake2xs.c) elseif (USE_SSE) message(STATUS "Using sse sources") - set(SOURCE_FILES source_subfolder/sse/blake2b.c - source_subfolder/sse/blake2bp.c - source_subfolder/sse/blake2s.c - source_subfolder/sse/blake2sp.c - source_subfolder/sse/blake2xb.c - source_subfolder/sse/blake2xs.c) + set(SOURCE_FILES ${src}/sse/blake2b.c + ${src}/sse/blake2bp.c + ${src}/sse/blake2s.c + ${src}/sse/blake2sp.c + ${src}/sse/blake2xb.c + ${src}/sse/blake2xs.c) else () message(STATUS "Using ref sources") - set(SOURCE_FILES source_subfolder/ref/blake2bp-ref.c - source_subfolder/ref/blake2b-ref.c - source_subfolder/ref/blake2sp-ref.c - source_subfolder/ref/blake2s-ref.c - source_subfolder/ref/blake2xb-ref.c - source_subfolder/ref/blake2xs-ref.c) + set(SOURCE_FILES ${src}/ref/blake2bp-ref.c + ${src}/ref/blake2b-ref.c + ${src}/ref/blake2sp-ref.c + ${src}/ref/blake2s-ref.c + ${src}/ref/blake2xb-ref.c + ${src}/ref/blake2xs-ref.c) endif() add_library(${CMAKE_PROJECT_NAME} ${SOURCE_FILES}) -set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES PUBLIC_HEADER source_subfolder/ref/blake2.h) +set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES PUBLIC_HEADER ${src}/ref/blake2.h) +include(GNUInstallDirs) install(TARGETS ${CMAKE_PROJECT_NAME} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libb2 - ) + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libb2) diff --git a/recipes/libb2/all/conanfile.py b/recipes/libb2/all/conanfile.py index 88ad67891d73b3..faf2474da04c45 100644 --- a/recipes/libb2/all/conanfile.py +++ b/recipes/libb2/all/conanfile.py @@ -1,65 +1,85 @@ import os -import glob -from conans import ConanFile, tools, CMake -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rename + +required_conan_version = ">=1.53.0" + class libb2Conan(ConanFile): name = "libb2" + description = ( + "libb2 is a library that implements the BLAKE2 cryptographic hash function, which is faster than MD5, " + "SHA-1, SHA-2, and SHA-3, yet is at least as secure as the latest standard SHA-3" + ) license = ["CC0-1.0", "OpenSSL", "APSL-2.0"] url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/BLAKE2/BLAKE2" - description = ("libb2 is a library that implemets the BLAKE2 cryptographic hash function, which is faster than MD5, \ - SHA-1, SHA-2, and SHA-3, yet is at least as secure as the latest standard SHA-3") + topics = ("blake2", "hash") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" - topics = ("conan", "blake2", "hash") - exports_sources = ["CMakeLists.txt"] - generators = ["cmake"] - options = {"fPIC": [True, False], "shared": [True, False], "use_sse": [True, False], "use_neon": [True, False]} - default_options = {"fPIC": True, "shared": False, "use_sse": False, "use_neon": False} - _cmake = None + options = { + "shared": [True, False], + "fPIC": [True, False], + "use_sse": [True, False], + "use_neon": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + "use_sse": False, + "use_neon": False, + } - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) - @property - def _build_subfolder(self): - return "build_subfolder" + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, 11) if self.options.use_neon and not "arm" in self.settings.arch: raise ConanInvalidConfiguration("Neon sources only supported on arm-based CPUs") if self.options.use_neon and self.options.use_sse: raise ConanInvalidConfiguration("Neon and SSE can not be used together.") - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob("BLAKE2-*")[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if not self._cmake: - self._cmake = CMake(self) - self._cmake.definitions["USE_SSE"] = self.options.use_sse - self._cmake.definitions["USE_NEON"] = self.options.use_neon - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["USE_SSE"] = self.options.use_sse + tc.variables["USE_NEON"] = self.options.use_neon + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - self.cpp_info.includedirs = ["include", os.path.join("include","libb2")] + self.cpp_info.libs = ["b2"] + self.cpp_info.includedirs = ["include", os.path.join("include", "libb2")] diff --git a/recipes/libb2/all/test_package/CMakeLists.txt b/recipes/libb2/all/test_package/CMakeLists.txt index 6aab347eddf535..a422f3ac0c116e 100644 --- a/recipes/libb2/all/test_package/CMakeLists.txt +++ b/recipes/libb2/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libb2 REQUIRED CONFIG) add_executable(example example.cpp) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example libb2::libb2) set_property(TARGET example PROPERTY CXX_STANDARD 11) diff --git a/recipes/libb2/all/test_package/conanfile.py b/recipes/libb2/all/test_package/conanfile.py index 0383b1729b0649..8d52b7021efe14 100644 --- a/recipes/libb2/all/test_package/conanfile.py +++ b/recipes/libb2/all/test_package/conanfile.py @@ -1,9 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class blake2TestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/libb2/all/test_v1_package/CMakeLists.txt b/recipes/libb2/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libb2/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libb2/all/test_v1_package/conanfile.py b/recipes/libb2/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..24ecc57793dc6f --- /dev/null +++ b/recipes/libb2/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +import os +from conans import ConanFile, CMake, tools + +class blake2TestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From 39bad72319fefa39fb1b7b8d1db201a12ffb241c Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 6 Sep 2023 15:05:24 +0200 Subject: [PATCH 0540/1140] (#17125) aws-sdk-cpp: conan v2 support * conan v2 support * use rm_safe to delete s3-crt option * use cache_variables * use preprocessor_definitions * aws-c-event-stream is always a direct dependency * disable warnings as errors * aws-checksums is a direct dependency * restore compatible versions of dependencies * restore cmake_minimum_required to satisfy stupid hook * fix build_modules * fix requires in package_info() * fix pulseaudio detection * Add missing transitive headers, fix cmake modules * use version range for openssl * bump libcurl * add version range for libcurl --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/aws-sdk-cpp/all/CMakeLists.txt | 11 - recipes/aws-sdk-cpp/all/conandata.yml | 38 ++-- recipes/aws-sdk-cpp/all/conanfile.py | 203 ++++++++++-------- ...30-0004-improve-pulseaudio-detection.patch | 2 +- .../all/test_package/CMakeLists.txt | 11 +- .../aws-sdk-cpp-plugin/CMakeLists.txt | 4 +- .../aws-sdk-cpp/all/test_package/conanfile.py | 19 +- .../all/test_v1_package/CMakeLists.txt | 8 + .../all/test_v1_package/conanfile.py | 17 ++ 9 files changed, 171 insertions(+), 142 deletions(-) delete mode 100644 recipes/aws-sdk-cpp/all/CMakeLists.txt create mode 100644 recipes/aws-sdk-cpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/aws-sdk-cpp/all/test_v1_package/conanfile.py diff --git a/recipes/aws-sdk-cpp/all/CMakeLists.txt b/recipes/aws-sdk-cpp/all/CMakeLists.txt deleted file mode 100644 index d19ff91050d959..00000000000000 --- a/recipes/aws-sdk-cpp/all/CMakeLists.txt +++ /dev/null @@ -1,11 +0,0 @@ -cmake_minimum_required(VERSION 3.5) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -if(MSVC) - add_definitions(-D_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING) -endif() - -add_subdirectory(source_subfolder) diff --git a/recipes/aws-sdk-cpp/all/conandata.yml b/recipes/aws-sdk-cpp/all/conandata.yml index 8abd96ad2e0be1..5818aef791db03 100644 --- a/recipes/aws-sdk-cpp/all/conandata.yml +++ b/recipes/aws-sdk-cpp/all/conandata.yml @@ -10,29 +10,19 @@ sources: sha256: "5dd09baa28d3f6f4fb03fbba1a4269724d79bcca3d47752cd3e15caf97276bda" patches: "1.9.234": - - base_path: source_subfolder - patch_file: patches/1.9.234-0001-issue-1816.patch - - base_path: source_subfolder - patch_file: patches/1.9.234-0002-disable-sort-links.patch - - base_path: source_subfolder - patch_file: patches/1.9.100-0002-aws-plugin-conf.patch + - patch_file: patches/1.9.234-0001-issue-1816.patch + - patch_file: patches/1.9.234-0002-disable-sort-links.patch + - patch_file: patches/1.9.100-0002-aws-plugin-conf.patch + - patch_file: patches/1.8.130-0004-improve-pulseaudio-detection.patch "1.9.100": - - base_path: source_subfolder - patch_file: patches/1.9.100-0001-disable-sort-links.patch - - base_path: source_subfolder - patch_file: patches/1.9.100-0002-aws-plugin-conf.patch - - base_path: source_subfolder - patch_file: patches/1.9.100-0003-issue-1816.patch + - patch_file: patches/1.9.100-0001-disable-sort-links.patch + - patch_file: patches/1.9.100-0002-aws-plugin-conf.patch + - patch_file: patches/1.9.100-0003-issue-1816.patch + - patch_file: patches/1.8.130-0004-improve-pulseaudio-detection.patch "1.8.130": - - base_path: source_subfolder - patch_file: patches/1.8.130-0001-disable-sort-links.patch - - base_path: source_subfolder - patch_file: patches/1.8.130-0002-force-archive-directory-to-library-directory.patch - - base_path: source_subfolder - patch_file: patches/1.8.130-0003-disable-cmake-install-rpath-use-link-path.patch - - base_path: source_subfolder - patch_file: patches/1.8.130-0004-improve-pulseaudio-detection.patch - - base_path: source_subfolder - patch_file: patches/1.8.130-0005-aws-plugin-conf.patch - - base_path: source_subfolder - patch_file: patches/1.8.130-0006-issue-1816.patch + - patch_file: patches/1.8.130-0001-disable-sort-links.patch + - patch_file: patches/1.8.130-0002-force-archive-directory-to-library-directory.patch + - patch_file: patches/1.8.130-0003-disable-cmake-install-rpath-use-link-path.patch + - patch_file: patches/1.8.130-0004-improve-pulseaudio-detection.patch + - patch_file: patches/1.8.130-0005-aws-plugin-conf.patch + - patch_file: patches/1.8.130-0006-issue-1816.patch diff --git a/recipes/aws-sdk-cpp/all/conanfile.py b/recipes/aws-sdk-cpp/all/conanfile.py index 91c2066868882a..678d3e32eb8c95 100644 --- a/recipes/aws-sdk-cpp/all/conanfile.py +++ b/recipes/aws-sdk-cpp/all/conanfile.py @@ -1,11 +1,14 @@ import os -from conan.tools.files import rename -from conan.tools.microsoft import msvc_runtime_flag -from conans import CMake, ConanFile, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import cross_building, stdcpp_library +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rename, replace_in_file, rm, rmdir +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +from conan.tools.scm import Version -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.54.0" class AwsSdkCppConan(ConanFile): @@ -15,7 +18,7 @@ class AwsSdkCppConan(ConanFile): homepage = "https://github.com/aws/aws-sdk-cpp" description = "AWS SDK for C++" topics = ("aws", "cpp", "cross-platform", "amazon", "cloud") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" _sdks = ( "access-management", @@ -304,17 +307,7 @@ class AwsSdkCppConan(ConanFile): default_options["transfer"] = True default_options["text-to-speech"] = True - generators = "cmake", "cmake_find_package" short_paths = True - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _is_msvc(self): - return str(self.settings.compiler) in ["Visual Studio", "msvc"] @property def _internal_requirements(self): @@ -329,35 +322,36 @@ def _internal_requirements(self): @property def _use_aws_crt_cpp(self): - return tools.Version(self.version) >= "1.9" + return Version(self.version) >= "1.9" def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - if tools.Version(self.version) < "1.9": - delattr(self.options, "s3-crt") + if Version(self.version) < "1.9": + self.options.rm_safe("s3-crt") def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): - self.requires("aws-c-common/0.6.19") + self.requires("aws-c-common/0.8.2") + self.requires("aws-c-event-stream/0.2.7") + self.requires("aws-checksums/0.1.13") if self._use_aws_crt_cpp: self.requires("aws-c-cal/0.5.13") self.requires("aws-c-http/0.6.13") self.requires("aws-c-io/0.10.20") - self.requires("aws-crt-cpp/0.17.23") - else: - self.requires("aws-c-event-stream/0.2.7") + self.requires("aws-crt-cpp/0.17.23", transitive_headers=True) if self.settings.os != "Windows": - self.requires("openssl/1.1.1n") - self.requires("libcurl/7.80.0") + self.requires("openssl/[>=1.1 <4]") + self.requires("libcurl/[>=7.78.0 <9]") if self.settings.os in ["Linux", "FreeBSD"]: if self.options.get_safe("text-to-speech"): self.requires("pulseaudio/14.2") @@ -365,21 +359,21 @@ def requirements(self): def validate(self): if (self.options.shared and self.settings.compiler == "gcc" - and tools.Version(self.settings.compiler.version) < "6.0"): + and Version(self.settings.compiler.version) < "6.0"): raise ConanInvalidConfiguration( "Doesn't support gcc5 / shared. " "See https://github.com/conan-io/conan-center-index/pull/4401#issuecomment-802631744" ) - if (tools.Version(self.version) < "1.9.234" + if (Version(self.version) < "1.9.234" and self.settings.compiler == "gcc" - and tools.Version(self.settings.compiler.version) >= "11.0" + and Version(self.settings.compiler.version) >= "11.0" and self.settings.build_type == "Release"): raise ConanInvalidConfiguration( "Versions prior to 1.9.234 don't support release builds on >= gcc 11 " "See https://github.com/aws/aws-sdk-cpp/issues/1505" ) if self._use_aws_crt_cpp: - if self._is_msvc and "MT" in msvc_runtime_flag(self): + if is_msvc(self) and is_msvc_static_runtime(self): raise ConanInvalidConfiguration("Static runtime is not working for more recent releases") else: if self.settings.os == "Macos" and self.settings.arch == "armv8": @@ -390,48 +384,60 @@ def validate(self): def package_id(self): for hl_comp in self._internal_requirements.keys(): - if getattr(self.options, hl_comp): + if getattr(self.info.options, hl_comp): for internal_requirement in self._internal_requirements[hl_comp]: setattr(self.info.options, internal_requirement, True) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) + def generate(self): + tc = CMakeToolchain(self) + # All option() are defined before project() in upstream CMakeLists, + # therefore we must use cache_variables build_only = ["core"] for sdk in self._sdks: if self.options.get_safe(sdk): build_only.append(sdk) - self._cmake.definitions["BUILD_ONLY"] = ";".join(build_only) + tc.cache_variables["BUILD_ONLY"] = ";".join(build_only) - self._cmake.definitions["ENABLE_UNITY_BUILD"] = True - self._cmake.definitions["ENABLE_TESTING"] = False - self._cmake.definitions["AUTORUN_UNIT_TESTS"] = False - self._cmake.definitions["BUILD_DEPS"] = False + tc.cache_variables["ENABLE_UNITY_BUILD"] = True + tc.cache_variables["ENABLE_TESTING"] = False + tc.cache_variables["AUTORUN_UNIT_TESTS"] = False + tc.cache_variables["BUILD_DEPS"] = False if self.settings.os != "Windows": - self._cmake.definitions["ENABLE_OPENSSL_ENCRYPTION"] = True - - self._cmake.definitions["MINIMIZE_SIZE"] = self.options.min_size - if self._is_msvc and not self._use_aws_crt_cpp: - self._cmake.definitions["FORCE_SHARED_CRT"] = "MD" in msvc_runtime_flag(self) - - if tools.cross_building(self): - self._cmake.definitions["CURL_HAS_H2_EXITCODE"] = "0" - self._cmake.definitions["CURL_HAS_H2_EXITCODE__TRYRUN_OUTPUT"] = "" - self._cmake.definitions["CURL_HAS_TLS_PROXY_EXITCODE"] = "0" - self._cmake.definitions["CURL_HAS_TLS_PROXY_EXITCODE__TRYRUN_OUTPUT"] = "" - self._cmake.configure() - return self._cmake + tc.cache_variables["ENABLE_OPENSSL_ENCRYPTION"] = True + + tc.cache_variables["MINIMIZE_SIZE"] = self.options.min_size + if is_msvc(self) and not self._use_aws_crt_cpp: + tc.cache_variables["FORCE_SHARED_CRT"] = not is_msvc_static_runtime(self) + + if cross_building(self): + tc.cache_variables["CURL_HAS_H2_EXITCODE"] = "0" + tc.cache_variables["CURL_HAS_H2_EXITCODE__TRYRUN_OUTPUT"] = "" + tc.cache_variables["CURL_HAS_TLS_PROXY_EXITCODE"] = "0" + tc.cache_variables["CURL_HAS_TLS_PROXY_EXITCODE__TRYRUN_OUTPUT"] = "" + if is_msvc(self): + tc.preprocessor_definitions["_SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING"] = "1" + tc.cache_variables["BUILD_SHARED_LIBS"] = self.options.shared + tc.generate() + + deps = CMakeDeps(self) + deps.generate() + + def _patch_sources(self): + apply_conandata_patches(self) + # Disable warnings as errors + replace_in_file( + self, os.path.join(self.source_folder, "cmake", "compiler_settings.cmake"), + 'list(APPEND AWS_COMPILER_WARNINGS "-Wall" "-Werror" "-pedantic" "-Wextra")', "", + ) def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + self._patch_sources() + cmake = CMake(self) + cmake.configure() cmake.build() @property @@ -449,44 +455,56 @@ def _create_project_cmake_module(self): "toolchains/pkg-config.pc.in", "aws-cpp-sdk-core/include/aws/core/VersionConfig.h" ]: - self.copy(file, src=self._source_subfolder, dst=self._res_folder) - tools.replace_in_file(os.path.join(self.package_folder, self._res_folder, file), "CMAKE_CURRENT_SOURCE_DIR", "AWS_NATIVE_SDK_ROOT", strict=False) + copy(self, file, src=self.source_folder, dst=os.path.join(self.package_folder, self._res_folder)) + replace_in_file( + self, os.path.join(self.package_folder, self._res_folder, file), + "CMAKE_CURRENT_SOURCE_DIR", "AWS_NATIVE_SDK_ROOT", + strict=False, + ) # avoid getting error from hook - with tools.chdir(os.path.join(self.package_folder, self._res_folder)): - rename(self, os.path.join("toolchains", "cmakeProjectConfig.cmake"), os.path.join("toolchains", "cmakeProjectConf.cmake")) - tools.replace_in_file(os.path.join("cmake", "utilities.cmake"), "cmakeProjectConfig.cmake", "cmakeProjectConf.cmake") + rename(self, os.path.join(self.package_folder, self._res_folder, "toolchains", "cmakeProjectConfig.cmake"), + os.path.join(self.package_folder, self._res_folder, "toolchains", "cmakeProjectConf.cmake")) + replace_in_file( + self, os.path.join(self.package_folder, self._res_folder, "cmake", "utilities.cmake"), + "cmakeProjectConfig.cmake", "cmakeProjectConf.cmake", + ) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - if self._is_msvc: - self.copy(pattern="*.lib", dst="lib", keep_path=False) - tools.remove_files_by_mask(os.path.join(self.package_folder, "bin"), "*.lib") + if is_msvc(self): + copy(self, "*.lib", src=self.build_folder, dst=os.path.join(self.package_folder, "lib"), keep_path=False) + rm(self, "*.lib", os.path.join(self.package_folder, "bin")) - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) self._create_project_cmake_module() def package_info(self): self.cpp_info.set_property("cmake_file_name", "AWSSDK") + sdk_plugin_conf = os.path.join(self._res_folder, "cmake", "sdk_plugin_conf.cmake") + self.cpp_info.set_property("cmake_build_modules", [sdk_plugin_conf]) + # core component self.cpp_info.components["core"].set_property("cmake_target_name", "AWS::aws-sdk-cpp-core") self.cpp_info.components["core"].set_property("pkg_config_name", "aws-sdk-cpp-core") self.cpp_info.components["core"].libs = ["aws-cpp-sdk-core"] - self.cpp_info.components["core"].requires = ["aws-c-common::aws-c-common-lib"] + self.cpp_info.components["core"].requires = [ + "aws-c-common::aws-c-common", + "aws-c-event-stream::aws-c-event-stream", + "aws-checksums::aws-checksums", + ] if self._use_aws_crt_cpp: self.cpp_info.components["core"].requires.extend([ - "aws-c-cal::aws-c-cal-lib", - "aws-c-http::aws-c-http-lib", - "aws-c-io::aws-c-io-lib", - "aws-crt-cpp::aws-crt-cpp-lib", + "aws-c-cal::aws-c-cal", + "aws-c-http::aws-c-http", + "aws-c-io::aws-c-io", + "aws-crt-cpp::aws-crt-cpp", ]) - else: - self.cpp_info.components["core"].requires.append("aws-c-event-stream::aws-c-event-stream-lib") # other components enabled_sdks = [sdk for sdk in self._sdks if self.options.get_safe(sdk)] @@ -500,8 +518,8 @@ def package_info(self): # TODO: there is no way to properly emulate COMPONENTS names for # find_package(AWSSDK COMPONENTS ) in set_property() # right now: see https://github.com/conan-io/conan/issues/10258 - self.cpp_info.components[sdk].set_property("cmake_target_name", "AWS::aws-sdk-cpp-{}".format(sdk)) - self.cpp_info.components[sdk].set_property("pkg_config_name", "aws-sdk-cpp-{}".format(sdk)) + self.cpp_info.components[sdk].set_property("cmake_target_name", f"AWS::aws-sdk-cpp-{sdk}") + self.cpp_info.components[sdk].set_property("pkg_config_name", f"aws-sdk-cpp-{sdk}") self.cpp_info.components[sdk].requires = ["core"] if sdk in self._internal_requirements: self.cpp_info.components[sdk].requires.extend(self._internal_requirements[sdk]) @@ -510,7 +528,7 @@ def package_info(self): # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.components[sdk].names["cmake_find_package"] = "aws-sdk-cpp-" + sdk self.cpp_info.components[sdk].names["cmake_find_package_multi"] = "aws-sdk-cpp-" + sdk - component_alias = "aws-sdk-cpp-{}_alias".format(sdk) # to emulate COMPONENTS names for find_package() + component_alias = f"aws-sdk-cpp-{sdk}_alias" # to emulate COMPONENTS names for find_package() self.cpp_info.components[component_alias].names["cmake_find_package"] = sdk self.cpp_info.components[component_alias].names["cmake_find_package_multi"] = sdk self.cpp_info.components[component_alias].requires = [sdk] @@ -534,9 +552,14 @@ def package_info(self): if self.options.get_safe("text-to-speech"): self.cpp_info.components["text-to-speech"].frameworks.append("CoreAudio") - lib_stdcpp = tools.stdcpp_library(self) - if lib_stdcpp: - self.cpp_info.components["core"].system_libs.append(lib_stdcpp) + libcxx = stdcpp_library(self) + if libcxx: + self.cpp_info.components["core"].system_libs.append(libcxx) + + self.cpp_info.components["plugin_scripts"].requires = ["core"] + self.cpp_info.components["plugin_scripts"].builddirs.extend([ + os.path.join(self._res_folder, "cmake"), + os.path.join(self._res_folder, "toolchains")]) # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "AWSSDK" @@ -545,9 +568,5 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "AWS" self.cpp_info.components["core"].names["cmake_find_package"] = "aws-sdk-cpp-core" self.cpp_info.components["core"].names["cmake_find_package_multi"] = "aws-sdk-cpp-core" - - self.cpp_info.components["plugin_scripts"].requires = ["core"] - self.cpp_info.components["plugin_scripts"].builddirs.extend([ - os.path.join(self._res_folder, "cmake"), - os.path.join(self._res_folder, "toolchains")]) - self.cpp_info.components["plugin_scripts"].build_modules.append(os.path.join(self._res_folder, "cmake", "sdk_plugin_conf.cmake")) + self.cpp_info.components["plugin_scripts"].build_modules["cmake_find_package"] = [sdk_plugin_conf] + self.cpp_info.components["plugin_scripts"].build_modules["cmake_find_package_multi"] = [sdk_plugin_conf] diff --git a/recipes/aws-sdk-cpp/all/patches/1.8.130-0004-improve-pulseaudio-detection.patch b/recipes/aws-sdk-cpp/all/patches/1.8.130-0004-improve-pulseaudio-detection.patch index 5a47717a4552ae..9930b981211f60 100644 --- a/recipes/aws-sdk-cpp/all/patches/1.8.130-0004-improve-pulseaudio-detection.patch +++ b/recipes/aws-sdk-cpp/all/patches/1.8.130-0004-improve-pulseaudio-detection.patch @@ -24,7 +24,7 @@ index b1054515d5..d1a34ddfc5 100644 message(STATUS "Pulse audio header files have been detected, included pulse audio as a possible sound driver implementation.") add_definitions("-DPULSE") - set(PLATFORM_LIBS ${PLATFORM_LIBS} pulse pulse-simple) -+ set(PLATFORM_LIBS ${PLATFORM_LIBS} "CONAN_PKG::pulseaudio") ++ set(PLATFORM_LIBS ${PLATFORM_LIBS} "pulseaudio::pulseaudio") else() message(WARNING "We've detected that you are building on linux, but the header files for pulseaudio are not available.\ If you are providing your own audio implementation or you will not be using the text-to-speech library, this is fine.\ diff --git a/recipes/aws-sdk-cpp/all/test_package/CMakeLists.txt b/recipes/aws-sdk-cpp/all/test_package/CMakeLists.txt index efb9a3d957583e..dda85fd047b73f 100644 --- a/recipes/aws-sdk-cpp/all/test_package/CMakeLists.txt +++ b/recipes/aws-sdk-cpp/all/test_package/CMakeLists.txt @@ -1,13 +1,10 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) find_package(AWSSDK REQUIRED CONFIG) add_subdirectory(aws-sdk-cpp-plugin) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} aws-sdk-cpp-plugin) -set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 11) +target_link_libraries(${PROJECT_NAME} PRIVATE aws-sdk-cpp-plugin) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/aws-sdk-cpp/all/test_package/aws-sdk-cpp-plugin/CMakeLists.txt b/recipes/aws-sdk-cpp/all/test_package/aws-sdk-cpp-plugin/CMakeLists.txt index dddf745d2e4081..37d0edc6941d9d 100644 --- a/recipes/aws-sdk-cpp/all/test_package/aws-sdk-cpp-plugin/CMakeLists.txt +++ b/recipes/aws-sdk-cpp/all/test_package/aws-sdk-cpp-plugin/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.8) add_project(aws-sdk-cpp-plugin "C++ AWS SDK plugin" AWS::aws-sdk-cpp-s3) @@ -8,7 +8,7 @@ include(GenerateExportHeader) generate_export_header(${PROJECT_NAME} BASE_NAME aws_sdk_cpp_plugin) target_include_directories(${PROJECT_NAME} PUBLIC $ $) target_link_libraries(${PROJECT_NAME} PUBLIC ${PROJECT_LIBS}) -set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 11) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) setup_install() diff --git a/recipes/aws-sdk-cpp/all/test_package/conanfile.py b/recipes/aws-sdk-cpp/all/test_package/conanfile.py index 38f4483872d47f..e845ae751a3017 100644 --- a/recipes/aws-sdk-cpp/all/test_package/conanfile.py +++ b/recipes/aws-sdk-cpp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/aws-sdk-cpp/all/test_v1_package/CMakeLists.txt b/recipes/aws-sdk-cpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..0d20897301b68b --- /dev/null +++ b/recipes/aws-sdk-cpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/aws-sdk-cpp/all/test_v1_package/conanfile.py b/recipes/aws-sdk-cpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/aws-sdk-cpp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 0faff79b5d05f12b62bc8a1f98e7b0db2740258b Mon Sep 17 00:00:00 2001 From: whalien Date: Wed, 6 Sep 2023 21:47:46 +0800 Subject: [PATCH 0541/1140] (#18702) feat: update tree-sitter-c to conan v2 * feat: update tree-sitter-c to conan v2 * fix: update grammar lib to dynamic lib * fix: self review * fix: update package_type to lib * fix: add static lib recipe --------- Co-authored-by: Carlos Zoido --- recipes/tree-sitter-c/all/CMakeLists.txt | 19 ++++--- recipes/tree-sitter-c/all/conandata.yml | 3 + recipes/tree-sitter-c/all/conanfile.py | 57 ++++++++++--------- .../all/test_package/CMakeLists.txt | 3 - .../all/test_package/conanfile.py | 20 +++++-- recipes/tree-sitter-c/config.yml | 2 + 6 files changed, 62 insertions(+), 42 deletions(-) diff --git a/recipes/tree-sitter-c/all/CMakeLists.txt b/recipes/tree-sitter-c/all/CMakeLists.txt index 2d76c83c9cbd42..0500a39a48fb98 100644 --- a/recipes/tree-sitter-c/all/CMakeLists.txt +++ b/recipes/tree-sitter-c/all/CMakeLists.txt @@ -1,9 +1,6 @@ cmake_minimum_required(VERSION 3.0) project(tree-sitter-c C) -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(tree-sitter REQUIRED CONFIG) include(GenerateExportHeader) @@ -12,11 +9,19 @@ file(WRITE api.h [[ #include #include "tree_sitter_c_export.h" -TREE_SITTER_C_EXPORT const TSLanguage *tree_sitter_c(void); +#ifdef __cplusplus +extern "C" { +#endif + +const TSLanguage *tree_sitter_c(void); + +#ifdef __cplusplus +} +#endif ]]) add_library(${PROJECT_NAME} - source_subfolder/src/parser.c + src/src/parser.c ) target_link_libraries(${PROJECT_NAME} PUBLIC @@ -24,8 +29,8 @@ target_link_libraries(${PROJECT_NAME} ) target_include_directories(${PROJECT_NAME} PRIVATE - $ - $ + $ + $ ) set_target_properties(${PROJECT_NAME} PROPERTIES diff --git a/recipes/tree-sitter-c/all/conandata.yml b/recipes/tree-sitter-c/all/conandata.yml index fe7f5673971670..f225285a8fae5c 100644 --- a/recipes/tree-sitter-c/all/conandata.yml +++ b/recipes/tree-sitter-c/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.20.3": + url: "https://github.com/tree-sitter/tree-sitter-c/archive/refs/tags/v0.20.3.tar.gz" + sha256: "8c72a765230324f2b64e9ed66e027daf1a2ed24dde5fbf21398ad8ff7fca2a2d" "0.20.2": url: "https://github.com/tree-sitter/tree-sitter-c/archive/v0.20.2.tar.gz" sha256: "af66fde03feb0df4faf03750102a0d265b007e5d957057b6b293c13116a70af2" diff --git a/recipes/tree-sitter-c/all/conanfile.py b/recipes/tree-sitter-c/all/conanfile.py index 84ab13ea082134..87e43c96d6c623 100644 --- a/recipes/tree-sitter-c/all/conanfile.py +++ b/recipes/tree-sitter-c/all/conanfile.py @@ -1,8 +1,10 @@ -from conans import CMake, ConanFile, tools -import functools +from conan import ConanFile +from conan.tools.cmake import CMake +from conan.tools.files import get, replace_in_file, copy +from conan.tools.layout import basic_layout import os -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" class TreeSitterCConan(ConanFile): @@ -13,21 +15,22 @@ class TreeSitterCConan(ConanFile): homepage = "https://github.com/tree-sitter/tree-sitter-c" license = "MIT" settings = "os", "arch", "compiler", "build_type" + package_type = "library" + generators = "CMakeToolchain", "CMakeDeps" options = { - "fPIC": [True, False], "shared": [True, False], + "fPIC": [True, False], } default_options = { - "fPIC": True, "shared": False, + "fPIC": True, } - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeToolchain", "CMakeDeps" exports_sources = "CMakeLists.txt" - @property - def _source_subfolder(self): - return "source_subfolder" + def layout(self): + basic_layout(self, src_folder="src") def config_options(self): if self.settings.os == "Windows": @@ -35,38 +38,38 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd - - def requirements(self): - self.requires("tree-sitter/0.20.0") + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def requirements(self): + self.requires("tree-sitter/0.20.8", transitive_headers=True, transitive_libs=True) def _patch_sources(self): if not self.options.shared: - tools.replace_in_file( - os.path.join(self._source_subfolder, "src", "parser.c"), + replace_in_file( + self, + os.path.join(self.source_folder, "src", "parser.c"), "__declspec(dllexport)", "" ) def build(self): self._patch_sources() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy( + self, + "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + ) + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/tree-sitter-c/all/test_package/CMakeLists.txt b/recipes/tree-sitter-c/all/test_package/CMakeLists.txt index 48140fe26ab46d..177a777e8ddf7c 100644 --- a/recipes/tree-sitter-c/all/test_package/CMakeLists.txt +++ b/recipes/tree-sitter-c/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ cmake_minimum_required(VERSION 3.1) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(tree-sitter-c REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) diff --git a/recipes/tree-sitter-c/all/test_package/conanfile.py b/recipes/tree-sitter-c/all/test_package/conanfile.py index 38f4483872d47f..fc47f4cefd6122 100644 --- a/recipes/tree-sitter-c/all/test_package/conanfile.py +++ b/recipes/tree-sitter-c/all/test_package/conanfile.py @@ -1,10 +1,20 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout + import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -12,6 +22,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + cmd = os.path.join(self.cpp.build.bindir, "test_package") + self.run(cmd, env="conanrun") diff --git a/recipes/tree-sitter-c/config.yml b/recipes/tree-sitter-c/config.yml index 8304408636b4bf..7070a273f171ac 100644 --- a/recipes/tree-sitter-c/config.yml +++ b/recipes/tree-sitter-c/config.yml @@ -1,4 +1,6 @@ versions: + "0.20.3": + folder: all "0.20.2": folder: all "0.20.1": From 0252c5088755a2087accd5722a335105310ef346 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 6 Sep 2023 23:35:27 +0900 Subject: [PATCH 0542/1140] (#19538) re2: add version 2023-09-01 --- recipes/re2/all/conandata.yml | 3 +++ recipes/re2/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/re2/all/conandata.yml b/recipes/re2/all/conandata.yml index 9b52a871bf2616..f87d569bda02a7 100644 --- a/recipes/re2/all/conandata.yml +++ b/recipes/re2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20230901": + url: "https://github.com/google/re2/releases/download/2023-09-01/re2-2023-09-01.tar.gz" + sha256: "5bb6875ae1cd1e9fedde98018c346db7260655f86fdb8837e3075103acd3649b" "20230801": url: "https://github.com/google/re2/releases/download/2023-08-01/re2-2023-08-01.tar.gz" sha256: "d82d0efe2389949244445e7a6ac9a10fccc3d6a3d267ec4652991a51291647b0" diff --git a/recipes/re2/config.yml b/recipes/re2/config.yml index fb1f7527256cf1..d57588459f0b8f 100644 --- a/recipes/re2/config.yml +++ b/recipes/re2/config.yml @@ -1,4 +1,6 @@ versions: + "20230901": + folder: all "20230801": folder: all "20230701": From 50a2b912cde7bb5c98a7dfc217e412afd3917653 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Wed, 6 Sep 2023 17:46:37 +0200 Subject: [PATCH 0543/1140] (#19614) [imagl] Migrate to Conan 2.x and fix JSON error in CI * Updating imagl recipe for conan 2.0 * adding src_folder parameter to cmake_layout to please linter * Back to minimum conan 1.59 * Inspired by zlib recipe and now it passes v1 hooks. * Do not use validate_build(), but validate() instead * Applying jwillikers suggestions. * Final endline added * add cmake_find_package_multi generator as jwillikers suggests it. Co-authored-by: Jordan Williams * Removing base_path from patches and a useless _cmake member of ImaglConan class * -Switch to github URLs since my GitLab instance is temporarily down -Change license name to uppercase * update deps Signed-off-by: Uilian Ries * private target Signed-off-by: Uilian Ries * revert conandata.yml Signed-off-by: Uilian Ries * remove 0.1.0 version Signed-off-by: Uilian Ries * Keep Woazim as true author * change homepage to GH url Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Benjamin ALBOUY-KISSI Co-authored-by: Woazim <54191598+Woazim@users.noreply.github.com> Co-authored-by: Jordan Williams Co-authored-by: Daniel --- recipes/imagl/all/CMakeLists.txt | 7 -- recipes/imagl/all/conandata.yml | 28 +++-- recipes/imagl/all/conanfile.py | 118 ++++++++---------- recipes/imagl/all/test_package/CMakeLists.txt | 9 +- recipes/imagl/all/test_package/conanfile.py | 19 ++- .../imagl/all/test_v1_package/CMakeLists.txt | 8 ++ .../imagl/all/test_v1_package/conanfile.py | 17 +++ 7 files changed, 111 insertions(+), 95 deletions(-) delete mode 100644 recipes/imagl/all/CMakeLists.txt create mode 100644 recipes/imagl/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/imagl/all/test_v1_package/conanfile.py diff --git a/recipes/imagl/all/CMakeLists.txt b/recipes/imagl/all/CMakeLists.txt deleted file mode 100644 index 434aea21733de3..00000000000000 --- a/recipes/imagl/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include("conanbuildinfo.cmake") -conan_basic_setup(TARGETS) - -add_subdirectory(source_subfolder) diff --git a/recipes/imagl/all/conandata.yml b/recipes/imagl/all/conandata.yml index 4c28973c33e6b8..338c8a935d27e9 100644 --- a/recipes/imagl/all/conandata.yml +++ b/recipes/imagl/all/conandata.yml @@ -1,26 +1,30 @@ sources: "0.1.0": - url: "https://gitlab-lepuy.iut-clermont.uca.fr/opengl/imagl/-/archive/v0.1.0/imagl-v0.1.0.tar.gz" - sha256: "9dcfba4c2efa8d44bf4cc9edd324794865dd6d6331467d3c69f5c5574db3844e" + url: "https://github.com/Woazim/imaGL/archive/refs/tags/v0.1.0.tar.gz" + sha256: "070d155f61c3036be67683dcec7bef57d5407f5aa7ca35487358b55fd2762ef8" "0.1.1": - url: "https://gitlab-lepuy.iut-clermont.uca.fr/opengl/imagl/-/archive/v0.1.1/imagl-v0.1.1.tar.gz" - sha256: "4a7502cc733431af6423246fe5144e2eddb984454a66cca51742c852980ac862" + url: "https://github.com/Woazim/imaGL/archive/refs/tags/v0.1.1.tar.gz" + sha256: "25c1df00dfd1741b013044de9407f30f58ca64d155d862db740518ed8667f3ec" "0.1.2": - url: "https://gitlab-lepuy.iut-clermont.uca.fr/opengl/imagl/-/archive/v0.1.2/imagl-v0.1.2.tar.gz" - sha256: "d1edf74e00f969a47dc56e4400b805600d6997270339d49e91b7c6112a2cb37e" + url: "https://github.com/Woazim/imaGL/archive/refs/tags/v0.1.2.tar.gz" + sha256: "03296707f4c6b5a03cd4d6670c7444c0660d22ca09de981e57fcb75111fd16a5" "0.2.1": - url: "https://gitlab-lepuy.iut-clermont.uca.fr/opengl/imagl/-/archive/v0.2.1/imagl-v0.2.1.tar.gz" - sha256: "5a68cdeff4338e411695cca16c4230567de298f8efee2a9fadcc6fa644a70248" + url: "https://github.com/Woazim/imaGL/archive/refs/tags/v0.2.1.tar.gz" + sha256: "b0109b1d0cadf3054ad959ed4a0420b61202f8143f5a7ad766c1e449603d30d8" patches: "0.1.0": - patch_file: "patches/0001-no-unmanaged-conan-0.1.x.patch" - base_path: "source_subfolder" + patch_description: "No unmanaged conan: update CMakeLists.txt remove call to conan" + patch_type: conan "0.1.1": - patch_file: "patches/0001-no-unmanaged-conan-0.1.x.patch" - base_path: "source_subfolder" + patch_description: "No unmanaged conan: update CMakeLists.txt remove call to conan" + patch_type: conan "0.1.2": - patch_file: "patches/0001-no-unmanaged-conan-0.1.x.patch" - base_path: "source_subfolder" + patch_description: "No unmanaged conan: update CMakeLists.txt remove call to conan" + patch_type: conan "0.2.1": - patch_file: "patches/0001-no-unmanaged-conan-0.2.1.patch" - base_path: "source_subfolder" + patch_description: "No unmanaged conan: update CMakeLists.txt remove call to conan" + patch_type: conan diff --git a/recipes/imagl/all/conanfile.py b/recipes/imagl/all/conanfile.py index a8994d4c2ba67a..e756a56a2d5483 100644 --- a/recipes/imagl/all/conanfile.py +++ b/recipes/imagl/all/conanfile.py @@ -1,12 +1,18 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout, CMakeDeps +from conan.tools.scm import Version +from conan.tools.build import check_min_cppstd +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.microsoft import is_msvc, check_min_vs +from conan.errors import ConanInvalidConfiguration +import os -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" class ImaglConan(ConanFile): name = "imagl" - license = "GPL-3.0-or-later" + license = "LGPL-3.0-only" homepage = "https://github.com/Woazim/imaGL" url = "https://github.com/conan-io/conan-center-index" description = "A lightweight library to load image for OpenGL application." @@ -24,108 +30,88 @@ class ImaglConan(ConanFile): "with_png": True, "with_jpeg": True, } - generators = "cmake" - exports_sources = ["CMakeLists.txt", "patches/**"] - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def _min_cppstd(self): + return 20 @property def _compilers_minimum_version(self): - minimum_versions = { + return { "gcc": "9", - "Visual Studio": "16.2", - "msvc": "19.22", "clang": "10", "apple-clang": "11" } - if tools.Version(self.version) <= "0.1.1" or tools.Version(self.version) == "0.2.0": - minimum_versions["Visual Studio"] = "16.5" - minimum_versions["msvc"] = "19.25" - return minimum_versions @property def _supports_jpeg(self): - return tools.Version(self.version) >= "0.2.0" + return Version(self.version) >= "0.2.0" + + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": - del self.options.fPIC + self.options.rm_safe("fPIC") if not self._supports_jpeg: - del self.options.with_jpeg + self.options.rm_safe("with_jpeg") def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_png: - self.requires("libpng/1.6.37") + self.requires("libpng/1.6.40") if self._supports_jpeg and self.options.with_jpeg: - self.requires("libjpeg/9d") + self.requires("libjpeg/9e") def validate(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 20) - - def lazy_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] - - #Special check for clang that can only be linked to libc++ - if self.settings.compiler == "clang" and self.settings.compiler.libcxx != "libc++": + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 192) + if not is_msvc(self): + 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." + ) + + # INFO: Special check for clang that can only be linked to libc++ + if self.settings.compiler == "clang" and self.settings.get_safe("compiler.libcxx") != "libc++": raise ConanInvalidConfiguration("imagl requires some C++20 features, which are available in libc++ for clang compiler.") - compiler_version = str(self.settings.compiler.version) - - minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("imaGL requires C++20. Your compiler is unknown. Assuming it supports C++20.") - elif lazy_lt_semver(compiler_version, minimum_version): - raise ConanInvalidConfiguration("imaGL requires some C++20 features, which your {} {} compiler does not support.".format(str(self.settings.compiler), compiler_version)) - else: - print("Your compiler is {} {} and is compatible.".format(str(self.settings.compiler), compiler_version)) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - - self._cmake = CMake(self) - - self._cmake.definitions["STATIC_LIB"] = not self.options.shared - self._cmake.definitions["SUPPORT_PNG"] = self.options.with_png + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + deps = CMakeDeps(self) + deps.generate() + tc = CMakeToolchain(self) + tc.variables["STATIC_LIB"] = not self.options.shared + tc.variables["SUPPORT_PNG"] = self.options.with_png if self._supports_jpeg: - self._cmake.definitions["SUPPORT_JPEG"] = self.options.with_jpeg - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + tc.variables["SUPPORT_JPEG"] = self.options.with_jpeg + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", self.source_folder, os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() def package_info(self): debug_suffix = "d" if self.settings.build_type == "Debug" else "" static_suffix = "" if self.options.shared else "s" - self.cpp_info.libs = ["imaGL{}{}".format(debug_suffix, static_suffix)] + self.cpp_info.libs = [f"imaGL{debug_suffix}{static_suffix}"] if not self.options.shared: self.cpp_info.defines = ["IMAGL_STATIC=1"] - diff --git a/recipes/imagl/all/test_package/CMakeLists.txt b/recipes/imagl/all/test_package/CMakeLists.txt index 15d229320021ca..ba0d23b2326bb9 100644 --- a/recipes/imagl/all/test_package/CMakeLists.txt +++ b/recipes/imagl/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(imagl CONFIG REQUIRED) add_executable(example example.cpp) -target_link_libraries(example ${CONAN_LIBS}) -set_target_properties(example PROPERTIES CXX_STANDARD 20 CXX_STANDARD_REQUIRED ON) +target_link_libraries(example PRIVATE imagl::imagl) +target_compile_features(example PRIVATE cxx_std_20) diff --git a/recipes/imagl/all/test_package/conanfile.py b/recipes/imagl/all/test_package/conanfile.py index 156e2a8976e7c0..0d267f1fe3b58f 100644 --- a/recipes/imagl/all/test_package/conanfile.py +++ b/recipes/imagl/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class ImaglTestConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/imagl/all/test_v1_package/CMakeLists.txt b/recipes/imagl/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/imagl/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/imagl/all/test_v1_package/conanfile.py b/recipes/imagl/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..923bd771c14e7a --- /dev/null +++ b/recipes/imagl/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class ImaglTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From 182af3038d67b37586390ae8d1c4f3f60ae5c9e6 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 6 Sep 2023 19:52:45 +0300 Subject: [PATCH 0544/1140] (#19252) libsixel: migrate to Conan v2 * libsixel: migrate to Conan v2 * libsixel: bump deps * libsixel: remove incorrect library files * libsixel: fix_apple_shared_install_name() --- recipes/libsixel/all/conanfile.py | 107 ++++++++++-------- .../libsixel/all/test_package/CMakeLists.txt | 5 +- .../libsixel/all/test_package/conanfile.py | 21 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../libsixel/all/test_v1_package/conanfile.py | 17 +++ 5 files changed, 102 insertions(+), 56 deletions(-) create mode 100644 recipes/libsixel/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libsixel/all/test_v1_package/conanfile.py diff --git a/recipes/libsixel/all/conanfile.py b/recipes/libsixel/all/conanfile.py index 8748a8a951d306..5b731a76e5de89 100644 --- a/recipes/libsixel/all/conanfile.py +++ b/recipes/libsixel/all/conanfile.py @@ -1,18 +1,28 @@ import os -import functools -from conans import ConanFile, Meson, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.build import cross_building +from conan.tools.files import copy, get, rmdir, rm +from conan.tools.gnu import PkgConfigDeps +from conan.tools.layout import basic_layout +from conan.tools.meson import MesonToolchain, Meson from conan.tools.microsoft import is_msvc -required_conan_version = ">=1.33.0" +required_conan_version = ">=1.53.0" + class LibSixelConan(ConanFile): name = "libsixel" - description = "A SIXEL encoder/decoder implementation derived from kmiya's sixel (https://github.com/saitoha/sixel)." - topics = ("sixel") + description = ("A SIXEL encoder/decoder implementation derived from kmiya's sixel" + " (https://github.com/saitoha/sixel).") license = "MIT" - homepage = "https://github.com/libsixel/libsixel" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/libsixel/libsixel" + topics = "sixel" + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -32,75 +42,80 @@ class LibSixelConan(ConanFile): "with_jpeg": True, "with_png": True, } - generators = "cmake", "pkg_config" - - @property - def _source_subfolder(self): - return "source_subfolder" def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx - - def validate(self): - if hasattr(self, "settings_build") and tools.cross_building(self): - raise ConanInvalidConfiguration("Cross-building not implemented") - if is_msvc(self): - raise ConanInvalidConfiguration("{}/{} does not support Visual Studio".format(self.name, self.version)) + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") - def build_requirements(self): - self.build_requires("meson/0.62.2") - self.build_requires("pkgconf/1.7.4") + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): if self.options.with_curl: - self.requires("libcurl/7.83.1") + self.requires("libcurl/8.2.0") if self.options.with_gd: - self.requires("libgd/2.3.2") + self.requires("libgd/2.3.3") if self.options.with_gdk_pixbuf2: - self.requires("gdk-pixbuf/2.42.6") + self.requires("gdk-pixbuf/2.42.10") if self.options.with_jpeg: - self.requires("libjpeg/9d") + self.requires("libjpeg/9e") if self.options.with_png: - self.requires("libpng/1.6.37") + self.requires("libpng/1.6.40") + + def validate(self): + if hasattr(self, "settings_build") and cross_building(self): + raise ConanInvalidConfiguration("Cross-building not implemented") + if is_msvc(self): + raise ConanInvalidConfiguration(f"{self.ref} does not support Visual Studio") + + def build_requirements(self): + self.tool_requires("meson/1.2.0") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_meson(self): - meson = Meson(self) - defs = { + def generate(self): + tc = MesonToolchain(self) + tc.project_options = { "libcurl": "enabled" if self.options.with_curl else "disabled", "gd": "enabled" if self.options.with_gd else "disabled", "gdk-pixbuf2": "enabled" if self.options.with_gdk_pixbuf2 else "disabled", "img2sixel": "disabled", "sixel2png": "disabled", "python2": "disabled", + "libdir": "lib", } - meson.configure( - defs=defs, - source_folder=self._source_subfolder, - ) - return meson + tc.generate() + tc = PkgConfigDeps(self) + tc.generate() def build(self): - meson = self._configure_meson() + meson = Meson(self) + meson.configure() meson.build() def package(self): - self.copy("LICENSE*", dst="licenses", src=self._source_subfolder) - meson = self._configure_meson() + copy(self, "LICENSE*", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + meson = Meson(self) meson.install() - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + fix_apple_shared_install_name(self) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + if self.options.shared: + rm(self, "*.a", os.path.join(self.package_folder, "lib")) + rm(self, "*.lib", os.path.join(self.package_folder, "lib")) + else: + rm(self, "*.dll", os.path.join(self.package_folder, "bin")) + rm(self, "*.so*", os.path.join(self.package_folder, "lib")) + rm(self, "*.dylib", os.path.join(self.package_folder, "lib")) def package_info(self): self.cpp_info.libs = ["sixel"] diff --git a/recipes/libsixel/all/test_package/CMakeLists.txt b/recipes/libsixel/all/test_package/CMakeLists.txt index 199ae95ae65fc3..9bb9b6871d67d6 100644 --- a/recipes/libsixel/all/test_package/CMakeLists.txt +++ b/recipes/libsixel/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(libsixel REQUIRED CONFIG) add_executable(${PROJECT_NAME} ${PROJECT_NAME}.c) diff --git a/recipes/libsixel/all/test_package/conanfile.py b/recipes/libsixel/all/test_package/conanfile.py index e556cc050d509c..ef5d7042163ecc 100644 --- a/recipes/libsixel/all/test_package/conanfile.py +++ b/recipes/libsixel/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class TestConan(ConanFile): +class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libsixel/all/test_v1_package/CMakeLists.txt b/recipes/libsixel/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libsixel/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libsixel/all/test_v1_package/conanfile.py b/recipes/libsixel/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..e556cc050d509c --- /dev/null +++ b/recipes/libsixel/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 826e03f0adae39187c8658abad3520b04fd23b88 Mon Sep 17 00:00:00 2001 From: temap Date: Wed, 6 Sep 2023 20:55:01 +0300 Subject: [PATCH 0545/1140] (#19493) linux-headers-generic: add version 5.15.128 --- recipes/linux-headers-generic/all/conandata.yml | 3 +++ recipes/linux-headers-generic/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/linux-headers-generic/all/conandata.yml b/recipes/linux-headers-generic/all/conandata.yml index ecc5fdb03690f3..3086bd648e6c65 100644 --- a/recipes/linux-headers-generic/all/conandata.yml +++ b/recipes/linux-headers-generic/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "5.15.128": + url: "https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.15.128.tar.gz" + sha256: "4ce1331bb3877bc92581ec5faff76d63d19e7b1fa174acdda1f5cba4a8f2abf7" "5.14.9": url: "https://cdn.kernel.org/pub/linux/kernel/v5.x/linux-5.14.9.tar.gz" sha256: "b5cd37e6d193c8f6a98e41ce6f9d97260d178e0a3cfc43d7ff684f67c6c25f29" diff --git a/recipes/linux-headers-generic/config.yml b/recipes/linux-headers-generic/config.yml index a8d9d5e7bbfa80..d4c808d80cdc5b 100644 --- a/recipes/linux-headers-generic/config.yml +++ b/recipes/linux-headers-generic/config.yml @@ -1,4 +1,6 @@ versions: + "5.15.128": + folder: all "5.14.9": folder: all "5.13.9": From 1b8825365f000babd8535f47d6ec9704beb472df Mon Sep 17 00:00:00 2001 From: temap Date: Wed, 6 Sep 2023 21:36:56 +0300 Subject: [PATCH 0546/1140] (#19495) xmlsec: add version 1.2.33 --- recipes/xmlsec/all/conandata.yml | 3 +++ recipes/xmlsec/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/xmlsec/all/conandata.yml b/recipes/xmlsec/all/conandata.yml index 46664dc0decc9f..d74fd9230c88cb 100644 --- a/recipes/xmlsec/all/conandata.yml +++ b/recipes/xmlsec/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.33": + url: "https://www.aleksey.com/xmlsec/download/older-releases/xmlsec1-1.2.33.tar.gz" + sha256: "26041d35a20a245ed5a2fb9ee075f10825664d274220cb5190340fa87a4d0931" "1.2.32": url: "https://www.aleksey.com/xmlsec/download/older-releases/xmlsec1-1.2.32.tar.gz" sha256: "e383702853236004e5b08e424b8afe9b53fe9f31aaa7a5382f39d9533eb7c043" diff --git a/recipes/xmlsec/config.yml b/recipes/xmlsec/config.yml index be77378a243925..3853f0ae48f16a 100644 --- a/recipes/xmlsec/config.yml +++ b/recipes/xmlsec/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.33": + folder: all "1.2.32": folder: all "1.2.31": From 2771cb36f381a93e1409b41b941fc9492debb80b Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 6 Sep 2023 21:39:03 +0200 Subject: [PATCH 0547/1140] (#19500) autoconf: less verbose package_info() --- recipes/autoconf/all/conanfile.py | 23 ++++------------------- 1 file changed, 4 insertions(+), 19 deletions(-) diff --git a/recipes/autoconf/all/conanfile.py b/recipes/autoconf/all/conanfile.py index e8f1925de206c2..6030c1664be5b7 100644 --- a/recipes/autoconf/all/conanfile.py +++ b/recipes/autoconf/all/conanfile.py @@ -108,29 +108,14 @@ def package_info(self): # TODO: These variables can be removed since the scripts now locate the resources # relative to themselves. dataroot_path = os.path.join(self.package_folder, "res", "autoconf") - self.output.info(f"Defining AC_MACRODIR environment variable: {dataroot_path}") self.buildenv_info.define_path("AC_MACRODIR", dataroot_path) - - self.output.info(f"Defining autom4te_perllibdir environment variable: {dataroot_path}") self.buildenv_info.define_path("autom4te_perllibdir", dataroot_path) bin_path = os.path.join(self.package_folder, "bin") - - autoconf_bin = os.path.join(bin_path, "autoconf") - self.output.info(f"Defining AUTOCONF environment variable: {autoconf_bin}") - self.buildenv_info.define_path("AUTOCONF", autoconf_bin) - - autoreconf_bin = os.path.join(bin_path, "autoreconf") - self.output.info(f"Defining AUTORECONF environment variable: {autoreconf_bin}") - self.buildenv_info.define_path("AUTORECONF", autoreconf_bin) - - autoheader_bin = os.path.join(bin_path, "autoheader") - self.output.info(f"Defining AUTOHEADER environment variable: {autoheader_bin}") - self.buildenv_info.define_path("AUTOHEADER", autoheader_bin) - - autom4te_bin = os.path.join(bin_path, "autom4te") - self.output.info(f"Defining AUTOM4TE environment variable: {autom4te_bin}") - self.buildenv_info.define_path("AUTOM4TE", autom4te_bin) + self.buildenv_info.define_path("AUTOCONF", os.path.join(bin_path, "autoconf")) + self.buildenv_info.define_path("AUTORECONF", os.path.join(bin_path, "autoreconf")) + self.buildenv_info.define_path("AUTOHEADER", os.path.join(bin_path, "autoheader")) + self.buildenv_info.define_path("AUTOM4TE", os.path.join(bin_path, "autom4te")) # TODO: to remove in conan v2 self.env_info.PATH.append(bin_path) From b2242f628686844f0cd979fd27a2eb96396f908c Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 05:13:20 +0900 Subject: [PATCH 0548/1140] (#19566) octo-encryption-cpp: support conan v2, add package_type, relax openssl and cmake versions * octo-encryption-cpp: support conan v2, add package_type, relax openssl and cmake versions * make openssl transitive_headers --- recipes/octo-encryption-cpp/all/conandata.yml | 4 +- recipes/octo-encryption-cpp/all/conanfile.py | 64 ++++++++++--------- .../all/test_package/CMakeLists.txt | 8 +-- .../all/test_package/conanfile.py | 20 +++--- 4 files changed, 49 insertions(+), 47 deletions(-) diff --git a/recipes/octo-encryption-cpp/all/conandata.yml b/recipes/octo-encryption-cpp/all/conandata.yml index 1e42247500f04a..d2c6c293649c60 100644 --- a/recipes/octo-encryption-cpp/all/conandata.yml +++ b/recipes/octo-encryption-cpp/all/conandata.yml @@ -1,4 +1,4 @@ sources: "1.1.0": - sha256: f595eb6c44187e8f5f047fc7bd6747ba0d50ad99f526fe87c16fdba9c77b513d - url: https://github.com/ofiriluz/octo-encryption-cpp/archive/refs/tags/v1.1.0.tar.gz + url: "https://github.com/ofiriluz/octo-encryption-cpp/archive/refs/tags/v1.1.0.tar.gz" + sha256: "f595eb6c44187e8f5f047fc7bd6747ba0d50ad99f526fe87c16fdba9c77b513d" diff --git a/recipes/octo-encryption-cpp/all/conanfile.py b/recipes/octo-encryption-cpp/all/conanfile.py index 991faa27ffc844..263f2034b1a24b 100644 --- a/recipes/octo-encryption-cpp/all/conanfile.py +++ b/recipes/octo-encryption-cpp/all/conanfile.py @@ -4,19 +4,24 @@ from conan.tools.build import check_min_cppstd from conan.errors import ConanInvalidConfiguration from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc_static_runtime import os -required_conan_version = ">=1.50.0" - +required_conan_version = ">=1.53.0" class OctoEncryptionCPPConan(ConanFile): name = "octo-encryption-cpp" + description = "Octo encryption library" license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/ofiriluz/octo-encryption-cpp" - description = "Octo encryption library" topics = ("cryptography", "cpp") - settings = "os", "compiler", "build_type", "arch" + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + + @property + def _min_cppstd(self): + return 17 @property def _compilers_minimum_version(self): @@ -25,45 +30,41 @@ def _compilers_minimum_version(self): "clang": "9", "apple-clang": "11", "Visual Studio": "16", - "msvc": "1923", + "msvc": "192", } - def generate(self): - tc = CMakeToolchain(self) - tc.variables["DISABLE_TESTS"] = True - tc.variables["DISABLE_EXAMPLES"] = True - tc.generate() - cd = CMakeDeps(self) - cd.generate() - def layout(self): cmake_layout(self, src_folder="src") - def validate(self): - if self.info.settings.compiler.cppstd: - check_min_cppstd(self, "17") + def requirements(self): + self.requires("openssl/[>=1.1 <4]", transitive_headers=True) + def validate(self): + if self.info.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration( - f"{self.name} requires C++17, which your compiler does not support." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - else: - self.output.warn(f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17.") if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": raise ConanInvalidConfiguration(f"{self.name} does not support clang with libc++. Use libstdc++ instead.") - if self.settings.compiler == "Visual Studio" and self.settings.compiler.runtime in ["MTd", "MT"]: - raise ConanInvalidConfiguration(f"{self.name} does not support MSVC MT/MTd configurations, only MD/MDd is supported") + if is_msvc_static_runtime(self): + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC MT/MTd configurations, only MD/MDd is supported") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") - def requirements(self): - self.requires("openssl/1.1.1q") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build_requirements(self): - self.build_requires("cmake/3.24.0") + def generate(self): + tc = CMakeToolchain(self) + tc.variables["DISABLE_TESTS"] = True + tc.variables["DISABLE_EXAMPLES"] = True + tc.generate() + cd = CMakeDeps(self) + cd.generate() def build(self): cmake = CMake(self) @@ -76,11 +77,14 @@ def package(self): cmake.install() def package_info(self): + self.cpp_info.libs = ["octo-encryption-cpp"] + self.cpp_info.set_property("cmake_file_name", "octo-encryption-cpp") self.cpp_info.set_property("cmake_target_name", "octo::octo-encryption-cpp") self.cpp_info.set_property("pkg_config_name", "octo-encryption-cpp") - self.cpp_info.libs = ["octo-encryption-cpp"] + self.cpp_info.requires = ["openssl::openssl"] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.names["cmake_find_package"] = "octo-encryption-cpp" self.cpp_info.names["cmake_find_package_multi"] = "octo-encryption-cpp" self.cpp_info.names["pkg_config"] = "octo-encryption-cpp" - self.cpp_info.requires = ["openssl::openssl"] diff --git a/recipes/octo-encryption-cpp/all/test_package/CMakeLists.txt b/recipes/octo-encryption-cpp/all/test_package/CMakeLists.txt index a07fac747020c3..bd49d24ed139e2 100644 --- a/recipes/octo-encryption-cpp/all/test_package/CMakeLists.txt +++ b/recipes/octo-encryption-cpp/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(octo-encryption-cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} octo::octo-encryption-cpp) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE octo::octo-encryption-cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/octo-encryption-cpp/all/test_package/conanfile.py b/recipes/octo-encryption-cpp/all/test_package/conanfile.py index 62e07ce5add598..ef5d7042163ecc 100644 --- a/recipes/octo-encryption-cpp/all/test_package/conanfile.py +++ b/recipes/octo-encryption-cpp/all/test_package/conanfile.py @@ -1,19 +1,16 @@ -from conans import ConanFile -from conan.tools.cmake import CMake, CMakeToolchain +from conan import ConanFile from conan.tools.build import can_run -from conan.tools.cmake import cmake_layout +from conan.tools.cmake import cmake_layout, CMake import os -required_conan_version = ">=1.43.0" - class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "CMakeDeps", "VirtualRunEnv" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" - def generate(self): - tc = CMakeToolchain(self) - tc.generate() + def requirements(self): + self.requires(self.tested_reference_str) def layout(self): cmake_layout(self) @@ -25,4 +22,5 @@ def build(self): def test(self): if can_run(self): - self.run(os.path.join(self.cpp.build.bindirs[0], "test_package"), env="conanrun") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") From cb4d2464ee5dfc4f3d85b4d3c4984bafd80bdff7 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 05:52:10 +0900 Subject: [PATCH 0549/1140] (#19568) cppitertools: support conan v2 more, update boost --- recipes/cppitertools/all/conandata.yml | 4 +- recipes/cppitertools/all/conanfile.py | 82 ++++++++++--------- .../all/test_package/CMakeLists.txt | 12 +-- .../all/test_package/conanfile.py | 1 + 4 files changed, 53 insertions(+), 46 deletions(-) diff --git a/recipes/cppitertools/all/conandata.yml b/recipes/cppitertools/all/conandata.yml index b8a68ed038695c..03371485048710 100644 --- a/recipes/cppitertools/all/conandata.yml +++ b/recipes/cppitertools/all/conandata.yml @@ -1,4 +1,4 @@ sources: "2.1": - url: https://github.com/ryanhaining/cppitertools/archive/v2.1.tar.gz - sha256: f7bcd4531e37083609bb92c3f0ae03b56e7197002d0dc9c695104dcef445f2ab + url: "https://github.com/ryanhaining/cppitertools/archive/v2.1.tar.gz" + sha256: "f7bcd4531e37083609bb92c3f0ae03b56e7197002d0dc9c695104dcef445f2ab" diff --git a/recipes/cppitertools/all/conanfile.py b/recipes/cppitertools/all/conanfile.py index 15118a8925b22e..d59270a8f393ac 100644 --- a/recipes/cppitertools/all/conanfile.py +++ b/recipes/cppitertools/all/conanfile.py @@ -1,69 +1,75 @@ import os from conan import ConanFile from conan.tools.build import check_min_cppstd -from conan.tools.files import get, copy, rename +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout from conan.tools.scm import Version from conan.errors import ConanInvalidConfiguration -required_conan_version = ">=1.50.0" +required_conan_version = ">=1.53.0" class CppItertoolsConan(ConanFile): name = "cppitertools" - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://github.com/ryanhaining/cppitertools" description = "Implementation of python itertools and builtin iteration functions for C++17" - topics = ("cpp17", "iter", "itertools") license = "BSD-2-Clause" - no_copy_source = True - + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ryanhaining/cppitertools" + topics = ("cpp17", "iter", "itertools", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - options = {'zip_longest': [True, False]} - default_options = {'zip_longest': False} + options = { + 'zip_longest': [True, False], + } + default_options = { + 'zip_longest': False, + } + no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" - - def source(self): - get(self, **self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - rename(self, extracted_dir, self._source_subfolder) - - def validate(self): - if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 17) + def _min_cppstd(self): + return 17 - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "Visual Studio": "15", "msvc": "191", "gcc": "7", "clang": "5.0", "apple-clang": "9.1" } - compiler = str(self.settings.compiler) - compiler_version = Version(self.settings.compiler.version) - - if compiler not in minimal_version: - self.output.info("{} requires a compiler that supports at least C++17".format(self.name)) - return - # Exclude compilers not supported by cppitertools - if compiler_version < minimal_version[compiler]: - raise ConanInvalidConfiguration("{} requires a compiler that supports at least C++17. {} {} is not".format( - self.name, compiler, Version(self.settings.compiler.version.value))) + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): if self.options.zip_longest: - self.requires('boost/1.75.0') + self.requires('boost/1.83.0') + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("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) def package(self): - copy(self, "*.hpp", src=os.path.join(self.source_folder, self._source_subfolder), dst=os.path.join(self.package_folder,"include", "cppitertools"), excludes=('examples/**', 'test/**')) - copy(self, "LICENSE.md", src=os.path.join(self.source_folder, self._source_subfolder), dst=os.path.join(self.package_folder,"licenses")) + copy(self, "LICENSE.md", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*.hpp", src=self.source_folder, dst=os.path.join(self.package_folder, "include", "cppitertools"), excludes=('examples/**', 'test/**')) + def package_info(self): - self.cpp_info.set_property("cmake_file_name", "cppitertools") - self.cpp_info.set_property("cmake_target_name", "cppitertools::cppitertools") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - def package_id(self): - self.info.clear() + + self.cpp_info.set_property("cmake_file_name", "cppitertools") + self.cpp_info.set_property("cmake_target_name", "cppitertools::cppitertools") + diff --git a/recipes/cppitertools/all/test_package/CMakeLists.txt b/recipes/cppitertools/all/test_package/CMakeLists.txt index 39161129005c36..18b263b57ca6f8 100644 --- a/recipes/cppitertools/all/test_package/CMakeLists.txt +++ b/recipes/cppitertools/all/test_package/CMakeLists.txt @@ -1,14 +1,14 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(cppitertools REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} cppitertools::cppitertools) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE cppitertools::cppitertools) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) if(ZIP_LONGEST) add_executable(test_zip_longest test_zip_longest.cpp) - target_link_libraries(test_zip_longest cppitertools::cppitertools) - set_property(TARGET test_zip_longest PROPERTY CXX_STANDARD 17) + target_link_libraries(test_zip_longest PRIVATE cppitertools::cppitertools) + target_compile_features(test_zip_longest PRIVATE cxx_std_17) endif() diff --git a/recipes/cppitertools/all/test_package/conanfile.py b/recipes/cppitertools/all/test_package/conanfile.py index 758d48b5853bac..fac50abb3d577a 100644 --- a/recipes/cppitertools/all/test_package/conanfile.py +++ b/recipes/cppitertools/all/test_package/conanfile.py @@ -7,6 +7,7 @@ class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" + test_type = "explicit" def generate(self): tc = CMakeToolchain(self) From 8e5020b457ae9c2e8ee3d246468d2543156c85b5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 6 Sep 2023 23:15:45 +0200 Subject: [PATCH 0550/1140] (#19610) freetype: bump brotli, restore fixed version of libpng, and proper version range for zlib --- recipes/freetype/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/freetype/all/conanfile.py b/recipes/freetype/all/conanfile.py index 5073e3cf9b655b..1415f8ffb04464 100644 --- a/recipes/freetype/all/conanfile.py +++ b/recipes/freetype/all/conanfile.py @@ -64,13 +64,13 @@ def layout(self): def requirements(self): if self.options.with_png: - self.requires("libpng/[>=1.6 <1.7]") + self.requires("libpng/1.6.40") if self.options.with_zlib: - self.requires("zlib/[>=1.2 <1.3]") + self.requires("zlib/[>=1.2.10 <2]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.get_safe("with_brotli"): - self.requires("brotli/1.0.9") + self.requires("brotli/1.1.0") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From c1788389e9c867623a87763fbad3b986697aa5a4 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 06:51:34 +0900 Subject: [PATCH 0551/1140] (#19622) daw_header_libraries: add version 2.96.1 --- recipes/daw_header_libraries/all/conandata.yml | 3 +++ recipes/daw_header_libraries/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/daw_header_libraries/all/conandata.yml b/recipes/daw_header_libraries/all/conandata.yml index 76073e7c9033b9..f07d3ecdd0bdb8 100644 --- a/recipes/daw_header_libraries/all/conandata.yml +++ b/recipes/daw_header_libraries/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.96.1": + url: "https://github.com/beached/header_libraries/archive/v2.96.1.tar.gz" + sha256: "2a9a5c33baa9e3adc1d82fa13a56522638af13cc39372a0c1c8f5c5d984f1464" "2.95.0": url: "https://github.com/beached/header_libraries/archive/v2.95.0.tar.gz" sha256: "8799c06f0587b202fd6049d95e70b04675acbfdbf6e86ac3bbd061cbb9d42b54" diff --git a/recipes/daw_header_libraries/config.yml b/recipes/daw_header_libraries/config.yml index 6a27257347e52a..e5da3ea85fe212 100644 --- a/recipes/daw_header_libraries/config.yml +++ b/recipes/daw_header_libraries/config.yml @@ -1,4 +1,6 @@ versions: + "2.96.1": + folder: all "2.95.0": folder: all "2.93.1": From 9393765500d77219be327a7578da3c386a60ad72 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 7 Sep 2023 11:04:31 +0300 Subject: [PATCH 0552/1140] (#18180) aravis: add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * aravis: add package_type * aravis: restore test_v1_package * aravis: use is_apple_os() * aravis: bump deps * aravis: add transitive_headers=True, bump deps * User hsot version for glib * Apply suggestions from code review Co-authored-by: ericLemanissier --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: ericLemanissier --- recipes/aravis/all/conanfile.py | 26 ++++++++++--------- .../aravis/all/test_package/CMakeLists.txt | 2 +- .../aravis/all/test_package/test_package.c | 5 ++-- .../aravis/all/test_v1_package/CMakeLists.txt | 6 ++--- 4 files changed, 20 insertions(+), 19 deletions(-) diff --git a/recipes/aravis/all/conanfile.py b/recipes/aravis/all/conanfile.py index aaa8cad5fb1b43..6ccff17b4bf8ee 100644 --- a/recipes/aravis/all/conanfile.py +++ b/recipes/aravis/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.apple import fix_apple_shared_install_name, is_apple_os from conan.tools.build import cross_building from conan.tools.env import VirtualBuildEnv, VirtualRunEnv from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get, rename, rm, rmdir @@ -12,16 +12,18 @@ import os import glob -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.56.0 <2 || >=2.0.6" class AravisConan(ConanFile): name = "aravis" + description = "A vision library for genicam based cameras." license = "LGPL-2.1-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/AravisProject/aravis" - description = "A vision library for genicam based cameras." topics = ("usb", "camera") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -48,7 +50,7 @@ def export_sources(self): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: del self.options.packet_socket def configure(self): @@ -63,13 +65,14 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glib/2.75.2") - self.requires("libxml2/2.10.3") + # glib-object.h and gio/gio.h are used in several public headers + self.requires("glib/2.77.2", transitive_headers=True) + self.requires("libxml2/2.11.4") self.requires("zlib/1.2.13") if self.options.usb: self.requires("libusb/1.0.26") if self.options.gst_plugin: - self.requires("gstreamer/1.19.2") + self.requires("gstreamer/1.22.3") self.requires("gst-plugins-base/1.19.2") def validate(self): @@ -77,18 +80,17 @@ def validate(self): raise ConanInvalidConfiguration("Static runtime is not supported on Windows due to GLib issues") if self.options.shared and not self.dependencies["glib"].options.shared: raise ConanInvalidConfiguration("Shared Aravis cannot link to static GLib") - if self.settings.os == "Macos" and self.dependencies["glib"].options.shared: + if is_apple_os(self) and self.dependencies["glib"].options.shared: raise ConanInvalidConfiguration( "macOS builds are disabled when glib is shared until " "conan-io/conan#7324 gets merged to fix macOS SIP issue #8443" ) def build_requirements(self): - self.tool_requires("meson/1.0.0") - if hasattr(self, "settings_build") and cross_building(self): - self.tool_requires("glib/2.75.2") + self.tool_requires("meson/1.2.1") + self.tool_requires("glib/") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/1.9.5") if self.options.introspection: self.tool_requires("gobject-introspection/1.72.0") diff --git a/recipes/aravis/all/test_package/CMakeLists.txt b/recipes/aravis/all/test_package/CMakeLists.txt index 8a5d8c220194f0..f8a36c47767ce3 100644 --- a/recipes/aravis/all/test_package/CMakeLists.txt +++ b/recipes/aravis/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(aravis REQUIRED CONFIG) diff --git a/recipes/aravis/all/test_package/test_package.c b/recipes/aravis/all/test_package/test_package.c index 9a63b9ea3a8648..762afa0db71a78 100644 --- a/recipes/aravis/all/test_package/test_package.c +++ b/recipes/aravis/all/test_package/test_package.c @@ -1,9 +1,8 @@ #include -#include #include +#include -int main(int argc, char **argv) -{ +int main() { printf("Enumerating Aravis interfaces:\n"); unsigned int if_count = arv_get_n_interfaces(); for (unsigned int if_index = 0; if_index < if_count; if_index++) { diff --git a/recipes/aravis/all/test_v1_package/CMakeLists.txt b/recipes/aravis/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..91630d79f4abb3 100644 --- a/recipes/aravis/all/test_v1_package/CMakeLists.txt +++ b/recipes/aravis/all/test_v1_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) From 43313ebbdd30ba8b09ca3066bc0fa606b9431893 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 7 Sep 2023 10:30:52 +0200 Subject: [PATCH 0553/1140] (#19438) onnxruntime/all: bump deps * onnxruntime/all: bump onnx * bump protobuf * bump wil * remove Protobuf patch --- recipes/onnxruntime/all/conanfile.py | 6 +++--- .../all/patches/1.15.1-0001-cmake-dependencies.patch | 9 --------- 2 files changed, 3 insertions(+), 12 deletions(-) diff --git a/recipes/onnxruntime/all/conanfile.py b/recipes/onnxruntime/all/conanfile.py index c69e32a34aa82f..dc0f2dce95435e 100644 --- a/recipes/onnxruntime/all/conanfile.py +++ b/recipes/onnxruntime/all/conanfile.py @@ -68,12 +68,12 @@ def _onnx_version(self): version = Version(self.version) return { "1.14": "1.13.1", - "1.15": "1.14.0", + "1.15": "1.14.1", }[f"{version.major}.{version.minor}"] def requirements(self): self.requires("abseil/20230125.3") - self.requires("protobuf/3.21.9") + self.requires("protobuf/3.21.12") self.requires("date/3.0.1") self.requires("re2/20230801") self.requires(f"onnx/{self._onnx_version}") @@ -87,7 +87,7 @@ def requirements(self): if self.settings.os != "Windows": self.requires("nsync/1.26.0") else: - self.requires("wil/1.0.230629.1") + self.requires("wil/1.0.230824.2") if self.options.with_xnnpack: self.requires("xnnpack/cci.20220801") diff --git a/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch b/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch index bee9115bc809ef..4ebc87b3a4ddce 100644 --- a/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch +++ b/recipes/onnxruntime/all/patches/1.15.1-0001-cmake-dependencies.patch @@ -30,15 +30,6 @@ diff --git a/cmake/external/onnxruntime_external_deps.cmake b/cmake/external/onn index 9effd1a2db..a059c28e36 100644 --- a/cmake/external/onnxruntime_external_deps.cmake +++ b/cmake/external/onnxruntime_external_deps.cmake -@@ -152,7 +152,7 @@ FetchContent_Declare( - URL ${DEP_URL_protobuf} - URL_HASH SHA1=${DEP_SHA1_protobuf} - PATCH_COMMAND ${ONNXRUNTIME_PROTOBUF_PATCH_COMMAND} -- FIND_PACKAGE_ARGS 3.21.12 NAMES Protobuf -+ FIND_PACKAGE_ARGS NAMES Protobuf - ) - set(protobuf_BUILD_TESTS OFF CACHE BOOL "Build protobuf tests" FORCE) - if (CMAKE_SYSTEM_NAME STREQUAL "Android") @@ -173,6 +173,7 @@ FetchContent_Declare( date URL ${DEP_URL_date} From 5c257277231e50416ff7aea644fdfaa639b11f92 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 7 Sep 2023 11:32:50 +0200 Subject: [PATCH 0554/1140] (#19557) gdk-pixbuf: bump glib MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * gdk-pixbuf: bump glib * Update conanfile.py * Remove old glib workaround * Bump libpng --------- Co-authored-by: Rubén Rincón Blanco --- recipes/gdk-pixbuf/all/conanfile.py | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/recipes/gdk-pixbuf/all/conanfile.py b/recipes/gdk-pixbuf/all/conanfile.py index fe76b0dd2bad42..4f44d797427e77 100644 --- a/recipes/gdk-pixbuf/all/conanfile.py +++ b/recipes/gdk-pixbuf/all/conanfile.py @@ -12,13 +12,13 @@ import os -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.56.0 <2 || >=2.0.6" class GdkPixbufConan(ConanFile): name = "gdk-pixbuf" description = "toolkit for image loading and pixel buffer manipulation" - topics = ("gdk-pixbuf", "image") + topics = ("image") url = "https://github.com/conan-io/conan-center-index" homepage = "https://developer.gnome.org/gdk-pixbuf/" license = "LGPL-2.1-or-later" @@ -63,9 +63,9 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glib/2.76.0", transitive_headers=True, transitive_libs=True, run=can_run(self)) + self.requires("glib/2.77.0", transitive_headers=True, transitive_libs=True) if self.options.with_libpng: - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") if self.options.with_libtiff: self.requires("libtiff/4.4.0") if self.options.with_libjpeg == "libjpeg-turbo": @@ -93,8 +93,7 @@ def build_requirements(self): self.tool_requires("meson/1.0.0") if not self.conf.get("tools.gnu:pkg_config", check_type=str): self.tool_requires("pkgconf/1.9.3") - if not can_run(self): - self.tool_requires("glib/2.76.0") + self.tool_requires("glib/") if self.options.with_introspection: self.tool_requires("gobject-introspection/1.72.0") From 211cb331e24e6f7e6226f9acf441264d28d5ec77 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 19:15:55 +0900 Subject: [PATCH 0555/1140] (#19616) wasmer: add version 4.2.0 --- recipes/wasmer/all/conandata.yml | 27 +++++++++++++++++++++++++++ recipes/wasmer/config.yml | 2 ++ 2 files changed, 29 insertions(+) diff --git a/recipes/wasmer/all/conandata.yml b/recipes/wasmer/all/conandata.yml index 9f36767ca9925e..8b03fa42930cd7 100644 --- a/recipes/wasmer/all/conandata.yml +++ b/recipes/wasmer/all/conandata.yml @@ -1,4 +1,31 @@ sources: + "4.2.0": + Windows: + "x86_64": + "Visual Studio": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-windows-amd64.tar.gz" + sha256: "f2eeff46e6974f06d1ee3dc64515a2fbd9f0897575ce7e8ed5c6e3b4353ded24" + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-windows-gnu64.tar.gz" + sha256: "13374b1d781a2aec2cb981f8c38ad0935476c7d508b993bc48f684a13e283943" + Linux: + "x86_64": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-linux-amd64.tar.gz" + sha256: "3ea947b1accb6247aa90d914331132827c49a422d2dba8459e2f0cf02c1acf80" + "armv8": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-linux-aarch64.tar.gz" + sha256: "681fe6ad3e7f139d3d2ed8cfbf6ceb4d54098c32da9663bbf849e6429d6e8f1c" + Macos: + "x86_64": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-darwin-amd64.tar.gz" + sha256: "4d629eafe6d7249b276691cb0f834d7d00cf89953700628abe06a224f76b7d79" + "armv8": + "gcc": + url: "https://github.com/wasmerio/wasmer/releases/download/v4.2.0/wasmer-darwin-arm64.tar.gz" + sha256: "ab928c3717c2597f484868d5d97baabe939bffeb1ba38f348bcda9c828022069" "4.1.1": Windows: "x86_64": diff --git a/recipes/wasmer/config.yml b/recipes/wasmer/config.yml index bac9dd3778328e..1f9b03131e5700 100644 --- a/recipes/wasmer/config.yml +++ b/recipes/wasmer/config.yml @@ -1,4 +1,6 @@ versions: + "4.2.0": + folder: "all" "4.1.1": folder: "all" "4.0.0": From d7b63348552d3e26fb2b581f9ed8923fe2a6ded3 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 19:53:11 +0900 Subject: [PATCH 0556/1140] (#19623) zmqpp: support conan v2 more, add patch description * zmqpp: support conan v2 more, add patch description * make zeromq transitive_libs Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/zmqpp/all/conandata.yml | 6 ++++++ recipes/zmqpp/all/conanfile.py | 26 +++++++++++++------------- 2 files changed, 19 insertions(+), 13 deletions(-) diff --git a/recipes/zmqpp/all/conandata.yml b/recipes/zmqpp/all/conandata.yml index b8b843edf38c8e..4bc0fe616e5744 100644 --- a/recipes/zmqpp/all/conandata.yml +++ b/recipes/zmqpp/all/conandata.yml @@ -5,5 +5,11 @@ sources: patches: "4.2.0": - patch_file: "patches/0001-fix-cmake.patch" + patch_description: "use cci's zeromq, separate shared and static build" + patch_type: "conan" - patch_file: "patches/0002-missing-includes.patch" + patch_description: "include missing includes" + patch_type: "portability" - patch_file: "patches/0003-Allow-building-with-Werror-undef.patch" + patch_description: "fix WIN32 detection" + patch_type: "portability" diff --git a/recipes/zmqpp/all/conanfile.py b/recipes/zmqpp/all/conanfile.py index 8d4bf7d455227f..a4ed7a7549f25e 100644 --- a/recipes/zmqpp/all/conanfile.py +++ b/recipes/zmqpp/all/conanfile.py @@ -4,20 +4,20 @@ from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.53.0" class ZmqppConan(ConanFile): name = "zmqpp" - homepage = "https://github.com/zeromq/zmqpp" - license = "MPL-2.0" - url = "https://github.com/conan-io/conan-center-index" description = ( "This C++ binding for 0mq/zmq is a 'high-level' library that hides " "most of the c-style interface core 0mq provides." ) + license = "MPL-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/zeromq/zmqpp" topics = ("zmq", "0mq", "zeromq", "message-queue", "asynchronous") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -28,6 +28,10 @@ class ZmqppConan(ConanFile): "fPIC": True, } + @property + def _min_cppstd(self): + return 11 + def export_sources(self): export_conandata_patches(self) @@ -37,24 +41,20 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass + self.options.rm_safe("fPIC") def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zeromq/4.3.4") + self.requires("zeromq/4.3.4", transitive_headers=True, transitive_libs=True) def validate(self): if self.info.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 11) + check_min_cppstd(self, self._min_cppstd) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) From 96d8d9952ca43b1ff87159019908ca7851616b47 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 20:37:25 +0900 Subject: [PATCH 0557/1140] (#19635) wasmtime: add version 12.0.1 --- recipes/wasmtime/all/conandata.yml | 30 ++++++++++++++++++++++++++++++ recipes/wasmtime/config.yml | 2 ++ 2 files changed, 32 insertions(+) diff --git a/recipes/wasmtime/all/conandata.yml b/recipes/wasmtime/all/conandata.yml index e337fecbbe9778..59e975128a2ee3 100644 --- a/recipes/wasmtime/all/conandata.yml +++ b/recipes/wasmtime/all/conandata.yml @@ -1,4 +1,34 @@ sources: + "12.0.1": + Windows: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-x86_64-windows-c-api.zip" + sha256: "e5da4752260ffd38e28cc56fc1db6f3cec65f9bf352b5e9757a92873e5a6f408" + MinGW: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-x86_64-mingw-c-api.zip" + sha256: "7b7a6c7d3e2603ec51837c28ec5c9306d599d44b707d052faa5102c691e07685" + Linux: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-x86_64-linux-c-api.tar.xz" + sha256: "7f09952cba8e92ff3bd18ad59b847fb353a6cd6c9069b38c1b9763610616347f" + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-aarch64-linux-c-api.tar.xz" + sha256: "fd7080f59413aca47e473e2f2517fbd75ef16d963925a7333c09d0621c81b449" + "s390x": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-s390x-linux-c-api.tar.xz" + sha256: "4482d42cf683f5ee4213fcb1c69f0b5fa7b4d948186d26ae6f647cc92ac4e779" + Macos: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-x86_64-macos-c-api.tar.xz" + sha256: "89059ed138cb59c8c1f9008053da848d3d9e15c5edfe1a3f2f2d7c0c5bbf9597" + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-aarch64-macos-c-api.tar.xz" + sha256: "8dca391f22cf53ae4b19a689e3a2cce87541bb4575a98d2f402f36402be419f7" + Android: + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.1/wasmtime-v12.0.1-aarch64-linux-c-api.tar.xz" + sha256: "fd7080f59413aca47e473e2f2517fbd75ef16d963925a7333c09d0621c81b449" "9.0.1": Windows: "x86_64": diff --git a/recipes/wasmtime/config.yml b/recipes/wasmtime/config.yml index dbe6065513d63b..de77d1db49a4f3 100644 --- a/recipes/wasmtime/config.yml +++ b/recipes/wasmtime/config.yml @@ -1,4 +1,6 @@ versions: + "12.0.1": + folder: all "9.0.1": folder: all "7.0.0": From 47aa07a40037dea99836ec706b49d069ae16998c Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 7 Sep 2023 21:13:14 +0900 Subject: [PATCH 0558/1140] (#19636) octo-keygen-cpp: update dependencies, add package_type --- recipes/octo-keygen-cpp/all/conandata.yml | 4 +- recipes/octo-keygen-cpp/all/conanfile.py | 72 ++++++++++--------- .../all/test_package/CMakeLists.txt | 8 +-- .../all/test_package/conanfile.py | 8 +-- .../all/test_package/test_package.cpp | 18 ----- 5 files changed, 48 insertions(+), 62 deletions(-) diff --git a/recipes/octo-keygen-cpp/all/conandata.yml b/recipes/octo-keygen-cpp/all/conandata.yml index 1915a524b0e388..2fde3196d3682a 100644 --- a/recipes/octo-keygen-cpp/all/conandata.yml +++ b/recipes/octo-keygen-cpp/all/conandata.yml @@ -1,4 +1,4 @@ sources: "1.0.0": - sha256: c4c60b4defed781d164e8fcc002c98df6fef0166ac2a18c7919dbbda22accecf - url: https://github.com/ofiriluz/octo-keygen-cpp/archive/refs/tags/v1.0.0.tar.gz + url: "https://github.com/ofiriluz/octo-keygen-cpp/archive/refs/tags/v1.0.0.tar.gz" + sha256: "c4c60b4defed781d164e8fcc002c98df6fef0166ac2a18c7919dbbda22accecf" diff --git a/recipes/octo-keygen-cpp/all/conanfile.py b/recipes/octo-keygen-cpp/all/conanfile.py index 52e5634af7ecfe..b9e37112cb2f5f 100644 --- a/recipes/octo-keygen-cpp/all/conanfile.py +++ b/recipes/octo-keygen-cpp/all/conanfile.py @@ -2,8 +2,9 @@ from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout from conan.tools.files import get, copy from conan.tools.build import check_min_cppstd -from conan.errors import ConanInvalidConfiguration from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc_static_runtime +from conan.errors import ConanInvalidConfiguration import os required_conan_version = ">=1.50.0" @@ -11,12 +12,17 @@ class OctoKeygenCPPConan(ConanFile): name = "octo-keygen-cpp" + description = "Key generation / certificate generation using openssl for CPP" license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/ofiriluz/octo-keygen-cpp" - description = "Octo keygen library" topics = ("pki", "keypair", "certificates", "cpp") - settings = "os", "compiler", "build_type", "arch" + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + + @property + def _min_cppstd(self): + return 17 @property def _compilers_minimum_version(self): @@ -25,47 +31,43 @@ def _compilers_minimum_version(self): "clang": "9", "apple-clang": "11", "Visual Studio": "16", - "msvc": "1923", + "msvc": "192", } - def generate(self): - tc = CMakeToolchain(self) - tc.variables["DISABLE_TESTS"] = True - tc.generate() - cd = CMakeDeps(self) - cd.generate() - def layout(self): cmake_layout(self, src_folder="src") - def validate(self): - if self.info.settings.compiler.cppstd: - check_min_cppstd(self, "17") + def requirements(self): + self.requires("octo-logger-cpp/1.1.0", transitive_headers=True) + self.requires("octo-encryption-cpp/1.1.0", transitive_headers=True) + self.requires("fmt/10.1.1") + self.requires("openssl/[>=1.1 <4]") + def validate(self): + if self.info.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration( - f"{self.name} requires C++17, which your compiler does not support." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - else: - self.output.warn(f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17.") if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": - raise ConanInvalidConfiguration(f"{self.name} does not support clang with libc++. Use libstdc++ instead.") - if self.settings.compiler == "Visual Studio" and self.settings.compiler.runtime in ["MTd", "MT"]: - raise ConanInvalidConfiguration(f"{self.name} does not support MSVC MT/MTd configurations, only MD/MDd is supported") + raise ConanInvalidConfiguration(f"{self.ref} does not support clang with libc++. Use libstdc++ instead.") + if is_msvc_static_runtime(self): + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC MT/MTd configurations, only MD/MDd is supported") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") - def requirements(self): - self.requires("octo-logger-cpp/1.1.0") - self.requires("octo-encryption-cpp/1.1.0") - self.requires("fmt/9.0.0") - self.requires("openssl/1.1.1q") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build_requirements(self): - self.tool_requires("cmake/3.24.0") + def generate(self): + tc = CMakeToolchain(self) + tc.variables["DISABLE_TESTS"] = True + tc.generate() + cd = CMakeDeps(self) + cd.generate() def build(self): cmake = CMake(self) @@ -78,16 +80,18 @@ def package(self): cmake.install() def package_info(self): + self.cpp_info.libs = ["octo-keygen-cpp"] self.cpp_info.set_property("cmake_file_name", "octo-keygen-cpp") self.cpp_info.set_property("cmake_target_name", "octo::octo-keygen-cpp") self.cpp_info.set_property("pkg_config_name", "octo-keygen-cpp") - self.cpp_info.libs = ["octo-keygen-cpp"] - self.cpp_info.names["cmake_find_package"] = "octo-keygen-cpp" - self.cpp_info.names["cmake_find_package_multi"] = "octo-keygen-cpp" - self.cpp_info.names["pkg_config"] = "octo-keygen-cpp" self.cpp_info.requires = [ "fmt::fmt", "openssl::openssl", "octo-logger-cpp::octo-logger-cpp", "octo-encryption-cpp::octo-encryption-cpp" ] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "octo-keygen-cpp" + self.cpp_info.names["cmake_find_package_multi"] = "octo-keygen-cpp" + self.cpp_info.names["pkg_config"] = "octo-keygen-cpp" diff --git a/recipes/octo-keygen-cpp/all/test_package/CMakeLists.txt b/recipes/octo-keygen-cpp/all/test_package/CMakeLists.txt index 7a68c9f36c4bf5..ec355db2143f37 100644 --- a/recipes/octo-keygen-cpp/all/test_package/CMakeLists.txt +++ b/recipes/octo-keygen-cpp/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(octo-keygen-cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} octo::octo-keygen-cpp) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE octo::octo-keygen-cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/octo-keygen-cpp/all/test_package/conanfile.py b/recipes/octo-keygen-cpp/all/test_package/conanfile.py index 6f1d3245dd7e80..bb7197d60a7c5d 100644 --- a/recipes/octo-keygen-cpp/all/test_package/conanfile.py +++ b/recipes/octo-keygen-cpp/all/test_package/conanfile.py @@ -7,11 +7,11 @@ class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "CMakeDeps", "VirtualRunEnv" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" - def generate(self): - tc = CMakeToolchain(self) - tc.generate() + def requirements(self): + self.requires(self.tested_reference_str) def layout(self): cmake_layout(self) diff --git a/recipes/octo-keygen-cpp/all/test_package/test_package.cpp b/recipes/octo-keygen-cpp/all/test_package/test_package.cpp index 98222f149cce9a..418c7b3cdcaa5c 100644 --- a/recipes/octo-keygen-cpp/all/test_package/test_package.cpp +++ b/recipes/octo-keygen-cpp/all/test_package/test_package.cpp @@ -13,7 +13,6 @@ #include "octo-keygen-cpp/openssl/ssl-keypair.hpp" #include "octo-keygen-cpp/openssl/ssl-keypair-certificate-chain.hpp" #include "octo-keygen-cpp/openssl/ssl-keypair-certificate.hpp" -#include #include #include @@ -87,16 +86,6 @@ constexpr auto TARGET_CERT = "-----BEGIN CERTIFICATE-----\n" int main(int argc, char** argv) { - octo::logger::Logger logger("PSKeygen"); - std::shared_ptr config = - std::make_shared(); - octo::logger::SinkConfig console_writer_sink("Console", octo::logger::SinkConfig::SinkType::CONSOLE_SINK); - config->add_sink(console_writer_sink); - octo::logger::Manager::instance() - .editable_channel("PSKeygen") - .set_log_level(octo::logger::Log::LogLevel::DEBUG); - octo::logger::Manager::instance().configure(config); - auto ca = octo::keygen::ssl::SSLKeypairCertificateChain::load_certificate_chain( std::make_unique(ROOTCA) ); @@ -106,18 +95,11 @@ int main(int argc, char** argv) auto chain = octo::keygen::ssl::SSLKeypairCertificateChain::load_certificate_chain( std::make_unique(SUBCA) ); - logger.info() << "IS CA = " << ca->is_any_ca(); - logger.info() << "IS VALID CERT = " << ca->is_valid_chain(target.get(), - chain.get()); octo::keygen::KeygenPtr ssl_key_gen = std::make_shared(); octo::keygen::KeygenOptions ssl_opts; octo::keygen::KeypairPtr ssl_key_pair = ssl_key_gen->generate_keypair(ssl_opts); - logger.info() << "\n" << ssl_key_pair->private_key(); - logger.info() << "\n" << ssl_key_pair->public_key(); octo::keygen::KeygenOptions ssl_sign_opts; octo::keygen::KeypairCertificatePtr ssl_cert = ssl_key_gen->sign_key_pair(ssl_key_pair, ssl_sign_opts); - logger.info() << "\n" << ssl_cert->certificate(); - logger.info() << "\n" << ssl_cert->pretty_print_certificate_info(); } From bd5ac37105e41eec9963f65ad8b39fad49b6c7ac Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 7 Sep 2023 19:31:04 +0300 Subject: [PATCH 0559/1140] (#18733) tinkerforge-bindings: migrate to Conan v2 * tinkerforge-bindings: migrate to Conan v2 * tinkerforge-bindings: restore VirtualRunEnv in test_package --- .../tinkerforge-bindings/all/CMakeLists.txt | 11 +-- recipes/tinkerforge-bindings/all/conanfile.py | 74 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 18 ++++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 16 ++++ 6 files changed, 82 insertions(+), 52 deletions(-) create mode 100644 recipes/tinkerforge-bindings/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tinkerforge-bindings/all/test_v1_package/conanfile.py diff --git a/recipes/tinkerforge-bindings/all/CMakeLists.txt b/recipes/tinkerforge-bindings/all/CMakeLists.txt index 2ea059e4508bae..9c3750e3fa826c 100644 --- a/recipes/tinkerforge-bindings/all/CMakeLists.txt +++ b/recipes/tinkerforge-bindings/all/CMakeLists.txt @@ -1,11 +1,10 @@ cmake_minimum_required(VERSION 3.4) project(tinkerforge_bindings) -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +set(SOURCES_DIR ${CMAKE_CURRENT_LIST_DIR}/src) -file(GLOB SOURCES ${CMAKE_SOURCE_DIR}/source_subfolder/source/*.c) -file(GLOB HEADERS ${CMAKE_SOURCE_DIR}/source_subfolder/source/*.h) +file(GLOB SOURCES ${SOURCES_DIR}/source/*.c) +file(GLOB HEADERS ${SOURCES_DIR}/source/*.h) if(WIN32 AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) @@ -17,10 +16,8 @@ if(MSVC) target_link_libraries(${PROJECT_NAME} PRIVATE ws2_32 advapi32) endif() +include(GNUInstallDirs) set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER "${HEADERS}") install(TARGETS ${PROJECT_NAME} - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib - RUNTIME DESTINATION bin PUBLIC_HEADER DESTINATION include ) diff --git a/recipes/tinkerforge-bindings/all/conanfile.py b/recipes/tinkerforge-bindings/all/conanfile.py index fb57c7fccf3f72..f287887f2f3ea7 100644 --- a/recipes/tinkerforge-bindings/all/conanfile.py +++ b/recipes/tinkerforge-bindings/all/conanfile.py @@ -1,17 +1,23 @@ -from conans import ConanFile, tools, CMake -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.microsoft import is_msvc_static_runtime + +required_conan_version = ">=1.53.0" + class TinkerforgeBindingsConan(ConanFile): name = "tinkerforge-bindings" + description = "API bindings to control Tinkerforge's Bricks and Bricklets" + license = "CC0 1.0 Universal" url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.tinkerforge.com/" - license = "CC0 1.0 Universal" - description = "API bindings to control Tinkerforge's Bricks and Bricklets" - topics = "iot", "maker", "bindings" + topics = ("iot", "maker", "bindings") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -22,19 +28,8 @@ class TinkerforgeBindingsConan(ConanFile): "fPIC": True, } - _cmake = None - generators = "cmake" - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - def export_sources(self): - self.copy("CMakeLists.txt") + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -42,40 +37,41 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): - if self.settings.compiler == "Visual Studio" and self.options.shared and "MT" in self.settings.compiler.runtime: + if self.options.shared and is_msvc_static_runtime(self): raise ConanInvalidConfiguration("Static runtime + shared is failing to link") def source(self): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=False) + get(self, **self.conan_data["sources"][self.version], strip_root=False) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.source_path.parent) cmake.build() def package(self): - self.copy("license.txt", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "license.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): + self.cpp_info.set_property("cmake_file_name", "tinkerforge-bindings") self.cpp_info.set_property("cmake_target_name", "tinkerforge::bindings") - self.cpp_info.names["cmake_find_package"] = "tinkerforge" - self.cpp_info.names["cmake_find_package_multi"] = "tinkerforge" - self.cpp_info.filenames["cmake_find_package"] = "tinkerforge-bindings" - self.cpp_info.filenames["cmake_find_package_multi"] = "tinkerforge-bindings" + self.cpp_info.components["_bindings"].set_property("cmake_target_name", "bindings") self.cpp_info.components["_bindings"].names["cmake_find_package"] = "bindings" self.cpp_info.components["_bindings"].names["cmake_find_package_multi"] = "bindings" self.cpp_info.components["_bindings"].libs = ["tinkerforge_bindings"] @@ -84,3 +80,9 @@ def package_info(self): self.cpp_info.components["_bindings"].system_libs = ["pthread"] elif self.settings.os == "Windows": self.cpp_info.components["_bindings"].system_libs = ["advapi32", "ws2_32"] + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "tinkerforge" + self.cpp_info.names["cmake_find_package_multi"] = "tinkerforge" + self.cpp_info.filenames["cmake_find_package"] = "tinkerforge-bindings" + self.cpp_info.filenames["cmake_find_package_multi"] = "tinkerforge-bindings" diff --git a/recipes/tinkerforge-bindings/all/test_package/CMakeLists.txt b/recipes/tinkerforge-bindings/all/test_package/CMakeLists.txt index b831e148cc9c04..4be380621fecde 100644 --- a/recipes/tinkerforge-bindings/all/test_package/CMakeLists.txt +++ b/recipes/tinkerforge-bindings/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(tinkerforge-bindings REQUIRED) +find_package(tinkerforge-bindings REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} tinkerforge::bindings) diff --git a/recipes/tinkerforge-bindings/all/test_package/conanfile.py b/recipes/tinkerforge-bindings/all/test_package/conanfile.py index 0245c9a8028a3f..ef5d7042163ecc 100644 --- a/recipes/tinkerforge-bindings/all/test_package/conanfile.py +++ b/recipes/tinkerforge-bindings/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,5 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - self.run(os.path.join("bin", "test_package"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tinkerforge-bindings/all/test_v1_package/CMakeLists.txt b/recipes/tinkerforge-bindings/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/tinkerforge-bindings/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/tinkerforge-bindings/all/test_v1_package/conanfile.py b/recipes/tinkerforge-bindings/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..9b63bd176646ba --- /dev/null +++ b/recipes/tinkerforge-bindings/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "test_package"), run_environment=True) From d55139ac069a4b9b5e708ce18930392757239c9b Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 8 Sep 2023 08:35:20 +0200 Subject: [PATCH 0560/1140] (#19638) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 7491fb37d05f18..72b011e53dd5d2 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -68,6 +68,7 @@ required_for_references: - aws-crt-cpp - aws-kvs-pic - aws-libfabric +- aws-sdk-cpp - b2 - b64 - backport-cpp @@ -511,6 +512,7 @@ required_for_references: - libatomic_ops - libattr - libavif +- libb2 - libbacktrace - libbigwig - libbsd @@ -1107,8 +1109,10 @@ required_for_references: - tllist - tlx - toml11 +- tracy - trantor - tree-sitter +- tree-sitter-c - troldal-zippy - trompeloeil - tsl-hopscotch-map From 9ea2d2cf40fdc97564b5cd556a314a0529e05e53 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 8 Sep 2023 11:25:31 +0300 Subject: [PATCH 0561/1140] (#18708) lightpcapng: migrate to Conan v2 * lightpcapng: migrate to Conan v2 * lightpcapng: restore VirtualRunEnv in test_package * lightpcapng: bump deps --------- Co-authored-by: Carlos Zoido --- recipes/lightpcapng/all/CMakeLists.txt | 8 -- recipes/lightpcapng/all/conanfile.py | 78 ++++++++++--------- .../all/test_package/CMakeLists.txt | 9 +-- .../lightpcapng/all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 83 insertions(+), 58 deletions(-) delete mode 100644 recipes/lightpcapng/all/CMakeLists.txt create mode 100644 recipes/lightpcapng/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/lightpcapng/all/test_v1_package/conanfile.py diff --git a/recipes/lightpcapng/all/CMakeLists.txt b/recipes/lightpcapng/all/CMakeLists.txt deleted file mode 100644 index 5cfb924ad4de79..00000000000000 --- a/recipes/lightpcapng/all/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) - diff --git a/recipes/lightpcapng/all/conanfile.py b/recipes/lightpcapng/all/conanfile.py index ea6e74e5ca99f7..3625228ec25347 100644 --- a/recipes/lightpcapng/all/conanfile.py +++ b/recipes/lightpcapng/all/conanfile.py @@ -1,15 +1,21 @@ -from conans import ConanFile, CMake, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" + class LightPcapNgConan(ConanFile): name = "lightpcapng" - homepage = "https://github.com/Technica-Engineering/LightPcapNg" description = "Library for general-purpose tracing based on PCAPNG file format" - topics = ("pcapng", "pcap") - url = "https://github.com/conan-io/conan-center-index" license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Technica-Engineering/LightPcapNg" + topics = ("pcapng", "pcap") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -21,17 +27,6 @@ class LightPcapNgConan(ConanFile): "fPIC": True, "with_zstd": True, } - generators = "cmake", "cmake_paths", "cmake_find_package" - exports_sources = "CMakeLists.txt" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" def config_options(self): if self.settings.os == "Windows": @@ -40,43 +35,50 @@ def config_options(self): def configure(self): if self.options.with_zstd: self.options["zstd"].shared = self.options.shared - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_zstd: - self.requires("zstd/1.4.5") + self.requires("zstd/1.5.5") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LIGHT_USE_ZSTD"] = self.options.with_zstd + tc.variables["BUILD_TESTING"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["LIGHT_USE_ZSTD"] = self.options.with_zstd - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() def package_info(self): - self.cpp_info.names["cmake_find_package"] = "light_pcapng" - self.cpp_info.names["cmake_find_package_multi"] = "light_pcapng" - self.cpp_info.components["liblight_pcapng"].names["cmake_find_package"] = "light_pcapng" - self.cpp_info.components["liblight_pcapng"].names["cmake_find_package_multi"] = "light_pcapng" + self.cpp_info.set_property("cmake_file_name", "light_pcapng") + self.cpp_info.set_property("cmake_target_name", "light_pcapng::light_pcapng") self.cpp_info.components["liblight_pcapng"].libs = ["light_pcapng"] - if self.options.with_zstd: self.cpp_info.components["liblight_pcapng"].requires = ["zstd::zstd"] + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "light_pcapng" + self.cpp_info.names["cmake_find_package_multi"] = "light_pcapng" + self.cpp_info.components["liblight_pcapng"].names["cmake_find_package"] = "light_pcapng" + self.cpp_info.components["liblight_pcapng"].names["cmake_find_package_multi"] = "light_pcapng" diff --git a/recipes/lightpcapng/all/test_package/CMakeLists.txt b/recipes/lightpcapng/all/test_package/CMakeLists.txt index 8927c32d3f4ef6..f7eaac4f3f9501 100644 --- a/recipes/lightpcapng/all/test_package/CMakeLists.txt +++ b/recipes/lightpcapng/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(light_pcapng REQUIRED) +find_package(light_pcapng REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} light_pcapng::light_pcapng) diff --git a/recipes/lightpcapng/all/test_package/conanfile.py b/recipes/lightpcapng/all/test_package/conanfile.py index 3da371b660e0a3..ef5d7042163ecc 100644 --- a/recipes/lightpcapng/all/test_package/conanfile.py +++ b/recipes/lightpcapng/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/lightpcapng/all/test_v1_package/CMakeLists.txt b/recipes/lightpcapng/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/lightpcapng/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/lightpcapng/all/test_v1_package/conanfile.py b/recipes/lightpcapng/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/lightpcapng/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From ff7a8905859446d2fbd05daabfe4dd1c248a6844 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 8 Sep 2023 12:07:14 +0200 Subject: [PATCH 0562/1140] (#19670) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 72b011e53dd5d2..5cb7b126937182 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -26,6 +26,7 @@ required_for_references: - apr - apr-util - apriltag +- aravis - archicad-apidevkit - arcus - arduinojson @@ -437,6 +438,7 @@ required_for_references: - id3v2lib - iir1 - im95able-rea +- imagl - imake - imath - imgui @@ -617,6 +619,7 @@ required_for_references: - libserial - libsgp4 - libsigcpp +- libsixel - libslz - libsmacker - libsndfile @@ -802,6 +805,8 @@ required_for_references: - objectbox - objectbox-generator - observer-ptr-lite +- octo-encryption-cpp +- octo-keygen-cpp - octo-logger-cpp - octomap - odbc @@ -1212,6 +1217,7 @@ required_for_references: - zlib - zlib-ng - zmarok-semver +- zmqpp - zookeeper-client-c - zpp_bits - zstd From c85da474374847cd263be2699c35586e1cdbb971 Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Fri, 8 Sep 2023 12:57:39 +0200 Subject: [PATCH 0563/1140] (#19617) Some improvements for tree-sitter-c recipe --- recipes/tree-sitter-c/all/CMakeLists.txt | 5 ++--- recipes/tree-sitter-c/all/conanfile.py | 21 +++++++++++++++------ 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/recipes/tree-sitter-c/all/CMakeLists.txt b/recipes/tree-sitter-c/all/CMakeLists.txt index 0500a39a48fb98..a028ec4e4627cd 100644 --- a/recipes/tree-sitter-c/all/CMakeLists.txt +++ b/recipes/tree-sitter-c/all/CMakeLists.txt @@ -21,7 +21,7 @@ const TSLanguage *tree_sitter_c(void); ]]) add_library(${PROJECT_NAME} - src/src/parser.c + src/parser.c ) target_link_libraries(${PROJECT_NAME} PUBLIC @@ -29,8 +29,7 @@ target_link_libraries(${PROJECT_NAME} ) target_include_directories(${PROJECT_NAME} PRIVATE - $ - $ + $ ) set_target_properties(${PROJECT_NAME} PROPERTIES diff --git a/recipes/tree-sitter-c/all/conanfile.py b/recipes/tree-sitter-c/all/conanfile.py index 87e43c96d6c623..9f73c2c805dcef 100644 --- a/recipes/tree-sitter-c/all/conanfile.py +++ b/recipes/tree-sitter-c/all/conanfile.py @@ -1,7 +1,6 @@ from conan import ConanFile -from conan.tools.cmake import CMake +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import get, replace_in_file, copy -from conan.tools.layout import basic_layout import os required_conan_version = ">=1.53.0" @@ -16,7 +15,7 @@ class TreeSitterCConan(ConanFile): license = "MIT" settings = "os", "arch", "compiler", "build_type" package_type = "library" - generators = "CMakeToolchain", "CMakeDeps" + options = { "shared": [True, False], "fPIC": [True, False], @@ -26,11 +25,21 @@ class TreeSitterCConan(ConanFile): "fPIC": True, } - generators = "CMakeToolchain", "CMakeDeps" + exports_sources = "CMakeLists.txt" def layout(self): - basic_layout(self, src_folder="src") + cmake_layout(self, src_folder="src") + + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=(self.export_sources_folder + "/src")) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["TREE_SITTER_C_SRC_DIR"] = self.source_folder.replace("\\", "/") + tc.generate() + deps = CMakeDeps(self) + deps.generate() def config_options(self): if self.settings.os == "Windows": @@ -59,7 +68,7 @@ def _patch_sources(self): def build(self): self._patch_sources() cmake = CMake(self) - cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) + cmake.configure() cmake.build() def package(self): From 57211c1fbbcd2e218f58cbda694dbce9cbce0cdd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 8 Sep 2023 13:05:27 +0200 Subject: [PATCH 0564/1140] Change Zlib ranges docu (#19676) * Typo * better wording * Remove spaces --- docs/adding_packages/dependencies.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docs/adding_packages/dependencies.md b/docs/adding_packages/dependencies.md index c421b0a9d9f678..a69f895483ed0a 100644 --- a/docs/adding_packages/dependencies.md +++ b/docs/adding_packages/dependencies.md @@ -181,9 +181,12 @@ Currently, these are: * OpenSSL: `[>=1.1 <4]` for libraries known to be compatible with OpenSSL 1.x and 3.x * CMake: `[>3.XX <4]`, where `3.XX` is the minimum version of CMake required by the relevant build scripts -* Zlib: `[>=1.X.Y <2]`, where `1.X.Y` is the minimum version of Zlib required, starting from `1.2.10` * Libcurl: `[>=X.YY <9]`, where `X.YY` is the minimum version of Libcurl required, starting from `7.78` +> **Note**: You might also see Zlib ranges in some PR by CCI maintainers. +> We're adding them little by little to avoid missing binaries and conflict errors. +> Please do not open PRs moving Zlib to ranges for now, we'll update this page when PRs are free to add new ranges. + > **Warning**: With Conan 1.x, [version ranges](https://docs.conan.io/1/versioning/version_ranges.html) adhere to a much more strict sematic version spec, > OpenSSL 1.1.x does not follow this so the client will not resolve to that range and will pick a 3.x version. In order to select a lower version you From df0e278ed9029f9ceca67af767271ecc2f477070 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 8 Sep 2023 14:41:43 +0300 Subject: [PATCH 0565/1140] (#18738) tidy-html5: migrate to Conan v2 * tidy-html5: migrate to Conan v2 * tidy-html5: restore VirtualRunEnv in test_package * tidy-html5: set correct license ID https://spdx.org/licenses/HTMLTIDY.html --- recipes/tidy-html5/all/CMakeLists.txt | 7 -- recipes/tidy-html5/all/conandata.yml | 1 - recipes/tidy-html5/all/conanfile.py | 96 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../tidy-html5/all/test_package/conanfile.py | 21 ++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 7 files changed, 92 insertions(+), 65 deletions(-) delete mode 100644 recipes/tidy-html5/all/CMakeLists.txt create mode 100644 recipes/tidy-html5/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tidy-html5/all/test_v1_package/conanfile.py diff --git a/recipes/tidy-html5/all/CMakeLists.txt b/recipes/tidy-html5/all/CMakeLists.txt deleted file mode 100644 index e5cb637716b890..00000000000000 --- a/recipes/tidy-html5/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include("conanbuildinfo.cmake") -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/tidy-html5/all/conandata.yml b/recipes/tidy-html5/all/conandata.yml index dbfb937f0f3c26..56deb76dc5c665 100644 --- a/recipes/tidy-html5/all/conandata.yml +++ b/recipes/tidy-html5/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "5.8.0": - patch_file: "patches/0001-robust-install-pdb.patch" - base_path: "source_subfolder" diff --git a/recipes/tidy-html5/all/conanfile.py b/recipes/tidy-html5/all/conanfile.py index c7d99c3c56b673..cc182cadf26f4d 100644 --- a/recipes/tidy-html5/all/conanfile.py +++ b/recipes/tidy-html5/all/conanfile.py @@ -1,17 +1,22 @@ -from conans import ConanFile, CMake, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" class TidyHtml5Conan(ConanFile): name = "tidy-html5" - license = "W3C" + description = "The granddaddy of HTML tools, with support for modern standards" + license = "HTMLTIDY" url = "https://github.com/conan-io/conan-center-index" homepage = "http://www.html-tidy.org" - description = "The granddaddy of HTML tools, with support for modern standards" topics = ("html", "parser", "xml", "tools") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -24,17 +29,8 @@ class TidyHtml5Conan(ConanFile): "support_localizations": True, } - exports_sources = ["CMakeLists.txt", "patches/**"] - generators = "cmake" - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -42,51 +38,57 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - cmake = CMake(self) - cmake.definitions['BUILD_TAB2SPACE'] = False - cmake.definitions['BUILD_SAMPLE_CODE'] = False - cmake.definitions['TIDY_COMPAT_HEADERS'] = False - cmake.definitions['SUPPORT_CONSOLE_APP'] = False - cmake.definitions['SUPPORT_LOCALIZATIONS'] = self.options.support_localizations - cmake.definitions['ENABLE_DEBUG_LOG'] = False - cmake.definitions['ENABLE_ALLOC_DEBUG'] = False - cmake.definitions['ENABLE_MEMORY_DEBUG'] = False - cmake.definitions['BUILD_SHARED_LIB'] = self.options.shared - cmake.configure(build_folder=self._build_subfolder) - self._cmake = cmake - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_TAB2SPACE"] = False + tc.variables["BUILD_SAMPLE_CODE"] = False + tc.variables["TIDY_COMPAT_HEADERS"] = False + tc.variables["SUPPORT_CONSOLE_APP"] = False + tc.variables["SUPPORT_LOCALIZATIONS"] = self.options.support_localizations + tc.variables["ENABLE_DEBUG_LOG"] = False + tc.variables["ENABLE_ALLOC_DEBUG"] = False + tc.variables["ENABLE_MEMORY_DEBUG"] = False + tc.variables["BUILD_SHARED_LIB"] = self.options.shared + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - self.copy("LICENSE.md", dst="licenses", src=os.path.join(self._source_subfolder, 'README')) - cmake = self._configure_cmake() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "LICENSE.md", + dst=os.path.join(self.package_folder, "licenses"), + src=os.path.join(self.source_folder, "README")) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.pdb") + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.pdb", os.path.join(self.package_folder, "lib"), recursive=True) if self.options.shared: to_remove = "*tidy_static*" if self.settings.os == "Windows" else "*.a" - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), to_remove) + rm(self, to_remove, os.path.join(self.package_folder, "lib"), recursive=True) def package_info(self): - self.cpp_info.names["pkg_config"] = "tidy" - suffix = "_static" if self.settings.os == "Windows" and not self.options.shared else "" - suffix += "d" if self.settings.compiler == "Visual Studio" and self.settings.build_type == "Debug" else "" + self.cpp_info.set_property("pkg_config_name", "tidy") + suffix = "" + if self.settings.os == "Windows" and not self.options.shared: + suffix = "_static" + if is_msvc(self) and self.settings.build_type == "Debug": + suffix += "d" self.cpp_info.libs = ["tidy" + suffix] if self.settings.os == "Windows" and not self.options.shared: self.cpp_info.defines.append("TIDY_STATIC") diff --git a/recipes/tidy-html5/all/test_package/CMakeLists.txt b/recipes/tidy-html5/all/test_package/CMakeLists.txt index 7b9b613cbb24a3..e21ed1c05b78fa 100644 --- a/recipes/tidy-html5/all/test_package/CMakeLists.txt +++ b/recipes/tidy-html5/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(tidy-html5 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE tidy-html5::tidy-html5) diff --git a/recipes/tidy-html5/all/test_package/conanfile.py b/recipes/tidy-html5/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/tidy-html5/all/test_package/conanfile.py +++ b/recipes/tidy-html5/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tidy-html5/all/test_v1_package/CMakeLists.txt b/recipes/tidy-html5/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/tidy-html5/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/tidy-html5/all/test_v1_package/conanfile.py b/recipes/tidy-html5/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/tidy-html5/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b2f903b863a13b8d575c723a14f6066ad317b827 Mon Sep 17 00:00:00 2001 From: Klaus Holst Jacobsen <48069914+klausholstjacobsen@users.noreply.github.com> Date: Fri, 8 Sep 2023 16:53:30 +0200 Subject: [PATCH 0566/1140] (#19023) dsp-filters/20170309: Added dsp-filters recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * dsp-filters: Added dsp-filters recipe * Copying proper package files also on windows * MAde recipe msvc compliant * Added missing final endline * Added "m" system lib * Cleanup * Update recipes/dsp-filters/all/conandata.yml * Update recipes/dsp-filters/all/conandata.yml * Update recipes/dsp-filters/config.yml --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Carlos Zoido --- recipes/dsp-filters/all/conandata.yml | 12 +++ recipes/dsp-filters/all/conanfile.py | 74 +++++++++++++++++++ .../0001-remove-explicit-cmake-options.patch | 14 ++++ .../0002-remove-msvc-cmake-flags.patch | 14 ++++ .../all/test_package/CMakeLists.txt | 7 ++ .../dsp-filters/all/test_package/conanfile.py | 29 ++++++++ .../all/test_package/test_package.cpp | 11 +++ recipes/dsp-filters/config.yml | 3 + 8 files changed, 164 insertions(+) create mode 100644 recipes/dsp-filters/all/conandata.yml create mode 100644 recipes/dsp-filters/all/conanfile.py create mode 100644 recipes/dsp-filters/all/patches/0001-remove-explicit-cmake-options.patch create mode 100644 recipes/dsp-filters/all/patches/0002-remove-msvc-cmake-flags.patch create mode 100644 recipes/dsp-filters/all/test_package/CMakeLists.txt create mode 100644 recipes/dsp-filters/all/test_package/conanfile.py create mode 100644 recipes/dsp-filters/all/test_package/test_package.cpp create mode 100644 recipes/dsp-filters/config.yml diff --git a/recipes/dsp-filters/all/conandata.yml b/recipes/dsp-filters/all/conandata.yml new file mode 100644 index 00000000000000..17f324a8e1446b --- /dev/null +++ b/recipes/dsp-filters/all/conandata.yml @@ -0,0 +1,12 @@ +sources: + "cci.20170309": + url: "https://github.com/vinniefalco/DSPFilters/archive/acc49170e79a94fcb9c04b8a2116e9f8dffd1c7d.tar.gz" + sha256: "330c3960e55b8cdbf041d8ec4790a21a326dc331e43bf14c144ae5d88a47d53d" +patches: + "cci.20170309": + - patch_file: "patches/0001-remove-explicit-cmake-options.patch" + patch_description: "Remove explicit STATIC and FPIC options in CMakeLists.txt" + patch_type: "conan" + - patch_file: "patches/0002-remove-msvc-cmake-flags.patch" + patch_description: "Remove MY_FLAGS options in CMakeLists.txt" + patch_type: "conan" diff --git a/recipes/dsp-filters/all/conanfile.py b/recipes/dsp-filters/all/conanfile.py new file mode 100644 index 00000000000000..d4ef17870d0514 --- /dev/null +++ b/recipes/dsp-filters/all/conanfile.py @@ -0,0 +1,74 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout +from conan.tools.files import copy, get, apply_conandata_patches, export_conandata_patches, rename +from conan.tools.microsoft import is_msvc +import os + +required_conan_version = ">=1.53.0" + +class DSPFiltersConan(ConanFile): + name = "dsp-filters" + description = "Set of DSP filters" + topics = ("dsp", "filters") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/vinniefalco/DSPFilters" + license = "MIT" + settings = "os", "arch", "compiler", "build_type" + package_type = "library" + + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def validate(self): + # in case it does not work in another configuration, it should validated here too + if is_msvc(self) and self.options.shared: + raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") + + def export_sources(self): + export_conandata_patches(self) + + def layout(self): + cmake_layout(self, src_folder="src") + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + + def build(self): + apply_conandata_patches(self) + + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, "shared")) + cmake.build() + + def package(self): + copy(self, "lib*", src=os.path.join(self.build_folder, "DSPFilters"), dst=os.path.join(self.package_folder, "lib"), keep_path=False) + copy(self, "DSPFilters.lib", src=os.path.join(self.build_folder, "DSPFilters", f"{self.settings.build_type}"), dst=os.path.join(self.package_folder, "lib"), keep_path=False) + + copy(self, "*.h", src=os.path.join(self.source_folder, "shared", "DSPFilters", "include"), dst=os.path.join(self.package_folder, "include")) + copy(self, "README.md", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + rename(self, src=os.path.join(self.package_folder, "licenses", "README.md"), dst=os.path.join(self.package_folder, "licenses", "license")) + + def package_info(self): + self.cpp_info.libs = ["DSPFilters"] + + if self.settings.os in ["Linux", "FreeBSD", "Neutrino"]: + self.cpp_info.system_libs.extend(["m"]) diff --git a/recipes/dsp-filters/all/patches/0001-remove-explicit-cmake-options.patch b/recipes/dsp-filters/all/patches/0001-remove-explicit-cmake-options.patch new file mode 100644 index 00000000000000..cece818ce0db26 --- /dev/null +++ b/recipes/dsp-filters/all/patches/0001-remove-explicit-cmake-options.patch @@ -0,0 +1,14 @@ +--- shared/DSPFilters/CMakeLists.txt 2017-03-09 13:40:27.000000000 +0100 ++++ shared/DSPFilters/CMakeLists.txt 2023-08-03 09:10:56.248123716 +0200 +@@ -4,10 +4,8 @@ + + aux_source_directory(${CMAKE_CURRENT_SOURCE_DIR}/source SOURCE_LIB) + +-add_library(${PROJECT_NAME} STATIC ${SOURCE_LIB}) ++add_library(${PROJECT_NAME} ${SOURCE_LIB}) + + target_include_directories(${PROJECT_NAME} + PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/include) + +-set_property(TARGET ${PROJECT_NAME} PROPERTY POSITION_INDEPENDENT_CODE ON) +- diff --git a/recipes/dsp-filters/all/patches/0002-remove-msvc-cmake-flags.patch b/recipes/dsp-filters/all/patches/0002-remove-msvc-cmake-flags.patch new file mode 100644 index 00000000000000..e16d647a99e9c3 --- /dev/null +++ b/recipes/dsp-filters/all/patches/0002-remove-msvc-cmake-flags.patch @@ -0,0 +1,14 @@ +--- shared/CMakeLists.txt 2023-08-28 13:14:13.868202500 +0200 ++++ shared/CMakeLists.txt 2023-08-28 13:14:42.827596800 +0200 +@@ -8,11 +8,6 @@ + set(CMAKE_BUILD_TYPE Release) + + if((${CMAKE_CXX_COMPILER_ID} STREQUAL MSVC)) +- set(MYFLAGS "/O2 /WX- /MT") +- set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${MYFLAGS}") +- set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} ${MYFLAGS}") +- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${MYFLAGS}") +- set(CMAKE_C_FLAGS_RELEASE "${CMAKE_C_FLAGS_RELEASE} ${MYFLAGS}") + include(CheckSymbolExists) + check_symbol_exists(snprintf "stdio.h" HAVE_SNPRINTF) + if(NOT HAVE_SNPRINTF) diff --git a/recipes/dsp-filters/all/test_package/CMakeLists.txt b/recipes/dsp-filters/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..f823007a47a745 --- /dev/null +++ b/recipes/dsp-filters/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.14.0) +project(test_package LANGUAGES CXX) + +find_package(dsp-filters REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE dsp-filters::dsp-filters) diff --git a/recipes/dsp-filters/all/test_package/conanfile.py b/recipes/dsp-filters/all/test_package/conanfile.py new file mode 100644 index 00000000000000..922d35b61f37a5 --- /dev/null +++ b/recipes/dsp-filters/all/test_package/conanfile.py @@ -0,0 +1,29 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not can_run(self): + return + + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/dsp-filters/all/test_package/test_package.cpp b/recipes/dsp-filters/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..10690f2821e166 --- /dev/null +++ b/recipes/dsp-filters/all/test_package/test_package.cpp @@ -0,0 +1,11 @@ +#include + +#include + +int main() { + Dsp::SimpleFilter, 1> f; + f.setup(1, 100, 1000); + f.reset(); + + return 0; +} diff --git a/recipes/dsp-filters/config.yml b/recipes/dsp-filters/config.yml new file mode 100644 index 00000000000000..d7e185cf9c9647 --- /dev/null +++ b/recipes/dsp-filters/config.yml @@ -0,0 +1,3 @@ +versions: + "cci.20170309": + folder: all From 41b2eead38891495043f0f5d3a16b92135718bd2 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 9 Sep 2023 01:41:43 +0900 Subject: [PATCH 0567/1140] (#19602) mpc: add version 1.3.1, update dependencies, fix homepage * mpc: add version 1.3.1, update dependenies * just beautification --- recipes/mpc/all/conandata.yml | 11 ++++--- recipes/mpc/all/conanfile.py | 33 ++++++++++++--------- recipes/mpc/all/test_package/CMakeLists.txt | 2 +- recipes/mpc/all/test_package/conanfile.py | 3 +- recipes/mpc/config.yml | 2 ++ 5 files changed, 31 insertions(+), 20 deletions(-) diff --git a/recipes/mpc/all/conandata.yml b/recipes/mpc/all/conandata.yml index cd8f83a739d7d6..8f24801eccbac3 100644 --- a/recipes/mpc/all/conandata.yml +++ b/recipes/mpc/all/conandata.yml @@ -1,10 +1,13 @@ sources: + "1.3.1": + url: "https://ftp.gnu.org/gnu/mpc/mpc-1.3.1.tar.gz" + sha256: "ab642492f5cf882b74aa0cb730cd410a81edcdbec895183ce930e706c1c759b8" "1.2.0": - url: https://ftp.gnu.org/gnu/mpc/mpc-1.2.0.tar.gz - sha256: e90f2d99553a9c19911abdb4305bf8217106a957e3994436428572c8dfe8fda6 + url: "https://ftp.gnu.org/gnu/mpc/mpc-1.2.0.tar.gz" + sha256: "e90f2d99553a9c19911abdb4305bf8217106a957e3994436428572c8dfe8fda6" "1.1.0": - url: https://ftp.gnu.org/gnu/mpc/mpc-1.1.0.tar.gz - sha256: 6985c538143c1208dcb1ac42cedad6ff52e267b47e5f970183a3e75125b43c2e + url: "https://ftp.gnu.org/gnu/mpc/mpc-1.1.0.tar.gz" + sha256: "6985c538143c1208dcb1ac42cedad6ff52e267b47e5f970183a3e75125b43c2e" patches: "1.2.0": - patch_file: "patches/1.2.0-0001-asin-missing-limits.patch" diff --git a/recipes/mpc/all/conanfile.py b/recipes/mpc/all/conanfile.py index f996155628e5c3..820b8fd1588b87 100644 --- a/recipes/mpc/all/conanfile.py +++ b/recipes/mpc/all/conanfile.py @@ -14,16 +14,22 @@ class MpcConan(ConanFile): name = "mpc" - package_type = "library" description = "GNU MPC is a C library for the arithmetic of complex numbers with arbitrarily high precision " \ "and correct rounding of the result" - topics = ("conan", "mpc", "multiprecision", "math", "mathematics") - url = "https://github.com/conan-io/conan-center-index" - homepage = "http://www.multiprecision.org/mpc/home.html" license = "LGPL-3.0-or-later" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.multiprecision.org/" + topics = ("multiprecision", "math", "mathematics") settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} + package_type = "library" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } def export_sources(self): export_conandata_patches(self) @@ -38,14 +44,17 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def layout(self): + basic_layout(self, src_folder="src") + def requirements(self): - self.requires("gmp/6.2.1", transitive_headers=True) - self.requires("mpfr/4.1.0", transitive_headers=True) + self.requires("gmp/6.3.0", transitive_headers=True) + self.requires("mpfr/4.2.0", transitive_headers=True) def validate(self): # FIXME: add msvc support, upstream has a makefile.vc if is_msvc(self): - raise ConanInvalidConfiguration("mpc can be built with msvc, but it's not supported yet in this recipe.") + raise ConanInvalidConfiguration(f"{self.ref} can be built with msvc, but it's not supported yet in this recipe.") @property def _settings_build(self): @@ -57,12 +66,8 @@ def build_requirements(self): if not self.conf.get("tools.microsoft.bash:path", check_type=str): self.tool_requires("msys2/cci.latest") - def layout(self): - basic_layout(self, src_folder="src") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): env = VirtualBuildEnv(self) diff --git a/recipes/mpc/all/test_package/CMakeLists.txt b/recipes/mpc/all/test_package/CMakeLists.txt index 5167a095daebe6..3a407d4714c495 100644 --- a/recipes/mpc/all/test_package/CMakeLists.txt +++ b/recipes/mpc/all/test_package/CMakeLists.txt @@ -1,5 +1,5 @@ cmake_minimum_required(VERSION 3.1) -project(test_package C) +project(test_package LANGUAGES C) find_package(mpc REQUIRED CONFIG) diff --git a/recipes/mpc/all/test_package/conanfile.py b/recipes/mpc/all/test_package/conanfile.py index da190011b6b6d2..45240bc8742292 100644 --- a/recipes/mpc/all/test_package/conanfile.py +++ b/recipes/mpc/all/test_package/conanfile.py @@ -5,8 +5,9 @@ class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" + settings = "os", "arch", "compiler", "build_type" generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" def layout(self): cmake_layout(self) diff --git a/recipes/mpc/config.yml b/recipes/mpc/config.yml index d07c95e5966190..ad477c94d0d7aa 100644 --- a/recipes/mpc/config.yml +++ b/recipes/mpc/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.1": + folder: all "1.2.0": folder: all "1.1.0": From e8e47a3792f7b174f097fb03eadbea20d4067f0d Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Fri, 8 Sep 2023 20:41:18 +0200 Subject: [PATCH 0568/1140] (#19615) [SoPlex] bump version to 6.0.4 * [soplex] bump version to 6.0.4 * Drop test package for conan v1 * Bump dependency versions * Require zlib only when boost is not used * Revert "Require zlib only when boost is not used" This reverts commit 9cbda13e0cffb2cb9d9068279db4135fe5e59878. * Enable shared mode on Windows * Add package type --- recipes/soplex/all/conandata.yml | 3 +++ recipes/soplex/all/conanfile.py | 15 ++++++++------- .../soplex/all/test_v1_package/CMakeLists.txt | 9 --------- .../soplex/all/test_v1_package/conanfile.py | 18 ------------------ recipes/soplex/config.yml | 2 ++ 5 files changed, 13 insertions(+), 34 deletions(-) delete mode 100644 recipes/soplex/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/soplex/all/test_v1_package/conanfile.py diff --git a/recipes/soplex/all/conandata.yml b/recipes/soplex/all/conandata.yml index eaf5ac83b44274..b034a63a756936 100644 --- a/recipes/soplex/all/conandata.yml +++ b/recipes/soplex/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.0.4": + url: "https://github.com/scipopt/soplex/archive/refs/tags/release-604.tar.gz" + sha256: "691f5b593cb85c2586522d5de5a5a7692958d22ff1ddffb4fc395f4696590b6f" "6.0.3": url: "https://github.com/scipopt/soplex/archive/refs/tags/release-603.tar.gz" sha256: "2bdf9adc9ac6ad48f98056679b7b852e626ac4aaaf277e7d4ce17794ed1097be" diff --git a/recipes/soplex/all/conanfile.py b/recipes/soplex/all/conanfile.py index d1ea6917fd3ef5..5e4c8355aefd44 100644 --- a/recipes/soplex/all/conanfile.py +++ b/recipes/soplex/all/conanfile.py @@ -19,6 +19,7 @@ class SoPlexConan(ConanFile): homepage = "https://soplex.zib.de" topics = ("simplex", "solver", "linear", "programming") settings = "os", "arch", "compiler", "build_type" + package_type = "library" options = { "shared": [True, False], "fPIC": [True, False], @@ -62,8 +63,6 @@ def validate(self): raise ConanInvalidConfiguration( f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -77,13 +76,14 @@ def configure(self): self.options.rm_safe("fPIC") def requirements(self): - self.requires("zlib/1.2.13", transitive_headers=True) + # transitive libs as anything using soplex requires gzread, gzwrite, gzclose, gzopen + self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) if self.options.with_gmp: # transitive libs as anything using soplex requires __gmpz_init_set_si # see https://github.com/conan-io/conan-center-index/pull/16017#issuecomment-1495688452 - self.requires("gmp/6.2.1", transitive_headers=True, transitive_libs=True) + self.requires("gmp/6.3.0", transitive_headers=True, transitive_libs=True) if self.options.with_boost: - self.requires("boost/1.81.0", transitive_headers=True) # also update Boost_VERSION_MACRO below! + self.requires("boost/1.83.0", transitive_headers=True) # also update Boost_VERSION_MACRO below! def layout(self): cmake_layout(self, src_folder="src") @@ -92,7 +92,7 @@ def generate(self): tc = CMakeToolchain(self) tc.variables["GMP"] = self.options.with_gmp tc.variables["BOOST"] = self.options.with_boost - tc.variables["Boost_VERSION_MACRO"] = "108100" + tc.variables["Boost_VERSION_MACRO"] = "108300" if self.options.with_gmp: tc.cache_variables["GMP_INCLUDE_DIRS"] = ";".join(self.dependencies["gmp"].cpp_info.includedirs) tc.cache_variables["GMP_LIBRARIES"] = "gmp::gmp" @@ -113,12 +113,13 @@ def package(self): copy(self, pattern="*.h", src=join(self.source_folder, "src", "soplex"), dst=join(self.package_folder, "include", "soplex")) copy(self, pattern="*.hpp", src=join(self.source_folder, "src", "soplex"), dst=join(self.package_folder, "include", "soplex")) copy(self, pattern="*.h", src=join(self.build_folder, "soplex"), dst=join(self.package_folder, "include", "soplex")) + copy(self, pattern="*.lib", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib"), keep_path=False) if self.options.shared: copy(self, pattern="*.so*", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) + copy(self, pattern="*.dll", src=join(self.build_folder, "bin"), dst=join(self.package_folder, "bin")) copy(self, pattern="*.dylib*", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) else: copy(self, pattern="*.a", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) - copy(self, pattern="*.lib", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib"), keep_path=False) fix_apple_shared_install_name(self) def package_info(self): diff --git a/recipes/soplex/all/test_v1_package/CMakeLists.txt b/recipes/soplex/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 8bf82de500d9f1..00000000000000 --- a/recipes/soplex/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) -set(CMAKE_CXX_STANDARD 14) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ - ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/soplex/all/test_v1_package/conanfile.py b/recipes/soplex/all/test_v1_package/conanfile.py deleted file mode 100644 index 5a05af3c2dfd2f..00000000000000 --- a/recipes/soplex/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,18 +0,0 @@ -from conans import ConanFile, CMake -from conan.tools.build import cross_building -import os - - -class TestPackageV1Conan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) diff --git a/recipes/soplex/config.yml b/recipes/soplex/config.yml index bce376a5fec908..73bcf839da6182 100644 --- a/recipes/soplex/config.yml +++ b/recipes/soplex/config.yml @@ -1,3 +1,5 @@ versions: + "6.0.4": + folder: all "6.0.3": folder: all From 3ed05fcc0e2d97a58422aa4eddc76d8fd249bd36 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 8 Sep 2023 21:57:49 +0200 Subject: [PATCH 0569/1140] (#19645) fontconfig/meson: bump deps * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * Update conanfile.py --- recipes/fontconfig/meson/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/fontconfig/meson/conanfile.py b/recipes/fontconfig/meson/conanfile.py index f037cbc5601ca2..4ae32ba159e757 100644 --- a/recipes/fontconfig/meson/conanfile.py +++ b/recipes/fontconfig/meson/conanfile.py @@ -56,9 +56,9 @@ def requirements(self): def build_requirements(self): self.tool_requires("gperf/3.1") - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.2") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 7ab44287b4ec4f0f7c7e19e793c50ed12b4e41c7 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 9 Sep 2023 23:35:07 +0900 Subject: [PATCH 0570/1140] (#19680) zpp_bits: add version 4.4.19 --- recipes/zpp_bits/all/conandata.yml | 3 +++ recipes/zpp_bits/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/zpp_bits/all/conandata.yml b/recipes/zpp_bits/all/conandata.yml index aa294b864983dd..199c85b5f2f5a2 100644 --- a/recipes/zpp_bits/all/conandata.yml +++ b/recipes/zpp_bits/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.4.19": + url: "https://github.com/eyalz800/zpp_bits/archive/v4.4.19.tar.gz" + sha256: "1d8f92e616d61cd54cb2582280cc5a28e4457d8d9cfc331137859f8ef29ff637" "4.4.18": url: "https://github.com/eyalz800/zpp_bits/archive/v4.4.18.tar.gz" sha256: "c81a221a3d857218d990aa39f420f4cb5cdbe906672d22286b871355068bc14b" diff --git a/recipes/zpp_bits/config.yml b/recipes/zpp_bits/config.yml index e6e42fa0160a36..e2021292dbcd6b 100644 --- a/recipes/zpp_bits/config.yml +++ b/recipes/zpp_bits/config.yml @@ -1,4 +1,6 @@ versions: + "4.4.19": + folder: all "4.4.18": folder: all "4.4.17": From 8d98dc016574d84efaa0ffd8d78f44f6aa56d8e0 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 04:54:10 +0900 Subject: [PATCH 0571/1140] (#19657) imgui: add version 1.89.9/1.89.9-docking --- recipes/imgui/all/conandata.yml | 6 ++++++ recipes/imgui/config.yml | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/recipes/imgui/all/conandata.yml b/recipes/imgui/all/conandata.yml index 18b830b59f3648..58720d3d51f67f 100644 --- a/recipes/imgui/all/conandata.yml +++ b/recipes/imgui/all/conandata.yml @@ -1,4 +1,10 @@ sources: + "1.89.9": + url: "https://github.com/ocornut/imgui/archive/v1.89.9.tar.gz" + sha256: "1acc27a778b71d859878121a3f7b287cd81c29d720893d2b2bf74455bf9d52d6" + "1.89.9-docking": + url: "https://github.com/ocornut/imgui/archive/v1.89.9-docking.tar.gz" + sha256: "2481489ce9091239b3cab8a330d0409ffdd9ee607ad1f3fe3a0b0b751c27a8eb" "1.89.8": url: "https://github.com/ocornut/imgui/archive/v1.89.8.tar.gz" sha256: "6680ccc32430009a8204291b1268b2367d964bd6d1b08a4e0358a017eb8e8c9e" diff --git a/recipes/imgui/config.yml b/recipes/imgui/config.yml index d3d7aaa4e4a686..138b61745517a6 100644 --- a/recipes/imgui/config.yml +++ b/recipes/imgui/config.yml @@ -1,4 +1,8 @@ versions: + "1.89.9": + folder: all + "1.89.9-docking": + folder: all "1.89.8": folder: all "1.89.8-docking": From d5815e1bd2f7b516550ed6f91b4a081617bf36d6 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 07:31:12 +0900 Subject: [PATCH 0572/1140] (#19701) quill: update fmt/10.1.1 --- recipes/quill/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/quill/all/conanfile.py b/recipes/quill/all/conanfile.py index ef58c5e9a36f97..311710c99f8c57 100644 --- a/recipes/quill/all/conanfile.py +++ b/recipes/quill/all/conanfile.py @@ -69,7 +69,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fmt/10.1.0", transitive_headers=True) + self.requires("fmt/10.1.1", transitive_headers=True) def validate(self): supported_archs = ["x86", "x86_64", "armv6", "armv7", "armv7hf", "armv8"] From 798d8843a358106bd1e2988cb4cdca17816fa744 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 15:13:51 +0900 Subject: [PATCH 0573/1140] (#19699) soci: update dependencies --- recipes/soci/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/soci/all/conanfile.py b/recipes/soci/all/conanfile.py index 6b15a39df0e5f1..d800bb3ba60425 100644 --- a/recipes/soci/all/conanfile.py +++ b/recipes/soci/all/conanfile.py @@ -62,15 +62,15 @@ def configure(self): def requirements(self): if self.options.with_sqlite3: - self.requires("sqlite3/3.41.1") + self.requires("sqlite3/3.43.0") if self.options.with_odbc and self.settings.os != "Windows": self.requires("odbc/2.3.11") if self.options.with_mysql: - self.requires("libmysqlclient/8.0.31") + self.requires("libmysqlclient/8.1.0") if self.options.with_postgresql: - self.requires("libpq/14.7") + self.requires("libpq/15.4") if self.options.with_boost: - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") @property def _minimum_compilers_version(self): From e8284b595811b8acd8f827a8831a547a45e9a157 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 16:33:46 +0900 Subject: [PATCH 0574/1140] (#19705) visit_struct: update boost/1.83.0 --- recipes/visit_struct/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/visit_struct/all/conanfile.py b/recipes/visit_struct/all/conanfile.py index b4d861bfec980d..7cb8d11207ec2e 100644 --- a/recipes/visit_struct/all/conanfile.py +++ b/recipes/visit_struct/all/conanfile.py @@ -34,7 +34,7 @@ def layout(self): def requirements(self): if self.options.with_boost_fusion or self.options.with_boost_hana: - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") def package_id(self): self.info.clear() From 5370d7eb6f353f5e935d421674710ca10091cf97 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 17:32:49 +0900 Subject: [PATCH 0575/1140] (#19707) samurai: add version 0.6.0 --- recipes/samurai/all/conandata.yml | 3 +++ recipes/samurai/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/samurai/all/conandata.yml b/recipes/samurai/all/conandata.yml index d10010d1fa9f96..ea3efb85336675 100644 --- a/recipes/samurai/all/conandata.yml +++ b/recipes/samurai/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.6.0": + url: "https://github.com/hpc-maths/samurai/archive/v0.6.0.tar.gz" + sha256: "bab96adac8e1553b79678a22de2248bec67c7c205b5fd35e9e1aaccaca41286e" "0.3.0": url: "https://github.com/hpc-maths/samurai/archive/v0.3.0.tar.gz" sha256: "5e6313d92fa2cd23941192c74014749acfcfbcfd5fdc1601cb3c9f4d151c7f4e" diff --git a/recipes/samurai/config.yml b/recipes/samurai/config.yml index 0e8084dbaff4b5..570ab7165280c5 100644 --- a/recipes/samurai/config.yml +++ b/recipes/samurai/config.yml @@ -1,4 +1,6 @@ versions: + "0.6.0": + folder: all "0.3.0": folder: all "0.2.0": From d77771c2300e9c6a2d6861d7d4efe0b2040381d3 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 17:53:17 +0900 Subject: [PATCH 0576/1140] (#19708) restinio: update fmt/10.1.1 --- recipes/restinio/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/restinio/all/conanfile.py b/recipes/restinio/all/conanfile.py index 076732d0bd175c..f9c52830c3a32e 100644 --- a/recipes/restinio/all/conanfile.py +++ b/recipes/restinio/all/conanfile.py @@ -38,7 +38,7 @@ def layout(self): def requirements(self): self.requires("http_parser/2.9.4") - self.requires("fmt/10.1.0") + self.requires("fmt/10.1.1") self.requires("expected-lite/0.6.3") self.requires("optional-lite/3.5.0") self.requires("string-view-lite/1.7.0") From d63b1dedb3573e99cd09abe2ff08f0b52366f2eb Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 18:31:19 +0900 Subject: [PATCH 0577/1140] (#19706) usockets: update boost/1.83.0 --- recipes/usockets/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/usockets/all/conanfile.py b/recipes/usockets/all/conanfile.py index 4f69ddfc963bf7..d7b3860e4e1662 100644 --- a/recipes/usockets/all/conanfile.py +++ b/recipes/usockets/all/conanfile.py @@ -127,7 +127,7 @@ def requirements(self): elif self.options.eventloop == "gcd": self.requires("libdispatch/5.3.2") elif self.options.eventloop == "boost": - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def build_requirements(self): if self._settings_build.os == "Windows" and not self._uses_msbuild: From e704a5db80a784d4074655b6b1c669032db2bfd1 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 21:16:17 +0900 Subject: [PATCH 0578/1140] (#19710) seadex-genesis: update fmt/10.1.0 --- recipes/seadex-genesis/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/seadex-genesis/all/conanfile.py b/recipes/seadex-genesis/all/conanfile.py index 55649339605a91..2328e60870392f 100644 --- a/recipes/seadex-genesis/all/conanfile.py +++ b/recipes/seadex-genesis/all/conanfile.py @@ -50,7 +50,7 @@ def configure(self): def requirements(self): # Exposes headers and symbols: https://github.com/SeadexGmbH/genesis/blob/master/genesis/source/version.cpp - self.requires("fmt/10.0.0", transitive_headers=True, transitive_libs=True) + self.requires("fmt/10.1.0", transitive_headers=True, transitive_libs=True) self.requires("seadex-essentials/2.1.3", transitive_headers=True, transitive_libs=True) def source(self): From d2edf960219b55227508985eea6fa504c805e493 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 22:33:30 +0900 Subject: [PATCH 0579/1140] (#19711) highfive: update dependencies --- recipes/highfive/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/highfive/all/conanfile.py b/recipes/highfive/all/conanfile.py index ebce29b0f3b163..acad7b94ba402d 100644 --- a/recipes/highfive/all/conanfile.py +++ b/recipes/highfive/all/conanfile.py @@ -34,9 +34,9 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("hdf5/1.14.0") + self.requires("hdf5/1.14.1") if self.options.with_boost: - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") if self.options.with_eigen: self.requires("eigen/3.4.0") if self.options.with_xtensor: From 98d412baac50854ff57d3bc6a88e3997ee96ad6d Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 23:13:16 +0900 Subject: [PATCH 0580/1140] (#19712) xtensor: update dependencies --- recipes/xtensor/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/xtensor/all/conanfile.py b/recipes/xtensor/all/conanfile.py index 9bcb5c8f335ae5..91b15e6e0415a2 100644 --- a/recipes/xtensor/all/conanfile.py +++ b/recipes/xtensor/all/conanfile.py @@ -57,9 +57,9 @@ def requirements(self): if Version(self.version) < "0.24.0": self.requires("xsimd/7.5.0") else: - self.requires("xsimd/10.0.0") + self.requires("xsimd/11.1.0") if self.options.tbb: - self.requires("onetbb/2021.7.0") + self.requires("onetbb/2021.10.0") def package_id(self): self.info.clear() From 30e8e7b87c96e0f6f273a05d8983a7097ebc5cec Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 10 Sep 2023 23:56:56 +0900 Subject: [PATCH 0581/1140] (#19715) daw_utf_range: update daw_header_libraries/2.96.1 --- recipes/daw_utf_range/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/daw_utf_range/all/conanfile.py b/recipes/daw_utf_range/all/conanfile.py index 77684e08bfd01d..23fff04d5723fe 100644 --- a/recipes/daw_utf_range/all/conanfile.py +++ b/recipes/daw_utf_range/all/conanfile.py @@ -38,7 +38,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("daw_header_libraries/2.95.0") + self.requires("daw_header_libraries/2.96.1") def package_id(self): self.info.clear() From bb2269f13533d94660ee444d39f246f1d468b5e3 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 10 Sep 2023 19:46:31 +0300 Subject: [PATCH 0582/1140] (#18193) audiofile: add package_type, add v1.1.1 * audiofile: add package_type * audiofile: add missing include in test_package * audiofile: add v1.1.1 * audiofile: add a check for GCC * audiofile: set correct C++ standard for v1.1.1 * audiofile: add proper compiler versions check --- recipes/audiofile/all/conandata.yml | 3 ++ recipes/audiofile/all/conanfile.py | 47 +++++++++++++++---- .../audiofile/all/test_package/CMakeLists.txt | 7 ++- .../all/test_package/test_package.cpp | 3 ++ .../all/test_v1_package/CMakeLists.txt | 11 ++--- recipes/audiofile/config.yml | 2 + 6 files changed, 55 insertions(+), 18 deletions(-) diff --git a/recipes/audiofile/all/conandata.yml b/recipes/audiofile/all/conandata.yml index 042cc12d06dd13..288d8a5ec4d8c9 100644 --- a/recipes/audiofile/all/conandata.yml +++ b/recipes/audiofile/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.1": + url: "https://github.com/adamstark/AudioFile/archive/1.1.1.tar.gz" + sha256: "664f9d5fbbf1ff6c603ae054a35224f12e9856a1d8680be567909015ccaac328" "1.1.0": url: "https://github.com/adamstark/AudioFile/archive/1.1.0.tar.gz" sha256: "7546e39ca17ac09c653f46bfecce4a9936fae3784209ad53094915c78792a327" diff --git a/recipes/audiofile/all/conanfile.py b/recipes/audiofile/all/conanfile.py index 0d083108cea086..c9bd8f69c8aa34 100644 --- a/recipes/audiofile/all/conanfile.py +++ b/recipes/audiofile/all/conanfile.py @@ -1,4 +1,5 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout @@ -11,34 +12,60 @@ class AudiofileConan(ConanFile): name = "audiofile" description = "A simple C++11 library for reading and writing audio files." - topics = ("audiofile", "audio", "file-format", "wav", "aif") license = "MIT" - homepage = "https://github.com/adamstark/AudioFile" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/adamstark/AudioFile" + topics = ("audio", "file-format", "wav", "aif", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + # v1.1.1 uses is_signed_v + return 11 if Version(self.version) < "1.1.1" else 17 + + @property + def _compilers_minimum_version(self): + return { + "Visual Studio": "16", + "msvc": "192", + "gcc": "7", + "clang": "6", + "apple-clang": "10", + } + def configure(self): if Version(self.version) < "1.1.0": self.license = "GPL-3.0-or-later" + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 11) - - def layout(self): - basic_layout(self, src_folder="src") + check_min_cppstd(self, self._min_cppstd) + if self._min_cppstd > 11: + 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], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) - copy(self, "AudioFile.h", src=self.source_folder, dst=os.path.join(self.package_folder, "include")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "AudioFile.h", + dst=os.path.join(self.package_folder, "include"), + src=self.source_folder) def package_info(self): self.cpp_info.bindirs = [] diff --git a/recipes/audiofile/all/test_package/CMakeLists.txt b/recipes/audiofile/all/test_package/CMakeLists.txt index 6f7178f4a89271..fab8ac8a0b20c3 100644 --- a/recipes/audiofile/all/test_package/CMakeLists.txt +++ b/recipes/audiofile/all/test_package/CMakeLists.txt @@ -5,4 +5,9 @@ find_package(audiofile REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE audiofile::audiofile) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) + +if (audiofile_VERSION VERSION_GREATER_EQUAL "1.1.1") + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +else() + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +endif() diff --git a/recipes/audiofile/all/test_package/test_package.cpp b/recipes/audiofile/all/test_package/test_package.cpp index 6943fcec35d572..d95bc64031cdab 100644 --- a/recipes/audiofile/all/test_package/test_package.cpp +++ b/recipes/audiofile/all/test_package/test_package.cpp @@ -1,3 +1,6 @@ +// workaround for a missing include in v1.0.9 and earlier +#include + #include #include diff --git a/recipes/audiofile/all/test_v1_package/CMakeLists.txt b/recipes/audiofile/all/test_v1_package/CMakeLists.txt index 60fb00c9f3f14b..91630d79f4abb3 100644 --- a/recipes/audiofile/all/test_v1_package/CMakeLists.txt +++ b/recipes/audiofile/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(audiofile REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE audiofile::audiofile) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/audiofile/config.yml b/recipes/audiofile/config.yml index 5fc24e2e9c1883..1b65530cbacc9d 100644 --- a/recipes/audiofile/config.yml +++ b/recipes/audiofile/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.1": + folder: all "1.1.0": folder: all "1.0.9": From e12cac43e306ffa21e26a3f6cf6114a1759ca721 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 10 Sep 2023 20:28:43 +0300 Subject: [PATCH 0583/1140] (#18942) libnetfilter_queue: migrate to Conan v2 * libnetfilter_queue: migrate to Conan v2 * libnetfilter_queue: bump deps * libnetfilter_queue: add missing PkgConfigDeps, transitive_headers * libnetfilter_queue: add tool_requires("pkgconf/1.9.5") * libnetfilter_queue: add transitive_libs for libmnl Should not be necessary, but the CI failure does not make much sense either. * Update recipes/libnetfilter_queue/all/conanfile.py Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/libnetfilter_queue/all/conanfile.py | 106 +++---- .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 22 +- .../all/test_package/example.c | 258 +++++++++--------- .../all/test_v1_package/CMakeLists.txt | 8 + .../all/test_v1_package/conanfile.py | 18 ++ 6 files changed, 232 insertions(+), 189 deletions(-) create mode 100644 recipes/libnetfilter_queue/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libnetfilter_queue/all/test_v1_package/conanfile.py diff --git a/recipes/libnetfilter_queue/all/conanfile.py b/recipes/libnetfilter_queue/all/conanfile.py index 56576ded262ce0..73bddfa9c2d3a7 100644 --- a/recipes/libnetfilter_queue/all/conanfile.py +++ b/recipes/libnetfilter_queue/all/conanfile.py @@ -1,69 +1,83 @@ import os -from conans import ConanFile, tools, AutoToolsBuildEnvironment -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.29.1" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain, PkgConfigDeps +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.53.0" + class Libnetfilter_queueConan(ConanFile): name = "libnetfilter_queue" + description = ("userspace library that provides an API to packets" + " that have been queued by the kernel packet filter") license = "GPL-2.0-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://netfilter.org/projects/libnetfilter_queue/index.html" - description = "userspace library that provides an API to packets that have been queued by the kernel packet filter" - topics = ("libnetfilter_queue", "netfilter") - settings = "os", "compiler", "build_type", "arch" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - generators = "pkg_config" - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" + topics = "netfilter" - def requirements(self): - self.requires("libmnl/1.0.4") - self.requires("libnfnetlink/1.0.1") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - os.rename(extracted_dir, self._source_subfolder) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC - def configure(self): + def validate(self): if self.settings.os != "Linux": - raise ConanInvalidConfiguration("libnetfilter_queue is only supported on Linux") - if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd - - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self) - conf_args = [] + raise ConanInvalidConfiguration(f"{self.ref} is only supported on Linux.") + + def configure(self): if self.options.shared: - conf_args.extend(["--enable-shared", "--disable-static"]) - else: - conf_args.extend(["--disable-shared", "--enable-static"]) - self._autotools.configure(configure_dir=self._source_subfolder, args=conf_args) - return self._autotools + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("libmnl/1.0.4", transitive_headers=True, transitive_libs=True) + self.requires("libnfnetlink/1.0.2", transitive_headers=True) + + def build_requirements(self): + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() + deps = PkgConfigDeps(self) + deps.generate() def build(self): - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + autotools = Autotools(self) autotools.install() - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "etc")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "etc")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.libs = ["netfilter_queue"] - self.cpp_info.names["pkg_config"] = "libnetfilter_queue" + self.cpp_info.set_property("pkg_config_name", "libnetfilter_queue") diff --git a/recipes/libnetfilter_queue/all/test_package/CMakeLists.txt b/recipes/libnetfilter_queue/all/test_package/CMakeLists.txt index 4dbc40cd2c4d9e..58e2406eaac645 100644 --- a/recipes/libnetfilter_queue/all/test_package/CMakeLists.txt +++ b/recipes/libnetfilter_queue/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.10) -project(PackageTest) +cmake_minimum_required(VERSION 3.15) +project(PackageTest LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libnetfilter_queue REQUIRED CONFIG) add_executable(example example.c) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example libnetfilter_queue::libnetfilter_queue) diff --git a/recipes/libnetfilter_queue/all/test_package/conanfile.py b/recipes/libnetfilter_queue/all/test_package/conanfile.py index 1097433829a7c2..cf3b9d75009a72 100644 --- a/recipes/libnetfilter_queue/all/test_package/conanfile.py +++ b/recipes/libnetfilter_queue/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class Libnetfilter_queueTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run("{} {}".format(bin_path, 0), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(f"{bin_path} 0", env="conanrun") diff --git a/recipes/libnetfilter_queue/all/test_package/example.c b/recipes/libnetfilter_queue/all/test_package/example.c index f229443f228aa4..6260070d870800 100644 --- a/recipes/libnetfilter_queue/all/test_package/example.c +++ b/recipes/libnetfilter_queue/all/test_package/example.c @@ -1,17 +1,17 @@ +#include #include #include #include -#include #include #include -#include +#include #include #include #include -#include #include +#include #include @@ -20,153 +20,149 @@ static struct mnl_socket *nl; -static void -nfq_send_verdict(int queue_num, uint32_t id) -{ - char buf[MNL_SOCKET_BUFFER_SIZE]; - struct nlmsghdr *nlh; - struct nlattr *nest; +static void nfq_send_verdict(int queue_num, uint32_t id) { + char buf[MNL_SOCKET_BUFFER_SIZE]; + struct nlmsghdr *nlh; + struct nlattr *nest; - nlh = nfq_nlmsg_put(buf, NFQNL_MSG_VERDICT, queue_num); - nfq_nlmsg_verdict_put(nlh, id, NF_ACCEPT); + nlh = nfq_nlmsg_put(buf, NFQNL_MSG_VERDICT, queue_num); + nfq_nlmsg_verdict_put(nlh, id, NF_ACCEPT); - /* example to set the connmark. First, start NFQA_CT section: */ - nest = mnl_attr_nest_start(nlh, NFQA_CT); + /* example to set the connmark. First, start NFQA_CT section: */ + nest = mnl_attr_nest_start(nlh, NFQA_CT); - /* then, add the connmark attribute: */ - mnl_attr_put_u32(nlh, CTA_MARK, htonl(42)); - /* more conntrack attributes, e.g. CTA_LABELS could be set here */ + /* then, add the connmark attribute: */ + mnl_attr_put_u32(nlh, CTA_MARK, htonl(42)); + /* more conntrack attributes, e.g. CTA_LABELS could be set here */ - /* end conntrack section */ - mnl_attr_nest_end(nlh, nest); + /* end conntrack section */ + mnl_attr_nest_end(nlh, nest); - if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { - perror("mnl_socket_send"); - exit(EXIT_FAILURE); - } + if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { + perror("mnl_socket_send"); + exit(EXIT_FAILURE); + } } -static int queue_cb(const struct nlmsghdr *nlh, void *data) -{ - struct nfqnl_msg_packet_hdr *ph = NULL; - struct nlattr *attr[NFQA_MAX+1] = {}; - uint32_t id = 0, skbinfo; - struct nfgenmsg *nfg; - uint16_t plen; +static int queue_cb(const struct nlmsghdr *nlh, void *data) { + struct nfqnl_msg_packet_hdr *ph = NULL; + struct nlattr *attr[NFQA_MAX + 1] = {}; + uint32_t id = 0, skbinfo; + struct nfgenmsg *nfg; + uint16_t plen; - if (nfq_nlmsg_parse(nlh, attr) < 0) { - perror("problems parsing"); - return MNL_CB_ERROR; - } + if (nfq_nlmsg_parse(nlh, attr) < 0) { + perror("problems parsing"); + return MNL_CB_ERROR; + } - nfg = mnl_nlmsg_get_payload(nlh); + nfg = mnl_nlmsg_get_payload(nlh); - if (attr[NFQA_PACKET_HDR] == NULL) { - fputs("metaheader not set\n", stderr); - return MNL_CB_ERROR; - } + if (attr[NFQA_PACKET_HDR] == NULL) { + fputs("metaheader not set\n", stderr); + return MNL_CB_ERROR; + } - ph = mnl_attr_get_payload(attr[NFQA_PACKET_HDR]); + ph = mnl_attr_get_payload(attr[NFQA_PACKET_HDR]); - plen = mnl_attr_get_payload_len(attr[NFQA_PAYLOAD]); - /* void *payload = mnl_attr_get_payload(attr[NFQA_PAYLOAD]); */ + plen = mnl_attr_get_payload_len(attr[NFQA_PAYLOAD]); + /* void *payload = mnl_attr_get_payload(attr[NFQA_PAYLOAD]); */ - skbinfo = attr[NFQA_SKB_INFO] ? ntohl(mnl_attr_get_u32(attr[NFQA_SKB_INFO])) : 0; + skbinfo = attr[NFQA_SKB_INFO] ? ntohl(mnl_attr_get_u32(attr[NFQA_SKB_INFO])) : 0; - if (attr[NFQA_CAP_LEN]) { - uint32_t orig_len = ntohl(mnl_attr_get_u32(attr[NFQA_CAP_LEN])); - if (orig_len != plen) - printf("truncated "); - } + if (attr[NFQA_CAP_LEN]) { + uint32_t orig_len = ntohl(mnl_attr_get_u32(attr[NFQA_CAP_LEN])); + if (orig_len != plen) + printf("truncated "); + } - if (skbinfo & NFQA_SKB_GSO) - printf("GSO "); + if (skbinfo & NFQA_SKB_GSO) + printf("GSO "); - id = ntohl(ph->packet_id); - printf("packet received (id=%u hw=0x%04x hook=%u, payload len %u", - id, ntohs(ph->hw_protocol), ph->hook, plen); + id = ntohl(ph->packet_id); + printf("packet received (id=%u hw=0x%04x hook=%u, payload len %u", id, ntohs(ph->hw_protocol), + ph->hook, plen); - /* - * ip/tcp checksums are not yet valid, e.g. due to GRO/GSO. - * The application should behave as if the checksums are correct. - * - * If these packets are later forwarded/sent out, the checksums will - * be corrected by kernel/hardware. - */ - if (skbinfo & NFQA_SKB_CSUMNOTREADY) - printf(", checksum not ready"); - puts(")"); + /* + * ip/tcp checksums are not yet valid, e.g. due to GRO/GSO. + * The application should behave as if the checksums are correct. + * + * If these packets are later forwarded/sent out, the checksums will + * be corrected by kernel/hardware. + */ + if (skbinfo & NFQA_SKB_CSUMNOTREADY) + printf(", checksum not ready"); + puts(")"); - nfq_send_verdict(ntohs(nfg->res_id), id); + nfq_send_verdict(ntohs(nfg->res_id), id); - return MNL_CB_OK; + return MNL_CB_OK; } -int main(int argc, char *argv[]) -{ - char *buf; - /* largest possible packet payload, plus netlink data overhead: */ - size_t sizeof_buf = 0xffff + (MNL_SOCKET_BUFFER_SIZE/2); - struct nlmsghdr *nlh; - int ret; - unsigned int portid, queue_num; - - if (argc != 2) { - printf("Usage: %s [queue_num]\n", argv[0]); - exit(EXIT_FAILURE); - } - queue_num = atoi(argv[1]); - - nl = mnl_socket_open(NETLINK_NETFILTER); - if (nl == NULL) { - perror("mnl_socket_open"); - exit(EXIT_FAILURE); - } - - if (mnl_socket_bind(nl, 0, MNL_SOCKET_AUTOPID) < 0) { - perror("mnl_socket_bind"); - exit(EXIT_FAILURE); - } - portid = mnl_socket_get_portid(nl); - - buf = malloc(sizeof_buf); - if (!buf) { - perror("allocate receive buffer"); - exit(EXIT_FAILURE); - } - - nlh = nfq_nlmsg_put(buf, NFQNL_MSG_CONFIG, queue_num); - nfq_nlmsg_cfg_put_cmd(nlh, AF_INET, NFQNL_CFG_CMD_BIND); - - if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { - perror("mnl_socket_send"); - exit(EXIT_FAILURE); - } - - nlh = nfq_nlmsg_put(buf, NFQNL_MSG_CONFIG, queue_num); - nfq_nlmsg_cfg_put_params(nlh, NFQNL_COPY_PACKET, 0xffff); - - mnl_attr_put_u32(nlh, NFQA_CFG_FLAGS, htonl(NFQA_CFG_F_GSO)); - mnl_attr_put_u32(nlh, NFQA_CFG_MASK, htonl(NFQA_CFG_F_GSO)); - - if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { - perror("mnl_socket_send"); - exit(EXIT_FAILURE); - } - - /* ENOBUFS is signalled to userspace when packets were lost - * on kernel side. In most cases, userspace isn't interested - * in this information, so turn it off. - */ - ret = 1; - mnl_socket_setsockopt(nl, NETLINK_NO_ENOBUFS, &ret, sizeof(int)); - ret = mnl_socket_recvfrom(nl, buf, sizeof_buf); - if (ret == -1) { - perror("mnl_socket_recvfrom"); - exit(EXIT_FAILURE); - } - - mnl_socket_close(nl); - - return 0; +int main(int argc, char *argv[]) { + char *buf; + /* largest possible packet payload, plus netlink data overhead: */ + size_t sizeof_buf = 0xffff + (MNL_SOCKET_BUFFER_SIZE / 2); + struct nlmsghdr *nlh; + int ret; + unsigned int portid, queue_num; + + if (argc != 2) { + printf("Usage: %s [queue_num]\n", argv[0]); + exit(EXIT_FAILURE); + } + queue_num = atoi(argv[1]); + + nl = mnl_socket_open(NETLINK_NETFILTER); + if (nl == NULL) { + perror("mnl_socket_open"); + exit(EXIT_FAILURE); + } + + if (mnl_socket_bind(nl, 0, MNL_SOCKET_AUTOPID) < 0) { + perror("mnl_socket_bind"); + exit(EXIT_FAILURE); + } + portid = mnl_socket_get_portid(nl); + + buf = malloc(sizeof_buf); + if (!buf) { + perror("allocate receive buffer"); + exit(EXIT_FAILURE); + } + + nlh = nfq_nlmsg_put(buf, NFQNL_MSG_CONFIG, queue_num); + nfq_nlmsg_cfg_put_cmd(nlh, AF_INET, NFQNL_CFG_CMD_BIND); + + if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { + perror("mnl_socket_send"); + exit(EXIT_FAILURE); + } + + nlh = nfq_nlmsg_put(buf, NFQNL_MSG_CONFIG, queue_num); + nfq_nlmsg_cfg_put_params(nlh, NFQNL_COPY_PACKET, 0xffff); + + mnl_attr_put_u32(nlh, NFQA_CFG_FLAGS, htonl(NFQA_CFG_F_GSO)); + mnl_attr_put_u32(nlh, NFQA_CFG_MASK, htonl(NFQA_CFG_F_GSO)); + + if (mnl_socket_sendto(nl, nlh, nlh->nlmsg_len) < 0) { + perror("mnl_socket_send"); + exit(EXIT_FAILURE); + } + + /* ENOBUFS is signalled to userspace when packets were lost + * on kernel side. In most cases, userspace isn't interested + * in this information, so turn it off. + */ + ret = 1; + mnl_socket_setsockopt(nl, NETLINK_NO_ENOBUFS, &ret, sizeof(int)); + ret = mnl_socket_recvfrom(nl, buf, sizeof_buf); + if (ret == -1) { + perror("mnl_socket_recvfrom"); + exit(EXIT_FAILURE); + } + + mnl_socket_close(nl); + + return 0; } diff --git a/recipes/libnetfilter_queue/all/test_v1_package/CMakeLists.txt b/recipes/libnetfilter_queue/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libnetfilter_queue/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libnetfilter_queue/all/test_v1_package/conanfile.py b/recipes/libnetfilter_queue/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..528904ad9f9595 --- /dev/null +++ b/recipes/libnetfilter_queue/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class Libnetfilter_queueTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run("{} {}".format(bin_path, 0), run_environment=True) From 5f690e214ae4b3a431a28b5f16979cda96f3b61b Mon Sep 17 00:00:00 2001 From: qwqbot Date: Mon, 11 Sep 2023 02:11:22 +0800 Subject: [PATCH 0584/1140] (#19028) add evmc * add evmc * Fix current build in CCI Signed-off-by: Uilian Ries * fix cmake tool_requires --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/evmc/all/conandata.yml | 4 + recipes/evmc/all/conanfile.py | 81 +++++++++++++++++++ recipes/evmc/all/test_package/CMakeLists.txt | 8 ++ recipes/evmc/all/test_package/conanfile.py | 26 ++++++ .../evmc/all/test_package/test_package.cpp | 19 +++++ recipes/evmc/config.yml | 3 + 6 files changed, 141 insertions(+) create mode 100644 recipes/evmc/all/conandata.yml create mode 100644 recipes/evmc/all/conanfile.py create mode 100644 recipes/evmc/all/test_package/CMakeLists.txt create mode 100644 recipes/evmc/all/test_package/conanfile.py create mode 100644 recipes/evmc/all/test_package/test_package.cpp create mode 100644 recipes/evmc/config.yml diff --git a/recipes/evmc/all/conandata.yml b/recipes/evmc/all/conandata.yml new file mode 100644 index 00000000000000..6c98b724e418c4 --- /dev/null +++ b/recipes/evmc/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "10.1.1": + url: "https://github.com/ethereum/evmc/archive/v10.1.1.tar.gz" + sha256: "314a18635b2727a5129a7da3e4e15bd2fd76ee0c5ae19f21391b7a94e79cf459" diff --git a/recipes/evmc/all/conanfile.py b/recipes/evmc/all/conanfile.py new file mode 100644 index 00000000000000..13c6e5da4cc780 --- /dev/null +++ b/recipes/evmc/all/conanfile.py @@ -0,0 +1,81 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMakeToolchain, CMake, cmake_layout +from conan.tools.files import get, copy, rmdir +from conan.tools.build import check_min_cppstd +from conan.tools.scm import Version +import os + + +required_conan_version = ">=1.54.0" + + +class EVMCConan(ConanFile): + name = "evmc" + description = "EVMC – Ethereum Client-VM Connector API" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ethereum/evmc" + topics = ("ethereum", "wasm", "evm") + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + tool_requires = "cmake/[>=3.16.2 <4]" + options = {"fPIC": [True, False]} + default_options = {"fPIC": True} + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "Visual Studio": "16", + "msvc": "192", + "gcc": "8", + "clang": "9", + "apple-clang": "10", + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["EVMC_INSTALL"] = True + tc.variables["EVMC_TESTING"] = False + tc.variables["EVMC_JAVA"] = False + tc.variables["EVMC_TESTING"] = False + tc.variables["EVMC_EXAMPLES"] = False + tc.variables["EVMC_TOOLS"] = False + tc.variables["HUNTER_ENABLED"] = False + tc.generate() + + def validate(self): + if self.settings.get_safe("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) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + self.cpp_info.libs = ["evmc-instructions", "evmc-loader", "tooling"] diff --git a/recipes/evmc/all/test_package/CMakeLists.txt b/recipes/evmc/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..d3cab735f84a22 --- /dev/null +++ b/recipes/evmc/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.12) +project(test_package LANGUAGES CXX) + +find_package(evmc REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE evmc::evmc) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/evmc/all/test_package/conanfile.py b/recipes/evmc/all/test_package/conanfile.py new file mode 100644 index 00000000000000..a9fb96656f2039 --- /dev/null +++ b/recipes/evmc/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/evmc/all/test_package/test_package.cpp b/recipes/evmc/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..2810a6cfce9456 --- /dev/null +++ b/recipes/evmc/all/test_package/test_package.cpp @@ -0,0 +1,19 @@ +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include + +int main() { + const auto table = evmc_get_instruction_names_table(EVMC_BYZANTIUM); + std::cout << "HEX 0x80: " << evmc::hex(0x80) << std::endl; + + return EXIT_SUCCESS; +} diff --git a/recipes/evmc/config.yml b/recipes/evmc/config.yml new file mode 100644 index 00000000000000..a29f6d72c69f65 --- /dev/null +++ b/recipes/evmc/config.yml @@ -0,0 +1,3 @@ +versions: + "10.1.1": + folder: all From 433e3972c4ab4256c0ea150a4727b34fb3aa9445 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 03:49:33 +0900 Subject: [PATCH 0585/1140] (#19447) libzippp: add version 6.1-1.9.2 * libzippp: add version 6.1-1.9.2 * fix patch version check * add build_require for 6.1 * always require cmake * improve version check for applying patch --- recipes/libzippp/all/conandata.yml | 3 +++ recipes/libzippp/all/conanfile.py | 11 ++++++++--- recipes/libzippp/config.yml | 2 ++ 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/recipes/libzippp/all/conandata.yml b/recipes/libzippp/all/conandata.yml index f31401deb346d5..90151532c90b56 100644 --- a/recipes/libzippp/all/conandata.yml +++ b/recipes/libzippp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.1-1.9.2": + url: "https://github.com/ctabin/libzippp/archive/libzippp-v6.1-1.9.2.tar.gz" + sha256: "3796f174780f23938749da493cf4cbc4c55f84a568ec395f2c256dfe10129305" "6.0-1.9.2": url: "https://github.com/ctabin/libzippp/archive/libzippp-v6.0-1.9.2.tar.gz" sha256: "f9aef9811802a18e69cd50527381d70c2e0f0d8a839f1d41914f6234f5964fc3" diff --git a/recipes/libzippp/all/conanfile.py b/recipes/libzippp/all/conanfile.py index e0c0670ea25f1c..9699cb890e5fcf 100644 --- a/recipes/libzippp/all/conanfile.py +++ b/recipes/libzippp/all/conanfile.py @@ -64,6 +64,9 @@ def validate(self): if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": raise ConanInvalidConfiguration(f"{self.ref} does not support clang with libc++. Use libstdc++ instead.") + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -74,15 +77,17 @@ def generate(self): tc.variables["LIBZIPPP_INSTALL_HEADERS"] = True tc.variables["LIBZIPPP_BUILD_TESTS"] = False tc.variables["LIBZIPPP_ENABLE_ENCRYPTION"] = self.options.with_encryption + tc.variables["LIBZIPPP_CMAKE_CONFIG_MODE"] = True tc.generate() deps = CMakeDeps(self) deps.generate() def _patch_source(self): - replace_in_file(self, os.path.join(self.source_folder, 'CMakeLists.txt'), - 'find_package(LIBZIP MODULE REQUIRED)', - 'find_package(libzip REQUIRED CONFIG)') + if Version(self.version) <= "6.0": + replace_in_file(self, os.path.join(self.source_folder, 'CMakeLists.txt'), + 'find_package(LIBZIP MODULE REQUIRED)', + 'find_package(libzip REQUIRED CONFIG)') def build(self): self._patch_source() diff --git a/recipes/libzippp/config.yml b/recipes/libzippp/config.yml index 4ba054a3032a99..f715620c8ae878 100644 --- a/recipes/libzippp/config.yml +++ b/recipes/libzippp/config.yml @@ -1,4 +1,6 @@ versions: + "6.1-1.9.2": + folder: all "6.0-1.9.2": folder: all "5.0-1.8.0": From 1af2c17b53a2f7b27d720f7ec6ce32133482fac3 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 04:30:35 +0900 Subject: [PATCH 0586/1140] (#19656) ada: add version 2.6.7, remove older versions --- recipes/ada/all/conandata.yml | 21 +++------------------ recipes/ada/all/conanfile.py | 8 ++------ recipes/ada/config.yml | 14 ++------------ 3 files changed, 7 insertions(+), 36 deletions(-) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index 1ffb1049ac57f3..0d566dbc80ea82 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.7": + url: "https://github.com/ada-url/ada/archive/v2.6.7.tar.gz" + sha256: "882a0aa6e19174b60b2fa00ee75d35a31ecd5158fb97d0e4e719ba21bb07acb9" "2.6.4": url: "https://github.com/ada-url/ada/archive/v2.6.4.tar.gz" sha256: "5b488e9a7a700de5d40a749c96c4339bcc9c425e5f5406a0887b13e70bd90907" @@ -17,21 +20,3 @@ sources: "2.4.2": url: "https://github.com/ada-url/ada/archive/v2.4.2.tar.gz" sha256: "d865ab8828c14fc1e2217ca9f5d7918d50775175b2873faf2fbda0085e0623d2" - "2.4.1": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.4.1.tar.gz" - sha256: "e9359937e7aeb8e5889515c0a9e22cd5da50e9b053038eb092135a0e64888fe7" - "2.4.0": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.4.0.tar.gz" - sha256: "14624f1dfd966fee85272688064714172ff70e6e304a1e1850f352a07e4c6dc7" - "2.3.1": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.3.1.tar.gz" - sha256: "298992ec0958979090566c7835ea60c14f5330d6372ee092ef6eee1d2e6ac079" - "2.3.0": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.3.0.tar.gz" - sha256: "932a93f6a745775343ebdbaafca295e07b9513f6aaeb738f9e85dcb397925e33" - "2.2.0": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.2.0.tar.gz" - sha256: "40a6b3fe0d5c62936c081e8403790ec05d5afe3d0909eece894efcfef7e678ee" - "2.0.0": - url: "https://github.com/ada-url/ada/archive/refs/tags/v2.0.0.tar.gz" - sha256: "a18272e1c5d6580f62a333df88149e3810ffedcb61b3fb06c480a5b52e458b5e" diff --git a/recipes/ada/all/conanfile.py b/recipes/ada/all/conanfile.py index 76d787b5a14b7d..4954905b8f7dee 100644 --- a/recipes/ada/all/conanfile.py +++ b/recipes/ada/all/conanfile.py @@ -45,9 +45,6 @@ def config_options(self): del self.options.fPIC def configure(self): - if Version(self.version) <= "2.0.0": - self.options.rm_safe("shared") - self.package_type = "static-library" if self.options.get_safe("shared"): self.options.rm_safe("fPIC") @@ -55,7 +52,7 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.settings.compiler.cppstd: + if self.settings.compiler.get_safe("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: @@ -77,8 +74,7 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["BUILD_TESTING"] = False - if Version(self.version) >= "2.4.2": - tc.variables["ADA_TOOLS"] = False + tc.variables["ADA_TOOLS"] = False tc.generate() deps = CMakeDeps(self) diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index 4b6a02c6d6d420..2c76fe7baba056 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.7": + folder: all "2.6.4": folder: all "2.6.2": @@ -11,15 +13,3 @@ versions: folder: all "2.4.2": folder: all - "2.4.1": - folder: all - "2.4.0": - folder: all - "2.3.1": - folder: all - "2.3.0": - folder: all - "2.2.0": - folder: all - "2.0.0": - folder: all From 9d1f315e0aeeed69257b0afb40150bd6aa4f4997 Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Sun, 10 Sep 2023 22:31:30 +0200 Subject: [PATCH 0587/1140] (#19719) xz_utils: add v5.4.4 --- recipes/xz_utils/all/conandata.yml | 3 +++ recipes/xz_utils/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/xz_utils/all/conandata.yml b/recipes/xz_utils/all/conandata.yml index da0e232cb7e1ab..458ec761997212 100644 --- a/recipes/xz_utils/all/conandata.yml +++ b/recipes/xz_utils/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "5.4.4": + url: "https://tukaani.org/xz/xz-5.4.4.tar.gz" + sha256: "aae39544e254cfd27e942d35a048d592959bd7a79f9a624afb0498bb5613bdf8" "5.4.2": url: "https://tukaani.org/xz/xz-5.4.2.tar.gz" sha256: "87947679abcf77cc509d8d1b474218fd16b72281e2797360e909deaee1ac9d05" diff --git a/recipes/xz_utils/config.yml b/recipes/xz_utils/config.yml index 326a90e52c8373..88aa46f065b924 100644 --- a/recipes/xz_utils/config.yml +++ b/recipes/xz_utils/config.yml @@ -1,4 +1,6 @@ versions: + "5.4.4": + folder: all "5.4.2": folder: all "5.4.0": From 1eabd5381d40da1063d547fa7beb86c1f7eae220 Mon Sep 17 00:00:00 2001 From: Dmitry Baryshev Date: Mon, 11 Sep 2023 00:10:19 +0300 Subject: [PATCH 0588/1140] (#19723) libavif: bump deps --- recipes/libavif/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/libavif/all/conanfile.py b/recipes/libavif/all/conanfile.py index dc46d0267dd992..247dc536d3759b 100644 --- a/recipes/libavif/all/conanfile.py +++ b/recipes/libavif/all/conanfile.py @@ -47,10 +47,10 @@ def _has_dav1d(self): return self.options.with_decoder == "dav1d" def requirements(self): - self.requires("libaom-av1/3.5.0") + self.requires("libaom-av1/3.6.1") self.requires("libyuv/1854") if self._has_dav1d: - self.requires("dav1d/1.0.0") + self.requires("dav1d/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], From 60c425654521662c515163e591cbf0410827a355 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 11:32:32 +0900 Subject: [PATCH 0589/1140] (#19720) samurai: update dependencies --- recipes/samurai/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/samurai/all/conanfile.py b/recipes/samurai/all/conanfile.py index 3c3caf72355d32..8e629d1289dfbe 100644 --- a/recipes/samurai/all/conanfile.py +++ b/recipes/samurai/all/conanfile.py @@ -40,10 +40,10 @@ def layout(self): def requirements(self): self.requires("cli11/2.3.2") - self.requires("fmt/9.1.0") + self.requires("fmt/10.1.1") self.requires("highfive/2.7.1") self.requires("pugixml/1.13") - self.requires("xsimd/10.0.0") + self.requires("xsimd/11.1.0") self.requires("xtensor/0.24.3") def package_id(self): From a941b237a6444e5ce706edb01fff1955ebb212a3 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 13:06:18 +0900 Subject: [PATCH 0590/1140] (#18580) functions-framework-cpp: add version 1.2.0, support conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * functions-framework-cpp: add version 1.2.0, support conan v2 * Update recipes/functions-framework-cpp/all/conanfile.py * add patches for compilation errors * remove unused function * update boost/1.83.0 --------- Co-authored-by: Rubén Rincón Blanco --- .../all/CMakeLists.txt | 7 -- .../functions-framework-cpp/all/conandata.yml | 18 ++- .../functions-framework-cpp/all/conanfile.py | 108 ++++++++---------- ...ch => 1.0.0-0001-dont-skip-namelink.patch} | 0 .../1.0.0-0002-find-nlohmann_json.patch | 22 ++++ .../1.2.0-0001-dont-skip-namelink.patch | 12 ++ .../1.2.0-0002-find-nlohmann_json.patch | 22 ++++ .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 19 ++- recipes/functions-framework-cpp/config.yml | 2 + 10 files changed, 140 insertions(+), 77 deletions(-) delete mode 100644 recipes/functions-framework-cpp/all/CMakeLists.txt rename recipes/functions-framework-cpp/all/patches/{0001-dont-skip-namelink.patch => 1.0.0-0001-dont-skip-namelink.patch} (100%) create mode 100644 recipes/functions-framework-cpp/all/patches/1.0.0-0002-find-nlohmann_json.patch create mode 100644 recipes/functions-framework-cpp/all/patches/1.2.0-0001-dont-skip-namelink.patch create mode 100644 recipes/functions-framework-cpp/all/patches/1.2.0-0002-find-nlohmann_json.patch diff --git a/recipes/functions-framework-cpp/all/CMakeLists.txt b/recipes/functions-framework-cpp/all/CMakeLists.txt deleted file mode 100644 index c921d02a0d877e..00000000000000 --- a/recipes/functions-framework-cpp/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/functions-framework-cpp/all/conandata.yml b/recipes/functions-framework-cpp/all/conandata.yml index c01327cda0d09f..0f463b674b8cca 100644 --- a/recipes/functions-framework-cpp/all/conandata.yml +++ b/recipes/functions-framework-cpp/all/conandata.yml @@ -1,8 +1,22 @@ sources: + "1.2.0": + url: "https://github.com/GoogleCloudPlatform/functions-framework-cpp/archive/refs/tags/v1.2.0.tar.gz" + sha256: "729e24ef58a03b563e48d8006d63972b16a22bcf93bf2b49f40c3b219032b64b" "1.0.0": url: "https://github.com/GoogleCloudPlatform/functions-framework-cpp/archive/refs/tags/v1.0.0.tar.gz" sha256: "005f2fbe3b8be9f6f0bf7a4a5d218a23b0f62d854a5e84c56872dd3a4d2820f7" patches: + "1.2.0": + - patch_file: "patches/1.2.0-0001-dont-skip-namelink.patch" + patch_description: "disable NAMELINK_SKIP" + patch_type: "portability" + - patch_file: "patches/1.2.0-0002-find-nlohmann_json.patch" + patch_description: "use cci's nlohmann_json" + patch_type: "conan" "1.0.0": - - patch_file: "patches/0001-dont-skip-namelink.patch" - base_path: "source_subfolder" + - patch_file: "patches/1.0.0-0001-dont-skip-namelink.patch" + patch_description: "disable NAMELINK_SKIP" + patch_type: "portability" + - patch_file: "patches/1.0.0-0002-find-nlohmann_json.patch" + patch_description: "use cci's nlohmann_json" + patch_type: "conan" diff --git a/recipes/functions-framework-cpp/all/conanfile.py b/recipes/functions-framework-cpp/all/conanfile.py index 96389274771c44..859f3f1596a4e6 100644 --- a/recipes/functions-framework-cpp/all/conanfile.py +++ b/recipes/functions-framework-cpp/all/conanfile.py @@ -1,19 +1,22 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.microsoft import check_min_vs, is_msvc_static_runtime, is_msvc +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.build import check_min_cppstd, cross_building +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout import os -required_conan_version = ">=1.43.0" - +required_conan_version = ">=1.53.0" class FunctionsFrameworkCppConan(ConanFile): name = "functions-framework-cpp" description = "An open source FaaS (Functions as a Service) framework" license = "Apache-2.0" - topics = ("google", "cloud", "functions-as-a-service", "faas-framework") - homepage = "https://github.com/GoogleCloudPlatform/functions-framework-cpp" url = "https://github.com/conan-io/conan-center-index" - + homepage = "https://github.com/GoogleCloudPlatform/functions-framework-cpp" + topics = ("google", "cloud", "functions-as-a-service", "faas-framework") settings = "os", "arch", "compiler", "build_type" + package_type = "library" options = { "shared": [True, False], "fPIC": [True, False], @@ -22,23 +25,24 @@ class FunctionsFrameworkCppConan(ConanFile): "shared": False, "fPIC": True, } - - generators = "cmake", "cmake_find_package_multi", "cmake_find_package" short_paths = True - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 17 @property - def _is_msvc(self): - return str(self.settings.compiler) in ["Visual Studio", "msvc"] + def _compilers_minimum_version(self): + return { + "gcc": "9", + "Visual Studio": "15.7", + "msvc": "190", + "clang": "7", + "apple-clang": "11", + } def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -46,21 +50,15 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def requirements(self): - self.requires("abseil/20211102.0") - self.requires("boost/1.78.0") - self.requires("nlohmann_json/3.10.5") + def layout(self): + cmake_layout(self, src_folder="src") - @property - def _compilers_minimum_version(self): - return { - "gcc": "9", - "Visual Studio": "15.7", - "clang": "7", - "apple-clang": "11", - } + def requirements(self): + self.requires("abseil/20230125.3") + self.requires("boost/1.83.0") + self.requires("nlohmann_json/3.11.2", transitive_headers=True) @property def _required_boost_components(self): @@ -68,10 +66,10 @@ def _required_boost_components(self): def validate(self): miss_boost_required_comp = \ - any(getattr(self.options["boost"], + any(getattr(self.dependencies["boost"].options, "without_{}".format(boost_comp), True) for boost_comp in self._required_boost_components) - if self.options["boost"].header_only or miss_boost_required_comp: + if self.dependencies["boost"].options.header_only or miss_boost_required_comp: raise ConanInvalidConfiguration( "{0} requires non-header-only boost with these components: {1}".format( self.name, ", ".join(self._required_boost_components) @@ -79,7 +77,7 @@ def validate(self): ) if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) + check_min_cppstd(self, self._min_cppstd) def loose_lt_semver(v1, v2): lv1 = [int(v) for v in v1.split(".")] @@ -90,46 +88,40 @@ def loose_lt_semver(v1, v2): minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version and loose_lt_semver(str(self.settings.compiler.version), minimum_version): raise ConanInvalidConfiguration( - "{} requires C++17, which your compiler does not support.".format(self.name) + "{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - if self._is_msvc and self.options.shared: + if is_msvc(self) and self.options.shared: raise ConanInvalidConfiguration("Fails to build for Visual Studio as a DLL") - if hasattr(self, "settings_build") and tools.cross_building(self): + if hasattr(self, "settings_build") and cross_building(self): raise ConanInvalidConfiguration( "Recipe not prepared for cross-building (yet)" ) def source(self): - tools.get( - **self.conan_data["sources"][self.version], - destination=self._source_subfolder, - strip_root=True - ) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["BUILD_TESTING"] = False - self._cmake.definitions["FUNCTIONS_FRAMEWORK_CPP_TEST_EXAMPLES"] = False - - self._cmake.configure() - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.cache_variables["BUILD_TESTING"] = False + tc.variables["FUNCTIONS_FRAMEWORK_CPP_TEST_EXAMPLES"] = False + tc.generate() + deps = CMakeDeps(self) + deps.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "functions_framework_cpp") diff --git a/recipes/functions-framework-cpp/all/patches/0001-dont-skip-namelink.patch b/recipes/functions-framework-cpp/all/patches/1.0.0-0001-dont-skip-namelink.patch similarity index 100% rename from recipes/functions-framework-cpp/all/patches/0001-dont-skip-namelink.patch rename to recipes/functions-framework-cpp/all/patches/1.0.0-0001-dont-skip-namelink.patch diff --git a/recipes/functions-framework-cpp/all/patches/1.0.0-0002-find-nlohmann_json.patch b/recipes/functions-framework-cpp/all/patches/1.0.0-0002-find-nlohmann_json.patch new file mode 100644 index 00000000000000..869e28e5358111 --- /dev/null +++ b/recipes/functions-framework-cpp/all/patches/1.0.0-0002-find-nlohmann_json.patch @@ -0,0 +1,22 @@ +diff --git a/google/cloud/functions/CMakeLists.txt b/google/cloud/functions/CMakeLists.txt +index f7cac3a..38f7449 100644 +--- a/google/cloud/functions/CMakeLists.txt ++++ b/google/cloud/functions/CMakeLists.txt +@@ -23,6 +23,7 @@ configure_file(internal/version_info.h.in + find_package(absl REQUIRED) + find_package(Boost REQUIRED COMPONENTS program_options) + find_package(Threads REQUIRED) ++find_package(nlohmann_json REQUIRED) + + add_library( + functions_framework_cpp # cmake-format: sort +@@ -76,7 +77,8 @@ target_include_directories(functions_framework_cpp SYSTEM + PUBLIC $) + target_link_libraries( + functions_framework_cpp PUBLIC absl::time Boost::headers +- Boost::program_options Threads::Threads) ++ Boost::program_options Threads::Threads ++ nlohmann_json::nlohmann_json) + target_compile_definitions(functions_framework_cpp + PUBLIC BOOST_BEAST_USE_STD_STRING_VIEW) + set_target_properties( diff --git a/recipes/functions-framework-cpp/all/patches/1.2.0-0001-dont-skip-namelink.patch b/recipes/functions-framework-cpp/all/patches/1.2.0-0001-dont-skip-namelink.patch new file mode 100644 index 00000000000000..661786756beb57 --- /dev/null +++ b/recipes/functions-framework-cpp/all/patches/1.2.0-0001-dont-skip-namelink.patch @@ -0,0 +1,12 @@ +diff --git a/google/cloud/functions/CMakeLists.txt b/google/cloud/functions/CMakeLists.txt +index 2b9506b..609c238 100644 +--- a/google/cloud/functions/CMakeLists.txt ++++ b/google/cloud/functions/CMakeLists.txt +@@ -137,7 +137,6 @@ install( + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT runtime + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + COMPONENT runtime +- NAMELINK_SKIP + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + COMPONENT development + NAMELINK_COMPONENT development diff --git a/recipes/functions-framework-cpp/all/patches/1.2.0-0002-find-nlohmann_json.patch b/recipes/functions-framework-cpp/all/patches/1.2.0-0002-find-nlohmann_json.patch new file mode 100644 index 00000000000000..974fed8146e709 --- /dev/null +++ b/recipes/functions-framework-cpp/all/patches/1.2.0-0002-find-nlohmann_json.patch @@ -0,0 +1,22 @@ +diff --git a/google/cloud/functions/CMakeLists.txt b/google/cloud/functions/CMakeLists.txt +index 2b9506b..ab3aaaa 100644 +--- a/google/cloud/functions/CMakeLists.txt ++++ b/google/cloud/functions/CMakeLists.txt +@@ -23,6 +23,7 @@ configure_file(internal/version_info.h.in + find_package(absl REQUIRED) + find_package(Boost REQUIRED COMPONENTS program_options) + find_package(Threads REQUIRED) ++find_package(nlohmann_json REQUIRED) + + add_library( + functions_framework_cpp # cmake-format: sort +@@ -80,7 +81,8 @@ target_include_directories(functions_framework_cpp SYSTEM + PUBLIC $) + target_link_libraries( + functions_framework_cpp PUBLIC absl::time Boost::headers +- Boost::program_options Threads::Threads) ++ Boost::program_options Threads::Threads ++ nlohmann_json::nlohmann_json) + target_compile_definitions(functions_framework_cpp + PUBLIC BOOST_BEAST_USE_STD_STRING_VIEW) + set_target_properties( diff --git a/recipes/functions-framework-cpp/all/test_package/CMakeLists.txt b/recipes/functions-framework-cpp/all/test_package/CMakeLists.txt index d4b4a2212f334e..5126c69942f535 100644 --- a/recipes/functions-framework-cpp/all/test_package/CMakeLists.txt +++ b/recipes/functions-framework-cpp/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ cmake_minimum_required(VERSION 3.8) -project(test_package CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +project(test_package LANGUAGES CXX) find_package(functions_framework_cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} functions-framework-cpp::framework) +target_link_libraries(${PROJECT_NAME} PRIVATE functions-framework-cpp::framework) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/functions-framework-cpp/all/test_package/conanfile.py b/recipes/functions-framework-cpp/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/functions-framework-cpp/all/test_package/conanfile.py +++ b/recipes/functions-framework-cpp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/functions-framework-cpp/config.yml b/recipes/functions-framework-cpp/config.yml index c7f13630776fb5..45091dac1186fa 100644 --- a/recipes/functions-framework-cpp/config.yml +++ b/recipes/functions-framework-cpp/config.yml @@ -1,3 +1,5 @@ versions: + "1.2.0": + folder: "all" "1.0.0": folder: "all" From d6c62a425b77b3681520bc5466373ba8c9ca0912 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 13:48:42 +0900 Subject: [PATCH 0591/1140] (#18845) geos: add version 3.12.0 * geos: add version 3.12.0 * 3.12.0 requires C++14 * add patch to solve compilation error on msvc * fix patch_type * Fix Windows build by passing build type Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/geos/all/conandata.yml | 9 +++++ recipes/geos/all/conanfile.py | 33 +++++++++++++++++-- .../all/patches/3.12.0-0001-fix-cmake.patch | 31 +++++++++++++++++ recipes/geos/config.yml | 2 ++ 4 files changed, 72 insertions(+), 3 deletions(-) create mode 100644 recipes/geos/all/patches/3.12.0-0001-fix-cmake.patch diff --git a/recipes/geos/all/conandata.yml b/recipes/geos/all/conandata.yml index dce86864c12ad3..cce81a5d0af84f 100644 --- a/recipes/geos/all/conandata.yml +++ b/recipes/geos/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.12.0": + url: "https://github.com/libgeos/geos/releases/download/3.12.0/geos-3.12.0.tar.bz2" + sha256: "d96db96011259178a35555a0f6d6e75a739e52a495a6b2aa5efb3d75390fbc39" "3.11.2": url: "https://github.com/libgeos/geos/releases/download/3.11.2/geos-3.11.2.tar.bz2" sha256: "b1f077669481c5a3e62affc49e96eb06f281987a5d36fdab225217e5b825e4cc" @@ -14,3 +17,9 @@ sources: "3.10.2": url: "https://download.osgeo.org/geos/geos-3.10.2.tar.bz2" sha256: "50bbc599ac386b4c2b3962dcc411f0040a61f204aaef4eba7225ecdd0cf45715" +patches: + "3.12.0": + - patch_file: "patches/3.12.0-0001-fix-cmake.patch" + patch_description: "Fix CMake on Windows with Visual Studio" + patch_type: "official" + patch_source: "https://github.com/libgeos/geos/pull/945" diff --git a/recipes/geos/all/conanfile.py b/recipes/geos/all/conanfile.py index 7238296e0a1c15..5bfc63783c7e53 100644 --- a/recipes/geos/all/conanfile.py +++ b/recipes/geos/all/conanfile.py @@ -1,7 +1,8 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd, stdcpp_library from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, rmdir +from conan.tools.files import copy, get, rmdir, export_conandata_patches, apply_conandata_patches from conan.tools.scm import Version import os @@ -30,10 +31,29 @@ class GeosConan(ConanFile): "utils": True, } + @property + def _min_cppstd(self): + return "14" if Version(self.version) >= "3.12.0" else "11" + + @property + def _compilers_minimum_version(self): + return { + "14": { + "gcc": "6", + "clang": "5", + "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", + }, + }.get(self._min_cppstd, {}) + @property def _has_inline_option(self): return Version(self.version) < "3.11.0" + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -48,8 +68,13 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 11) + if self.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) @@ -62,6 +87,7 @@ def generate(self): tc.cache_variables["BUILD_BENCHMARKS"] = False else: tc.variables["BUILD_BENCHMARKS"] = False + tc.cache_variables["CMAKE_BUILD_TYPE"] = str(self.settings.build_type) if self._has_inline_option: tc.variables["DISABLE_GEOS_INLINE"] = not self.options.inline tc.variables["BUILD_TESTING"] = False @@ -71,6 +97,7 @@ def generate(self): tc.generate() def build(self): + apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/geos/all/patches/3.12.0-0001-fix-cmake.patch b/recipes/geos/all/patches/3.12.0-0001-fix-cmake.patch new file mode 100644 index 00000000000000..d0abdd50a8211c --- /dev/null +++ b/recipes/geos/all/patches/3.12.0-0001-fix-cmake.patch @@ -0,0 +1,31 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 7a2906c..cdab138 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -114,8 +114,12 @@ endif() + + # Make sure we know our build type + if(NOT CMAKE_BUILD_TYPE) +- set(CMAKE_BUILD_TYPE ${DEFAULT_BUILD_TYPE}) +- message(STATUS "GEOS: Using default build type: ${CMAKE_BUILD_TYPE}") ++ get_property(_is_multi_config_generator GLOBAL PROPERTY GENERATOR_IS_MULTI_CONFIG) ++ if (NOT _is_multi_config_generator) ++ set(CMAKE_BUILD_TYPE ${DEFAULT_BUILD_TYPE}) ++ message(STATUS "GEOS: Using default build type: ${CMAKE_BUILD_TYPE}") ++ endif() ++ unset(_is_multi_config_generator) + else() + message(STATUS "GEOS: Build type: ${CMAKE_BUILD_TYPE}") + endif() +@@ -186,6 +190,11 @@ set(CMAKE_CXX_FLAGS_ASAN "${CMAKE_CXX_FLAGS_DEBUG} -fsanitize=address -fno-omit- + set(CMAKE_EXE_LINKER_FLAGS_ASAN "${CMAKE_EXE_LINKER_FLAGS_DEBUG} -fsanitize=address") + set(CMAKE_SHARED_LINKER_FLAGS_ASAN "${CMAKE_SHARED_LINKER_FLAGS_DEBUG} -fsanitize=address") + ++get_property(_cmake_build_type_is_cache CACHE CMAKE_BUILD_TYPE PROPERTY TYPE) ++if (_cmake_build_type_is_cache) ++ set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo" "ASAN") ++endif() ++unset(_cmake_build_type_is_cache) + set_property(CACHE CMAKE_BUILD_TYPE PROPERTY STRINGS "Debug" "Release" "MinSizeRel" "RelWithDebInfo" "ASAN") + + #----------------------------------------------------------------------------- diff --git a/recipes/geos/config.yml b/recipes/geos/config.yml index aad029ca82e113..bbc8ab7daf85ca 100644 --- a/recipes/geos/config.yml +++ b/recipes/geos/config.yml @@ -1,4 +1,6 @@ versions: + "3.12.0": + folder: all "3.11.2": folder: all "3.11.1": From 4198a051b0f4e7004e896a614a378f5debd2c296 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 11 Sep 2023 08:27:42 +0300 Subject: [PATCH 0592/1140] (#18855) corrade: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * corrade: migrate to Conan v2 * disable VS2022, simplify test_package * allow vs2022 * corrade: fix conandata.yml patch attributes * corrade: auto-load all exported CMake module files * corrade: get rid of vs_ide_version() * Fix linter error --------- Co-authored-by: memsharded Co-authored-by: Rubén Rincón Blanco --- recipes/corrade/all/CMakeLists.txt | 7 - recipes/corrade/all/conandata.yml | 9 +- recipes/corrade/all/conanfile.py | 160 ++++++++++-------- .../corrade/all/test_package/CMakeLists.txt | 11 +- recipes/corrade/all/test_package/conanfile.py | 39 +++-- .../corrade/all/test_package/test_package.cpp | 6 +- 6 files changed, 120 insertions(+), 112 deletions(-) delete mode 100644 recipes/corrade/all/CMakeLists.txt diff --git a/recipes/corrade/all/CMakeLists.txt b/recipes/corrade/all/CMakeLists.txt deleted file mode 100644 index 61f3d3b039e2bb..00000000000000 --- a/recipes/corrade/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -add_subdirectory("source_subfolder") diff --git a/recipes/corrade/all/conandata.yml b/recipes/corrade/all/conandata.yml index 4b0cd1b7fd3fb8..82a5660e749504 100644 --- a/recipes/corrade/all/conandata.yml +++ b/recipes/corrade/all/conandata.yml @@ -7,8 +7,7 @@ sources: url: https://github.com/mosra/corrade/archive/v2019.10.tar.gz patches: "2020.06": - - base_path: "source_subfolder" - patch_file: "patches/2020.06/0001-emscripten-toolchain.patch" - # patch_type: "portability" - # description: "Remove unnecessary dependency on UseEmscripten" - # source: "https://github.com/mosra/corrade/issues/104" + - patch_file: "patches/2020.06/0001-emscripten-toolchain.patch" + patch_type: "portability" + patch_description: "Remove unnecessary dependency on UseEmscripten" + patch_source: "https://github.com/mosra/corrade/issues/104" diff --git a/recipes/corrade/all/conanfile.py b/recipes/corrade/all/conanfile.py index dcff18b711642d..347781614d5e33 100644 --- a/recipes/corrade/all/conanfile.py +++ b/recipes/corrade/all/conanfile.py @@ -1,21 +1,24 @@ -from conan.tools.microsoft import is_msvc -from conan.tools.microsoft.visual import vs_ide_version -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -import functools import os -required_conan_version = ">=1.45.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import cross_building +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +from conan.tools.microsoft import is_msvc, check_min_vs + +required_conan_version = ">=1.52.0" class CorradeConan(ConanFile): name = "corrade" description = "Corrade is a multiplatform utility library written in C++11/C++14." - topics = ("corrade", "magnum", "filesystem", "console", "environment", "os") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://magnum.graphics/corrade" - license = "MIT" + topics = ("magnum", "filesystem", "console", "environment", "os") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -38,22 +41,9 @@ class CorradeConan(ConanFile): "with_utility": True, } - generators = "cmake" - short_paths = True - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - def export_sources(self): - self.copy("CMakeLists.txt") - self.copy("cmake/*") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + copy(self, "cmake/*", src=self.recipe_folder, dst=self.export_sources_folder) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -61,79 +51,96 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def validate(self): - if is_msvc(self) and tools.Version(vs_ide_version(self)) < 14: - raise ConanInvalidConfiguration("Corrade requires Visual Studio version 14 or greater") + def layout(self): + cmake_layout(self, src_folder="src") - if not self.options.with_utility and (self.options.with_testsuite or self.options.with_interconnect or self.options.with_pluginmanager): - raise ConanInvalidConfiguration("Component 'utility' is required for 'test_suite', 'interconnect' and 'plugin_manager'") + def validate(self): + check_min_vs(self, 190) + if not self.options.with_utility and ( + self.options.with_testsuite or self.options.with_interconnect or self.options.with_pluginmanager + ): + raise ConanInvalidConfiguration( + "Component 'utility' is required for 'test_suite', 'interconnect' and 'plugin_manager'" + ) def build_requirements(self): - if hasattr(self, "settings_build") and tools.cross_building(self, skip_x64_x86=True): - self.build_requires("corrade/{}".format(self.version)) + if hasattr(self, "settings_build") and cross_building(self, skip_x64_x86=True): + self.tool_requires(f"corrade/{self.version}") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["BUILD_STATIC"] = not self.options.shared - cmake.definitions["BUILD_STATIC_PIC"] = self.options.get_safe("fPIC", False) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_STATIC"] = not self.options.shared + tc.variables["BUILD_STATIC_PIC"] = self.options.get_safe("fPIC", False) - cmake.definitions["BUILD_DEPRECATED"] = self.options.build_deprecated - cmake.definitions["WITH_INTERCONNECT"] = self.options.with_interconnect - cmake.definitions["WITH_MAIN"] = self.options.with_main - cmake.definitions["WITH_PLUGINMANAGER"] = self.options.with_pluginmanager - cmake.definitions["WITH_TESTSUITE"] = self.options.with_testsuite - cmake.definitions["WITH_UTILITY"] = self.options.with_utility - cmake.definitions["WITH_RC"] = self.options.with_utility + tc.variables["BUILD_DEPRECATED"] = self.options.build_deprecated + tc.variables["WITH_INTERCONNECT"] = self.options.with_interconnect + tc.variables["WITH_MAIN"] = self.options.with_main + tc.variables["WITH_PLUGINMANAGER"] = self.options.with_pluginmanager + tc.variables["WITH_TESTSUITE"] = self.options.with_testsuite + tc.variables["WITH_UTILITY"] = self.options.with_utility + tc.variables["WITH_RC"] = self.options.with_utility # Corrade uses suffix on the resulting "lib"-folder when running cmake.install() # Set it explicitly to empty, else Corrade might set it implicitly (eg. to "64") - cmake.definitions["LIB_SUFFIX"] = "" + tc.variables["LIB_SUFFIX"] = "" if is_msvc(self): - cmake.definitions["MSVC2015_COMPATIBILITY"] = vs_ide_version(self) == "14" - cmake.definitions["MSVC2017_COMPATIBILITY"] = vs_ide_version(self) == "15" - cmake.definitions["MSVC2019_COMPATIBILITY"] = vs_ide_version(self) == "16" + if check_min_vs(self, 193, raise_invalid=False): + tc.variables["MSVC2019_COMPATIBILITY"] = True + elif check_min_vs(self, 192, raise_invalid=False): + tc.variables["MSVC2017_COMPATIBILITY"] = True + elif check_min_vs(self, 191, raise_invalid=False): + tc.variables["MSVC2015_COMPATIBILITY"] = True - cmake.configure(build_folder=self._build_subfolder) - - return cmake + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - share_cmake = os.path.join(self.package_folder, "share", "cmake", "Corrade") - self.copy("UseCorrade.cmake", src=share_cmake, dst=os.path.join(self.package_folder, "lib", "cmake")) - self.copy("CorradeLibSuffix.cmake", src=share_cmake, dst=os.path.join(self.package_folder, "lib", "cmake")) - self.copy("*.cmake", src=os.path.join(self.source_folder, "cmake"), dst=os.path.join("lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "share")) + copy(self, "UseCorrade.cmake", + src=share_cmake, + dst=os.path.join(self.package_folder, "lib", "cmake")) + copy(self, "CorradeLibSuffix.cmake", + src=share_cmake, + dst=os.path.join(self.package_folder, "lib", "cmake")) + copy(self, "*.cmake", + src=os.path.join(self.export_sources_folder, "cmake"), + dst=os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): self.cpp_info.set_property("cmake_find_mode", "both") self.cpp_info.set_property("cmake_file_name", "Corrade") - self.cpp_info.names["cmake_find_package"] = "Corrade" - self.cpp_info.names["cmake_find_package_multi"] = "Corrade" + self.cpp_info.set_property("cmake_target_name", "Corrade::Corrade") suffix = "-d" if self.settings.build_type == "Debug" else "" - # The FindCorrade.cmake file provided by the library populates some extra stuff - self.cpp_info.set_property("cmake_build_modules", [os.path.join("lib", "cmake", "conan-corrade-vars.cmake")]) - self.cpp_info.components["_corrade"].build_modules.append(os.path.join("lib", "cmake", "conan-corrade-vars.cmake")) + cmake_modules = [ + # Reproduces the variables and calls performed by the FindCorrade.cmake provided by the library + os.path.join("lib", "cmake", "conan-corrade-vars.cmake"), + # Autodetects LIB_SUFFIX (either "64" or "") + os.path.join("lib", "cmake", "CorradeLibSuffix.cmake"), + # Exports build flags and macros + os.path.join("lib", "cmake", "UseCorrade.cmake"), + ] + self.cpp_info.set_property("cmake_build_modules", cmake_modules) + self.cpp_info.components["_corrade"].build_modules["cmake_find_package"] = cmake_modules + self.cpp_info.components["_corrade"].build_modules["cmake_find_package_multi"] = cmake_modules if self.options.with_main: self.cpp_info.components["main"].set_property("cmake_target_name", "Corrade::Main") @@ -153,10 +160,10 @@ def package_info(self): self.cpp_info.components["utility"].requires = ["_corrade"] # This one is statically linked into utility - #self.cpp_info.components["containers"].set_property("cmake_target_name", "Corrade::Containers") - #self.cpp_info.components["containers"].names["cmake_find_package"] = "Containers" - #self.cpp_info.components["containers"].names["cmake_find_package_multi"] = "Containers" - #self.cpp_info.components["containers"].libs = ["CorradeContainers" + suffix] + # self.cpp_info.components["containers"].set_property("cmake_target_name", "Corrade::Containers") + # self.cpp_info.components["containers"].names["cmake_find_package"] = "Containers" + # self.cpp_info.components["containers"].names["cmake_find_package_multi"] = "Containers" + # self.cpp_info.components["containers"].libs = ["CorradeContainers" + suffix] if self.options.with_interconnect: self.cpp_info.components["interconnect"].set_property("cmake_target_name", "Corrade::Interconnect") @@ -181,9 +188,12 @@ def package_info(self): if self.options.with_utility: bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bindir)) + self.output.info(f"Appending PATH environment variable: {bindir}") self.env_info.PATH.append(bindir) # pkg_config: Add more explicit naming to generated files (avoid filesystem collision). - for key, cmp in self.cpp_info.components.items(): - self.cpp_info.components[key].names["pkg_config"] = "{}_{}".format(self.name, key) + for key, component in self.cpp_info.components.items(): + component.set_property("pkg_config_name", f"{self.name}_{key}") + + self.cpp_info.names["cmake_find_package"] = "Corrade" + self.cpp_info.names["cmake_find_package_multi"] = "Corrade" diff --git a/recipes/corrade/all/test_package/CMakeLists.txt b/recipes/corrade/all/test_package/CMakeLists.txt index e4c1f34b721de4..94206f42ad33ea 100644 --- a/recipes/corrade/all/test_package/CMakeLists.txt +++ b/recipes/corrade/all/test_package/CMakeLists.txt @@ -1,14 +1,11 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(Corrade REQUIRED) +find_package(Corrade REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} Corrade::Main) -if(VERSION_2019_10) +if(VERSION_2019_10) target_compile_definitions(${PROJECT_NAME} PRIVATE VERSION_2019_10) endif() if(WITH_UTILITY) diff --git a/recipes/corrade/all/test_package/conanfile.py b/recipes/corrade/all/test_package/conanfile.py index be914f107e1214..9c0893a63e85bc 100644 --- a/recipes/corrade/all/test_package/conanfile.py +++ b/recipes/corrade/all/test_package/conanfile.py @@ -1,28 +1,37 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake, CMakeToolchain import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["WITH_UTILITY"] = self.dependencies["corrade"].options.with_utility + if self.dependencies["corrade"].ref.version == "2019.10": + tc.variables["VERSION_2019_10"] = True + tc.generate() def build(self): cmake = CMake(self) - cmake.definitions["WITH_UTILITY"] = self.options["corrade"].with_utility - if self.deps_cpp_info["corrade"].version == "2019.10": - cmake.definitions["VERSION_2019_10"] = True cmake.configure() cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) - - if self.options["corrade"].with_utility: - # Run corrade-rc - self.run("corrade-rc --help", run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") if self.settings.os == "Emscripten": - bin_path = os.path.join("bin", "test_package.js") - self.run("node {}".format(bin_path), run_environment=True) + bin_path = os.path.join(self.cpp.build.bindir, "test_package.js") + self.run(f"node {bin_path}", env="conanrun") diff --git a/recipes/corrade/all/test_package/test_package.cpp b/recipes/corrade/all/test_package/test_package.cpp index 8f5dc321a44de1..c0e1a6d7932b20 100644 --- a/recipes/corrade/all/test_package/test_package.cpp +++ b/recipes/corrade/all/test_package/test_package.cpp @@ -1,5 +1,4 @@ -#include -#include // Here it is 'nothing' +#include // Here it is 'nothing' #ifndef VERSION_2019_10 #include @@ -9,10 +8,11 @@ #include #endif +#include int main() { std::cout << "Test package for Corrade\n"; - + #ifndef VERSION_2019_10 std::cout << "Corrade " << CORRADE_VERSION_YEAR << "." << CORRADE_VERSION_MONTH << std::endl; #endif From 6d1f113d24fbc10e844e095b07fb832266b7b17d Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 15:50:13 +0900 Subject: [PATCH 0593/1140] (#19716) hictk: update dependencies --- recipes/hictk/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/hictk/all/conanfile.py b/recipes/hictk/all/conanfile.py index cf1428272f4659..8f5dc0a67cf84f 100644 --- a/recipes/hictk/all/conanfile.py +++ b/recipes/hictk/all/conanfile.py @@ -42,8 +42,8 @@ def requirements(self): self.requires("fast_float/5.2.0", transitive_headers=True) if self.options.with_eigen: self.requires("eigen/3.4.0", transitive_headers=True) - self.requires("fmt/10.0.0", transitive_headers=True) - self.requires("hdf5/1.14.0", transitive_headers=True) + self.requires("fmt/10.1.0", transitive_headers=True) + self.requires("hdf5/1.14.1", transitive_headers=True) self.requires("highfive/2.7.1", transitive_headers=True) self.requires("libdeflate/1.18", transitive_headers=True) self.requires("parallel-hashmap/1.3.11", transitive_headers=True) From c57bf4b3a49c65734083af94b559692f26edecc2 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 11 Sep 2023 09:23:01 +0200 Subject: [PATCH 0594/1140] (#19727) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 5cb7b126937182..52d413af7f3cc5 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -259,6 +259,7 @@ required_for_references: - drmp3 - drogon - drwav +- dsp-filters - dtl - duckdb - duktape @@ -668,6 +669,7 @@ required_for_references: - libzip - libzippp - lief +- lightpcapng - linmath.h - linux-headers-generic - linux-syscall-support @@ -1099,16 +1101,28 @@ required_for_references: - threadpool - thrift - thrust +- tidy-html5 - timsort +- tinkerforge-bindings +- tiny-aes-c +- tiny-bignum-c - tiny-dnn +- tiny-regex-c +- tiny-utf8 +- tinycbor - tinycthread - tinycthreadpool - tinydir - tinyexif +- tinyexr - tinygltf - tinymidi +- tinyobjloader +- tinyply +- tinyspline - tinyxml - tinyxml2 +- tl - tl-expected - tl-function-ref - tllist From 3aeb2ae80ba27ab067bc267f3b4347fc1ba2d878 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Mon, 11 Sep 2023 11:10:43 +0200 Subject: [PATCH 0595/1140] (#18149) exiv2: add version 0.28.0, add win_unicode option for 0.27.x * init * fix * get_safe * fix sig * fix the fix * exiv2-xmp is an object library in 0.28 * fix linkage * component requires * indent * min std, min compiler version, extend fix * bump inih, better cppstd and compiler version check * fix * add c++17 compiler feature to test_package * endline * check max cppstd for versions older than 0.28.0 * linter linter again conan_version * fix build * Update recipes/exiv2/all/conanfile.py Co-authored-by: Matthieu Darbois * bump libpng version * add win_unicode option --------- Co-authored-by: Matthieu Darbois --- recipes/exiv2/all/conandata.yml | 8 ++ recipes/exiv2/all/conanfile.py | 77 ++++++++++++++++--- .../exiv2/all/patches/0001-link-0.28.0.patch | 22 ++++++ .../all/patches/0004-find-expat-0.28.0.patch | 16 ++++ recipes/exiv2/all/test_package/CMakeLists.txt | 4 + recipes/exiv2/config.yml | 2 + 6 files changed, 120 insertions(+), 9 deletions(-) create mode 100644 recipes/exiv2/all/patches/0001-link-0.28.0.patch create mode 100644 recipes/exiv2/all/patches/0004-find-expat-0.28.0.patch diff --git a/recipes/exiv2/all/conandata.yml b/recipes/exiv2/all/conandata.yml index 63e5ef9836649b..981b0a2937754c 100644 --- a/recipes/exiv2/all/conandata.yml +++ b/recipes/exiv2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.28.0": + url: "https://github.com/Exiv2/exiv2/releases/download/v0.28.0/exiv2-0.28.0-Source.tar.gz" + sha256: "89af3b5ef7277753ef7a7b5374ae017c6b9e304db3b688f1948e73e103491f3d" "0.27.5": url: "https://github.com/Exiv2/exiv2/releases/download/v0.27.5/exiv2-0.27.5-Source.tar.gz" sha256: "35a58618ab236a901ca4928b0ad8b31007ebdc0386d904409d825024e45ea6e2" @@ -6,6 +9,11 @@ sources: url: "https://github.com/Exiv2/exiv2/releases/download/v0.27.4/exiv2-0.27.4-Source.tar.gz" sha256: "84366dba7c162af9a7603bcd6c16f40fe0e9af294ba2fd2f66ffffb9fbec904e" patches: + "0.28.0": + - patch_file: "patches/0001-link-0.28.0.patch" + - patch_file: "patches/0004-find-expat-0.28.0.patch" + patch_description: "enforce usage of FindEXPAT.cmake" + patch_type: "conan" "0.27.5": - patch_file: "patches/0001-link-0.27.5.patch" - patch_file: "patches/0003-fix-ios.patch" diff --git a/recipes/exiv2/all/conanfile.py b/recipes/exiv2/all/conanfile.py index 34ee99761cacc6..b5c3445fd34dae 100644 --- a/recipes/exiv2/all/conanfile.py +++ b/recipes/exiv2/all/conanfile.py @@ -1,9 +1,12 @@ -from conan import ConanFile +from conan import ConanFile, conan_version from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout, CMakeDeps from conan.tools.files import get, copy, rmdir, save, export_conandata_patches, apply_conandata_patches -from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime, check_min_vs +from conan.tools.scm import Version import os +import sys import textwrap required_conan_version = ">=1.53.0" @@ -26,6 +29,9 @@ class Exiv2Conan(ConanFile): "with_png": [True, False], "with_xmp": [False, "bundled", "external"], "with_curl": [True, False], + "with_brotli": [True, False], + "with_inih": [True, False], + "win_unicode": [True, False], } default_options = { "shared": False, @@ -33,6 +39,9 @@ class Exiv2Conan(ConanFile): "with_png": True, "with_xmp": "bundled", "with_curl": False, + "with_brotli": True, + "with_inih": True, + "win_unicode": False, } provides = [] @@ -43,6 +52,14 @@ def export_sources(self): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) >= "0.28.0": + del self.options.win_unicode + else: + del self.options.with_brotli + del self.options.with_inih + + if self.settings.os == "Windows": + self.options.win_unicode = True def configure(self): if self.options.shared: @@ -58,14 +75,43 @@ def layout(self): def requirements(self): self.requires("libiconv/1.17") if self.options.with_png: - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") self.requires("zlib/1.2.13") if self.options.with_xmp == "bundled": self.requires("expat/2.5.0") if self.options.with_curl: - self.requires("libcurl/7.87.0") + self.requires("libcurl/8.2.1") + if self.options.get_safe("with_brotli"): + self.requires("brotli/1.0.9") + if self.options.get_safe("with_inih"): + self.requires("inih/57") def validate(self): + if Version(self.version) >= "0.28.0": + min_cppstd = 17 + + if self.settings.compiler.cppstd: + check_min_cppstd(self, min_cppstd) + check_min_vs(self, 191) + + compilers_minimum_version = { + "gcc": "8", + "clang": "5", + "apple-clang": "10", + } + if not is_msvc(self): + minimum_version = compilers_minimum_version.get(str(self.settings.compiler), False) + if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.ref} requires C++{min_cppstd}, which your compiler does not fully support." + ) + elif conan_version.major == 2: + # FIXME: linter complains, but function is there + # https://docs.conan.io/2.0/reference/tools/build.html?highlight=check_min_cppstd#conan-tools-build-check-max-cppstd + check_max_cppstd = getattr(sys.modules['conan.tools.build'], 'check_max_cppstd') + # https://github.com/Exiv2/exiv2/tree/v0.27.7#217-building-with-c11-and-other-compilers + check_max_cppstd(self, 14) + if self.options.with_xmp == "external": raise ConanInvalidConfiguration("adobe-xmp-toolkit is not available on cci (yet)") @@ -84,6 +130,12 @@ def generate(self): tc.variables["EXIV2_ENABLE_WEBREADY"] = self.options.with_curl tc.variables["EXIV2_ENABLE_CURL"] = self.options.with_curl tc.variables["EXIV2_ENABLE_SSH"] = False + if Version(self.version) >= "0.28.0": + tc.variables["EXIV2_ENABLE_BMFF"] = self.options.with_brotli + tc.variables["EXIV2_ENABLE_BROTLI"] = self.options.with_brotli + tc.variables["EXIV2_ENABLE_INIH"] = self.options.with_inih + else: + tc.variables["EXIV2_ENABLE_WIN_UNICODE"] = self.options.win_unicode tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" if is_msvc(self): @@ -145,6 +197,10 @@ def package_info(self): self.cpp_info.components["exiv2lib"].requires.extend(["libpng::libpng", "zlib::zlib"]) if self.options.with_curl: self.cpp_info.components["exiv2lib"].requires.append("libcurl::libcurl") + if self.options.get_safe("with_brotli"): + self.cpp_info.components["exiv2lib"].requires.extend(["brotli::brotlidec", "brotli::brotlienc"]) + if self.options.get_safe("with_inih"): + self.cpp_info.components["exiv2lib"].requires.append("inih::inireader") if self.settings.os in ("FreeBSD", "Linux"): self.cpp_info.components["exiv2lib"].system_libs.extend(["pthread"]) @@ -154,14 +210,17 @@ def package_info(self): # component exiv2-xmp if self.options.with_xmp == "bundled": - self.cpp_info.components["exiv2-xmp"].set_property("cmake_target_name", "exiv2-xmp") - self.cpp_info.components["exiv2-xmp"].libs = ["exiv2-xmp"] - self.cpp_info.components["exiv2-xmp"].requires = [ "expat::expat" ] - self.cpp_info.components["exiv2lib"].requires.append("exiv2-xmp") + if Version(self.version) < "0.28.0": + self.cpp_info.components["exiv2-xmp"].set_property("cmake_target_name", "exiv2-xmp") + self.cpp_info.components["exiv2-xmp"].libs = ["exiv2-xmp"] + self.cpp_info.components["exiv2-xmp"].requires = [ "expat::expat" ] + self.cpp_info.components["exiv2lib"].requires.append("exiv2-xmp") + else: + self.cpp_info.components["exiv2lib"].requires.append("expat::expat") # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.components["exiv2lib"].build_modules["cmake_find_package"] = [self._module_file_rel_path] self.cpp_info.components["exiv2lib"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - if self.options.with_xmp == "bundled": + if self.options.with_xmp == "bundled" and Version(self.version) < "0.28.0": self.cpp_info.components["exiv2-xmp"].build_modules["cmake_find_package"] = [self._module_file_rel_path] self.cpp_info.components["exiv2-xmp"].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] diff --git a/recipes/exiv2/all/patches/0001-link-0.28.0.patch b/recipes/exiv2/all/patches/0001-link-0.28.0.patch new file mode 100644 index 00000000000000..0c0e5fa28d40cc --- /dev/null +++ b/recipes/exiv2/all/patches/0001-link-0.28.0.patch @@ -0,0 +1,22 @@ +diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt +index 41a672e8..93370b5e 100644 +--- a/src/CMakeLists.txt ++++ b/src/CMakeLists.txt +@@ -170,10 +170,10 @@ if (MSVC) + set_target_properties(exiv2lib PROPERTIES LINK_FLAGS "/ignore:4099") + endif() + +-set_target_properties( exiv2lib_int PROPERTIES +- POSITION_INDEPENDENT_CODE ON +- COMPILE_DEFINITIONS exiv2lib_EXPORTS +-) ++ ++ ++ ++ + + # NOTE: Cannot use target_link_libraries on OBJECT libraries with old versions of CMake + target_include_directories(exiv2lib_int PRIVATE ${ZLIB_INCLUDE_DIR}) +-- +2.33.0.windows.1 + diff --git a/recipes/exiv2/all/patches/0004-find-expat-0.28.0.patch b/recipes/exiv2/all/patches/0004-find-expat-0.28.0.patch new file mode 100644 index 00000000000000..07fb4804513c7f --- /dev/null +++ b/recipes/exiv2/all/patches/0004-find-expat-0.28.0.patch @@ -0,0 +1,16 @@ +diff --git a/cmake/findDependencies.cmake b/cmake/findDependencies.cmake +index 1075c303..d8b580d4 100644 +--- a/cmake/findDependencies.cmake ++++ b/cmake/findDependencies.cmake +@@ -60,7 +60,7 @@ if (EXIV2_ENABLE_XMP AND EXIV2_ENABLE_EXTERNAL_XMP) + message(FATAL_ERROR "EXIV2_ENABLE_XMP AND EXIV2_ENABLE_EXTERNAL_XMP are mutually exclusive. You can only choose one of them") + else() + if (EXIV2_ENABLE_XMP) +- find_package(EXPAT REQUIRED) ++ find_package(EXPAT REQUIRED MODULE) + elseif (EXIV2_ENABLE_EXTERNAL_XMP) + find_package(XmpSdk REQUIRED) + endif () +-- +2.33.0.windows.1 + diff --git a/recipes/exiv2/all/test_package/CMakeLists.txt b/recipes/exiv2/all/test_package/CMakeLists.txt index 3bd4318c428bac..69bbd22508c9b5 100644 --- a/recipes/exiv2/all/test_package/CMakeLists.txt +++ b/recipes/exiv2/all/test_package/CMakeLists.txt @@ -5,3 +5,7 @@ find_package(exiv2 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} exiv2lib) + +if(${exiv2_VERSION} VERSION_GREATER_EQUAL "0.28.0") + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +endif() diff --git a/recipes/exiv2/config.yml b/recipes/exiv2/config.yml index 470d3a327a30b2..01a5aa663306e8 100644 --- a/recipes/exiv2/config.yml +++ b/recipes/exiv2/config.yml @@ -1,4 +1,6 @@ versions: + "0.28.0": + folder: all "0.27.5": folder: all "0.27.4": From dbe2569e1c94bbbec622cae27f6f132b3420ffef Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 19:34:12 +0900 Subject: [PATCH 0596/1140] (#19624) libcurl: update dependencies * libcurl: update dependencies * change zlib version range Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/libcurl/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/libcurl/all/conanfile.py b/recipes/libcurl/all/conanfile.py index 85bc4477130bef..40176f8f84e3b9 100644 --- a/recipes/libcurl/all/conanfile.py +++ b/recipes/libcurl/all/conanfile.py @@ -185,13 +185,13 @@ def requirements(self): elif self.options.with_ssl == "wolfssl": self.requires("wolfssl/5.6.3") if self.options.with_nghttp2: - self.requires("libnghttp2/1.55.1") + self.requires("libnghttp2/1.56.0") if self.options.with_libssh2: self.requires("libssh2/1.11.0") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.10 <2]") if self.options.with_brotli: - self.requires("brotli/1.0.9") + self.requires("brotli/1.1.0") if self.options.with_zstd: self.requires("zstd/1.5.5") if self.options.with_c_ares: @@ -216,7 +216,7 @@ def build_requirements(self): else: self.tool_requires("libtool/2.4.7") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.2") if self.settings.os in [ "tvOS", "watchOS" ]: self.tool_requires("gnu-config/cci.20210814") if self._settings_build.os == "Windows": From 2ceceb8c47fb39c79f7294411860fb39f4684313 Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Mon, 11 Sep 2023 14:25:30 +0200 Subject: [PATCH 0597/1140] (#19187) [highs] Enable shared build on Windows * [highs] Enable shared build on Windows and drop v1 test package * Re-add the required_conan_version line --- recipes/highs/all/conanfile.py | 7 ++----- .../highs/all/test_v1_package/CMakeLists.txt | 9 --------- recipes/highs/all/test_v1_package/conanfile.py | 18 ------------------ 3 files changed, 2 insertions(+), 32 deletions(-) delete mode 100644 recipes/highs/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/highs/all/test_v1_package/conanfile.py diff --git a/recipes/highs/all/conanfile.py b/recipes/highs/all/conanfile.py index a45cfe7de91d83..8758bb90904fef 100644 --- a/recipes/highs/all/conanfile.py +++ b/recipes/highs/all/conanfile.py @@ -1,7 +1,6 @@ from conan import ConanFile from conan.tools.apple import fix_apple_shared_install_name from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.errors import ConanInvalidConfiguration from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get from conan.tools.microsoft import is_msvc from conan.tools.scm import Version @@ -27,10 +26,6 @@ class HiGHSConan(ConanFile): "fPIC": True, } - def validate(self): - if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -75,6 +70,8 @@ def package(self): if self.options.shared: copy(self, pattern="*.so*", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) copy(self, pattern="*.dylib*", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) + copy(self, pattern="*.lib", src=self.build_folder, dst=join(self.package_folder, "lib"), keep_path=False) + copy(self, pattern="*.dll", src=self.build_folder, dst=join(self.package_folder, "bin"), keep_path=False) else: copy(self, pattern="*.a", src=join(self.build_folder, "lib"), dst=join(self.package_folder, "lib")) if Version(self.version) >= Version("1.5.3"): diff --git a/recipes/highs/all/test_v1_package/CMakeLists.txt b/recipes/highs/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 36b48f96d10783..00000000000000 --- a/recipes/highs/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) -set(CMAKE_CXX_STANDARD 11) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ - ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/highs/all/test_v1_package/conanfile.py b/recipes/highs/all/test_v1_package/conanfile.py deleted file mode 100644 index 5a05af3c2dfd2f..00000000000000 --- a/recipes/highs/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,18 +0,0 @@ -from conans import ConanFile, CMake -from conan.tools.build import cross_building -import os - - -class TestPackageV1Conan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) From 32c59bc7a56e7b0ba7e710497746e6a3a7396bbd Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Mon, 11 Sep 2023 17:24:01 +0400 Subject: [PATCH 0598/1140] (#19693) ade: 0.1.2c --- recipes/ade/all/conandata.yml | 3 +++ recipes/ade/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ade/all/conandata.yml b/recipes/ade/all/conandata.yml index 954c10dfe2c1d4..668f4325384370 100644 --- a/recipes/ade/all/conandata.yml +++ b/recipes/ade/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.1.2c": + url: "https://github.com/opencv/ade/archive/refs/tags/v0.1.2c.tar.gz" + sha256: "1387891c707c6e5c76448ea09e2df2e8bce1645c11f262c10b3f3ebec88749c2" "0.1.2a": url: "https://github.com/opencv/ade/archive/refs/tags/v0.1.2a.tar.gz" sha256: "c022a688b0554017e46e1cbdeb0105e625ca090fc3755c15df8c4451a304e084" diff --git a/recipes/ade/config.yml b/recipes/ade/config.yml index cbf2f373fb6306..373f3e14c45ff1 100644 --- a/recipes/ade/config.yml +++ b/recipes/ade/config.yml @@ -1,4 +1,6 @@ versions: + "0.1.2c": + folder: "all" "0.1.2a": folder: "all" "0.1.1f": From 46c64a6ce06c8bc97ffdff8a96ef694069103fc4 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 11 Sep 2023 23:43:34 +0900 Subject: [PATCH 0599/1140] (#19728) daw_json_link: add version 3.20.1, update dependencies --- recipes/daw_json_link/all/conandata.yml | 3 +++ recipes/daw_json_link/all/conanfile.py | 2 +- recipes/daw_json_link/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/daw_json_link/all/conandata.yml b/recipes/daw_json_link/all/conandata.yml index c72c7afca87692..a5b0b4f48353b9 100644 --- a/recipes/daw_json_link/all/conandata.yml +++ b/recipes/daw_json_link/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.20.1": + url: "https://github.com/beached/daw_json_link/archive/refs/tags/v3.20.1.tar.gz" + sha256: "046638bc4437d138cc8bdc882027d318ca3e267f33d1b419c5bdecb45b595a47" "3.19.0": url: "https://github.com/beached/daw_json_link/archive/refs/tags/v3.19.0.tar.gz" sha256: "85c2f6a84878925eb692c53b321b9b237481969c8caa3a9324b78540096a3559" diff --git a/recipes/daw_json_link/all/conanfile.py b/recipes/daw_json_link/all/conanfile.py index 7a1455d0e9bdad..a22aa6b41c06b3 100644 --- a/recipes/daw_json_link/all/conanfile.py +++ b/recipes/daw_json_link/all/conanfile.py @@ -39,7 +39,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("daw_header_libraries/2.93.1") + self.requires("daw_header_libraries/2.96.1") self.requires("daw_utf_range/2.2.3") def package_id(self): diff --git a/recipes/daw_json_link/config.yml b/recipes/daw_json_link/config.yml index b1d3c03d355078..97a23d5d146003 100644 --- a/recipes/daw_json_link/config.yml +++ b/recipes/daw_json_link/config.yml @@ -1,4 +1,6 @@ versions: + "3.20.1": + folder: "all" "3.19.0": folder: "all" "3.17.2": From 28cb271f9b1b22c79c8c57d943e40e97a90a723d Mon Sep 17 00:00:00 2001 From: Sneder89 <45610045+Sneder89@users.noreply.github.com> Date: Mon, 11 Sep 2023 22:38:09 +0200 Subject: [PATCH 0600/1140] (#19729) add cppcheck 2.12.0 * add cppcheck 2.12.0 * remove old versions --- recipes/cppcheck/all/conandata.yml | 30 +++++-------------- .../0004-pcre-debuglib-name-2.12.patch | 11 +++++++ recipes/cppcheck/config.yml | 6 ++-- 3 files changed, 20 insertions(+), 27 deletions(-) create mode 100644 recipes/cppcheck/all/patches/0004-pcre-debuglib-name-2.12.patch diff --git a/recipes/cppcheck/all/conandata.yml b/recipes/cppcheck/all/conandata.yml index 35bee8612638ba..43f1aa2fd39bee 100644 --- a/recipes/cppcheck/all/conandata.yml +++ b/recipes/cppcheck/all/conandata.yml @@ -1,35 +1,29 @@ sources: + "2.12": + url: "https://github.com/danmar/cppcheck/archive/2.12.0.tar.gz" + sha256: "7d67776118aee9a4f0214f993a4baa4a168b2dbb10c14b6ec5baf2ca147565b8" "2.11.1": url: "https://github.com/danmar/cppcheck/archive/2.11.1.tar.gz" sha256: "fef6ef868d562d49136f158e1d0f7a38237e7e1c0a91d9189bdd465f1fe54316" "2.10.3": url: "https://github.com/danmar/cppcheck/archive/2.10.3.tar.gz" sha256: "8aae5e116daeaaf5d19f3efa61b91c06f161cb97412a1d1af6e1e20686e48967" - "2.10": - url: "https://github.com/danmar/cppcheck/archive/2.10.tar.gz" - sha256: "785dcbf711048dfe43ae920b6eff2eeebb4a096e88188a40e173ca4c030f57c3" "2.9.3": url: "https://github.com/danmar/cppcheck/archive/2.9.3.tar.gz" sha256: "46319ca73e33e4b2bd91981a76a0d4f184cd3f86b62dc18e8938eabacd3ad2e3" - "2.9.2": - url: "https://github.com/danmar/cppcheck/archive/2.9.2.tar.gz" - sha256: "93920d24d4442856bf7916ee0e3fc31308bc23948e7029b4fd332e01cac63c3e" "2.8.2": url: "https://github.com/danmar/cppcheck/archive/2.8.2.tar.gz" sha256: "30ba99ab54089c44b83f02e2453da046a7edff5237950d4A0eb1eba4afcb4f45" patches: - "2.11.1": - - patch_file: "patches/0003-pcre-debuglib-name.patch" + "2.12": + - patch_file: "patches/0004-pcre-debuglib-name-2.12.patch" patch_description: "Consider the Debug suffix for Windows" patch_type: "portability" - "2.10.3": - - patch_file: "patches/0001-cli-remove-dmake-cmake-2.10.patch" - patch_description: "Remove dmake tool from target ALL" - patch_type: "portability" + "2.11.1": - patch_file: "patches/0003-pcre-debuglib-name.patch" patch_description: "Consider the Debug suffix for Windows" patch_type: "portability" - "2.10": + "2.10.3": - patch_file: "patches/0001-cli-remove-dmake-cmake-2.10.patch" patch_description: "Remove dmake tool from target ALL" patch_type: "portability" @@ -46,16 +40,6 @@ patches: - patch_file: "patches/0003-pcre-debuglib-name.patch" patch_description: "Consider the Debug suffix for Windows" patch_type: "portability" - "2.9.2": - - patch_file: "patches/0001-cli-remove-dmake-cmake.patch" - patch_description: "Remove dmake tool from target ALL" - patch_type: "portability" - - patch_file: "patches/0002-htmlreport-python3.patch" - patch_description: "Use Python 3 in Shebang Header" - patch_type: "portability" - - patch_file: "patches/0003-pcre-debuglib-name.patch" - patch_description: "Consider the Debug suffix for Windows" - patch_type: "portability" "2.8.2": - patch_file: "patches/0001-cli-remove-dmake-cmake-2.8.patch" patch_description: "Remove dmake tool from target ALL" diff --git a/recipes/cppcheck/all/patches/0004-pcre-debuglib-name-2.12.patch b/recipes/cppcheck/all/patches/0004-pcre-debuglib-name-2.12.patch new file mode 100644 index 00000000000000..7f30a7cb1d7d43 --- /dev/null +++ b/recipes/cppcheck/all/patches/0004-pcre-debuglib-name-2.12.patch @@ -0,0 +1,11 @@ +--- a/cmake/findDependencies.cmake 2023-09-09 15:10:31.000000000 +0200 ++++ b/cmake/findDependencies.cmake 2023-09-11 08:44:40.220863900 +0200 +@@ -31,7 +31,7 @@ + + if (HAVE_RULES) + find_path(PCRE_INCLUDE pcre.h) +- find_library(PCRE_LIBRARY pcre) ++ find_library(PCRE_LIBRARY NAMES pcre pcred) + if (NOT PCRE_LIBRARY OR NOT PCRE_INCLUDE) + message(FATAL_ERROR "pcre dependency for RULES has not been found") + endif() diff --git a/recipes/cppcheck/config.yml b/recipes/cppcheck/config.yml index 6325a54f72873f..c685c098418079 100644 --- a/recipes/cppcheck/config.yml +++ b/recipes/cppcheck/config.yml @@ -1,13 +1,11 @@ versions: + "2.12": + folder: all "2.11.1": folder: all "2.10.3": folder: all - "2.10": - folder: all "2.9.3": folder: all - "2.9.2": - folder: all "2.8.2": folder: all From a41491de3ae804b29d8146eb0381aa392be4733e Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Tue, 12 Sep 2023 00:28:40 +0200 Subject: [PATCH 0601/1140] (#19730) glib: add version 2.78.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/glib/all/conandata.yml | 3 +++ recipes/glib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glib/all/conandata.yml b/recipes/glib/all/conandata.yml index ec38114b48cbc0..b749d7ac74580a 100644 --- a/recipes/glib/all/conandata.yml +++ b/recipes/glib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.78.0": + url: "https://download.gnome.org/sources/glib/2.78/glib-2.78.0.tar.xz" + sha256: "44eaab8b720877ce303c5540b657b126f12dc94972d9880b52959f43fb537b30" "2.77.3": url: "https://download.gnome.org/sources/glib/2.77/glib-2.77.3.tar.xz" sha256: "1753f963bb680b28a83d6e2095f63d0d4b94244675bcd2603850b2ebc1ac6a61" diff --git a/recipes/glib/config.yml b/recipes/glib/config.yml index 1a21f71ff22892..87471ca63de5f7 100644 --- a/recipes/glib/config.yml +++ b/recipes/glib/config.yml @@ -1,4 +1,6 @@ versions: + "2.78.0": + folder: all "2.77.3": folder: all "2.77.2": From fc07677f477551d5ee1078e49eb611f01f4c8048 Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Tue, 12 Sep 2023 02:49:35 +0200 Subject: [PATCH 0602/1140] (#19731) hictk: add v0.0.2 --- recipes/hictk/all/conandata.yml | 3 +++ recipes/hictk/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/hictk/all/conandata.yml b/recipes/hictk/all/conandata.yml index b46596ee0372e8..accdbdc6e5b48e 100644 --- a/recipes/hictk/all/conandata.yml +++ b/recipes/hictk/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.0.2": + url: "https://github.com/paulsengroup/hictk/archive/refs/tags/v0.0.2.tar.gz" + sha256: "7716711ecb33247d8f79f6768ebbdcf55e51e9b6f962245747b33d0967431427" "0.0.1": url: "https://github.com/paulsengroup/hictk/archive/refs/tags/v0.0.1.tar.gz" sha256: "460985413c3b2e80121f7697c6c824a91955a38051de770d7eb946ddafa88460" diff --git a/recipes/hictk/config.yml b/recipes/hictk/config.yml index f6f5b5679b9d41..05473f80b31308 100644 --- a/recipes/hictk/config.yml +++ b/recipes/hictk/config.yml @@ -1,3 +1,5 @@ versions: + "0.0.2": + folder: all "0.0.1": folder: all From c993c77724307f87f7eb87aefdcafb11132e8084 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 12 Sep 2023 15:21:31 +0900 Subject: [PATCH 0603/1140] (#19407) sqlite_orm: update sqlite3/3.43.0 --- recipes/sqlite_orm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/sqlite_orm/all/conanfile.py b/recipes/sqlite_orm/all/conanfile.py index 90bb95e386b2e1..343f40bded77de 100644 --- a/recipes/sqlite_orm/all/conanfile.py +++ b/recipes/sqlite_orm/all/conanfile.py @@ -39,7 +39,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("sqlite3/3.41.1", transitive_headers=True, transitive_libs=True) + self.requires("sqlite3/3.43.0", transitive_headers=True, transitive_libs=True) def package_id(self): self.info.clear() From e5a0a38cdbeac3e7d7d90e1231d08d3391897cb2 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 12 Sep 2023 09:50:58 +0200 Subject: [PATCH 0604/1140] (#19737) pkgconf: add version 2.0.3 --- recipes/pkgconf/all/conandata.yml | 5 +++++ recipes/pkgconf/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/pkgconf/all/conandata.yml b/recipes/pkgconf/all/conandata.yml index cf574fc35a1d54..30195c0bf1274a 100644 --- a/recipes/pkgconf/all/conandata.yml +++ b/recipes/pkgconf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.3": + url: "https://distfiles.ariadne.space/pkgconf/pkgconf-2.0.3.tar.xz" + sha256: "cabdf3c474529854f7ccce8573c5ac68ad34a7e621037535cbc3981f6b23836c" "2.0.2": url: "https://distfiles.ariadne.space/pkgconf/pkgconf-2.0.2.tar.xz" sha256: "ea5a25ef8f251eb5377ec0e21c75fb61894433cfbdbf0b2559ba33e4c2664401" @@ -15,6 +18,8 @@ sources: url: "https://distfiles.ariadne.space/pkgconf/pkgconf-1.7.3.tar.xz" sha256: "b846aea51cf696c3392a0ae58bef93e2e72f8e7073ca6ad1ed8b01c85871f9c0" patches: + "2.0.3": + - patch_file: "patches/1.9.3-0003-PKG_CONF_PATH-allow-colon+semicolon-separator.patch" "2.0.2": - patch_file: "patches/1.9.3-0003-PKG_CONF_PATH-allow-colon+semicolon-separator.patch" "1.9.5": diff --git a/recipes/pkgconf/config.yml b/recipes/pkgconf/config.yml index e17ebc77d55fac..0ccc580d4eb3c0 100644 --- a/recipes/pkgconf/config.yml +++ b/recipes/pkgconf/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.3": + folder: "all" "2.0.2": folder: "all" "1.9.5": From 2b6e60603b632763987b72db0655cd1c623a41c3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 12 Sep 2023 10:41:59 +0200 Subject: [PATCH 0605/1140] (#19505) arrow: do not add build requires to cmake before arrow 13.0.0 --- recipes/arrow/all/conanfile.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index a7f22fcf6eceef..2edf070a224e05 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -378,6 +378,10 @@ def validate(self): if Version(self.version) < "6.0.0" and self.options.get_safe("simd_level") == "default": raise ConanInvalidConfiguration(f"In {self.ref}, simd_level options is not supported `default` value.") + def build_requirements(self): + if Version(self.version) >= "13.0.0": + self.tool_requires("cmake/[>=3.16 <4]") + def source(self): get(self, **self.conan_data["sources"][self.version], filename=f"apache-arrow-{self.version}.tar.gz", strip_root=True) @@ -527,9 +531,6 @@ def build(self): cmake.configure(build_script_folder=os.path.join(self.source_folder, "cpp")) cmake.build() - def build_requirements(self): - self.tool_requires("cmake/[>=3.16 <4]") - def package(self): copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy(self, pattern="NOTICE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) From 0111017d8b9c32d8192f8c3da036c162f1091be1 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 12 Sep 2023 17:58:41 +0900 Subject: [PATCH 0606/1140] (#19740) sqlite3: add version 3.43.1 --- recipes/sqlite3/all/conandata.yml | 3 +++ recipes/sqlite3/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sqlite3/all/conandata.yml b/recipes/sqlite3/all/conandata.yml index 7d17c799d5f248..464fb1e4a09242 100644 --- a/recipes/sqlite3/all/conandata.yml +++ b/recipes/sqlite3/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.43.1": + url: "https://sqlite.org/2023/sqlite-amalgamation-3430100.zip" + sha256: "7e634bbd4b2870a83dc7c1e3cc02e4d30b8555cd7db7b332f24e0c447fd0dd16" "3.43.0": url: "https://sqlite.org/2023/sqlite-amalgamation-3430000.zip" sha256: "bb5849ae4d7129c09d20596379a0b3f7b1ac59cf9998eba5ef283ea9b6c000a5" diff --git a/recipes/sqlite3/config.yml b/recipes/sqlite3/config.yml index f5a78a2be1eed6..fcd4427a99ec3c 100644 --- a/recipes/sqlite3/config.yml +++ b/recipes/sqlite3/config.yml @@ -1,4 +1,6 @@ versions: + "3.43.1": + folder: all "3.43.0": folder: all "3.42.0": From 997c76a25a3cf020f1197f948f99ac04024a98b7 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 12 Sep 2023 11:28:40 +0200 Subject: [PATCH 0607/1140] (#19733) [bot] Update authorized users list (2023-09-11) --- .c3i/authorized_users.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 56fdf9df94977a..345b797f068312 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1226,3 +1226,5 @@ authorized_users: - p-groarke - Kalixio - temap +- vient +- bryce-cahill From 29f50b38626d426f70dc394610f229ddf66e890d Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 12 Sep 2023 12:07:08 +0200 Subject: [PATCH 0608/1140] (#19754) [bot] Update list of references (prod-v2/ListPackages) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- .c3i/conan_v2_ready_references.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 52d413af7f3cc5..81f7ccff089c46 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -176,6 +176,7 @@ required_for_references: - concurrentqueue - console_bridge - continuable +- corrade - cotila - cpp-httplib - cpp-ipc @@ -295,6 +296,7 @@ required_for_references: - etc2comp - eternal - etl +- evmc - exiv2 - expat - expected-lite @@ -346,6 +348,7 @@ required_for_references: - ftxui - function2 - functionalplus +- functions-framework-cpp - fusepp - fxdiv - g3log @@ -589,6 +592,7 @@ required_for_references: - libmysqlclient - libnabo - libnet +- libnetfilter_queue - libnfnetlink - libnfs - libnghttp2 @@ -1125,10 +1129,15 @@ required_for_references: - tl - tl-expected - tl-function-ref +- tl-optional - tllist - tlx +- tmx +- tmxlite +- tng - toml11 - tracy +- transwarp - trantor - tree-sitter - tree-sitter-c From f0efbaf03ad111a63a6a381bc0caa0a405e11a6f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 12 Sep 2023 12:23:45 +0200 Subject: [PATCH 0609/1140] (#19685) Bump libspng's zlib requirement to [>=1.2.11 <2] range --- recipes/libspng/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libspng/all/conanfile.py b/recipes/libspng/all/conanfile.py index b9d182dd24f28f..f151ee813b2194 100644 --- a/recipes/libspng/all/conanfile.py +++ b/recipes/libspng/all/conanfile.py @@ -47,7 +47,7 @@ def requirements(self): if self.options.with_miniz: self.requires("miniz/3.0.2") else: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 30cc2e1abcbc36a1f010a048543385727d2eef3f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 12 Sep 2023 14:12:12 +0300 Subject: [PATCH 0610/1140] (#18596) functionalplus: add package_type --- recipes/functionalplus/all/conanfile.py | 40 ++++++++++++++----------- 1 file changed, 23 insertions(+), 17 deletions(-) diff --git a/recipes/functionalplus/all/conanfile.py b/recipes/functionalplus/all/conanfile.py index e87d42e53ba377..53628cdcaf1526 100644 --- a/recipes/functionalplus/all/conanfile.py +++ b/recipes/functionalplus/all/conanfile.py @@ -3,6 +3,7 @@ from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os required_conan_version = ">=1.50.0" @@ -12,12 +13,18 @@ class FunctionalPlusConan(ConanFile): name = "functionalplus" description = "Functional Programming Library for C++." license = "BSL-1.0" - topics = ("functionalplus", "fplus", "functional programming") + topics = ("fplus", "functional programming", "header-only") homepage = "https://github.com/Dobiasd/FunctionalPlus" url = "https://github.com/conan-io/conan-center-index" + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + return 14 + @property def _compilers_minimum_version(self): return { @@ -28,36 +35,35 @@ def _compilers_minimum_version(self): "apple-clang": "9", } + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 14) - - def loose_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version and loose_lt_semver(str(self.settings.compiler.version), minimum_version): - raise ConanInvalidConfiguration("functionalplus requires C++14, which your compiler does not support.") - - def layout(self): - basic_layout(self, src_folder="src") + 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], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass def package(self): - copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) - copy(self, "*", src=os.path.join(self.source_folder, "include"), dst=os.path.join(self.package_folder, "include")) + copy(self, "LICENSE", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*", + src=os.path.join(self.source_folder, "include"), + dst=os.path.join(self.package_folder, "include")) def package_info(self): self.cpp_info.set_property("cmake_file_name", "FunctionalPlus") From 0fda4efdbb40f7598964a46cb9d3713c4ed46aa7 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 12 Sep 2023 13:59:30 +0200 Subject: [PATCH 0611/1140] (#19667) pcre: use version range for zlib MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * typo * Update recipes/pcre/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/pcre/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pcre/all/conanfile.py b/recipes/pcre/all/conanfile.py index 8d0c74976c81bf..ca51bc38829c60 100644 --- a/recipes/pcre/all/conanfile.py +++ b/recipes/pcre/all/conanfile.py @@ -75,7 +75,7 @@ def requirements(self): if self.options.get_safe("with_bzip2"): self.requires("bzip2/1.0.8") if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if not self.options.build_pcre_8 and not self.options.build_pcre_16 and not self.options.build_pcre_32: From d7a1fe9b9d9b4f597e32378a8e05adee034ea6bc Mon Sep 17 00:00:00 2001 From: Dmitry Baryshev Date: Tue, 12 Sep 2023 16:11:25 +0300 Subject: [PATCH 0612/1140] (#19732) sail: Remove Windows SDK hack and try to rebuild V2 [closes #19591] * libavif: bump deps * sail: remove Windows SDK workaround hack --- recipes/sail/all/conanfile.py | 5 ----- 1 file changed, 5 deletions(-) diff --git a/recipes/sail/all/conanfile.py b/recipes/sail/all/conanfile.py index fb389e804f1317..31e7177ae090ee 100644 --- a/recipes/sail/all/conanfile.py +++ b/recipes/sail/all/conanfile.py @@ -104,11 +104,6 @@ def generate(self): # TODO: Remove after fixing https://github.com/conan-io/conan/issues/12012 if is_msvc(self): tc.cache_variables["CMAKE_TRY_COMPILE_CONFIGURATION"] = str(self.settings.build_type) - # TODO: Remove after fixing https://github.com/conan-io/conan-center-index/issues/13159 - # C3I workaround to force CMake to choose the highest version of - # the windows SDK available in the system - if is_msvc(self) and not self.conf.get("tools.cmake.cmaketoolchain:system_version"): - tc.variables["CMAKE_SYSTEM_VERSION"] = "10.0" tc.generate() deps = CMakeDeps(self) From d9066ea9ed9869e56ee98b280981d628fa5c29b6 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 12 Sep 2023 23:07:46 +0900 Subject: [PATCH 0613/1140] (#19755) gperftools: add version 2.13.0 --- recipes/gperftools/all/conandata.yml | 3 +++ recipes/gperftools/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/gperftools/all/conandata.yml b/recipes/gperftools/all/conandata.yml index 9b61f5954a26d7..b141978957b857 100644 --- a/recipes/gperftools/all/conandata.yml +++ b/recipes/gperftools/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.13.0": + url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.13/gperftools-2.13.tar.gz" + sha256: "4882c5ece69f8691e51ffd6486df7d79dbf43b0c909d84d3c0883e30d27323e7" "2.12.0": url: "https://github.com/gperftools/gperftools/releases/download/gperftools-2.12/gperftools-2.12.tar.gz" sha256: "fb611b56871a3d9c92ab0cc41f9c807e8dfa81a54a4a9de7f30e838756b5c7c6" diff --git a/recipes/gperftools/config.yml b/recipes/gperftools/config.yml index 901ed44b80295c..65392d0c25ec5d 100644 --- a/recipes/gperftools/config.yml +++ b/recipes/gperftools/config.yml @@ -1,4 +1,6 @@ versions: + "2.13.0": + folder: all "2.12.0": folder: all "2.11.0": From 9dd70b13c0d218c1c94a74e9e61ec3dbade80c43 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Thu, 14 Sep 2023 22:21:49 +0200 Subject: [PATCH 0614/1140] (#19779) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 81f7ccff089c46..8b4cb97448cab5 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -1143,12 +1143,21 @@ required_for_references: - tree-sitter-c - troldal-zippy - trompeloeil +- tscns +- tsil +- tsl-array-hash +- tsl-hat-trie - tsl-hopscotch-map +- tsl-ordered-map +- tsl-robin-map +- tsl-sparse-map +- tuplet - turtle - type_safe - tz - ua-nodeset - uchardet +- uncrustify - uni-algo - unicorn - unity From 2cb5af2a1389c9712844ab88a0c9d2596715f511 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Thu, 14 Sep 2023 23:22:40 +0200 Subject: [PATCH 0615/1140] (#19807) [bot] Update authorized users list (2023-09-14) --- .c3i/authorized_users.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 345b797f068312..212a9101efacf8 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1228,3 +1228,6 @@ authorized_users: - temap - vient - bryce-cahill +- alfred-sa +- leducp +- mrjoel From 927ea98d0f8228bbc787d73dfcf15c875dccf8a1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 15 Sep 2023 01:07:44 +0300 Subject: [PATCH 0616/1140] (#18263) platform.equality: migrate to Conan v2 * platform.equality: migrate to Conan v2 * platform.equality: restore test_v1_package * platform.equality: add cmake_find_package_multi generator to test_v1_package * platform.equality: fix missing includes * platform.equality: require libstdc++ * platform.equality: restore VirtualRunEnv in test_package --- recipes/platform.equality/all/conanfile.py | 75 +++++++++++-------- .../all/test_package/CMakeLists.txt | 9 +-- .../all/test_package/conanfile.py | 21 ++++-- .../all/test_package/test_package.cpp | 7 ++ .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 94 insertions(+), 43 deletions(-) create mode 100644 recipes/platform.equality/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/platform.equality/all/test_v1_package/conanfile.py diff --git a/recipes/platform.equality/all/conanfile.py b/recipes/platform.equality/all/conanfile.py index ce4633881f0af9..8aa89e267366d6 100644 --- a/recipes/platform.equality/all/conanfile.py +++ b/recipes/platform.equality/all/conanfile.py @@ -1,28 +1,37 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class PlatformInterfacesConan(ConanFile): name = "platform.equality" + description = ( + "platform.delegates is one of the libraries of the LinksPlatform modular framework, " + "which uses innovations from the C++20 standard, for slow parody any typing dictionary and others." + ) license = "LGPL-3.0-or-later" - homepage = "https://github.com/linksplatform/Equality" url = "https://github.com/conan-io/conan-center-index" - description = "platform.delegates is one of the libraries of the LinksPlatform modular framework, " \ - "which uses innovations from the C++20 standard, for slow parody any typing dictionary and others." + homepage = "https://github.com/linksplatform/Equality" topics = ("linksplatform", "cpp20", "equality", "ranges", "any", "header-only") - settings = "compiler" + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _minimum_cpp_standard(self): + return 20 @property def _internal_cpp_subfolder(self): - return os.path.join(self._source_subfolder, "cpp", "Platform.Equality") + return os.path.join(self.source_folder, "cpp", "Platform.Equality") @property def _compilers_minimum_version(self): @@ -30,37 +39,39 @@ def _compilers_minimum_version(self): "gcc": "10", "Visual Studio": "16", "clang": "11", - "apple-clang": "11" + "apple-clang": "11", } - @property - def _minimum_cpp_standard(self): - return 20 + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def validate(self): - minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._minimum_cpp_standard) + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) if not minimum_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) - - elif tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("platform.equality/{} " - "requires C++{} with {}, " - "which is not supported " - "by {} {}.".format( - self.version, self._minimum_cpp_standard, self.settings.compiler, self.settings.compiler, - self.settings.compiler.version)) + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") + elif Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.ref} requires C++{self._minimum_cpp_standard} with {self.settings.compiler}, " + f"which is not supported by {self.settings.compiler} {self.settings.compiler.version}." + ) - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) + if self.settings.compiler in ["clang", "apple-clang"] and not str(self.settings.compiler.libcxx).startswith("libstdc++"): + # ranges library from libc++ is not compatible with platform.equality + raise ConanInvalidConfiguration(f"{self.ref} requires libstdc++ with {self.settings.compiler}.") def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*.h", dst="include", src=self._internal_cpp_subfolder) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*.h", dst=os.path.join(self.package_folder, "include"), src=self._internal_cpp_subfolder) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/platform.equality/all/test_package/CMakeLists.txt b/recipes/platform.equality/all/test_package/CMakeLists.txt index c6c4cb78292bee..5821e9140a6f12 100644 --- a/recipes/platform.equality/all/test_package/CMakeLists.txt +++ b/recipes/platform.equality/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(platform.equality REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE platform.equality::platform.equality) set_target_properties(${PROJECT_NAME} PROPERTIES CXX_STANDARD 20) diff --git a/recipes/platform.equality/all/test_package/conanfile.py b/recipes/platform.equality/all/test_package/conanfile.py index d4128b04507778..ef5d7042163ecc 100644 --- a/recipes/platform.equality/all/test_package/conanfile.py +++ b/recipes/platform.equality/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/platform.equality/all/test_package/test_package.cpp b/recipes/platform.equality/all/test_package/test_package.cpp index fa88538c2fc869..ae61402c8fcd8a 100644 --- a/recipes/platform.equality/all/test_package/test_package.cpp +++ b/recipes/platform.equality/all/test_package/test_package.cpp @@ -1,3 +1,10 @@ +// Workaround for missing includes in platform.equality +#include +#include +#include +#include +#include + #include #include diff --git a/recipes/platform.equality/all/test_v1_package/CMakeLists.txt b/recipes/platform.equality/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/platform.equality/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/platform.equality/all/test_v1_package/conanfile.py b/recipes/platform.equality/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..49a3a66ea5bad4 --- /dev/null +++ b/recipes/platform.equality/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 1f8e6201da7cb5a2dbb2cdb2b3775021067323fb Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 15 Sep 2023 01:24:18 +0300 Subject: [PATCH 0617/1140] (#18270) redboltz-mqtt_cpp: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * redboltz-mqtt_cpp: migrate to Conan v2 * redboltz-mqtt_cpp: restore test_v1_package * redboltz-mqtt_cpp: restore VirtualRunEnv in test_package * redboltz-mqtt_cpp: bump deps * Update recipes/redboltz-mqtt_cpp/all/conanfile.py * Update recipes/redboltz-mqtt_cpp/all/conanfile.py --------- Co-authored-by: Francisco Ramírez --- recipes/redboltz-mqtt_cpp/all/conanfile.py | 62 ++++++++++++------- .../all/test_package/CMakeLists.txt | 6 +- .../all/test_package/conanfile.py | 19 ++++-- .../all/test_package/test_package.cpp | 2 +- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 80 insertions(+), 34 deletions(-) create mode 100644 recipes/redboltz-mqtt_cpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/redboltz-mqtt_cpp/all/test_v1_package/conanfile.py diff --git a/recipes/redboltz-mqtt_cpp/all/conanfile.py b/recipes/redboltz-mqtt_cpp/all/conanfile.py index 8fdf7f70084cf9..5ca0f086f35bf9 100644 --- a/recipes/redboltz-mqtt_cpp/all/conanfile.py +++ b/recipes/redboltz-mqtt_cpp/all/conanfile.py @@ -1,8 +1,14 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class MqttCPPConan(ConanFile): name = "redboltz-mqtt_cpp" @@ -10,20 +16,15 @@ class MqttCPPConan(ConanFile): license = "BSL-1.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/redboltz/mqtt_cpp" - topics = ("mqtt", "boost", "asio") + topics = ("mqtt", "boost", "asio", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - generators = "cmake" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" - - def requirements(self): - self.requires("boost/1.79.0") - - def package_id(self): - self.info.header_only() + def _min_cppstd(self): + return 14 @property def _compilers_minimum_version(self): @@ -33,27 +34,42 @@ def _compilers_minimum_version(self): "clang": "5", "apple-clang": "10", } - + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("boost/1.83.0") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 14) + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{} requires C++14, which your compiler does not support.".format(self.name)) + if Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration(f"{self.name} requires C++14, which your compiler does not support.") else: - self.output.warn("{} requires C++14. Your compiler is unknown. Assuming it supports C++14.".format(self.name)) - + self.output.warning(f"{self.name} requires C++14. Your compiler is unknown. Assuming it supports C++14.") + def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE_1_0.txt", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*.hpp", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE_1_0.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "mqtt_cpp") self.cpp_info.set_property("cmake_target_name", "mqtt_cpp::mqtt_cpp") diff --git a/recipes/redboltz-mqtt_cpp/all/test_package/CMakeLists.txt b/recipes/redboltz-mqtt_cpp/all/test_package/CMakeLists.txt index d57b3a725b42c5..bb306edeaaa9c5 100644 --- a/recipes/redboltz-mqtt_cpp/all/test_package/CMakeLists.txt +++ b/recipes/redboltz-mqtt_cpp/all/test_package/CMakeLists.txt @@ -1,10 +1,6 @@ -cmake_minimum_required(VERSION 3.8) - +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(mqtt_cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/redboltz-mqtt_cpp/all/test_package/conanfile.py b/recipes/redboltz-mqtt_cpp/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/redboltz-mqtt_cpp/all/test_package/conanfile.py +++ b/recipes/redboltz-mqtt_cpp/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/redboltz-mqtt_cpp/all/test_package/test_package.cpp b/recipes/redboltz-mqtt_cpp/all/test_package/test_package.cpp index 65e10348b409b3..a75d73b3ececd0 100644 --- a/recipes/redboltz-mqtt_cpp/all/test_package/test_package.cpp +++ b/recipes/redboltz-mqtt_cpp/all/test_package/test_package.cpp @@ -6,7 +6,7 @@ int main() { boost::asio::io_context ioc; auto c = MQTT_NS::make_async_client(ioc, "localhost", "40000"); - + c->set_client_id("test_package"); c->set_clean_session(true); diff --git a/recipes/redboltz-mqtt_cpp/all/test_v1_package/CMakeLists.txt b/recipes/redboltz-mqtt_cpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/redboltz-mqtt_cpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/redboltz-mqtt_cpp/all/test_v1_package/conanfile.py b/recipes/redboltz-mqtt_cpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/redboltz-mqtt_cpp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From b4c659f991c1460d7fc2f28ac2650df73e172dbb Mon Sep 17 00:00:00 2001 From: Dovydas Girdvainis Date: Fri, 15 Sep 2023 00:49:44 +0200 Subject: [PATCH 0618/1140] (#18914) Package/open62541 v1.3.6 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add v1.3.6 sources * update deps/ua-nodeset submodule * fix submodule source setup * fix check for msvc compiler * use conan v2 copy mechanism * do not add plugin, posix, win32 include dirs for single_header configurations * cleanup max_clang_version version formatting * fix nodeset path for test_package * retrigger CI/CD pipeline Signed-off-by: Dovydas Girdvainis * Simplify test_package, add package_type, fix licenses, openssl version range & conan fixes * Fix policy * Revert test_package.c --------- Signed-off-by: Dovydas Girdvainis Co-authored-by: Rubén Rincón Co-authored-by: Rubén Rincón Blanco --- recipes/open62541/all/conandata.yml | 3 + recipes/open62541/all/conanfile.py | 74 +++++++++---------- recipes/open62541/all/submoduledata.yml | 5 ++ .../open62541/all/test_package/conanfile.py | 6 +- recipes/open62541/config.yml | 2 + 5 files changed, 47 insertions(+), 43 deletions(-) diff --git a/recipes/open62541/all/conandata.yml b/recipes/open62541/all/conandata.yml index d458e6add2e688..e50e7d9a28e654 100644 --- a/recipes/open62541/all/conandata.yml +++ b/recipes/open62541/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.6": + url: "https://github.com/open62541/open62541/archive/v1.3.6.tar.gz" + sha256: "0751ce6273908b1e571f36591665f3d5b9451514c2478ea5f6b4b466d7da6b02" "1.3.4": url: "https://github.com/open62541/open62541/archive/v1.3.4.tar.gz" sha256: "3489cfa2f98c52df252adc8e641a9e59cb675bdfd5ef413b0d947e667cddd16d" diff --git a/recipes/open62541/all/conanfile.py b/recipes/open62541/all/conanfile.py index 25dd98cf850ffc..a620f7d0b2c630 100644 --- a/recipes/open62541/all/conanfile.py +++ b/recipes/open62541/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.tools.cmake import cmake_layout, CMake, CMakeToolchain, CMakeDeps from conan.tools.scm import Version -from conan.tools.files import apply_conandata_patches, collect_libs, export_conandata_patches, rename, rm, rmdir, get +from conan.tools.files import apply_conandata_patches, collect_libs, export_conandata_patches, copy, rm, rmdir, get from conan.errors import ConanInvalidConfiguration import glob import os @@ -12,7 +12,7 @@ class Open62541Conan(ConanFile): name = "open62541" - license = "MPLv2" + license = ("MPL-2.0", "CC0-1.0") homepage = "https://open62541.org/" url = "https://github.com/conan-io/conan-center-index" description = "open62541 is an open source and free implementation of OPC UA " \ @@ -24,10 +24,11 @@ class Open62541Conan(ConanFile): "All platform-specific functionality is implemented via exchangeable " \ "plugins. Plugin implementations are provided for the major operating systems." topics = ( - "opc ua", "open62541", "sdk", "server/client", "c", "iec-62541", + "opc ua", "sdk", "server/client", "c", "iec-62541", "industrial automation", "tsn", "time sensitive networks", "publish-subscirbe", "pubsub" ) + package_type = "library" settings = "os", "compiler", "build_type", "arch" options = { "fPIC": [True, False], @@ -181,7 +182,7 @@ def requirements(self): if self.options.encryption == "mbedtls": self.requires("mbedtls/2.25.0") elif self.options.encryption == "openssl": - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") if self.options.web_socket: self.requires("libwebsockets/4.3.2") if self.options.discovery == "With Multicast" or "multicast" in str(self.options.discovery): @@ -214,9 +215,7 @@ def validate(self): raise ConanInvalidConfiguration( "Lower Open62541 versions than 1.1.0 are not cpp compatible due to -fpermisive flags") - # FIXME: correct clang versions condition - max_clang_version = "8" if Version( - self.version) < "1.1.0" else "9" + max_clang_version = "8" if Version(self.version) < "1.1.0" else "9" if self.settings.compiler == "clang" and Version(self.settings.compiler.version) > max_clang_version: raise ConanInvalidConfiguration( "Open62541 supports Clang up to {} compiler version".format(max_clang_version)) @@ -244,19 +243,13 @@ def source(self): with open(submodule_filename, 'r') as submodule_stream: submodules_data = yaml.safe_load(submodule_stream) for path, submodule in submodules_data["submodules"][self.version].items(): - filename = os.path.basename(submodule["url"]) - archive_name = submodule["archive_pattern"].format( - version=os.path.splitext(filename.replace('v', ''))[0]) - - submodule_data = { - "url": submodule["url"], - "sha256": submodule["sha256"] - } - - get(self, **submodule_data) - submodule_source = os.path.join(self.source_folder, path) - rmdir(self, submodule_source) - rename(self, archive_name, submodule_source) + archive_name = os.path.splitext( + os.path.basename(submodule["url"]))[0] + get(self, url=submodule["url"], + sha256=submodule["sha256"], + destination=path, + filename=archive_name, + strip_root=True) def _get_log_level(self): return { @@ -356,11 +349,11 @@ def generate(self): tc.variables["UA_ENABLE_STATUSCODE_DESCRIPTIONS"] = self.options.readable_statuscodes tc.variables["UA_ENABLE_HARDENING"] = self.options.hardening - if self.settings.compiler == "Visual Studio" and self.options.shared == True: + if self.settings.compiler == "msvc" and self.options.shared == True: tc.variables["UA_MSVC_FORCE_STATIC_CRT"] = True tc.variables["UA_COMPILE_AS_CXX"] = self.options.cpp_compatible - + # Honor BUILD_SHARED_LIBS from conan_toolchain (see https://github.com/conan-io/conan/issues/11840) tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" @@ -371,8 +364,7 @@ def generate(self): def _patch_sources(self): apply_conandata_patches(self) if Version(self.version) >= "1.3.1": - os.unlink(os.path.join(self.source_folder, - "tools", "cmake", "FindPython3.cmake")) + os.unlink(os.path.join(self.source_folder, "tools", "cmake", "FindPython3.cmake")) def build(self): self._patch_sources() @@ -393,8 +385,9 @@ def _module_file_rel_path(self): return os.path.join(self._module_subfolder, "open62541Macros.cmake") def package(self): - self.copy("LICENSE", dst="licenses", src=self.source_folder) - self.copy("LICENSE-CC0", dst="licenses", src=self.source_folder) + licenses_dir = os.path.join(self.package_folder, "licenses") + copy(self, "LICENSE", src=self.source_folder, dst=licenses_dir) + copy(self, "LICENSE-CC0", src=self.source_folder, dst=licenses_dir) cmake = CMake(self) cmake.install() @@ -408,10 +401,9 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "share")) - self.copy("generate_*.py", src=self._tools_subfolder, - dst=os.path.join("res", "tools")) - self.copy("nodeset_compiler/*", src=self._tools_subfolder, - dst=os.path.join("res", "tools")) + tools_dir = os.path.join(self.package_folder, "res", "tools") + copy(self, "generate_*.py", src=self._tools_subfolder, dst=tools_dir) + copy(self, "nodeset_compiler/*", src=self._tools_subfolder, dst=tools_dir) @staticmethod def _chmod_plus_x(filename): @@ -423,10 +415,7 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "open62541" self.cpp_info.names["pkg_config"] = "open62541" self.cpp_info.libs = collect_libs(self) - self.cpp_info.includedirs = [ - "include", - os.path.join("include", "open62541", "plugin") - ] + self.cpp_info.includedirs = ["include"] # required for creating custom servers from ua-nodeset self.conf_info.define("user.open62541:tools_dir", os.path.join( @@ -439,14 +428,19 @@ def package_info(self): if self.options.single_header: self.cpp_info.defines.append("UA_ENABLE_AMALGAMATION") - if self.settings.os == "Windows": - self.cpp_info.system_libs.append("ws2_32") - self.cpp_info.includedirs.append( - os.path.join("include", "open62541", "win32")) else: self.cpp_info.includedirs.append( - os.path.join("include", "open62541", "posix")) - if self.settings.os in ("Linux", "FreeBSD"): + os.path.join("include", "open62541", "plugin")) + if self.settings.os == "Windows": + self.cpp_info.includedirs.append( + os.path.join("include", "open62541", "win32")) + else: + self.cpp_info.includedirs.append( + os.path.join("include", "open62541", "posix")) + + if self.settings.os == "Windows": + self.cpp_info.system_libs.append("ws2_32") + elif self.settings.os in ("Linux", "FreeBSD"): self.cpp_info.system_libs.extend(["pthread", "m", "rt"]) self.cpp_info.builddirs.append(self._module_subfolder) diff --git a/recipes/open62541/all/submoduledata.yml b/recipes/open62541/all/submoduledata.yml index 19278804be7058..5a2a7e3ff90b75 100644 --- a/recipes/open62541/all/submoduledata.yml +++ b/recipes/open62541/all/submoduledata.yml @@ -49,3 +49,8 @@ submodules: sha256: a2bcc1cda0154091ecbed25b8c40436c5b75d11bb38df28b35a2ceedb331d562 url: https://github.com/OPCFoundation/UA-Nodeset/archive/Errata-1.04.5.zip archive_pattern: "UA-Nodeset-{version}" + "1.3.6": + deps/ua-nodeset: + sha256: 032c93e3f7c335bbb2d2d699804a804c9cdce2a2ecc3fe7cde552f2130982c26 + url: https://github.com/OPCFoundation/UA-Nodeset/archive/Glass=1.0.0-2022-01-01.zip + archive_pattern: "UA-Nodeset-{version}" diff --git a/recipes/open62541/all/test_package/conanfile.py b/recipes/open62541/all/test_package/conanfile.py index 52782cf8480cf5..c1fe645c77cc34 100644 --- a/recipes/open62541/all/test_package/conanfile.py +++ b/recipes/open62541/all/test_package/conanfile.py @@ -7,7 +7,7 @@ # It will become the standard on Conan 2.x class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" def requirements(self): @@ -19,8 +19,8 @@ def layout(self): def generate(self): tc = CMakeToolchain(self) - tc.variables["open62541_NODESET_DIR"] = self.deps_user_info["ua-nodeset"].nodeset_dir.replace( - "\\", "/") # ua-nodeset path needs to be sanitized for windows systems + tc.variables["open62541_NODESET_DIR"] = self.dependencies["ua-nodeset"].conf_info.get( + "user.ua-nodeset:nodeset_dir").replace("\\", "/") # sanitize path for windows systems tc.variables["open62541_TOOLS_DIR"] = self.dependencies["open62541"].conf_info.get( "user.open62541:tools_dir") tc.generate() diff --git a/recipes/open62541/config.yml b/recipes/open62541/config.yml index 76c77487001109..a82ee371e80a5d 100644 --- a/recipes/open62541/config.yml +++ b/recipes/open62541/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.6": + folder: all "1.3.4": folder: all "1.3.1": From 90e3ab49607d0f3ddaa9d5e53d87e367c45dbd69 Mon Sep 17 00:00:00 2001 From: qwqbot Date: Fri, 15 Sep 2023 07:29:25 +0800 Subject: [PATCH 0619/1140] (#19472) spdlog: update fmt/10.1.1 --- recipes/spdlog/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/spdlog/all/conanfile.py b/recipes/spdlog/all/conanfile.py index b24d1adfcb1ba7..85bd609950223e 100644 --- a/recipes/spdlog/all/conanfile.py +++ b/recipes/spdlog/all/conanfile.py @@ -57,7 +57,7 @@ def requirements(self): fmt_version = "7.1.3" if self_version >= "1.12.0": - fmt_version = "10.1.0" + fmt_version = "10.1.1" elif self_version >= "1.11.0": fmt_version = "10.0.0" elif self_version >= "1.10.0": From cd2b27a2706b7925a90b7a1aa79621973543cc62 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 02:13:29 +0200 Subject: [PATCH 0620/1140] (#19664) openexr 3.x: use version range for zlib + add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * add package_type * sort methods by order of execution * Update recipes/openexr/3.x/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/openexr/3.x/conanfile.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/openexr/3.x/conanfile.py b/recipes/openexr/3.x/conanfile.py index 34ca44936ccbea..8d58713defa5c3 100644 --- a/recipes/openexr/3.x/conanfile.py +++ b/recipes/openexr/3.x/conanfile.py @@ -16,7 +16,7 @@ class OpenEXRConan(ConanFile): license = "BSD-3-Clause" homepage = "https://github.com/AcademySoftwareFoundation/openexr" url = "https://github.com/conan-io/conan-center-index" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -38,8 +38,11 @@ def configure(self): if self.options.shared: self.options.rm_safe("fPIC") + def layout(self): + cmake_layout(self, src_folder="src") + def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") # Note: OpenEXR and Imath are versioned independently. self.requires("imath/3.1.9", transitive_headers=True) @@ -47,9 +50,6 @@ def validate(self): if self.settings.compiler.cppstd: check_min_cppstd(self, 11) - def layout(self): - cmake_layout(self, src_folder="src") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 20a0a9cc364fee3f5e0a65c2fac103c62f9164ca Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 02:56:56 +0200 Subject: [PATCH 0621/1140] (#19666) openexr 2.x: use version range for zlib MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * Update recipes/openexr/2.x/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/openexr/2.x/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/openexr/2.x/conanfile.py b/recipes/openexr/2.x/conanfile.py index a68e5d8d7ad882..b23f21238a92e9 100644 --- a/recipes/openexr/2.x/conanfile.py +++ b/recipes/openexr/2.x/conanfile.py @@ -38,7 +38,7 @@ def configure(self): self.options.rm_safe("fPIC") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if Version(self.version) < "2.5.0" and hasattr(self, "settings_build") and cross_building(self): From 97f207a298ef1e3272c379ba9801652cba1d8604 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 03:54:28 +0200 Subject: [PATCH 0622/1140] (#19669) minizip: use version range for zlib + add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * add package_type * Update recipes/minizip/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/minizip/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/minizip/all/conanfile.py b/recipes/minizip/all/conanfile.py index e4316426a6e9c0..cec7c823f04293 100644 --- a/recipes/minizip/all/conanfile.py +++ b/recipes/minizip/all/conanfile.py @@ -13,7 +13,7 @@ class MinizipConan(ConanFile): license = "Zlib" description = "An experimental package to read and write files in .zip format, written on top of zlib" topics = ("zip", "compression", "inflate") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -46,7 +46,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13", transitive_headers=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True) if self.options.bzip2: self.requires("bzip2/1.0.8", transitive_headers=True) From 8b1252b00ce99af379e87340bc14d2e57159949f Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 15 Sep 2023 11:28:58 +0900 Subject: [PATCH 0623/1140] (#19760) dirent: add version 1.24 --- recipes/dirent/all/conandata.yml | 3 +++ recipes/dirent/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/dirent/all/conandata.yml b/recipes/dirent/all/conandata.yml index 41d2c31a73c7ac..30637c5892d6d2 100644 --- a/recipes/dirent/all/conandata.yml +++ b/recipes/dirent/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.24": + url: "https://github.com/tronkko/dirent/archive/1.24.tar.gz" + sha256: "37009127a65bb1ddc47d06c097321f87f45ca2e998b2ec3bf2e0b2b19649d6f9" "1.23.2": url: "https://github.com/tronkko/dirent/archive/1.23.2.tar.gz" sha256: "f72d39e3c39610b6901e391b140aa69b51e0eb99216939ed5e547b5dad03afb1" diff --git a/recipes/dirent/config.yml b/recipes/dirent/config.yml index 6086eb1e0524d8..bb0674fda16d81 100644 --- a/recipes/dirent/config.yml +++ b/recipes/dirent/config.yml @@ -1,3 +1,5 @@ versions: + "1.24": + folder: all "1.23.2": folder: all From 220cc0262dd825b684e0f6d893b7f8aac715c4d5 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 15 Sep 2023 04:49:33 +0200 Subject: [PATCH 0624/1140] (#19765) openssl: add version 1.1.1w --- recipes/openssl/1.x.x/conandata.yml | 10 ++++++++++ recipes/openssl/config.yml | 2 ++ 2 files changed, 12 insertions(+) diff --git a/recipes/openssl/1.x.x/conandata.yml b/recipes/openssl/1.x.x/conandata.yml index 14abde79960261..b4e34f1c74cae4 100644 --- a/recipes/openssl/1.x.x/conandata.yml +++ b/recipes/openssl/1.x.x/conandata.yml @@ -27,6 +27,12 @@ sources: - "https://www.openssl.org/source/openssl-1.1.1v.tar.gz" - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1v.tar.gz" - "https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1v/openssl-1.1.1v.tar.gz" + 1.1.1w: + sha256: cf3098950cb4d853ad95c0841f1f9c6d3dc102dccfcacd521d93925208b76ac8 + url: + - "https://www.openssl.org/source/openssl-1.1.1w.tar.gz" + - "https://www.openssl.org/source/old/1.1.1/openssl-1.1.1w.tar.gz" + - "https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1w/openssl-1.1.1w.tar.gz" patches: 1.0.2u: - patch_file: patches/1.0.2u-darwin-arm64.patch @@ -44,3 +50,7 @@ patches: - patch_file: patches/1.1.1-tvos-watchos.patch patch_description: "TVOS and WatchOS don't like fork()" patch_type: "portability" + 1.1.1w: + - patch_file: patches/1.1.1-tvos-watchos.patch + patch_description: "TVOS and WatchOS don't like fork()" + patch_type: "portability" diff --git a/recipes/openssl/config.yml b/recipes/openssl/config.yml index add37f9129c6c1..67834781567eb0 100644 --- a/recipes/openssl/config.yml +++ b/recipes/openssl/config.yml @@ -15,6 +15,8 @@ versions: folder: "3.x.x" # 1.1.1x releases + 1.1.1w: + folder: "1.x.x" 1.1.1v: folder: "1.x.x" 1.1.1u: From 5d576ffd98e5db1a6726656ab82150a7adc7efa4 Mon Sep 17 00:00:00 2001 From: Beartama <8091245+uyha@users.noreply.github.com> Date: Fri, 15 Sep 2023 05:29:52 +0200 Subject: [PATCH 0625/1140] (#19777) sml: add version 1.1.9 --- recipes/sml/all/conandata.yml | 3 +++ recipes/sml/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sml/all/conandata.yml b/recipes/sml/all/conandata.yml index 3c49eae1512502..39d52a814e37cc 100644 --- a/recipes/sml/all/conandata.yml +++ b/recipes/sml/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.9": + url: "https://github.com/boost-ext/sml/archive/refs/tags/v1.1.9.tar.gz" + sha256: "c5ebffcf791ca0b89fd49a410b720432de748a31b7e0c9e5bd5c567d11c8c477" "1.1.8": url: "https://github.com/boost-ext/sml/archive/refs/tags/v1.1.8.tar.gz" sha256: "d2626b2fd249fa0788ca364a2f8dcb4762dd72195f86d43370e4cad4c02262c5" diff --git a/recipes/sml/config.yml b/recipes/sml/config.yml index 5ebc9beff7190c..aff831fd45b0ab 100644 --- a/recipes/sml/config.yml +++ b/recipes/sml/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.9": + folder: all "1.1.8": folder: all "1.1.6": From fcf123c0e0416eacd0edfbb333f4ebcd235fa608 Mon Sep 17 00:00:00 2001 From: Andrei Malashkin Date: Fri, 15 Sep 2023 05:51:06 +0200 Subject: [PATCH 0626/1140] (#19778) add make/4.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add make/4.4 * add missing entry in config.yml --------- Co-authored-by: Rubén Rincón Blanco --- recipes/make/all/conandata.yml | 5 +++++ recipes/make/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/make/all/conandata.yml b/recipes/make/all/conandata.yml index fb6e6264363e76..d11432dff72945 100644 --- a/recipes/make/all/conandata.yml +++ b/recipes/make/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.4": + url: "http://ftpmirror.gnu.org/gnu/make/make-4.4.tar.gz" + sha256: "581f4d4e872da74b3941c874215898a7d35802f03732bdccee1d4a7979105d18" "4.3": url: "http://ftpmirror.gnu.org/gnu/make/make-4.3.tar.gz" sha256: "e05fdde47c5f7ca45cb697e973894ff4f5d79e13b750ed57d7b66d8defc78e19" @@ -6,6 +9,8 @@ sources: url: "http://ftpmirror.gnu.org/gnu/make/make-4.2.1.tar.bz2" sha256: "d6e262bf3601b42d2b1e4ef8310029e1dcf20083c5446b4b7aa67081fdffc589" patches: + "4.4": + - patch_file: "patches/4.3-0001-clang.patch" "4.3": - patch_file: "patches/4.3-0001-clang.patch" "4.2.1": diff --git a/recipes/make/config.yml b/recipes/make/config.yml index 0260fd9e5313f6..34673d1418b178 100644 --- a/recipes/make/config.yml +++ b/recipes/make/config.yml @@ -1,4 +1,6 @@ versions: + "4.4": + folder: all "4.3": folder: all "4.2.1": From f5516efa03caf412c8336f6251a576cbbb5a17c1 Mon Sep 17 00:00:00 2001 From: chausner <15180557+chausner@users.noreply.github.com> Date: Fri, 15 Sep 2023 06:10:49 +0200 Subject: [PATCH 0627/1140] (#19792) Add drwav 0.13.12 Co-authored-by: chausner --- recipes/drwav/all/conandata.yml | 4 ++++ recipes/drwav/config.yml | 2 ++ 2 files changed, 6 insertions(+) diff --git a/recipes/drwav/all/conandata.yml b/recipes/drwav/all/conandata.yml index 449e35d180bee0..cfc31466349bcf 100644 --- a/recipes/drwav/all/conandata.yml +++ b/recipes/drwav/all/conandata.yml @@ -1,4 +1,8 @@ sources: + # NOTE: https://github.com/mackron/dr_libs/blob/d35a3bc5efd02455d98cbe12b94647136f09b42d/dr_wav.h#L3 + "0.13.12": + url: https://github.com/mackron/dr_libs/archive/d35a3bc5efd02455d98cbe12b94647136f09b42d.zip + sha256: "4886462b8ed26f12b8bceccb80f1447075ed5e73240089f2a78e0c32b444b370" # NOTE: https://github.com/mackron/dr_libs/blob/4f6da71ed357ade92dc91f00e6be7301ec9a82a3/dr_wav.h#L3 "0.13.7": url: https://github.com/mackron/dr_libs/archive/4f6da71ed357ade92dc91f00e6be7301ec9a82a3.zip diff --git a/recipes/drwav/config.yml b/recipes/drwav/config.yml index 6c8f065f79d492..b1c16872231f4b 100644 --- a/recipes/drwav/config.yml +++ b/recipes/drwav/config.yml @@ -1,4 +1,6 @@ versions: + "0.13.12": + folder: all "0.13.7": folder: all "0.13.6": From ea3e909c38d644c8c1d74f4d0bcea4014c2af816 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 15 Sep 2023 06:49:36 +0200 Subject: [PATCH 0628/1140] (#19806) libsodium 1.0.19 --- recipes/libsodium/all/conandata.yml | 3 +++ recipes/libsodium/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libsodium/all/conandata.yml b/recipes/libsodium/all/conandata.yml index d0974216f8865e..c399471111c38b 100644 --- a/recipes/libsodium/all/conandata.yml +++ b/recipes/libsodium/all/conandata.yml @@ -1,6 +1,9 @@ # To update the version on CCI, add a new cci.date entry from the stable branch: # https://github.com/jedisct1/libsodium/commits/stable sources: + "1.0.19": + url: "https://github.com/jedisct1/libsodium/releases/download/1.0.19-RELEASE/libsodium-1.0.19.tar.gz" + sha256: "018d79fe0a045cca07331d37bd0cb57b2e838c51bc48fd837a1472e50068bbea" "1.0.18": url: "https://github.com/jedisct1/libsodium/releases/download/1.0.18-RELEASE/libsodium-1.0.18.tar.gz" sha256: "6f504490b342a4f8a4c4a02fc9b866cbef8622d5df4e5452b46be121e46636c1" diff --git a/recipes/libsodium/config.yml b/recipes/libsodium/config.yml index 819e72ce108262..4dfbbb5c3d410c 100644 --- a/recipes/libsodium/config.yml +++ b/recipes/libsodium/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.19": + folder: all "1.0.18": folder: all "cci.20220430": From 115a67a748b7d67f4ef4ef7d54fcfa0d88a7da2a Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 15 Sep 2023 07:29:16 +0200 Subject: [PATCH 0629/1140] (#19819) libwebp: add version 1.3.2 --- recipes/libwebp/all/conandata.yml | 7 +++++++ recipes/libwebp/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/libwebp/all/conandata.yml b/recipes/libwebp/all/conandata.yml index b036ea65e60550..47f77300daa6a3 100644 --- a/recipes/libwebp/all/conandata.yml +++ b/recipes/libwebp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.2": + url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.3.2.tar.gz" + sha256: "2a499607df669e40258e53d0ade8035ba4ec0175244869d1025d460562aa09b4" "1.3.1": url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.3.1.tar.gz" sha256: "b3779627c2dfd31e3d8c4485962c2efe17785ef975e2be5c8c0c9e6cd3c4ef66" @@ -27,6 +30,10 @@ sources: url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.0.3.tar.gz" sha256: "e20a07865c8697bba00aebccc6f54912d6bc333bb4d604e6b07491c1a226b34f" patches: + "1.3.2": + - patch_file: "patches/1.3.1-0001-fix-cmake.patch" + patch_description: "disable PIC, disable prefix library name on MSVC" + patch_type: "conan" "1.3.1": - patch_file: "patches/1.3.1-0001-fix-cmake.patch" patch_description: "disable PIC, disable prefix library name on MSVC" diff --git a/recipes/libwebp/config.yml b/recipes/libwebp/config.yml index 3bf80d4385ecdb..5efe9c8c34aa9f 100644 --- a/recipes/libwebp/config.yml +++ b/recipes/libwebp/config.yml @@ -1,4 +1,6 @@ versions: + "1.3.2": + folder: all "1.3.1": folder: all "1.3.0": From 27d562866a062cc4e4c3d05973780f8d24003d22 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 15 Sep 2023 09:30:34 +0200 Subject: [PATCH 0630/1140] (#19821) libtiff: add version 4.6.0 --- recipes/libtiff/all/conandata.yml | 7 +++++++ recipes/libtiff/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/libtiff/all/conandata.yml b/recipes/libtiff/all/conandata.yml index cc7431489956e4..96a6b01214da43 100644 --- a/recipes/libtiff/all/conandata.yml +++ b/recipes/libtiff/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.6.0": + url: "http://download.osgeo.org/libtiff/tiff-4.6.0.tar.gz" + sha256: "88b3979e6d5c7e32b50d7ec72fb15af724f6ab2cbf7e10880c360a77e4b5d99a" "4.5.1": url: "http://download.osgeo.org/libtiff/tiff-4.5.1.tar.gz" sha256: "d7f38b6788e4a8f5da7940c5ac9424f494d8a79eba53d555f4a507167dca5e2b" @@ -12,6 +15,10 @@ sources: url: "http://download.osgeo.org/libtiff/tiff-4.3.0.tar.gz" sha256: "0e46e5acb087ce7d1ac53cf4f56a09b221537fc86dfc5daaad1c2e89e1b37ac8" patches: + "4.6.0": + - patch_file: "patches/4.5.1-0001-cmake-dependencies.patch" + patch_description: "CMake: robust handling of dependencies" + patch_type: "conan" "4.5.1": - patch_file: "patches/4.5.1-0001-cmake-dependencies.patch" patch_description: "CMake: robust handling of dependencies" diff --git a/recipes/libtiff/config.yml b/recipes/libtiff/config.yml index 961a315dc8eb68..d9523166c18939 100644 --- a/recipes/libtiff/config.yml +++ b/recipes/libtiff/config.yml @@ -1,4 +1,6 @@ versions: + "4.6.0": + folder: all "4.5.1": folder: all "4.5.0": From 24e585d73100d52feeb52203b3ed47701fb5e2ab Mon Sep 17 00:00:00 2001 From: FireWolf <10460478+0xFireWolf@users.noreply.github.com> Date: Fri, 15 Sep 2023 01:09:18 -0700 Subject: [PATCH 0631/1140] (#19826) antlr4-cppruntime: Add version 4.13.1. --- recipes/antlr4-cppruntime/all/conandata.yml | 3 +++ recipes/antlr4-cppruntime/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/antlr4-cppruntime/all/conandata.yml b/recipes/antlr4-cppruntime/all/conandata.yml index 28bc286ec79b58..f6974e320b5592 100644 --- a/recipes/antlr4-cppruntime/all/conandata.yml +++ b/recipes/antlr4-cppruntime/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.13.1": + url: "https://github.com/antlr/antlr4/archive/refs/tags/4.13.1.tar.gz" + sha256: "da20d487524d7f0a8b13f73a8dc326de7fc2e5775f5a49693c0a4e59c6b1410c" "4.13.0": url: "https://github.com/antlr/antlr4/archive/refs/tags/4.13.0.tar.gz" sha256: "b7082b539256e6de5137a7d57afe89493dce234a3ce686dbae709ef6cf2d2c81" diff --git a/recipes/antlr4-cppruntime/config.yml b/recipes/antlr4-cppruntime/config.yml index 62ba72dbb3e3f8..05c77e20051f93 100644 --- a/recipes/antlr4-cppruntime/config.yml +++ b/recipes/antlr4-cppruntime/config.yml @@ -1,4 +1,6 @@ versions: + "4.13.1": + folder: all "4.13.0": folder: all "4.12.0": From 30a9f2eb1e4bf454b408712318b9c13376552a95 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Fri, 15 Sep 2023 19:33:33 +0930 Subject: [PATCH 0632/1140] (#17427) [tk] Migrate tk to conan 2.0 * [tk] Migrate tk to conan 2.0 * Move to modern conan implementation * Transition most file modifications to patches * [tk] Formatting and linting fixes * Apply black * Sort imports * Remove unused imports * Prefer fstrings over format where possible * [tk] Ensure license is exported with package * [tk] Fix typo in runenv vars retrieval * [tk] Fix NMake builds * Fix patch to appropriately remove TCL variables and handle the rules directory * Move build logic into the _build_nmake method rather than generate so that the values can be passed directly to the command line. * Fix windows lib name in package_info * [tk] Add dynamic runtime compatibility * [tk] Conditionally use AutotoolsDeps Only use AutotoolsDeps on linux where there are dependencies not passed directly to the library. This resolves an issue on Macos where configure failed to determine whether it was cross building when the AutotoolsDeps generator was used. * [tk] Invalidate Macos M1 builds * [tk] Modify validate to remove macos crossbuilds rather than M1 builds Co-authored-by: Matthieu Darbois --------- Co-authored-by: Matthieu Darbois --- recipes/tk/all/conandata.yml | 12 + recipes/tk/all/conanfile.py | 327 ++++++++++-------- .../0001-Add-unix-conan-compatibility.patch | 80 +++++ ...0002-Add-windows-conan-compatibility.patch | 145 ++++++++ .../all/patches/0003-Patch-tkConfig.sh.patch | 89 +++++ recipes/tk/all/test_package/CMakeLists.txt | 11 +- recipes/tk/all/test_package/conanfile.py | 21 +- .../all/test_package/{ => src}/test_package.c | 1 + recipes/tk/all/test_v1_package/CMakeLists.txt | 8 + recipes/tk/all/test_v1_package/conanfile.py | 17 + 10 files changed, 551 insertions(+), 160 deletions(-) create mode 100644 recipes/tk/all/patches/0001-Add-unix-conan-compatibility.patch create mode 100644 recipes/tk/all/patches/0002-Add-windows-conan-compatibility.patch create mode 100644 recipes/tk/all/patches/0003-Patch-tkConfig.sh.patch rename recipes/tk/all/test_package/{ => src}/test_package.c (92%) create mode 100644 recipes/tk/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tk/all/test_v1_package/conanfile.py diff --git a/recipes/tk/all/conandata.yml b/recipes/tk/all/conandata.yml index 8cbbcf9134e3cd..7e9e03ca25a75f 100644 --- a/recipes/tk/all/conandata.yml +++ b/recipes/tk/all/conandata.yml @@ -2,3 +2,15 @@ sources: "8.6.10": url: "https://prdownloads.sourceforge.net/tcl/tk8.6.10-src.tar.gz" sha256: "63df418a859d0a463347f95ded5cd88a3dd3aaa1ceecaeee362194bc30f3e386" + +patches: + "8.6.10": + - patch_file: "patches/0001-Add-unix-conan-compatibility.patch" + patch_description: "Add unix conan compatibility" + patch_type: "conan" + - patch_file: "patches/0002-Add-windows-conan-compatibility.patch" + patch_description: "Add windows conan compatibility" + patch_type: "conan" + - patch_file: "patches/0003-Patch-tkConfig.sh.patch" + patch_description: "Remove TK_BUILD_* and TK_SRC_DIR from tkConfig.sh for portability" + patch_type: "portability" diff --git a/recipes/tk/all/conanfile.py b/recipes/tk/all/conanfile.py index 97130833734db4..2c3e88ddc0d5b7 100644 --- a/recipes/tk/all/conanfile.py +++ b/recipes/tk/all/conanfile.py @@ -1,8 +1,26 @@ -from conans import ConanFile, AutoToolsBuildEnvironment, tools -from conans.errors import ConanException, ConanInvalidConfiguration, ConanExceptionInUserConanfileMethod import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanException, ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.build import cross_building +from conan.tools.env import VirtualBuildEnv, VirtualRunEnv +from conan.tools.files import ( + apply_conandata_patches, + chdir, + copy, + export_conandata_patches, + get, + replace_in_file, + rmdir, +) +from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.microsoft import NMakeDeps, NMakeToolchain, is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.55.0" + class TkConan(ConanFile): name = "tk" @@ -12,6 +30,7 @@ class TkConan(ConanFile): license = "TCL" url = "https://github.com/conan-io/conan-center-index" settings = "os", "compiler", "build_type", "arch" + package_type = "library" options = { "shared": [True, False], "fPIC": [True, False], @@ -21,24 +40,23 @@ class TkConan(ConanFile): "fPIC": True, } - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": - del self.options.fPIC + self.options.rm_safe("fPIC") def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") def requirements(self): - self.requires("tcl/{}".format(self.version)) + self.requires( + f"tcl/{self.version}", transitive_headers=True, transitive_libs=True + ) if self.settings.os == "Linux": self.requires("fontconfig/2.13.93") self.requires("xorg/system") @@ -48,66 +66,84 @@ def _settings_build(self): return getattr(self, "settings_build", self.settings) def build_requirements(self): - if self.settings.compiler != "Visual Studio": - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): + if not is_msvc(self): + if ( + self._settings_build.os == "Windows" + and not self.conf.get("tools.microsoft.bash:path") + and not self.conf.get("tools.microsoft.bash:subsystem") + ): self.build_requires("msys2/cci.latest") def validate(self): - if self.options["tcl"].shared != self.options.shared: - raise ConanInvalidConfiguration("The shared option of tcl and tk must have the same value") - - def source(self): - tools.get(**self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) - - def _patch_sources(self): - for build_system in ("unix", "win", ): - config_dir = self._get_configure_folder(build_system) - - if build_system != "win": - # When disabling 64-bit support (in 32-bit), this test must be 0 in order to use "long long" for 64-bit ints - # (${tcl_type_64bit} can be either "__int64" or "long long") - tools.replace_in_file(os.path.join(config_dir, "configure"), - "(sizeof(${tcl_type_64bit})==sizeof(long))", - "(sizeof(${tcl_type_64bit})!=sizeof(long))") - - makefile_in = os.path.join(config_dir, "Makefile.in") - # Avoid clearing CFLAGS and LDFLAGS in the makefile - # tools.replace_in_file(makefile_in, "\nCFLAGS{}".format(" " if (build_system == "win" and name == "tcl") else "\t"), "\n#CFLAGS\t") - tools.replace_in_file(makefile_in, "\nLDFLAGS\t", "\n#LDFLAGS\t") - tools.replace_in_file(makefile_in, "${CFLAGS}", "${CFLAGS} ${CPPFLAGS}") - - rules_ext_vc = os.path.join(self.source_folder, self._source_subfolder, "win", "rules-ext.vc") - tools.replace_in_file(rules_ext_vc, - "\n_RULESDIR = ", - "\n_RULESDIR = .\n#_RULESDIR = ") - rules_vc = os.path.join(self.source_folder, self._source_subfolder, "win", "rules.vc") - tools.replace_in_file(rules_vc, - r"$(_TCLDIR)\generic", - r"$(_TCLDIR)\include") - tools.replace_in_file(rules_vc, - "\nTCLSTUBLIB", - "\n#TCLSTUBLIB") - tools.replace_in_file(rules_vc, - "\nTCLIMPLIB", - "\n#TCLIMPLIB") + if self.dependencies["tcl"].options.shared != self.options.shared: + raise ConanInvalidConfiguration( + "The shared option of tcl and tk must have the same value" + ) + if self.settings.os == "Macos" and cross_building(self): + raise ConanInvalidConfiguration("The tk conan recipe does not currently support Macos cross-builds. A contribution to add this functionality would be welcome.") - win_makefile_in = os.path.join(self._get_configure_folder("win"), "Makefile.in") - tools.replace_in_file(win_makefile_in, "\nTCL_GENERIC_DIR", "\n#TCL_GENERIC_DIR") + def layout(self): + basic_layout(self, src_folder="src") - win_rules_vc = os.path.join(self._source_subfolder, "win", "rules.vc") - tools.replace_in_file(win_rules_vc, - "\ncwarn = $(cwarn) -WX", - "\n# cwarn = $(cwarn) -WX") - # disable whole program optimization to be portable across different MSVC versions. - # See conan-io/conan-center-index#4811 conan-io/conan-center-index#4094 - tools.replace_in_file( - win_rules_vc, - "OPTIMIZATIONS = $(OPTIMIZATIONS) -GL", - "# OPTIMIZATIONS = $(OPTIMIZATIONS) -GL") + def source(self): + get( + self, + **self.conan_data["sources"][self.version], + strip_root=True, + destination=self.source_folder, + ) + + def generate(self): + buildenv = VirtualBuildEnv(self) + buildenv.generate() + + if is_msvc(self): + tc = NMakeToolchain(self) + tc.generate() + + deps = NMakeDeps(self) + deps.generate() + else: + # Inject runenv variables into buildenv + # This is required because tcl needs to be available when configure tries to + # run a test executable + if not cross_building(self): + runenv = VirtualRunEnv(self) + runenv.generate(scope="build") + + yes_no = lambda v: "yes" if v else "no" + tc = AutotoolsToolchain(self) + tc.configure_args.append("--enable-threads") + tc.configure_args.append( + f"--enable-symbols={yes_no(self.settings.build_type == 'Debug')}" + ) + tc.configure_args.append( + f"--enable-64bit={yes_no(self.settings.arch == 'x86_64')}" + ) + tc.configure_args.append(f"--enable-aqua={yes_no(is_apple_os(self))}") + tc.configure_args.append( + f"--with-tcl={os.path.join(self.dependencies['tcl'].package_folder, 'lib')}" + ) + tc.configure_args.append(f"--with-x={yes_no(self.settings.os == 'Linux')}") + tc.make_args.append( + f"TCL_GENERIC_DIR={os.path.join(self.dependencies['tcl'].package_folder, 'include')}" + ) + if self.settings.os == "Windows": + tc.extra_defines.extend( + [ + "UNICODE", + "_UNICODE", + "_ATL_XP_TARGETING", + ] + ) + tc.generate() + + if self.settings.os == "Linux": + deps = AutotoolsDeps(self) + deps.generate() def _get_default_build_system(self): - if tools.is_apple_os(self.settings.os): + if is_apple_os(self): return "macosx" elif self.settings.os in ("Linux", "FreeBSD"): return "unix" @@ -120,8 +156,8 @@ def _get_configure_folder(self, build_system=None): if build_system is None: build_system = self._get_default_build_system() if build_system not in ["win", "unix", "macosx"]: - raise ConanExceptionInUserConanfileMethod("Invalid build system: {}".format(build_system)) - return os.path.join(self.source_folder, self._source_subfolder, build_system) + raise ConanException(f"Invalid build system: {build_system}") + return os.path.join(self.source_folder, build_system) def _build_nmake(self, target="release"): # https://core.tcl.tk/tips/doc/trunk/tip/477.md @@ -130,7 +166,7 @@ def _build_nmake(self, target="release"): opts.append("static") if self.settings.build_type == "Debug": opts.append("symbols") - if "MD" in str(self.settings.compiler.runtime): + if "dynamic" in str(self.settings.compiler.runtime) or "MD" in str(self.settings.compiler.runtime): opts.append("msvcrt") else: opts.append("nomsvcrt") @@ -138,121 +174,116 @@ def _build_nmake(self, target="release"): opts.append("unchecked") # https://core.tcl.tk/tk/tktview?name=3d34589aa0 # https://wiki.tcl-lang.org/page/Building+with+Visual+Studio+2017 - tcl_lib_path = os.path.join(self.deps_cpp_info["tcl"].rootpath, "lib") + tcl_lib_path = os.path.join(self.dependencies["tcl"].package_folder, "lib") tclimplib, tclstublib = None, None for lib in os.listdir(tcl_lib_path): if not lib.endswith(".lib"): continue if lib.startswith("tcl{}".format("".join(self.version.split(".")[:2]))): tclimplib = os.path.join(tcl_lib_path, lib) - elif lib.startswith("tclstub{}".format("".join(self.version.split(".")[:2]))): + elif lib.startswith( + "tclstub{}".format("".join(self.version.split(".")[:2])) + ): tclstublib = os.path.join(tcl_lib_path, lib) if tclimplib is None or tclstublib is None: raise ConanException("tcl dependency misses tcl and/or tclstub library") - with tools.vcvars(self.settings): - tcldir = self.deps_cpp_info["tcl"].rootpath.replace("/", "\\\\") + + flags = { + "INSTALLDIR": self.package_folder, + "OPTS": ",".join(opts), + "TCLDIR": self.dependencies["tcl"].package_folder, + "TCL_LIBRARY": self.dependencies["tcl"].runenv_info.vars(self).get("TCL_LIBRARY"), + "TCLIMPLIB": tclimplib, + "TCLSTUBLIB": tclstublib, + } + config_dir = self._get_configure_folder("win") + with chdir(self, config_dir): self.run( - """nmake -nologo -f "{cfgdir}/makefile.vc" INSTALLDIR="{pkgdir}" OPTS={opts} TCLDIR="{tcldir}" TCL_LIBRARY="{tcl_library}" TCLIMPLIB="{tclimplib}" TCLSTUBLIB="{tclstublib}" {target}""".format( - cfgdir=self._get_configure_folder("win"), - pkgdir=self.package_folder, - opts=",".join(opts), - tcldir=tcldir, - tclstublib=tclstublib, - tclimplib=tclimplib, - tcl_library=self.deps_env_info['tcl'].TCL_LIBRARY.replace("\\", "/"), - target=target, - ), cwd=self._get_configure_folder("win"), + f"""nmake -nologo -f makefile.vc {' '.join([f'{k}="{v}"' for k, v in flags.items()])} {target}""", + env="conanbuild", ) - def _configure_autotools(self): - tcl_root = self.deps_cpp_info["tcl"].rootpath - make_args = ["TCL_GENERIC_DIR={}".format(os.path.join(tcl_root, "include")).replace("\\", "/")] - if self._autotools: - return self._autotools, make_args - - tclConfigShFolder = os.path.join(tcl_root, "lib").replace("\\", "/") - - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) - yes_no = lambda v: "yes" if v else "no" - conf_args = [ - "--with-tcl={}".format(tools.unix_path(tclConfigShFolder)), - "--enable-threads", - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-symbols={}".format(yes_no(self.settings.build_type == "Debug")), - "--enable-64bit={}".format(yes_no(self.settings.arch == "x86_64")), - "--with-x={}".format(yes_no(self.settings.os == "Linux")), - "--enable-aqua={}".format(yes_no(tools.is_apple_os(self.settings.os))), - ] - - if self.settings.os == "Windows": - self._autotools.defines.extend(["UNICODE", "_UNICODE", "_ATL_XP_TARGETING", ]) - self._autotools.libs = [] - self._autotools.configure(configure_dir=self._get_configure_folder(), args=conf_args) - return self._autotools, make_args - def build(self): - self._patch_sources() - - if self.settings.compiler == "Visual Studio": + apply_conandata_patches(self) + if is_msvc(self): self._build_nmake() else: - autotools, make_args = self._configure_autotools() - autotools.make(args=make_args) + autotools = Autotools(self) + autotools.configure(build_script_folder=self._get_configure_folder()) + autotools.make() def package(self): - self.copy(pattern="license.terms", src=self._source_subfolder, dst="licenses") - if self.settings.compiler == "Visual Studio": + copy( + self, + pattern="license.terms", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses"), + ) + if is_msvc(self): self._build_nmake("install") else: - with tools.chdir(self.build_folder): - autotools, make_args = self._configure_autotools() - autotools.install(args=make_args) - autotools.make(target="install-private-headers", args=make_args) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) - tools.rmdir(os.path.join(self.package_folder, "man")) - tools.rmdir(os.path.join(self.package_folder, "share")) + with chdir(self, self.build_folder): + autotools = Autotools(self) + autotools.install() + # DESTDIR is only default initialized for target="install" + autotools.make( + target="install-private-headers", + args=[f"DESTDIR={self.package_folder}"], + ) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "man")) + rmdir(self, os.path.join(self.package_folder, "share")) - # FIXME: move to patch tkConfigShPath = os.path.join(self.package_folder, "lib", "tkConfig.sh") if os.path.exists(tkConfigShPath): - pkg_path = os.path.join(self.package_folder).replace('\\', '/') - tools.replace_in_file(tkConfigShPath, - pkg_path, - "${TK_ROOT}") - tools.replace_in_file(tkConfigShPath, - "\nTK_BUILD_", - "\n#TK_BUILD_") - tools.replace_in_file(tkConfigShPath, - "\nTK_SRC_DIR", - "\n#TK_SRC_DIR") + # This can only be modified after build since the value being replaced is a result + # of variable substitution in tkConfig.sh.in + replace_in_file(self, tkConfigShPath, "//", "${TK_ROOT}/") def package_info(self): - if self.settings.compiler == "Visual Studio": - tk_version = tools.Version(self.version) - lib_infix = "{}{}".format(tk_version.major, tk_version.minor) + tk_version = Version(self.version) + lib_infix = f"{tk_version.major}.{tk_version.minor}" + if is_msvc(self): + lib_infix = f"{tk_version.major}{tk_version.minor}" tk_suffix = "t{}{}{}".format( "" if self.options.shared else "s", "g" if self.settings.build_type == "Debug" else "", - "x" if "MD" in str(self.settings.compiler.runtime) and not self.options.shared else "", + "x" if ("dynamic" in str(self.settings.compiler.runtime) or "MD" in str(self.settings.compiler.runtime)) and not self.options.shared else "", ) else: - tk_version = tools.Version(self.version) - lib_infix = "{}.{}".format(tk_version.major, tk_version.minor) tk_suffix = "" - self.cpp_info.libs = ["tk{}{}".format(lib_infix, tk_suffix), "tkstub{}".format(lib_infix)] + self.cpp_info.libs = [f"tk{lib_infix}{tk_suffix}", f"tkstub{lib_infix}"] if self.settings.os == "Macos": self.cpp_info.frameworks = ["CoreFoundation", "Cocoa", "Carbon", "IOKit"] elif self.settings.os == "Windows": self.cpp_info.system_libs = [ - "netapi32", "kernel32", "user32", "advapi32", "userenv","ws2_32", "gdi32", - "comdlg32", "imm32", "comctl32", "shell32", "uuid", "ole32", "oleaut32" + "netapi32", + "kernel32", + "user32", + "advapi32", + "userenv", + "ws2_32", + "gdi32", + "comdlg32", + "imm32", + "comctl32", + "shell32", + "uuid", + "ole32", + "oleaut32", ] - tk_library = os.path.join(self.package_folder, "lib", "{}{}".format(self.name, ".".join(self.version.split(".")[:2]))).replace("\\", "/") - self.output.info("Setting TK_LIBRARY environment variable: {}".format(tk_library)) + tk_library = os.path.join( + self.package_folder, + "lib", + f"{self.name}{tk_version.major}.{tk_version.minor}", + ).replace("\\", "/") + self.output.info(f"Setting TK_LIBRARY environment variable: {tk_library}") self.env_info.TK_LIBRARY = tk_library + self.runenv_info.define("TK_LIBRARY", tk_library) - tcl_root = self.package_folder.replace("\\", "/") - self.output.info("Setting TCL_ROOT environment variable: {}".format(tcl_root)) - self.env_info.TCL_ROOT = tcl_root + tk_root = self.package_folder.replace("\\", "/") + self.output.info(f"Setting TK_ROOT environment variable: {tk_root}") + self.env_info.TK_ROOT = tk_root + self.runenv_info.define("TK_ROOT", tk_root) diff --git a/recipes/tk/all/patches/0001-Add-unix-conan-compatibility.patch b/recipes/tk/all/patches/0001-Add-unix-conan-compatibility.patch new file mode 100644 index 00000000000000..6fa4dea2761c6f --- /dev/null +++ b/recipes/tk/all/patches/0001-Add-unix-conan-compatibility.patch @@ -0,0 +1,80 @@ +Subject: [PATCH] Add unix conan compatibility + +--- + unix/Makefile.in | 11 +++++------ + unix/configure | 2 +- + 2 files changed, 6 insertions(+), 7 deletions(-) + +diff --git a/unix/Makefile.in b/unix/Makefile.in +index c6f8c25d7..7bc4a22ba 100644 +--- a/unix/Makefile.in ++++ b/unix/Makefile.in +@@ -143,7 +143,6 @@ CFLAGS = @CFLAGS_DEFAULT@ @CFLAGS@ + # Flags to pass to the linker + LDFLAGS_DEBUG = @LDFLAGS_DEBUG@ + LDFLAGS_OPTIMIZE = @LDFLAGS_OPTIMIZE@ +-LDFLAGS = @LDFLAGS_DEFAULT@ @LDFLAGS@ + + # A "-I" switch that can be used when compiling to make all of the + # X11 include files accessible (the configure script will try to +@@ -328,7 +327,7 @@ MAN_FLAGS = @MAN_FLAGS@ + + CC = @CC@ + +-CC_SWITCHES_NO_STUBS = ${CFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \ ++CC_SWITCHES_NO_STUBS = ${CFLAGS} ${CPPFLAGS} ${CFLAGS_WARNING} ${SHLIB_CFLAGS} \ + -I${UNIX_DIR} -I${GENERIC_DIR} -I${BMAP_DIR} -I${TCL_GENERIC_DIR} \ + -I${TCL_PLATFORM_DIR} ${@TK_WINDOWINGSYSTEM@_INCLUDES} ${AC_FLAGS} \ + ${PROTO_FLAGS} ${SECURITY_FLAGS} ${MEM_DEBUG_FLAGS} ${KEYSYM_FLAGS} \ +@@ -338,7 +337,7 @@ CC_SWITCHES = $(CC_SWITCHES_NO_STUBS) @TCL_STUB_FLAGS@ + + APP_CC_SWITCHES = $(CC_SWITCHES_NO_STUBS) @EXTRA_APP_CC_SWITCHES@ + +-DEPEND_SWITCHES = ${CFLAGS} -I${UNIX_DIR} -I${GENERIC_DIR} -I${BMAP_DIR} \ ++DEPEND_SWITCHES = ${CFLAGS} ${CPPFLAGS} -I${UNIX_DIR} -I${GENERIC_DIR} -I${BMAP_DIR} \ + -I${TCL_GENERIC_DIR} -I${TCL_PLATFORM_DIR} ${@TK_WINDOWINGSYSTEM@_INCLUDES} \ + ${AC_FLAGS} ${PROTO_FLAGS} ${SECURITY_FLAGS} ${MEM_DEBUG_FLAGS} \ + ${KEYSYM_FLAGS} @EXTRA_CC_SWITCHES@ +@@ -620,7 +619,7 @@ objs: ${OBJS} + + + ${WISH_EXE}: $(TK_STUB_LIB_FILE) $(WISH_OBJS) $(TK_LIB_FILE) @APP_RSRC_FILE@ +- ${CC} ${CFLAGS} ${LDFLAGS} $(WISH_OBJS) @TK_BUILD_LIB_SPEC@ \ ++ ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} $(WISH_OBJS) @TK_BUILD_LIB_SPEC@ \ + $(WISH_LIBS) $(CC_SEARCH_FLAGS) -o ${WISH_EXE} + + # Resetting the LIB_RUNTIME_DIR below is required so that +@@ -633,7 +632,7 @@ $(TKTEST_EXE): $(TKTEST_OBJS) $(TK_LIB_FILE) + $(MAKE) tktest-real LIB_RUNTIME_DIR="`pwd`:$(TCL_BIN_DIR)" + + tktest-real: ${TK_STUB_LIB_FILE} +- ${CC} ${CFLAGS} ${LDFLAGS} $(TKTEST_OBJS) ${TK_STUB_LIB_FILE} ${TCL_STUB_LIB_SPEC} @TK_BUILD_LIB_SPEC@ \ ++ ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} $(TKTEST_OBJS) ${TK_STUB_LIB_FILE} ${TCL_STUB_LIB_SPEC} @TK_BUILD_LIB_SPEC@ \ + $(WISH_LIBS) $(CC_SEARCH_FLAGS) -o $(TKTEST_EXE) + + # # FIXME: This xttest rule seems to be broken in a number of ways. It should +@@ -641,7 +640,7 @@ tktest-real: ${TK_STUB_LIB_FILE} + # # tktest, and it is not clear where this test.o object file comes from. + # + # xttest: test.o tkTest.o tkSquare.o $(TK_LIB_FILE) ${TK_STUB_LIB_FILE} +-# ${CC} ${CFLAGS} ${LDFLAGS} test.o tkTest.o tkSquare.o \ ++# ${CC} ${CFLAGS} ${CPPFLAGS} ${LDFLAGS} test.o tkTest.o tkSquare.o \ + # @TK_BUILD_LIB_SPEC@ ${TK_STUB_LIB_FILE} ${TCL_STUB_LIB_SPEC} \ + # $(WISH_LIBS) $(LD_SEARCH_FLAGS) -lXt -o xttest + +diff --git a/unix/configure b/unix/configure +index fb0f5a3d9..77256a740 100755 +--- a/unix/configure ++++ b/unix/configure +@@ -7279,7 +7279,7 @@ int + main () + { + switch (0) { +- case 1: case (sizeof(${tcl_type_64bit})==sizeof(long)): ; ++ case 1: case (sizeof(${tcl_type_64bit})!=sizeof(long)): ; + } + ; + return 0; +-- +2.40.0 + diff --git a/recipes/tk/all/patches/0002-Add-windows-conan-compatibility.patch b/recipes/tk/all/patches/0002-Add-windows-conan-compatibility.patch new file mode 100644 index 00000000000000..bd293b31a745e8 --- /dev/null +++ b/recipes/tk/all/patches/0002-Add-windows-conan-compatibility.patch @@ -0,0 +1,145 @@ +Subject: [PATCH] Add windows conan compatibility + +* Disable whole program optimization to be portable across different MSVC + versions. See conan-io/conan-center-index#4811 and + conan-io/conan-center-index#4094. +--- + win/rules-ext.vc | 8 ++++---- + win/rules.vc | 23 +++++++---------------- + 2 files changed, 11 insertions(+), 20 deletions(-) + +diff --git a/win/rules-ext.vc b/win/rules-ext.vc +index 58c70fa26..e7f953b4c 100644 +--- a/win/rules-ext.vc ++++ b/win/rules-ext.vc +@@ -37,7 +37,7 @@ macro to the name of the project makefile. + # First locate the Tcl directory that we are working with. + !ifdef TCLDIR + +-_RULESDIR = $(TCLDIR:/=\) ++_RULESDIR = . + + !else + +@@ -49,7 +49,7 @@ _RULESDIR=$(INSTALLDIR:/=\) + # Locate Tcl sources + !if [echo _RULESDIR = \> nmakehlp.out] \ + || [nmakehlp -L generic\tcl.h >> nmakehlp.out] +-_RULESDIR = ..\..\tcl ++_RULESDIR = . + !else + !include nmakehlp.out + !endif +@@ -61,9 +61,9 @@ _RULESDIR = ..\..\tcl + # Now look for the targets.vc file under the Tcl root. Note we check this + # file and not rules.vc because the latter also exists on older systems. + !if exist("$(_RULESDIR)\lib\nmake\targets.vc") # Building against installed Tcl +-_RULESDIR = $(_RULESDIR)\lib\nmake ++_RULESDIR = . + !elseif exist("$(_RULESDIR)\win\targets.vc") # Building against Tcl sources +-_RULESDIR = $(_RULESDIR)\win ++_RULESDIR = . + !else + # If we have not located Tcl's targets file, most likely we are compiling + # against an older version of Tcl and so must use our own support files. +diff --git a/win/rules.vc b/win/rules.vc +index cf80c9122..fe4a95dc9 100644 +--- a/win/rules.vc ++++ b/win/rules.vc +@@ -262,7 +262,7 @@ TCLINSTALL = 0 # Tk always builds against Tcl source, not an installed Tcl + !endif # TCLDIR == "" + + _TCLDIR = $(TCLDIR:/=\) +-_TCL_H = $(_TCLDIR)\generic\tcl.h ++_TCL_H = $(_TCLDIR)\include\tcl.h + !if !exist("$(_TCL_H)") + !error Could not locate tcl.h. Please set the TCLDIR macro to point to the Tcl *source* directory. + !endif +@@ -283,9 +283,9 @@ _TCLDIR = $(TCLDIR:/=\) + !if exist("$(_TCLDIR)\include\tcl.h") # Case 2(c) with TCLDIR defined + TCLINSTALL = 1 + _TCL_H = $(_TCLDIR)\include\tcl.h +-!elseif exist("$(_TCLDIR)\generic\tcl.h") # Case 2(d) with TCLDIR defined ++!elseif exist("$(_TCLDIR)\include\tcl.h") # Case 2(d) with TCLDIR defined + TCLINSTALL = 0 +-_TCL_H = $(_TCLDIR)\generic\tcl.h ++_TCL_H = $(_TCLDIR)\include\tcl.h + !endif + + !else # # Case 2(c) for extensions with TCLDIR undefined +@@ -311,7 +311,7 @@ _TCL_H = $(_TCLDIR)\include\tcl.h + !include nmakehlp.out + TCLINSTALL = 0 + TCLDIR = $(_TCLDIR) +-_TCL_H = $(_TCLDIR)\generic\tcl.h ++_TCL_H = $(_TCLDIR)\include\tcl.h + + !endif # exist(...) && ! $(NEED_TCL_SOURCE) + +@@ -619,7 +619,7 @@ OPTIMIZATIONS = $(OPTIMIZATIONS) -GS + # generated libraries only usable by the specific VC++ version that + # created it. Requires /LTCG linker option + !if [nmakehlp -c -GL] +-OPTIMIZATIONS = $(OPTIMIZATIONS) -GL ++ + CC_GL_OPT_ENABLED = 1 + !else + # In newer compilers -GL and -YX are incompatible. +@@ -1085,12 +1085,9 @@ STUBPREFIX = $(PROJECT)stub + + TCLSHNAME = $(PROJECT)sh$(VERSION)$(SUFX).exe + TCLSH = $(OUT_DIR)\$(TCLSHNAME) +-TCLIMPLIB = $(OUT_DIR)\$(PROJECT)$(VERSION)$(SUFX).lib + TCLLIBNAME = $(PROJECT)$(VERSION)$(SUFX).$(EXT) + TCLLIB = $(OUT_DIR)\$(TCLLIBNAME) + +-TCLSTUBLIBNAME = $(STUBPREFIX)$(VERSION).lib +-TCLSTUBLIB = $(OUT_DIR)\$(TCLSTUBLIBNAME) + TCL_INCLUDES = -I"$(WIN_DIR)" -I"$(GENERICDIR)" + + !else # ! $(DOING_TCL) +@@ -1105,12 +1102,9 @@ TCLSH = $(_TCLDIR)\bin\tclsh$(TCL_VERSION)$(SUFX:t=).exe + TCLSH = $(_TCLDIR)\bin\tclsh$(TCL_VERSION)t$(SUFX:t=).exe + !endif + +-TCLSTUBLIB = $(_TCLDIR)\lib\tclstub$(TCL_VERSION).lib +-TCLIMPLIB = $(_TCLDIR)\lib\tcl$(TCL_VERSION)$(SUFX:t=).lib + # When building extensions, may be linking against Tcl that does not add + # "t" suffix (e.g. 8.5 or 8.7). If lib not found check for that possibility. + !if !exist("$(TCLIMPLIB)") +-TCLIMPLIB = $(_TCLDIR)\lib\tcl$(TCL_VERSION)t$(SUFX:t=).lib + !endif + TCL_LIBRARY = $(_TCLDIR)\lib + TCLREGLIB = $(_TCLDIR)\lib\tclreg13$(SUFX:t=).lib +@@ -1124,18 +1118,15 @@ TCLSH = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)$(SUFX:t=).exe + !if !exist($(TCLSH)) + TCLSH = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclsh$(TCL_VERSION)t$(SUFX:t=).exe + !endif +-TCLSTUBLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclstub$(TCL_VERSION).lib +-TCLIMPLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)$(SUFX:t=).lib + # When building extensions, may be linking against Tcl that does not add + # "t" suffix (e.g. 8.5 or 8.7). If lib not found check for that possibility. + !if !exist("$(TCLIMPLIB)") +-TCLIMPLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tcl$(TCL_VERSION)t$(SUFX:t=).lib + !endif + TCL_LIBRARY = $(_TCLDIR)\library + TCLREGLIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tclreg13$(SUFX:t=).lib + TCLDDELIB = $(_TCLDIR)\win\$(BUILDDIRTOP)\tcldde14$(SUFX:t=).lib + TCLTOOLSDIR = $(_TCLDIR)\tools +-TCL_INCLUDES = -I"$(_TCLDIR)\generic" -I"$(_TCLDIR)\win" ++TCL_INCLUDES = -I"$(_TCLDIR)\include" -I"$(_TCLDIR)\win" + + !endif # TCLINSTALL + +@@ -1393,7 +1384,7 @@ carch = + + !if $(DEBUG) + # Turn warnings into errors +-cwarn = $(cwarn) -WX ++ + !endif + + INCLUDES = $(TCL_INCLUDES) $(TK_INCLUDES) $(PRJ_INCLUDES) +-- +2.40.0 + diff --git a/recipes/tk/all/patches/0003-Patch-tkConfig.sh.patch b/recipes/tk/all/patches/0003-Patch-tkConfig.sh.patch new file mode 100644 index 00000000000000..ecabe8916794b5 --- /dev/null +++ b/recipes/tk/all/patches/0003-Patch-tkConfig.sh.patch @@ -0,0 +1,89 @@ +Subject: [PATCH] Patch tkConfig.sh to remove TK_BUILD_ directories and + TK_SRC_DIR + +--- + unix/tkConfig.sh.in | 8 ++++---- + win/tkConfig.sh.in | 8 ++++---- + 2 files changed, 8 insertions(+), 8 deletions(-) + +diff --git a/unix/tkConfig.sh.in b/unix/tkConfig.sh.in +index bb85ad0a2..e564ec1f9 100644 +--- a/unix/tkConfig.sh.in ++++ b/unix/tkConfig.sh.in +@@ -53,7 +53,7 @@ TK_LIB_FLAG='@TK_LIB_FLAG@' + + # String to pass to linker to pick up the Tk library from its + # build directory. +-TK_BUILD_LIB_SPEC='@TK_BUILD_LIB_SPEC@' ++#TK_BUILD_LIB_SPEC='@TK_BUILD_LIB_SPEC@' + + # String to pass to linker to pick up the Tk library from its + # installed directory. +@@ -69,7 +69,7 @@ TK_INCLUDE_SPEC='@TK_INCLUDE_SPEC@' + # different place than the directory containing the source files, this + # points to the location of the sources, not the location where Tk was + # compiled. +-TK_SRC_DIR='@TK_SRC_DIR@' ++#TK_SRC_DIR='@TK_SRC_DIR@' + + # Needed if you want to make a 'fat' shared library library + # containing tk objects or link a different wish. +@@ -84,14 +84,14 @@ TK_STUB_LIB_FLAG='@TK_STUB_LIB_FLAG@' + + # String to pass to linker to pick up the Tk stub library from its + # build directory. +-TK_BUILD_STUB_LIB_SPEC='@TK_BUILD_STUB_LIB_SPEC@' ++#TK_BUILD_STUB_LIB_SPEC='@TK_BUILD_STUB_LIB_SPEC@' + + # String to pass to linker to pick up the Tk stub library from its + # installed directory. + TK_STUB_LIB_SPEC='@TK_STUB_LIB_SPEC@' + + # Path to the Tk stub library in the build directory. +-TK_BUILD_STUB_LIB_PATH='@TK_BUILD_STUB_LIB_PATH@' ++#TK_BUILD_STUB_LIB_PATH='@TK_BUILD_STUB_LIB_PATH@' + + # Path to the Tk stub library in the install directory. + TK_STUB_LIB_PATH='@TK_STUB_LIB_PATH@' +diff --git a/win/tkConfig.sh.in b/win/tkConfig.sh.in +index c511312f0..d5330b829 100644 +--- a/win/tkConfig.sh.in ++++ b/win/tkConfig.sh.in +@@ -47,7 +47,7 @@ TK_LIB_FLAG='@TK_LIB_FLAG@' + + # String to pass to linker to pick up the Tk library from its + # build directory. +-TK_BUILD_LIB_SPEC='@TK_BUILD_LIB_SPEC@' ++#TK_BUILD_LIB_SPEC='@TK_BUILD_LIB_SPEC@' + + # String to pass to linker to pick up the Tk library from its + # installed directory. +@@ -59,7 +59,7 @@ TK_LIB_SPEC='@TK_LIB_SPEC@' + # different place than the directory containing the source files, this + # points to the location of the sources, not the location where Tk was + # compiled. +-TK_SRC_DIR='@TK_SRC_DIR@' ++#TK_SRC_DIR='@TK_SRC_DIR@' + + # Needed if you want to make a 'fat' shared library library + # containing tk objects or link a different wish. +@@ -74,14 +74,14 @@ TK_STUB_LIB_FLAG='@TK_STUB_LIB_FLAG@' + + # String to pass to linker to pick up the Tk stub library from its + # build directory. +-TK_BUILD_STUB_LIB_SPEC='@TK_BUILD_STUB_LIB_SPEC@' ++#TK_BUILD_STUB_LIB_SPEC='@TK_BUILD_STUB_LIB_SPEC@' + + # String to pass to linker to pick up the Tk stub library from its + # installed directory. + TK_STUB_LIB_SPEC='@TK_STUB_LIB_SPEC@' + + # Path to the Tk stub library in the build directory. +-TK_BUILD_STUB_LIB_PATH='@TK_BUILD_STUB_LIB_PATH@' ++#TK_BUILD_STUB_LIB_PATH='@TK_BUILD_STUB_LIB_PATH@' + + # Path to the Tk stub library in the install directory. + TK_STUB_LIB_PATH='@TK_STUB_LIB_PATH@' +-- +2.40.0 + diff --git a/recipes/tk/all/test_package/CMakeLists.txt b/recipes/tk/all/test_package/CMakeLists.txt index 7672a2d37cdd95..5cec06aa08035b 100644 --- a/recipes/tk/all/test_package/CMakeLists.txt +++ b/recipes/tk/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(PackageTest C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup() +find_package(tk CONFIG REQUIRED) -add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +add_executable(example src/test_package.c) +target_link_libraries(example tk::tk) diff --git a/recipes/tk/all/test_package/conanfile.py b/recipes/tk/all/test_package/conanfile.py index a7a94271504b6b..91a8fc7a09b42a 100644 --- a/recipes/tk/all/test_package/conanfile.py +++ b/recipes/tk/all/test_package/conanfile.py @@ -1,17 +1,26 @@ -from conans import ConanFile, CMake, tools import os +from conan import ConanFile +from conan.tools.cmake import CMake, cmake_layout +from conan.tools.build import can_run -class TclTestConan(ConanFile): + +class fooTestConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + generators = "CMakeDeps", "CMakeToolchain" + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) cmake.configure() cmake.build() + def layout(self): + cmake_layout(self) + def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + cmd = os.path.join(self.cpp.build.bindir, "example") + self.run(cmd, env="conanrun") diff --git a/recipes/tk/all/test_package/test_package.c b/recipes/tk/all/test_package/src/test_package.c similarity index 92% rename from recipes/tk/all/test_package/test_package.c rename to recipes/tk/all/test_package/src/test_package.c index 601b2c8c2b4fc5..9a62551dccab6f 100644 --- a/recipes/tk/all/test_package/test_package.c +++ b/recipes/tk/all/test_package/src/test_package.c @@ -19,5 +19,6 @@ int main (int argc ,char *argv[]) { } Tcl_Finalize(); + fprintf(stderr, "Test package success.\n"); return EXIT_SUCCESS; } diff --git a/recipes/tk/all/test_v1_package/CMakeLists.txt b/recipes/tk/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..0fe0f8ae90d2ea --- /dev/null +++ b/recipes/tk/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") +conan_basic_setup() + +add_executable(${PROJECT_NAME} ../test_package/src/test_package.c) +target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) diff --git a/recipes/tk/all/test_v1_package/conanfile.py b/recipes/tk/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a7a94271504b6b --- /dev/null +++ b/recipes/tk/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TclTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From e1714d77f166e217ac1a4ca8ac1050a0dd1261c0 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 15:09:31 +0200 Subject: [PATCH 0633/1140] (#19824) spectra: add package_type --- recipes/spectra/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/spectra/all/conanfile.py b/recipes/spectra/all/conanfile.py index 084f85d8c49505..7f108912c8a5cf 100644 --- a/recipes/spectra/all/conanfile.py +++ b/recipes/spectra/all/conanfile.py @@ -15,6 +15,7 @@ class SpectraConan(ConanFile): topics = ("eigenvalue", "header-only") homepage = "https://spectralib.org" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -33,8 +34,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From 8b8c8d5a39610f33ba5215e1167d164528eb4c5f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 15:27:53 +0200 Subject: [PATCH 0634/1140] (#19825) taocpp-taopq: add package_type + fix traits of dependencies * add package_type * fix traits of libpq * bump libpq * Apply suggestions from code review --- recipes/taocpp-taopq/all/conanfile.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/taocpp-taopq/all/conanfile.py b/recipes/taocpp-taopq/all/conanfile.py index 4cf5de4b292312..7ea861e1070eaf 100644 --- a/recipes/taocpp-taopq/all/conanfile.py +++ b/recipes/taocpp-taopq/all/conanfile.py @@ -16,7 +16,7 @@ class TaoCPPTaopqConan(ConanFile): homepage = "https://github.com/taocpp/taopq" description = "C++ client library for PostgreSQL" topics = ("cpp17", "postgresql", "libpq", "data-base", "sql") - + package_type = "library" settings = "os", "arch", "build_type", "compiler" options = { "shared": [True, False], @@ -53,7 +53,8 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libpq/14.5") + # libpq-fe.h is included by many public headers of taocpp-taopq, and also uses some symbols of the lib (see https://github.com/conan-io/conan-center-index/pull/19825#issuecomment-1720996359) + self.requires("libpq/15.4", transitive_headers=True, transitive_libs=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): From a393a65c58bcec7318265e6fbf9a2ce84dd85c37 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 16:18:11 +0200 Subject: [PATCH 0635/1140] (#19828) tscns: add package_type * add package_type * simplify test_v1_package * format imports --- recipes/tscns/all/conanfile.py | 10 ++++++---- recipes/tscns/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 10 insertions(+), 11 deletions(-) diff --git a/recipes/tscns/all/conanfile.py b/recipes/tscns/all/conanfile.py index f9a1b573dbe33f..c1b715cc277477 100644 --- a/recipes/tscns/all/conanfile.py +++ b/recipes/tscns/all/conanfile.py @@ -1,13 +1,14 @@ +import os + from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy from conan.tools.build import check_min_cppstd +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.layout import basic_layout -import os - required_conan_version = ">=1.52.0" + class TscnsConan(ConanFile): name = "tscns" description = "A low overhead nanosecond clock based on x86 TSC" @@ -15,6 +16,7 @@ class TscnsConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/MengRao/tscns/" topics = ("timestamp", "x86_64", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" @property @@ -37,7 +39,7 @@ def validate(self): check_min_cppstd(self, self._min_cppstd) def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): apply_conandata_patches(self) diff --git a/recipes/tscns/all/test_v1_package/CMakeLists.txt b/recipes/tscns/all/test_v1_package/CMakeLists.txt index eebfbab4ba7b5f..0d20897301b68b 100644 --- a/recipes/tscns/all/test_v1_package/CMakeLists.txt +++ b/recipes/tscns/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(tscns REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE tscns::tscns) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From be4645021bd7d50b19d1c853984a73e4c2ecd7f5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 16:52:07 +0200 Subject: [PATCH 0636/1140] (#19829) tsl-array-hash: add package_type * add package_type * cleanup --- recipes/tsl-array-hash/all/conanfile.py | 6 ++---- .../tsl-array-hash/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/recipes/tsl-array-hash/all/conanfile.py b/recipes/tsl-array-hash/all/conanfile.py index 8c6297fe626729..4e37fe94c16996 100644 --- a/recipes/tsl-array-hash/all/conanfile.py +++ b/recipes/tsl-array-hash/all/conanfile.py @@ -14,6 +14,7 @@ class TslArrayHashConan(ConanFile): topics = ("string", "structure", "hash map", "hash set") homepage = "https://github.com/Tessil/array-hash" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -28,8 +29,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -43,7 +43,6 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "tsl::array_hash") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tsl-array-hash" @@ -55,4 +54,3 @@ def package_info(self): self.cpp_info.components["array_hash"].set_property("cmake_target_name", "tsl::array_hash") self.cpp_info.components["array_hash"].bindirs = [] self.cpp_info.components["array_hash"].libdirs = [] - self.cpp_info.components["array_hash"].resdirs = [] diff --git a/recipes/tsl-array-hash/all/test_v1_package/CMakeLists.txt b/recipes/tsl-array-hash/all/test_v1_package/CMakeLists.txt index 15d716d7a95051..0d20897301b68b 100644 --- a/recipes/tsl-array-hash/all/test_v1_package/CMakeLists.txt +++ b/recipes/tsl-array-hash/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(tsl-array-hash REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE tsl::array_hash) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From f2b8ca0fe191cd5e0a07ef8d7b7b96eef0aaf078 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 17:10:50 +0200 Subject: [PATCH 0637/1140] (#19830) tsl-hat-trie: add package_type * add package_type & fix traits * Update recipes/tsl-hat-trie/all/conanfile.py --- recipes/tsl-hat-trie/all/conanfile.py | 7 ++----- .../tsl-hat-trie/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/recipes/tsl-hat-trie/all/conanfile.py b/recipes/tsl-hat-trie/all/conanfile.py index fbce5d32f1f2b5..0c2749d1da56d7 100644 --- a/recipes/tsl-hat-trie/all/conanfile.py +++ b/recipes/tsl-hat-trie/all/conanfile.py @@ -14,7 +14,7 @@ class TslHatTrieConan(ConanFile): topics = ("string", "trie", "structure", "hash map", "hash set") homepage = "https://github.com/Tessil/hat-trie" url = "https://github.com/conan-io/conan-center-index" - + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" def layout(self): @@ -31,8 +31,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): rmdir(self, os.path.join(self.source_folder, "include", "tsl", "array-hash")) @@ -48,7 +47,6 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "tsl::hat_trie") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tsl-hat-trie" @@ -61,4 +59,3 @@ def package_info(self): self.cpp_info.components["hat_trie"].set_property("cmake_target_name", "tsl::hat_trie") self.cpp_info.components["hat_trie"].bindirs = [] self.cpp_info.components["hat_trie"].libdirs = [] - self.cpp_info.components["hat_trie"].resdirs = [] diff --git a/recipes/tsl-hat-trie/all/test_v1_package/CMakeLists.txt b/recipes/tsl-hat-trie/all/test_v1_package/CMakeLists.txt index 6a1b5a8c7df69f..0d20897301b68b 100644 --- a/recipes/tsl-hat-trie/all/test_v1_package/CMakeLists.txt +++ b/recipes/tsl-hat-trie/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(tsl-hat-trie REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE tsl::hat_trie) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From ba7b4f90e45e0dc4747f28a1211111e5f48d8698 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 17:30:18 +0200 Subject: [PATCH 0638/1140] (#19831) tsl-ordered-map: add package_type --- recipes/tsl-ordered-map/all/conanfile.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/recipes/tsl-ordered-map/all/conanfile.py b/recipes/tsl-ordered-map/all/conanfile.py index d13b78edda1474..9883b71a12ac38 100644 --- a/recipes/tsl-ordered-map/all/conanfile.py +++ b/recipes/tsl-ordered-map/all/conanfile.py @@ -14,6 +14,7 @@ class TslOrderedMapConan(ConanFile): topics = ("ordered-map", "structure", "hash map", "hash set") homepage = "https://github.com/Tessil/ordered-map" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -28,8 +29,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -43,7 +43,6 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "tsl::ordered_map") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tsl-ordered-map" @@ -55,4 +54,3 @@ def package_info(self): self.cpp_info.components["ordered_map"].set_property("cmake_target_name", "tsl::ordered_map") self.cpp_info.components["ordered_map"].bindirs = [] self.cpp_info.components["ordered_map"].libdirs = [] - self.cpp_info.components["ordered_map"].resdirs = [] From 53f1515d319a20eebaf7a9baa487f1adeeb19044 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 18:03:43 +0200 Subject: [PATCH 0639/1140] (#19835) tsl-robin-map: add package_type --- recipes/tsl-robin-map/all/conanfile.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/recipes/tsl-robin-map/all/conanfile.py b/recipes/tsl-robin-map/all/conanfile.py index 60cfac70c1a0d9..14ac380eaf6917 100644 --- a/recipes/tsl-robin-map/all/conanfile.py +++ b/recipes/tsl-robin-map/all/conanfile.py @@ -14,6 +14,7 @@ class TslRobinMapConan(ConanFile): topics = ("robin-map", "structure", "hash map", "hash set") homepage = "https://github.com/Tessil/robin-map" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -28,8 +29,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -43,7 +43,6 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "tsl::robin_map") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tsl-robin-map" @@ -55,4 +54,3 @@ def package_info(self): self.cpp_info.components["robin_map"].set_property("cmake_target_name", "tsl::robin_map") self.cpp_info.components["robin_map"].bindirs = [] self.cpp_info.components["robin_map"].libdirs = [] - self.cpp_info.components["robin_map"].resdirs = [] From 582901326991e324ad3d5020437a493c347ca0f0 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 19:21:37 +0200 Subject: [PATCH 0640/1140] (#19502) gettext: less verbose `package_info()` + add a layout + fix win_bash logic when `tools.microsoft.bash:path` is set * less verbose package_info() * add a layout * fix win_bash logic when tools.microsoft.bash:path is set --- recipes/gettext/all/conanfile.py | 38 +++++++++++++++----------------- 1 file changed, 18 insertions(+), 20 deletions(-) diff --git a/recipes/gettext/all/conanfile.py b/recipes/gettext/all/conanfile.py index 72a7afc2b30cc1..433bf975c10870 100644 --- a/recipes/gettext/all/conanfile.py +++ b/recipes/gettext/all/conanfile.py @@ -5,6 +5,7 @@ from conan.tools.env import Environment, VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir from conan.tools.gnu import AutotoolsToolchain, Autotools +from conan.tools.layout import basic_layout from conan.tools.microsoft import check_min_vs, is_msvc, unix_path, unix_path_package_info_legacy from conan.tools.scm import Version @@ -31,26 +32,29 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def layout(self): + basic_layout(self, src_folder="src") + def requirements(self): self.requires("libiconv/1.17") - def build_requirements(self): - if self._settings_build.os == "Windows" and not self.conf.get("tools.microsoft.bash:path", check_type=str): - self.win_bash = True - self.tool_requires("msys2/cci.latest") - if is_msvc(self): - self.build_requires("automake/1.16.5") + def package_id(self): + del self.info.settings.compiler def validate(self): if Version(self.version) < "0.21" and is_msvc(self): raise ConanInvalidConfiguration("MSVC builds of gettext for versions < 0.21 are not supported.") # FIXME: it used to be possible. What changed? - def package_id(self): - del self.info.settings.compiler + def build_requirements(self): + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") + if is_msvc(self): + self.build_requires("automake/1.16.5") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): env = VirtualBuildEnv(self) @@ -118,9 +122,9 @@ def build(self): def package(self): autotools = Autotools(self) autotools.install() - + copy(self, pattern="COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) - + rmdir(self, os.path.join(self.package_folder, "lib")) rmdir(self, os.path.join(self.package_folder, "include")) rmdir(self, os.path.join(self.package_folder, "share", "doc")) @@ -135,14 +139,8 @@ def package_info(self): autopoint = os.path.join(self.package_folder, "bin", "autopoint") self.buildenv_info.append_path("ACLOCAL_PATH", aclocal) self.buildenv_info.define_path("AUTOPOINT", autopoint) - - # TODO: the following can be removed when the recipe supports Conan >= 2.0 only - bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bindir)) - self.env_info.PATH.append(bindir) - self.output.info("Appending AUTOMAKE_CONAN_INCLUDES environment variable: {}".format(aclocal)) + # TODO: the following can be removed when the recipe supports Conan >= 2.0 only + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) self.env_info.AUTOMAKE_CONAN_INCLUDES.append(unix_path_package_info_legacy(self, aclocal)) - - self.output.info("Setting AUTOPOINT environment variable: {}".format(autopoint)) self.env_info.AUTOPOINT = unix_path_package_info_legacy(self, autopoint) From f982651f23c296c391b367bd829f801a03174725 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 16 Sep 2023 03:09:25 +0900 Subject: [PATCH 0641/1140] (#19836) wasmtime: add version 12.0.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * wasmtime: add version 12.0.2 * Update recipes/wasmtime/config.yml --------- Co-authored-by: Rubén Rincón Blanco --- recipes/wasmtime/all/conandata.yml | 30 ++++++++++++++++++++++++++++++ recipes/wasmtime/config.yml | 2 ++ 2 files changed, 32 insertions(+) diff --git a/recipes/wasmtime/all/conandata.yml b/recipes/wasmtime/all/conandata.yml index 59e975128a2ee3..c449ffc3965a66 100644 --- a/recipes/wasmtime/all/conandata.yml +++ b/recipes/wasmtime/all/conandata.yml @@ -1,4 +1,34 @@ sources: + "12.0.2": + Windows: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-x86_64-windows-c-api.zip" + sha256: "ad589d69722f0fdf0b6900fe1c708194575c487776504c44a5283c2960c03a92" + MinGW: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-x86_64-mingw-c-api.zip" + sha256: "773737d9072aed6efdbb6c8137561bd3d5e271008e6741687fa504ec384d0799" + Linux: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-x86_64-linux-c-api.tar.xz" + sha256: "9e02cd4201d74c68a236664f883873335c7427e820ce4a44c47c1cc98ec9e553" + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-aarch64-linux-c-api.tar.xz" + sha256: "daf6ca147b288cf915978f064853f403ca163b52806ae0a52ddd5bd91a5a2507" + "s390x": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-s390x-linux-c-api.tar.xz" + sha256: "65e75ffe34ced6710b56da071e9eb734eabdad69be07f3e6baae27e6b1a95d41" + Macos: + "x86_64": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-x86_64-macos-c-api.tar.xz" + sha256: "35a0d3590afb147f9b312820df87189a9a376cc5bddc2d90b8d7e57b412c7dc6" + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-aarch64-macos-c-api.tar.xz" + sha256: "6b8a13fbe6c5440b30632a1f9178df1cdc07bbf34633a105666e506bc8db941d" + Android: + "armv8": + url: "https://github.com/bytecodealliance/wasmtime/releases/download/v12.0.2/wasmtime-v12.0.2-aarch64-linux-c-api.tar.xz" + sha256: "daf6ca147b288cf915978f064853f403ca163b52806ae0a52ddd5bd91a5a2507" "12.0.1": Windows: "x86_64": diff --git a/recipes/wasmtime/config.yml b/recipes/wasmtime/config.yml index de77d1db49a4f3..e5ce53b819caaf 100644 --- a/recipes/wasmtime/config.yml +++ b/recipes/wasmtime/config.yml @@ -1,4 +1,6 @@ versions: + "12.0.2": + folder: all "12.0.1": folder: all "9.0.1": From 1d7d94e2d4f825f4ca27d41059e57829c2afc52f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 21:00:33 +0200 Subject: [PATCH 0642/1140] (#19838) tsl-sparse-map: add package_type * add package_type * simplify test_v1_package --- recipes/tsl-sparse-map/all/conanfile.py | 6 ++---- .../tsl-sparse-map/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 6 insertions(+), 11 deletions(-) diff --git a/recipes/tsl-sparse-map/all/conanfile.py b/recipes/tsl-sparse-map/all/conanfile.py index 4168882cba1a35..9afa37e182a6bf 100644 --- a/recipes/tsl-sparse-map/all/conanfile.py +++ b/recipes/tsl-sparse-map/all/conanfile.py @@ -14,6 +14,7 @@ class TslSparseMapConan(ConanFile): topics = ("sparse-map", "structure", "hash map", "hash set") homepage = "https://github.com/Tessil/sparse-map" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -28,8 +29,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -43,7 +43,6 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "tsl::sparse_map") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 once cmake_find_package* generators removed self.cpp_info.filenames["cmake_find_package"] = "tsl-sparse-map" @@ -55,4 +54,3 @@ def package_info(self): self.cpp_info.components["sparse_map"].set_property("cmake_target_name", "tsl::sparse_map") self.cpp_info.components["sparse_map"].bindirs = [] self.cpp_info.components["sparse_map"].libdirs = [] - self.cpp_info.components["sparse_map"].resdirs = [] diff --git a/recipes/tsl-sparse-map/all/test_v1_package/CMakeLists.txt b/recipes/tsl-sparse-map/all/test_v1_package/CMakeLists.txt index 3e681dedd0cd45..0d20897301b68b 100644 --- a/recipes/tsl-sparse-map/all/test_v1_package/CMakeLists.txt +++ b/recipes/tsl-sparse-map/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(tsl-sparse-map REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE tsl::sparse_map) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 9b64f858db8532669138eb02ae3d836a64aefed6 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 21:33:34 +0200 Subject: [PATCH 0643/1140] (#19839) tuplet: add package_type --- recipes/tuplet/all/conanfile.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/tuplet/all/conanfile.py b/recipes/tuplet/all/conanfile.py index e4ef08ece551c8..b8e4521ac33191 100644 --- a/recipes/tuplet/all/conanfile.py +++ b/recipes/tuplet/all/conanfile.py @@ -16,6 +16,7 @@ class TupletConan(ConanFile): homepage = "https://github.com/codeinred/tuplet" description = "A fast, simple tuple implementation that implements tuple as an aggregate" topics = ("tuple", "trivially-copyable", "modern-cpp") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -41,6 +42,9 @@ def _compilers_minimum_version(self): "apple-clang": "12" } + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() @@ -62,12 +66,8 @@ def loose_lt_semver(v1, v2): raise ConanInvalidConfiguration( f"{self.ref} requires C++{self._min_cppstd} which your compiler ({compiler}-{version}) does not support") - def layout(self): - basic_layout(self, src_folder="src") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From 8649f63e9e67df2a210f170ac1b4ab0267dc775c Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 22:15:20 +0200 Subject: [PATCH 0644/1140] (#19840) uncrustify: add package_type --- recipes/uncrustify/all/conanfile.py | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/recipes/uncrustify/all/conanfile.py b/recipes/uncrustify/all/conanfile.py index da8a4d29e3f0e3..0c905f0cb5c350 100644 --- a/recipes/uncrustify/all/conanfile.py +++ b/recipes/uncrustify/all/conanfile.py @@ -16,6 +16,7 @@ class UncrustifyConan(ConanFile): topics = "beautifier", "command-line" homepage = "https://github.com/uncrustify/uncrustify" url = "https://github.com/conan-io/conan-center-index" + package_type = "application" settings = "os", "arch", "compiler", "build_type" def layout(self): @@ -29,8 +30,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} requires GCC >=7") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) @@ -65,9 +65,6 @@ def package(self): def package_info(self): self.cpp_info.includedirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] # TODO: to remove in conan v2 - binpath = os.path.join(self.package_folder, "bin") - self.output.info(f"Adding to PATH: {binpath}") - self.env_info.PATH.append(binpath) + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) From 0b887c046306b7cc78ab00c8a48e5a16e8de5e62 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 22:59:01 +0200 Subject: [PATCH 0645/1140] (#19841) units: add package_type * add package_type * simplify test_v1_package * add a layout --- recipes/units/all/conanfile.py | 9 ++++++--- recipes/units/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 10 insertions(+), 10 deletions(-) diff --git a/recipes/units/all/conanfile.py b/recipes/units/all/conanfile.py index abb3f73f190416..f5e7559e8b3b49 100644 --- a/recipes/units/all/conanfile.py +++ b/recipes/units/all/conanfile.py @@ -2,6 +2,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get +from conan.tools.layout import basic_layout from conan.tools.scm import Version import os @@ -20,6 +21,7 @@ class UnitsConan(ConanFile): "no-dependencies") homepage = "https://github.com/nholthaus/units" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -36,6 +38,9 @@ def _minimum_compilers_version(self): "msvc": "190", } + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() @@ -49,8 +54,7 @@ def validate(self): ) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -64,4 +68,3 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "units::units") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] diff --git a/recipes/units/all/test_v1_package/CMakeLists.txt b/recipes/units/all/test_v1_package/CMakeLists.txt index b01d1d5fd06ef4..0d20897301b68b 100644 --- a/recipes/units/all/test_v1_package/CMakeLists.txt +++ b/recipes/units/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(units REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE units::units) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From b926dcc79565e8d81aa9d7d4c7e1e0f6bfcca76a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 15 Sep 2023 23:45:33 +0200 Subject: [PATCH 0646/1140] (#19842) utf8.h: add package_type * add package_type * simplify test_v1_package --- recipes/utf8.h/all/conanfile.py | 5 ++--- recipes/utf8.h/all/test_v1_package/CMakeLists.txt | 8 +++----- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/recipes/utf8.h/all/conanfile.py b/recipes/utf8.h/all/conanfile.py index 3c63ca89d61570..5053468bc7039f 100644 --- a/recipes/utf8.h/all/conanfile.py +++ b/recipes/utf8.h/all/conanfile.py @@ -13,6 +13,7 @@ class Utf8HConan(ConanFile): description = "Single header utf8 string functions for C and C++" topics = ("utf8", "unicode", "text") license = "Unlicense" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -23,8 +24,7 @@ def package_id(self): self.info.clear() def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -36,4 +36,3 @@ def package(self): def package_info(self): self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] diff --git a/recipes/utf8.h/all/test_v1_package/CMakeLists.txt b/recipes/utf8.h/all/test_v1_package/CMakeLists.txt index e35aca1f7a1353..0d20897301b68b 100644 --- a/recipes/utf8.h/all/test_v1_package/CMakeLists.txt +++ b/recipes/utf8.h/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES CXX) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(utf8.h REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE utf8.h::utf8.h) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 034efaefb15ccc4da4f634dc999ab707a1aacb14 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 16 Sep 2023 00:37:32 +0200 Subject: [PATCH 0647/1140] (#19843) v-hacd: add package_type --- recipes/v-hacd/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/v-hacd/all/conanfile.py b/recipes/v-hacd/all/conanfile.py index 0121a2fed52b85..7b0d91b5040841 100644 --- a/recipes/v-hacd/all/conanfile.py +++ b/recipes/v-hacd/all/conanfile.py @@ -16,6 +16,7 @@ class VhacdConan(ConanFile): topics = ("3d", "mesh", "shape", "decomposition", "convex") homepage = "https://github.com/kmammou/v-hacd" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -37,7 +38,7 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 11) + 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( @@ -45,8 +46,7 @@ def validate(self): ) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From 1b95ff852dffcfdd8b6edc0663ae9d32e5174c45 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 16 Sep 2023 02:00:20 +0200 Subject: [PATCH 0648/1140] (#19853) xpack: add package_type --- recipes/xpack/all/conanfile.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes/xpack/all/conanfile.py b/recipes/xpack/all/conanfile.py index 87dad9562235b8..fb4f7dbe93adb5 100644 --- a/recipes/xpack/all/conanfile.py +++ b/recipes/xpack/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.layout import basic_layout import os @@ -13,6 +13,7 @@ class XpackConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/xyz347/xpack" topics = ("json", "bson", "reflection", "xml", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -27,8 +28,8 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("rapidjson/cci.20220822", transitive_headers=True) - self.requires("rapidxml/1.13", transitive_headers=True) + self.requires("rapidjson/cci.20220822") + self.requires("rapidxml/1.13") def package_id(self): self.info.clear() From c34ba85b90b4d6275bd629dca95583ca4da5133f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 16 Sep 2023 02:13:39 +0200 Subject: [PATCH 0649/1140] (#19854) xproperty: add package_type --- recipes/xproperty/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/xproperty/all/conanfile.py b/recipes/xproperty/all/conanfile.py index f3db566cfff6d7..e6eeff282118e6 100644 --- a/recipes/xproperty/all/conanfile.py +++ b/recipes/xproperty/all/conanfile.py @@ -15,8 +15,9 @@ class XpropertyConan(ConanFile): topics = ("observer", "traitlets") homepage = "https://github.com/jupyter-xeus/xproperty" url = "https://github.com/conan-io/conan-center-index" - no_copy_source = True + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" + no_copy_source = True def layout(self): basic_layout(self, src_folder="src") @@ -32,8 +33,7 @@ def validate(self): check_min_cppstd(self, 14) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From fa010119ff3cfc071e71f0901a925ba6f3a547c2 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 16 Sep 2023 02:59:43 +0200 Subject: [PATCH 0650/1140] (#19858) zopfli: add package_type * add package_type * simplify test_v1_package --- recipes/zopfli/all/conanfile.py | 24 ++++++------------- .../zopfli/all/test_v1_package/CMakeLists.txt | 8 +++---- 2 files changed, 10 insertions(+), 22 deletions(-) diff --git a/recipes/zopfli/all/conanfile.py b/recipes/zopfli/all/conanfile.py index 1f0b88e5124353..35dd2870f9a777 100644 --- a/recipes/zopfli/all/conanfile.py +++ b/recipes/zopfli/all/conanfile.py @@ -4,7 +4,7 @@ from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.53.0" class ZopfliConan(ConanFile): @@ -16,8 +16,8 @@ class ZopfliConan(ConanFile): "Zopfli Compression Algorithm is a compression library programmed in C " "to perform very good, but slow, deflate or zlib compression." ) - topics = ("zopfli", "compression", "deflate", "gzip", "zlib") - + topics = ("compression", "deflate", "gzip", "zlib") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -34,25 +34,15 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def layout(self): cmake_layout(self, src_folder="src") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/zopfli/all/test_v1_package/CMakeLists.txt b/recipes/zopfli/all/test_v1_package/CMakeLists.txt index 0d2662cb23a483..0d20897301b68b 100644 --- a/recipes/zopfli/all/test_v1_package/CMakeLists.txt +++ b/recipes/zopfli/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES C) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(Zopfli REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE Zopfli::libzopfli) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From facf3592ff6f6cf62c3f821f88982acc07b9c07f Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Fri, 15 Sep 2023 18:11:25 -0700 Subject: [PATCH 0651/1140] (#19875) gegles-spdlog_setup: bump fmt --- recipes/gegles-spdlog_setup/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/gegles-spdlog_setup/all/conanfile.py b/recipes/gegles-spdlog_setup/all/conanfile.py index 9385009e7bf437..fd9faf40ac95a5 100644 --- a/recipes/gegles-spdlog_setup/all/conanfile.py +++ b/recipes/gegles-spdlog_setup/all/conanfile.py @@ -40,7 +40,7 @@ def layout(self): def requirements(self): self.requires("cpptoml/0.1.1") self.requires("spdlog/1.12.0") - self.requires("fmt/10.1.0") + self.requires("fmt/10.1.1") def package_id(self): self.info.clear() From 4d669f7385ec168453c10afda3d3c9f2c174c2b4 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 16 Sep 2023 09:50:28 +0200 Subject: [PATCH 0652/1140] (#19852) xorstr: add package_type --- recipes/xorstr/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/xorstr/all/conanfile.py b/recipes/xorstr/all/conanfile.py index 2712a05ac70441..f5d66df51bfdbb 100644 --- a/recipes/xorstr/all/conanfile.py +++ b/recipes/xorstr/all/conanfile.py @@ -15,8 +15,9 @@ class XorstrConan(ConanFile): topics = ("encryption", "string", "vectorized") homepage = "https://github.com/JustasMasiulis/xorstr" url = "https://github.com/conan-io/conan-center-index" - no_copy_source = True + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property def _min_cppstd(self): @@ -55,8 +56,7 @@ def loose_lt_semver(v1, v2): ) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From e9695f5f55547f6b7017e27e3465bbfd07f7e059 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 16 Sep 2023 22:32:46 +0900 Subject: [PATCH 0653/1140] (#19885) yyjson: add version 0.8.0 --- recipes/yyjson/all/conandata.yml | 3 +++ recipes/yyjson/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/yyjson/all/conandata.yml b/recipes/yyjson/all/conandata.yml index 35f28ce479a2e9..ad21b483cb8407 100644 --- a/recipes/yyjson/all/conandata.yml +++ b/recipes/yyjson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.8.0": + url: "https://github.com/ibireme/yyjson/archive/refs/tags/0.8.0.tar.gz" + sha256: "b2e39ac4c65f9050820c6779e6f7dd3c0d3fed9c6667f91caec0badbedce00f3" "0.7.0": url: "https://github.com/ibireme/yyjson/archive/refs/tags/0.7.0.tar.gz" sha256: "9b91ee48ac1fe5939f747d49f123d9a522b5f4e1e46165c1871936d583628a06" diff --git a/recipes/yyjson/config.yml b/recipes/yyjson/config.yml index 7a6fcce01199cc..f84f2efec202bb 100644 --- a/recipes/yyjson/config.yml +++ b/recipes/yyjson/config.yml @@ -1,4 +1,6 @@ versions: + "0.8.0": + folder: all "0.7.0": folder: all "0.6.0": From 1c0d4dad577bcf7467237fab95f4417e907ae359 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 16 Sep 2023 23:11:22 +0900 Subject: [PATCH 0654/1140] (#19886) cpu_features: add version 0.9.0 --- recipes/cpu_features/all/conandata.yml | 3 +++ recipes/cpu_features/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cpu_features/all/conandata.yml b/recipes/cpu_features/all/conandata.yml index 8e0a68b98fb045..b0a209ae1c3e88 100644 --- a/recipes/cpu_features/all/conandata.yml +++ b/recipes/cpu_features/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.9.0": + url: "https://github.com/google/cpu_features/archive/refs/tags/v0.9.0.tar.gz" + sha256: "bdb3484de8297c49b59955c3b22dba834401bc2df984ef5cfc17acbe69c5018e" "0.8.0": url: "https://github.com/google/cpu_features/archive/refs/tags/v0.8.0.tar.gz" sha256: "7021729f2db97aa34f218d12727314f23e8b11eaa2d5a907e8426bcb41d7eaac" diff --git a/recipes/cpu_features/config.yml b/recipes/cpu_features/config.yml index a4fbe67cb54a0d..7f1513eea2fa95 100644 --- a/recipes/cpu_features/config.yml +++ b/recipes/cpu_features/config.yml @@ -1,4 +1,6 @@ versions: + "0.9.0": + folder: "all" "0.8.0": folder: "all" "0.7.0": From 092f610afed9c8317be47a33da04be540b986f2d Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 16 Sep 2023 23:52:42 +0900 Subject: [PATCH 0655/1140] (#19889) uni-algo: add version 1.1.0 --- recipes/uni-algo/all/conandata.yml | 3 +++ recipes/uni-algo/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/uni-algo/all/conandata.yml b/recipes/uni-algo/all/conandata.yml index 506f983a8dd2c5..0aedc7a70319b1 100644 --- a/recipes/uni-algo/all/conandata.yml +++ b/recipes/uni-algo/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.0": + url: "https://github.com/uni-algo/uni-algo/archive/v1.1.0.tar.gz" + sha256: "f9aa30df9766fbbc7007b206c6db122313194e75b159dc222cddce016372d2de" "1.0.0": url: "https://github.com/uni-algo/uni-algo/archive/v1.0.0.tar.gz" sha256: "a59d61cd4a4fff08672831c7e5a8c204bb6e96c21506b6471771c01b38958a15" diff --git a/recipes/uni-algo/config.yml b/recipes/uni-algo/config.yml index 9ca04a66695cab..aabd23fca0e2da 100644 --- a/recipes/uni-algo/config.yml +++ b/recipes/uni-algo/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.0": + folder: all "1.0.0": folder: all "0.8.2": From 5a4b6a035b15941f48181141ab3dcb79bf09035f Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 17 Sep 2023 02:28:50 +0900 Subject: [PATCH 0656/1140] (#19893) platform.hashing: update cpu_features/0.9.0 --- recipes/platform.hashing/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/platform.hashing/all/conanfile.py b/recipes/platform.hashing/all/conanfile.py index bb49b80ef8c5ee..0e0affe79e746a 100644 --- a/recipes/platform.hashing/all/conanfile.py +++ b/recipes/platform.hashing/all/conanfile.py @@ -50,7 +50,7 @@ def requirements(self): if Version(self.version) >= "0.5.6": self.requires("cpuinfo/cci.20220228", transitive_headers=True) elif Version(self.version) >= "0.5.0": - self.requires("cpu_features/0.8.0", transitive_headers=True) + self.requires("cpu_features/0.9.0", transitive_headers=True) def package_id(self): self.info.clear() From 11fd93464a8113be088c2272e3cbebee675e7ff4 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 17 Sep 2023 03:51:43 +0900 Subject: [PATCH 0657/1140] (#19895) implot: update imgui/1.89.9 --- recipes/implot/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/implot/all/conanfile.py b/recipes/implot/all/conanfile.py index 20e340b605f31e..f2fa4d63a05867 100644 --- a/recipes/implot/all/conanfile.py +++ b/recipes/implot/all/conanfile.py @@ -39,7 +39,7 @@ def configure(self): def requirements(self): if Version(self.version) >= "0.15": - self.requires("imgui/1.89.8", transitive_headers=True) + self.requires("imgui/1.89.9", transitive_headers=True) elif Version(self.version) >= "0.14": self.requires("imgui/1.89.4", transitive_headers=True) elif Version(self.version) >= "0.13": From c99b97858ee2dda8e8b38a3452ddc943e9165587 Mon Sep 17 00:00:00 2001 From: Toni Neubert Date: Sat, 16 Sep 2023 21:29:58 +0200 Subject: [PATCH 0658/1140] (#19898) emio: add version 0.4.0 --- recipes/emio/all/conandata.yml | 3 +++ recipes/emio/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/emio/all/conandata.yml b/recipes/emio/all/conandata.yml index 7951ebbf46b659..e7d7963735f4c2 100644 --- a/recipes/emio/all/conandata.yml +++ b/recipes/emio/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.4.0": + url: "https://github.com/viatorus/emio/archive/0.4.0.tar.gz" + sha256: "847198a37fbf9dcc00ac85fbc64b283e41a018f53c39363129a4bdb9939338a6" "0.3.0": url: "https://github.com/viatorus/emio/archive/0.3.0.tar.gz" sha256: "d891d0a435a8b71eee78bba46b9abc3848b1c20d61eb747b6059adaf23acce1d" diff --git a/recipes/emio/config.yml b/recipes/emio/config.yml index d126790212e0c4..3842372f8b1f4d 100644 --- a/recipes/emio/config.yml +++ b/recipes/emio/config.yml @@ -1,3 +1,5 @@ versions: + "0.4.0": + folder: all "0.3.0": folder: all From bec32b1cc6f20f897a35b7cebf4f530521a3b1af Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 17 Sep 2023 23:25:59 +0900 Subject: [PATCH 0659/1140] (#19905) libdeflate: add version 1.19 --- recipes/libdeflate/all/conandata.yml | 3 +++ recipes/libdeflate/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libdeflate/all/conandata.yml b/recipes/libdeflate/all/conandata.yml index 01ec059a63c200..720157d82ac2bd 100644 --- a/recipes/libdeflate/all/conandata.yml +++ b/recipes/libdeflate/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.19": + url: "https://github.com/ebiggers/libdeflate/archive/refs/tags/v1.19.tar.gz" + sha256: "27bf62d71cd64728ff43a9feb92f2ac2f2bf748986d856133cc1e51992428c25" "1.18": url: "https://github.com/ebiggers/libdeflate/archive/refs/tags/v1.18.tar.gz" sha256: "225d982bcaf553221c76726358d2ea139bb34913180b20823c782cede060affd" diff --git a/recipes/libdeflate/config.yml b/recipes/libdeflate/config.yml index 2ecdca807a8d64..fe3db2bc74050b 100644 --- a/recipes/libdeflate/config.yml +++ b/recipes/libdeflate/config.yml @@ -1,4 +1,6 @@ versions: + "1.19": + folder: "all" "1.18": folder: "all" "1.17": From 5b3040b0ae2689f594a390afeb415d1fd9454579 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 18 Sep 2023 00:09:58 +0900 Subject: [PATCH 0660/1140] (#19924) libalsa: add version 1.2.10 --- recipes/libalsa/all/conandata.yml | 3 +++ recipes/libalsa/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libalsa/all/conandata.yml b/recipes/libalsa/all/conandata.yml index 55a14a6d4051e6..c612ddb389783b 100644 --- a/recipes/libalsa/all/conandata.yml +++ b/recipes/libalsa/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.10": + url: "https://github.com/alsa-project/alsa-lib/archive/v1.2.10.tar.gz" + sha256: "f55749847fd98274501f4691a2d847e89280c07d40a43cdac43d6443f69fc939" "1.2.7.2": url: "https://github.com/alsa-project/alsa-lib/archive/v1.2.7.2.tar.gz" sha256: "2ed6d908120beb4a91c2271b01489181b28dc9f35f32229ef83bcd5ac8817654" diff --git a/recipes/libalsa/config.yml b/recipes/libalsa/config.yml index b1fdda2825fa62..ce651c2f0d63a3 100644 --- a/recipes/libalsa/config.yml +++ b/recipes/libalsa/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.10": + folder: all "1.2.7.2": folder: all "1.2.7": From 9c8380a896b84867a1904ba66e296228e19f0af9 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 03:09:47 +0200 Subject: [PATCH 0661/1140] (#19918) libinterpolate: fix msvc min version + add package_type --- recipes/libinterpolate/all/conanfile.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/recipes/libinterpolate/all/conanfile.py b/recipes/libinterpolate/all/conanfile.py index b1c88daae5803a..c6aadd8b682fe0 100644 --- a/recipes/libinterpolate/all/conanfile.py +++ b/recipes/libinterpolate/all/conanfile.py @@ -17,6 +17,7 @@ class PackageConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/CD3/libInterpolate" topics = ("math", "spline", "interpolation", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -28,13 +29,12 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15", - "msvc": "19.0", + "msvc": "191", "gcc": "7", "clang": "4", "apple-clang": "10", } - def layout(self): basic_layout(self, src_folder="src") @@ -42,6 +42,9 @@ def requirements(self): self.requires("boost/1.80.0", transitive_headers=True) self.requires("eigen/3.3.7", transitive_headers=True) + def package_id(self): + self.info.clear() + def validate(self): if Version(self.version) < "2.6.4" and self.settings.os != "Linux": raise ConanInvalidConfiguration(f"{self.ref} is not supported by {self.settings.os}; Try the version >= 2.6.4") @@ -80,9 +83,6 @@ def package(self): src=os.path.join(self.source_folder, "src"), ) - def package_id(self): - self.info.clear() - def package_info(self): self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] From 43760a1c2cd4cdb6dd4845736dbe4d1195e9be81 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 04:10:28 +0200 Subject: [PATCH 0662/1140] (#19668) pcre2: use version range for zlib + add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * add package_type * Update recipes/pcre2/all/conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/pcre2/all/conanfile.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/recipes/pcre2/all/conanfile.py b/recipes/pcre2/all/conanfile.py index 5982290e7cdbe1..14600c9abe85c9 100644 --- a/recipes/pcre2/all/conanfile.py +++ b/recipes/pcre2/all/conanfile.py @@ -16,7 +16,7 @@ class PCRE2Conan(ConanFile): description = "Perl Compatible Regular Expressions" topics = ("regex", "regexp", "perl") license = "BSD-3-Clause" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -65,7 +65,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.get_safe("with_bzip2"): self.requires("bzip2/1.0.8") @@ -76,8 +76,7 @@ def validate(self): raise ConanInvalidConfiguration("build_pcre2_8 must be enabled for the pcre2grep program") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) From 405434bb3db8c036b9758c70ffc39e850caef327 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 18 Sep 2023 07:29:30 +0200 Subject: [PATCH 0663/1140] (#19914) cmake: add version 3.27.5 --- recipes/cmake/binary/conandata.yml | 19 +++++++++++++++++++ recipes/cmake/config.yml | 2 ++ 2 files changed, 21 insertions(+) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index afcf32ce814612..3eb4a53d2fff43 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.5": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.5-linux-aarch64.tar.gz" + sha256: "2ffaf176d0f93c332abaffbf3ce82fc8c90e49e0fcee8dc16338bcfbb150ead7" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.5-linux-x86_64.tar.gz" + sha256: "138c68addae825b16ed78d792dafef5e0960194833f48bd77e7e0429c6bc081c" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.5-macos10.10-universal.tar.gz" + sha256: "1f776640e6ad35b2b3fe2ab5e39cff363b2c3034ecb56e45597402b7bf010e47" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.5-windows-arm64.zip" + sha256: "3fcc84d34e3213b0e4261295eaddfc645685ab366dc570421555e7f3d3080d3a" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.5-windows-x86_64.zip" + sha256: "1e8e06c8ecf63d5f213019e1cd39ea41a6cf952db5f2c8e69b8e47f5bc302684" "3.27.4": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 94869f2ceea826..179f7ccf1c5b2c 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -1,4 +1,6 @@ versions: + "3.27.5": + folder: "binary" "3.27.4": folder: "binary" "3.27.1": From 759207d760e21cfedd31e22df665a271ee6965e3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 08:09:33 +0200 Subject: [PATCH 0664/1140] (#19850) wildmidi: add package_type --- recipes/wildmidi/all/conanfile.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/recipes/wildmidi/all/conanfile.py b/recipes/wildmidi/all/conanfile.py index 0e6c15d33a72bd..4648d8d359fa37 100644 --- a/recipes/wildmidi/all/conanfile.py +++ b/recipes/wildmidi/all/conanfile.py @@ -15,6 +15,7 @@ class WildmidiConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.mindwerks.net/projects/wildmidi" topics = ("audio", "midi", "multimedia", "music", "softsynth", "sound", "synth") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -72,10 +73,10 @@ def package_info(self): if is_msvc(self): libname = "libWildMidi" if not self.options.shared: - libname += "-static" + libname += "-static" else: libname = "WildMidi" - + self.cpp_info.set_property("cmake_file_name", "WildMidi") self.cpp_info.set_property("cmake_target_name", "WildMidi::libwildmidi") self.cpp_info.set_property("pkg_config_name", "wildmidi") @@ -92,3 +93,5 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "WildMidi" self.cpp_info.components["libwildmidi"].names["cmake_find_package"] = "libwildmidi" self.cpp_info.components["libwildmidi"].names["cmake_find_package_multi"] = "libwildmidi" + self.cpp_info.components["libwildmidi"].set_property("cmake_target_name", "WildMidi::libwildmidi") + self.cpp_info.components["libwildmidi"].set_property("pkg_config_name", "wildmidi") From 84268cc6407d94a408b62af0f561defbadb03929 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 08:33:30 +0200 Subject: [PATCH 0665/1140] (#19879) zpp_throwing: add package_type --- recipes/zpp_throwing/all/conanfile.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/recipes/zpp_throwing/all/conanfile.py b/recipes/zpp_throwing/all/conanfile.py index 6cfaa18e3dd020..7fb36897fcbae1 100644 --- a/recipes/zpp_throwing/all/conanfile.py +++ b/recipes/zpp_throwing/all/conanfile.py @@ -3,11 +3,12 @@ from conan.tools.build import check_min_cppstd from conan.tools.files import get, copy from conan.tools.layout import basic_layout -from conan.tools.scm import Version from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" + class ZppThrowingConan(ConanFile): name = "zpp_throwing" @@ -16,6 +17,7 @@ class ZppThrowingConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/eyalz800/zpp_throwing" topics = ("coroutines", "exceptions", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -67,7 +69,7 @@ def loose_lt_semver(v1, v2): raise ConanInvalidConfiguration(f"{self.ref} requires libc++ with 'coroutines' supported on your compiler.") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) From 26b5d9fb913aa008db6d93e6a926accd7fd39044 Mon Sep 17 00:00:00 2001 From: Tobias Hermann Date: Mon, 18 Sep 2023 09:10:11 +0200 Subject: [PATCH 0666/1140] (#19855) Add FunctionalPlus version 0.2.20-p0 --- recipes/functionalplus/all/conandata.yml | 3 +++ recipes/functionalplus/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/functionalplus/all/conandata.yml b/recipes/functionalplus/all/conandata.yml index ca33489d4d5de3..0abf05e2527934 100644 --- a/recipes/functionalplus/all/conandata.yml +++ b/recipes/functionalplus/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.2.20-p0": + url: "https://github.com/Dobiasd/FunctionalPlus/archive/v0.2.20-p0.tar.gz" + sha256: "6a8e56bd7976b7d5a6a31001f36bc199c2997f1144994fa0b48a1a5b8497abbc" "0.2.18-p0": url: "https://github.com/Dobiasd/FunctionalPlus/archive/v0.2.18-p0.tar.gz" sha256: "ffc63fc86f89a205accafa85c35790eda307adf5f1d6d51bb7ceb5c5e21e013b" diff --git a/recipes/functionalplus/config.yml b/recipes/functionalplus/config.yml index 42d00dd1c341a5..bc5d04d53c4bdd 100644 --- a/recipes/functionalplus/config.yml +++ b/recipes/functionalplus/config.yml @@ -1,4 +1,6 @@ versions: + "0.2.20-p0": + folder: all "0.2.18-p0": folder: all "0.2.17-p0": From 80f4b261dafc8d10b1eddb186033601987a22618 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 09:51:32 +0200 Subject: [PATCH 0667/1140] (#19846) vcglib: add package_type * add package_type & modernize more * simplify test_v1_package * fix eigen traits --- recipes/vcglib/all/conanfile.py | 15 ++++++--------- recipes/vcglib/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 10 insertions(+), 16 deletions(-) diff --git a/recipes/vcglib/all/conanfile.py b/recipes/vcglib/all/conanfile.py index f452d7336181c3..b05d8f64d45598 100644 --- a/recipes/vcglib/all/conanfile.py +++ b/recipes/vcglib/all/conanfile.py @@ -4,7 +4,7 @@ from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.53.0" class VcglibConan(ConanFile): @@ -14,7 +14,7 @@ class VcglibConan(ConanFile): topics = ("vcglib", "mesh-processing") homepage = "https://github.com/cnr-isti-vclab/vcglib" url = "https://github.com/conan-io/conan-center-index" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -35,24 +35,21 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass + self.options.rm_safe("fPIC") def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("eigen/3.4.0") + # vcglib public headers include several eigen headers (for example vcg/math/matrix44.h includes Eigen/Core) + self.requires("eigen/3.4.0", transitive_headers=True) def validate(self): if self.info.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/vcglib/all/test_v1_package/CMakeLists.txt b/recipes/vcglib/all/test_v1_package/CMakeLists.txt index 0b93c9e9b9c662..0d20897301b68b 100644 --- a/recipes/vcglib/all/test_v1_package/CMakeLists.txt +++ b/recipes/vcglib/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(vcglib REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE vcglib::vcglib) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 7a79d9be8b5cd983d88b7f7b97cec9b1a3a2dee7 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 10:36:27 +0200 Subject: [PATCH 0668/1140] (#19849) vectorial: add package_type * add package_type * simplify test_v1_package * add test_type to test package --- recipes/vectorial/all/conanfile.py | 12 +++++------- recipes/vectorial/all/test_package/conanfile.py | 7 ++++--- recipes/vectorial/all/test_v1_package/CMakeLists.txt | 8 +++----- 3 files changed, 12 insertions(+), 15 deletions(-) diff --git a/recipes/vectorial/all/conanfile.py b/recipes/vectorial/all/conanfile.py index fd7818ff4d997d..91f7fd34d7f37f 100644 --- a/recipes/vectorial/all/conanfile.py +++ b/recipes/vectorial/all/conanfile.py @@ -13,18 +13,18 @@ class VectorialConan(ConanFile): license = "BSD-2-Clause" homepage = "https://github.com/scoopr/vectorial" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True - def package_id(self): - self.info.clear() - def layout(self): basic_layout(self, src_folder="src") + def package_id(self): + self.info.clear() + def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -35,8 +35,6 @@ def package(self): def package_info(self): self.cpp_info.bindirs = [] - self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["m"] diff --git a/recipes/vectorial/all/test_package/conanfile.py b/recipes/vectorial/all/test_package/conanfile.py index d120a992c06a69..0a6bc68712d901 100644 --- a/recipes/vectorial/all/test_package/conanfile.py +++ b/recipes/vectorial/all/test_package/conanfile.py @@ -7,13 +7,14 @@ class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" - - def requirements(self): - self.requires(self.tested_reference_str) + test_type = "explicit" def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() diff --git a/recipes/vectorial/all/test_v1_package/CMakeLists.txt b/recipes/vectorial/all/test_v1_package/CMakeLists.txt index 394022f35f7caf..0d20897301b68b 100644 --- a/recipes/vectorial/all/test_v1_package/CMakeLists.txt +++ b/recipes/vectorial/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES CXX) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(vectorial REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE vectorial::vectorial) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 33b2ec2fcea15533f5067f2078e03948df4d588b Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 11:03:51 +0200 Subject: [PATCH 0669/1140] (#19851) winmd: add package_type & clear bindirs and libdirs in package_info() * add package_type & clear bindirs and libdirs in package_info() * fix cxxflags for conan v2 client --- recipes/winmd/all/conanfile.py | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/recipes/winmd/all/conanfile.py b/recipes/winmd/all/conanfile.py index 1882e7a4ae7032..e37dc1cc239fe2 100644 --- a/recipes/winmd/all/conanfile.py +++ b/recipes/winmd/all/conanfile.py @@ -5,10 +5,10 @@ from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc from conan.tools.scm import Version -from conan.tools.microsoft import is_msvc, check_min_vs -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" class WinMDConan(ConanFile): @@ -18,6 +18,7 @@ class WinMDConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/microsoft/winmd" topics = ("native", "C++", "WinRT", "WinMD") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -30,7 +31,9 @@ def _compilers_minimum_version(self): return { "gcc": "8", "clang": "12", - "apple-clang": "12.0", + "apple-clang": "12", + "Visual Studio": "15", + "msvc": "191", } def layout(self): @@ -40,20 +43,17 @@ def package_id(self): self.info.clear() def validate(self): - # FIXME: `self.settings` is not available in 2.0 but there are plenty of open issues about - # the migration point. For now we are only going to write valid 1.x recipes until we have a proper answer if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) - check_min_vs(self, 191) - if not is_msvc(self): - 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 (fully) support." - ) + + 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 (fully) support." + ) def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) @@ -65,6 +65,8 @@ def package(self): ) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] if not is_msvc(self): # ignore shadowing errors - self.cpp_info.cppflags = ['-fpermissive'] + self.cpp_info.cxxflags = ['-fpermissive'] From 0961e9d878672a472343b6af17590a8720e9ee42 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 18 Sep 2023 18:36:02 +0900 Subject: [PATCH 0670/1140] (#19571) crowcpp-crow: update dependencies, fix requires names * crowcpp-crow: update dependencies, fix requires names * use version range in crowcpp-crow>=1.0 Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/crowcpp-crow/all/conanfile.py | 11 +++++++---- recipes/crowcpp-crow/all/test_package/conanfile.py | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/recipes/crowcpp-crow/all/conanfile.py b/recipes/crowcpp-crow/all/conanfile.py index 001767af2d0fdb..baeed2070acd2d 100644 --- a/recipes/crowcpp-crow/all/conanfile.py +++ b/recipes/crowcpp-crow/all/conanfile.py @@ -42,12 +42,12 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") if self.version == "0.2": - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") if Version(self.version) >= "1.0": if self.options.with_ssl: - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <3]") if self.options.with_compression: self.requires("zlib/1.2.13") @@ -121,10 +121,13 @@ def package_info(self): self.cpp_info.set_property("cmake_file_name", "Crow") self.cpp_info.set_property("cmake_target_name", "Crow::Crow") + if Version(self.version) == "0.2": + self.cpp_info.requires.append("openssl::ssl") + if Version(self.version) >= "1.0": if self.options.with_ssl: self.cpp_info.defines.append("CROW_ENABLE_SSL") - self.cpp_info.requires.append("OpenSSL::ssl") + self.cpp_info.requires.append("openssl::ssl") if self.options.with_compression: self.cpp_info.defines.append("CROW_ENABLE_COMPRESSION") self.cpp_info.requires.append("zlib::zlib") diff --git a/recipes/crowcpp-crow/all/test_package/conanfile.py b/recipes/crowcpp-crow/all/test_package/conanfile.py index 3022a3897300e8..6fce18aff0519b 100644 --- a/recipes/crowcpp-crow/all/test_package/conanfile.py +++ b/recipes/crowcpp-crow/all/test_package/conanfile.py @@ -6,7 +6,7 @@ class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" def requirements(self): From e1a3583efcbf21232a101dd6d17a13df32664096 Mon Sep 17 00:00:00 2001 From: Laurent Rineau Date: Mon, 18 Sep 2023 12:34:16 +0200 Subject: [PATCH 0671/1140] (#19776) cgal: add CMake variable CGAL_USE_GMP for compatibility --- recipes/cgal/all/conanfile.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/recipes/cgal/all/conanfile.py b/recipes/cgal/all/conanfile.py index 3a63d4857c1679..2d4d74dba1bec9 100644 --- a/recipes/cgal/all/conanfile.py +++ b/recipes/cgal/all/conanfile.py @@ -163,6 +163,10 @@ def _create_cmake_module_variables(self, module_file): endfunction() CGAL_setup_CGAL_flags(CGAL::CGAL) + +# CGAL use may rely on the presence of those two variables +set(CGAL_USE_GMP TRUE CACHE INTERNAL "CGAL library is configured to use GMP") +set(CGAL_USE_MPFR TRUE CACHE INTERNAL "CGAL library is configured to use MPFR") ''') save(self, module_file, content) From c05290e2cf756a60f262ee904610ed3316da0d31 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 18 Sep 2023 20:17:34 +0900 Subject: [PATCH 0672/1140] (#19874) continuable: add version 4.2.2, update dependencies --- recipes/continuable/all/conandata.yml | 5 ++++- recipes/continuable/all/conanfile.py | 2 +- recipes/continuable/all/test_package/CMakeLists.txt | 2 +- recipes/continuable/config.yml | 2 ++ 4 files changed, 8 insertions(+), 3 deletions(-) diff --git a/recipes/continuable/all/conandata.yml b/recipes/continuable/all/conandata.yml index 13887549bde390..15db65fb152edd 100644 --- a/recipes/continuable/all/conandata.yml +++ b/recipes/continuable/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.2.2": + url: "https://github.com/Naios/continuable/archive/4.2.2.tar.gz" + sha256: "49bf82a349b26c01194631e4fe5d1dbad080b3b4a347eebc5cf95326ea130fba" "4.2.1": url: "https://github.com/Naios/continuable/archive/4.2.1.tar.gz" sha256: "19c7c2371c94ec759eac8169dea593703b54057551322b5d682643548c9c0146" @@ -6,5 +9,5 @@ sources: url: "https://github.com/Naios/continuable/archive/4.2.0.tar.gz" sha256: "d85bed930ac19d4b36b23778ad9ae943c2981f7492982bd51dadb89e8908d53f" "4.1.0": - sha256: "CBCF50B1B73D8B4EB54734C827D6736CD038960E13F80699958DBB87F1827650" url: "https://github.com/Naios/continuable/archive/4.1.0.tar.gz" + sha256: "CBCF50B1B73D8B4EB54734C827D6736CD038960E13F80699958DBB87F1827650" diff --git a/recipes/continuable/all/conanfile.py b/recipes/continuable/all/conanfile.py index 40af36527241ef..e724022beb95f0 100644 --- a/recipes/continuable/all/conanfile.py +++ b/recipes/continuable/all/conanfile.py @@ -78,7 +78,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("function2/4.1.0") + self.requires("function2/4.2.3") def package_id(self): self.info.clear() diff --git a/recipes/continuable/all/test_package/CMakeLists.txt b/recipes/continuable/all/test_package/CMakeLists.txt index f98eae0c75bf8e..9a7b7e199f5b87 100644 --- a/recipes/continuable/all/test_package/CMakeLists.txt +++ b/recipes/continuable/all/test_package/CMakeLists.txt @@ -5,7 +5,7 @@ find_package(continuable REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) set_target_properties(${PROJECT_NAME} PROPERTIES - CXX_STANDARD 14 CXX_STANDARD_REQUIRED ON ) target_link_libraries(${PROJECT_NAME} PRIVATE continuable::continuable) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/continuable/config.yml b/recipes/continuable/config.yml index 52fa67bcd41e8a..955cd0773fc58e 100644 --- a/recipes/continuable/config.yml +++ b/recipes/continuable/config.yml @@ -1,4 +1,6 @@ versions: + "4.2.2": + folder: all "4.2.1": folder: all "4.2.0": From 1e4622798f6e45b8570548d3b78bf3aa4a1e7499 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 13:57:16 +0200 Subject: [PATCH 0673/1140] (#19880) vectorclass: add package type & modernize a little bit more * add package_type & modernize a little bit more * simplify test v1 package --- recipes/vectorclass/all/conanfile.py | 16 ++++++++-------- .../all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 12 insertions(+), 15 deletions(-) diff --git a/recipes/vectorclass/all/conanfile.py b/recipes/vectorclass/all/conanfile.py index 5696b99489d45d..60e6bdcdc723a7 100644 --- a/recipes/vectorclass/all/conanfile.py +++ b/recipes/vectorclass/all/conanfile.py @@ -5,7 +5,7 @@ from conan.tools.files import copy, get import os -required_conan_version = ">=1.51.1" +required_conan_version = ">=1.50.0" class VectorclassConan(ConanFile): @@ -18,7 +18,7 @@ class VectorclassConan(ConanFile): topics = ("vectorclass", "vector", "simd") homepage = "https://github.com/vectorclass/version2" url = "https://github.com/conan-io/conan-center-index" - + package_type = "static-library" settings = "os", "arch", "compiler", "build_type" options = { "fPIC": [True, False], @@ -37,6 +37,7 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15.7", + "msvc": "191", "gcc": "7", "clang": "4.0", "apple-clang": "9.1", @@ -50,10 +51,10 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.info.settings.os not in ["Linux", "Windows", "Macos"] or self.info.settings.arch not in ["x86", "x86_64"]: + if self.settings.os not in ["Linux", "Windows", "Macos"] or self.settings.arch not in ["x86", "x86_64"]: raise ConanInvalidConfiguration("vectorclass supports Linux/Windows/macOS and x86/x86_64 only.") - if self.info.settings.compiler.get_safe("cppstd"): + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) def loose_lt_semver(v1, v2): @@ -62,15 +63,14 @@ def loose_lt_semver(v1, v2): min_length = min(len(lv1), len(lv2)) return lv1[:min_length] < lv2[:min_length] - minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) - if minimum_version and loose_lt_semver(str(self.info.settings.compiler.version), minimum_version): + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) + if minimum_version and loose_lt_semver(str(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], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/vectorclass/all/test_v1_package/CMakeLists.txt b/recipes/vectorclass/all/test_v1_package/CMakeLists.txt index 1d531c5d5a9305..0d20897301b68b 100644 --- a/recipes/vectorclass/all/test_v1_package/CMakeLists.txt +++ b/recipes/vectorclass/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(vectorclass REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE vectorclass::vectorclass) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From edeff846f34b00e97fedf72981d6194b222d7099 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 18 Sep 2023 14:44:01 +0200 Subject: [PATCH 0674/1140] (#19913) [doc] fix msvc version in header-only template --- docs/package_templates/header_only/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/package_templates/header_only/all/conanfile.py b/docs/package_templates/header_only/all/conanfile.py index 51ea9a72fb9541..6414c6f49c028f 100644 --- a/docs/package_templates/header_only/all/conanfile.py +++ b/docs/package_templates/header_only/all/conanfile.py @@ -36,7 +36,7 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15", - "msvc": "14.1", + "msvc": "191", "gcc": "5", "clang": "5", "apple-clang": "5.1", From 1d2f90e3c9d2e93a61b6fcac8268586b27737f33 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 18 Sep 2023 16:08:35 +0300 Subject: [PATCH 0675/1140] (#18259) frugally-deep: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * frugally-deep: migrate to Conan v2 * frugally-deep: restore test_v1_package * frugally-deep: restore VirtualRunEnv in test_package * frugally-deep: bump deps --------- Co-authored-by: Rubén Rincón Blanco --- recipes/frugally-deep/all/conanfile.py | 68 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 19 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 17 +++++ 5 files changed, 78 insertions(+), 41 deletions(-) create mode 100644 recipes/frugally-deep/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/frugally-deep/all/test_v1_package/conanfile.py diff --git a/recipes/frugally-deep/all/conanfile.py b/recipes/frugally-deep/all/conanfile.py index 2588afa778f5bf..4b479f8d56a41d 100644 --- a/recipes/frugally-deep/all/conanfile.py +++ b/recipes/frugally-deep/all/conanfile.py @@ -1,23 +1,30 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class FrugallyDeepConan(ConanFile): name = "frugally-deep" description = "Use Keras models in C++ with ease." license = "MIT" - topics = ("keras", "tensorflow") - homepage = "https://github.com/Dobiasd/frugally-deep" url = "https://github.com/conan-io/conan-center-index" - settings = "os", "compiler", "build_type", "arch" + homepage = "https://github.com/Dobiasd/frugally-deep" + topics = ("keras", "tensorflow", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 14 @property def _compilers_minimum_version(self): @@ -27,45 +34,44 @@ def _compilers_minimum_version(self): "clang": "3.7", "apple-clang": "9", } + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): self.requires("eigen/3.4.0") self.requires("functionalplus/0.2.18-p0") - self.requires("nlohmann_json/3.10.5") + self.requires("nlohmann_json/3.11.2") + + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 14) - - def lazy_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] - + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("frugally-deep requires C++14. Your compiler is unknown. Assuming it supports C++14.") - elif lazy_lt_semver(str(self.settings.compiler.version), minimum_version): - raise ConanInvalidConfiguration("frugally-deep requires C++14, which your compiler does not support.") - - def package_id(self): - self.info.header_only() + 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): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, "*", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "frugally-deep") self.cpp_info.set_property("cmake_target_name", "frugally-deep::fdeep") # TODO: back to global scope in conan v2 once cmake_find_package* generators removed - self.cpp_info.components["fdeep"].requires = ["eigen::eigen", - "functionalplus::functionalplus", - "nlohmann_json::nlohmann_json"] + self.cpp_info.components["fdeep"].requires = [ + "eigen::eigen", + "functionalplus::functionalplus", + "nlohmann_json::nlohmann_json", + ] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["fdeep"].system_libs = ["pthread"] diff --git a/recipes/frugally-deep/all/test_package/CMakeLists.txt b/recipes/frugally-deep/all/test_package/CMakeLists.txt index a8c615c1776b89..b64a8f93f961fd 100644 --- a/recipes/frugally-deep/all/test_package/CMakeLists.txt +++ b/recipes/frugally-deep/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(frugally-deep REQUIRED CONFIG) diff --git a/recipes/frugally-deep/all/test_package/conanfile.py b/recipes/frugally-deep/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/frugally-deep/all/test_package/conanfile.py +++ b/recipes/frugally-deep/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/frugally-deep/all/test_v1_package/CMakeLists.txt b/recipes/frugally-deep/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/frugally-deep/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/frugally-deep/all/test_v1_package/conanfile.py b/recipes/frugally-deep/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/frugally-deep/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From ef547a5a9618cc3c2e73bbb9b6d082da8ed70ff4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 18 Sep 2023 16:55:03 +0300 Subject: [PATCH 0676/1140] (#18261) platform.converters: migrate to Conan v2 * platform.converters: migrate to Conan v2 * platform.converters: restore test_v1_package * platform.converters: restore VirtualRunEnv in test_package --- recipes/platform.converters/all/conanfile.py | 73 ++++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 21 ++++-- .../all/test_package/test_package.cpp | 4 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++++ 6 files changed, 84 insertions(+), 46 deletions(-) create mode 100644 recipes/platform.converters/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/platform.converters/all/test_v1_package/conanfile.py diff --git a/recipes/platform.converters/all/conanfile.py b/recipes/platform.converters/all/conanfile.py index 4991da89bae2cc..2979e31430f9ba 100644 --- a/recipes/platform.converters/all/conanfile.py +++ b/recipes/platform.converters/all/conanfile.py @@ -1,28 +1,30 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class PlatformConvertersConan(ConanFile): name = "platform.converters" + description = "platform.converters is one of the libraries of the LinksPlatform modular framework, to provide conversions between different types" license = "MIT" - homepage = "https://github.com/linksplatform/Converters" url = "https://github.com/conan-io/conan-center-index" - description = "platform.converters is one of the libraries of the LinksPlatform modular framework, " \ - "to provide conversions between different types" - topics = ("linksplatform", "cpp20", "converters", "any", "native") - settings = "compiler", "arch" - no_copy_source = True + homepage = "https://github.com/linksplatform/Converters" + topics = ("linksplatform", "cpp20", "converters", "any", "native", "header-only") - @property - def _source_subfolder(self): - return "source_subfolder" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True @property - def _internal_cpp_subfolder(self): - return os.path.join(self._source_subfolder, "cpp", "Platform.Converters") + def _minimum_cpp_standard(self): + return 20 @property def _compilers_minimum_version(self): @@ -30,36 +32,41 @@ def _compilers_minimum_version(self): "gcc": "10", "Visual Studio": "16", "clang": "14", - "apple-clang": "14" + "apple-clang": "14", } - @property - def _minimum_cpp_standard(self): - return 20 + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def validate(self): minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) if not minimum_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) + self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") - elif tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{}/{} requires c++{}, " - "which is not supported by {} {}.".format( - self.name, self.version, self._minimum_cpp_standard, self.settings.compiler, - self.settings.compiler.version)) + elif Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.name}/{self.version} requires c++{self._minimum_cpp_standard}, " + f"which is not supported by {self.settings.compiler} {self.settings.compiler.version}." + ) if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, self._minimum_cpp_standard) - - def package_id(self): - self.info.header_only() + check_min_cppstd(self, self._minimum_cpp_standard) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + @property + def _internal_cpp_subfolder(self): + return os.path.join(self.source_folder, "cpp", "Platform.Converters") def package(self): - self.copy("*.h", dst="include", src=self._internal_cpp_subfolder) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*.h", dst=os.path.join(self.package_folder, "include"), src=self._internal_cpp_subfolder) + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/platform.converters/all/test_package/CMakeLists.txt b/recipes/platform.converters/all/test_package/CMakeLists.txt index 80c8108b7c3f74..3372d3e73b1861 100644 --- a/recipes/platform.converters/all/test_package/CMakeLists.txt +++ b/recipes/platform.converters/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(platform.converters CONFIG REQUIRED) +find_package(platform.converters REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} platform.converters::platform.converters) diff --git a/recipes/platform.converters/all/test_package/conanfile.py b/recipes/platform.converters/all/test_package/conanfile.py index 49a3a66ea5bad4..ef5d7042163ecc 100644 --- a/recipes/platform.converters/all/test_package/conanfile.py +++ b/recipes/platform.converters/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/platform.converters/all/test_package/test_package.cpp b/recipes/platform.converters/all/test_package/test_package.cpp index 283e7f59b558b9..47a24cfe4903b6 100644 --- a/recipes/platform.converters/all/test_package/test_package.cpp +++ b/recipes/platform.converters/all/test_package/test_package.cpp @@ -5,8 +5,8 @@ using namespace Platform::Converters; int main() { - int source {48}; + int source{48}; char to = Converter::Convert(source); - std::cout<<"int value: "< Date: Mon, 18 Sep 2023 17:55:52 +0300 Subject: [PATCH 0677/1140] (#18264) ctpg: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * ctpg: migrate to Conan v2 * ctpg: restore test_v1_package * ctpg: drop older versions * ctpg: set correct min compiler versions * ctpg: enable MSVC builds * Remove old version checks --------- Co-authored-by: Rubén Rincón Blanco --- recipes/ctpg/all/conandata.yml | 6 -- recipes/ctpg/all/conanfile.py | 86 +++++++++++-------- recipes/ctpg/all/test_package/CMakeLists.txt | 8 +- recipes/ctpg/all/test_package/conanfile.py | 28 ++++-- .../ctpg/all/test_package/test_package.cpp | 8 +- .../ctpg/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/ctpg/all/test_v1_package/conanfile.py | 17 ++++ recipes/ctpg/config.yml | 4 - 8 files changed, 99 insertions(+), 66 deletions(-) create mode 100644 recipes/ctpg/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/ctpg/all/test_v1_package/conanfile.py diff --git a/recipes/ctpg/all/conandata.yml b/recipes/ctpg/all/conandata.yml index e352628a7b1dd7..35ba92c0e04759 100644 --- a/recipes/ctpg/all/conandata.yml +++ b/recipes/ctpg/all/conandata.yml @@ -2,9 +2,3 @@ sources: "1.3.7": url: "https://github.com/peter-winter/ctpg/archive/refs/tags/v1.3.7.tar.gz" sha256: "6cc7c34de4983e21070599fd5693b65ef08cd5c8f42612e43b47eda723623429" - "1.3.6": - url: "https://github.com/peter-winter/ctpg/archive/refs/tags/v1.3.6.tar.gz" - sha256: "8ad5e06ab551fe30ff10faf6b53b85c862a873e3827505d5f5b63aae2b836ba2" - "1.3.5": - url: "https://github.com/peter-winter/ctpg/archive/refs/tags/v1.3.5.tar.gz" - sha256: "6874e71aecace33a07dd202c5c6c53277653d54daa13b460f4e1eb5b0c902d42" diff --git a/recipes/ctpg/all/conanfile.py b/recipes/ctpg/all/conanfile.py index bd69eefe8c5a2e..6e511a34160b52 100644 --- a/recipes/ctpg/all/conanfile.py +++ b/recipes/ctpg/all/conanfile.py @@ -1,59 +1,73 @@ -from conans.errors import ConanInvalidConfiguration -from conans import ConanFile, tools import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" + class CTPGConan(ConanFile): name = "ctpg" - license = "MIT" description = ( "Compile Time Parser Generator is a C++ single header library which takes a language description as a C++ code " "and turns it into a LR1 table parser with a deterministic finite automaton lexical analyzer, all in compile time." ) - topics = ("regex", "parser", "grammar", "compile-time") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/peter-winter/ctpg" - settings = "compiler", + topics = ("regex", "parser", "grammar", "compile-time", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True - _compiler_required_cpp17 = { - "Visual Studio": "16", - "gcc": "8", - "clang": "12", - "apple-clang": "12.0", - } + @property + def _min_cppstd(self): + return 17 @property - def _source_subfolder(self): - return "source_subfolder" + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "12", + "apple-clang": "12.0", + "msvc": "192", + "Visual Studio": "16", + } - def validate(self): - ## TODO: In ctpg<=1.3.5, Visual Studio C++ failed to compile ctpg with "error MSB6006: "CL.exe" exited with code -1073741571." - if self.settings.compiler == "Visual Studio": - raise ConanInvalidConfiguration("{} does not support Visual Studio currently.".format(self.name)) + def layout(self): + basic_layout(self, src_folder="src") - if self.settings.get_safe("compiler.cppstd"): - tools.check_min_cppstd(self, "17") + def package_id(self): + self.info.clear() - minimum_version = self._compiler_required_cpp17.get(str(self.settings.compiler), False) - if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{} requires C++17, which your compiler does not support.".format(self.name)) - else: - self.output.warn("{} requires C++17. Your compiler is unknown. Assuming it supports C++17.".format(self.name)) + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) - def package_id(self): - self.info.header_only() + 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): - tools.get(**self.conan_data["sources"][self.version], destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("LICENSE*", "licenses", self._source_subfolder) - if tools.Version(self.version) >= "1.3.7": - self.copy("ctpg.hpp", - os.path.join("include", "ctpg"), - os.path.join(self._source_subfolder, "include", "ctpg")) - else: - self.copy("ctpg.hpp", "include", os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE*", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + include_dir = os.path.join("include", "ctpg") + copy(self, "ctpg.hpp", + dst=os.path.join(self.package_folder, include_dir), + src=os.path.join(self.source_folder, include_dir)) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/ctpg/all/test_package/CMakeLists.txt b/recipes/ctpg/all/test_package/CMakeLists.txt index b09bb90b2f88d4..72fdf15fd58d71 100644 --- a/recipes/ctpg/all/test_package/CMakeLists.txt +++ b/recipes/ctpg/all/test_package/CMakeLists.txt @@ -1,17 +1,11 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(ctpg CONFIG REQUIRED) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} ctpg::ctpg) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) -if(CTPG_PLACED_CPTG_FOLDER) - target_compile_definitions(${PROJECT_NAME} PUBLIC CTPG_PLACED_CPTG_FOLDER) -endif() if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "MSVC") target_compile_options(${PROJECT_NAME} PUBLIC -constexpr:depth3000000) diff --git a/recipes/ctpg/all/test_package/conanfile.py b/recipes/ctpg/all/test_package/conanfile.py index 34c01340114eff..c5591f2deebdb2 100644 --- a/recipes/ctpg/all/test_package/conanfile.py +++ b/recipes/ctpg/all/test_package/conanfile.py @@ -1,18 +1,32 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake, CMakeToolchain, CMakeDeps +from conan.tools.scm import Version import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): cmake = CMake(self) - cmake.definitions["CTPG_PLACED_CPTG_FOLDER"] = tools.Version(self.deps_cpp_info["ctpg"].version) >= "1.3.7" cmake.configure() cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/ctpg/all/test_package/test_package.cpp b/recipes/ctpg/all/test_package/test_package.cpp index bcd377f23cbd81..0d99b97395ccd2 100644 --- a/recipes/ctpg/all/test_package/test_package.cpp +++ b/recipes/ctpg/all/test_package/test_package.cpp @@ -1,8 +1,4 @@ -#ifdef CTPG_PLACED_CPTG_FOLDER -# include "ctpg/ctpg.hpp" -#else -# include "ctpg.hpp" -#endif +#include "ctpg/ctpg.hpp" #include @@ -28,7 +24,7 @@ constexpr ctpg::parser p( ) ); -int main(int argc, char* argv[]) { +int main() { auto res = p.parse(ctpg::buffers::string_buffer("10, 20, 30"), std::cerr); bool success = res.has_value(); if (success) diff --git a/recipes/ctpg/all/test_v1_package/CMakeLists.txt b/recipes/ctpg/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/ctpg/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/ctpg/all/test_v1_package/conanfile.py b/recipes/ctpg/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..90eb89e3f2f46b --- /dev/null +++ b/recipes/ctpg/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/ctpg/config.yml b/recipes/ctpg/config.yml index 3da45bc7782505..fba76735a90139 100644 --- a/recipes/ctpg/config.yml +++ b/recipes/ctpg/config.yml @@ -1,7 +1,3 @@ versions: "1.3.7": folder: all - "1.3.6": - folder: all - "1.3.5": - folder: all From e23c7ef6c16cc0cb89e2370f7a05286c9eb5dec0 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 18 Sep 2023 20:01:08 +0300 Subject: [PATCH 0678/1140] (#18273) seqan3: migrate to Conan v2 * seqan3: migrate to Conan v2 * seqan3: restore test_v1_package * seqan3: restore VirtualRunEnv in test_package --- recipes/seqan3/all/conanfile.py | 55 +++++++++++-------- .../seqan3/all/test_package/CMakeLists.txt | 5 +- recipes/seqan3/all/test_package/conanfile.py | 19 +++++-- .../seqan3/all/test_v1_package/CMakeLists.txt | 8 +++ .../seqan3/all/test_v1_package/conanfile.py | 17 ++++++ 5 files changed, 72 insertions(+), 32 deletions(-) create mode 100644 recipes/seqan3/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/seqan3/all/test_v1_package/conanfile.py diff --git a/recipes/seqan3/all/conanfile.py b/recipes/seqan3/all/conanfile.py index ef55f38b024ff0..10b57ed42fdf79 100644 --- a/recipes/seqan3/all/conanfile.py +++ b/recipes/seqan3/all/conanfile.py @@ -1,60 +1,69 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class Seqan3Conan(ConanFile): name = "seqan3" - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://github.com/seqan/seqan3" description = "SeqAn3 is the new version of the popular SeqAn template library for the analysis of biological sequences." - topics = ("cpp20", "algorithms", "data structures", "biological sequences") license = "BSD-3-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/seqan/seqan3" + topics = ("cpp20", "algorithms", "data structures", "biological sequences", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 20 @property def _compilers_minimum_version(self): - return { - "gcc": "10", - } + return {"gcc": "10"} + + def layout(self): + basic_layout(self, src_folder="src") def package_id(self): - self.info.header_only() + self.info.clear() def validate(self): if self.settings.compiler != "gcc": raise ConanInvalidConfiguration("SeqAn3 only supports GCC.") if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 20) + check_min_cppstd(self, self._min_cppstd) + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: + if Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration("SeqAn3 requires C++20, which your compiler does not fully support.") else: - self.output.warn("SeqAn3 requires C++20. Your compiler is unknown. Assuming it supports C++20.") + self.output.warning("SeqAn3 requires C++20. Your compiler is unknown. Assuming it supports C++20.") if self.settings.compiler == "gcc" and self.settings.compiler.libcxx != "libstdc++11": - self.output.warn("SeqAn3 does not actively support libstdc++, consider using libstdc++11 instead.") + self.output.warning("SeqAn3 does not actively support libstdc++, consider using libstdc++11 instead.") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*", dst="include", - src=os.path.join(self._source_subfolder, "include"), keep_path=True) + copy(self, "*", dst=os.path.join(self.package_folder, "include"), src=os.path.join(self.source_folder, "include"), keep_path=True) + copy(self, "LICENSE.md", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) for submodule in ["range-v3", "cereal", "sdsl-lite"]: - self.copy("*.hpp", dst="include", - src=os.path.join(self._source_subfolder, "submodules", submodule, "include"), keep_path=True) - self.copy("LICENSE.md", dst="licenses", src=self._source_subfolder) + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "submodules", submodule, "include"), + keep_path=True) def package_info(self): self.cpp_info.set_property("cmake_file_name", "seqan3") diff --git a/recipes/seqan3/all/test_package/CMakeLists.txt b/recipes/seqan3/all/test_package/CMakeLists.txt index 8c21ec19c63842..11e58315f3f7e9 100644 --- a/recipes/seqan3/all/test_package/CMakeLists.txt +++ b/recipes/seqan3/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.12) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(seqan3 REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/seqan3/all/test_package/conanfile.py b/recipes/seqan3/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/seqan3/all/test_package/conanfile.py +++ b/recipes/seqan3/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/seqan3/all/test_v1_package/CMakeLists.txt b/recipes/seqan3/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/seqan3/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/seqan3/all/test_v1_package/conanfile.py b/recipes/seqan3/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/seqan3/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From a2799ed2fe7231cd19a9942b434bef328545e4fe Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 04:00:12 +0900 Subject: [PATCH 0679/1140] (#19721) lazycsv: add recipe * lazycsv: add recipe * drop support msvc --- recipes/lazycsv/all/conandata.yml | 4 ++ recipes/lazycsv/all/conanfile.py | 72 +++++++++++++++++++ .../lazycsv/all/test_package/CMakeLists.txt | 8 +++ recipes/lazycsv/all/test_package/conanfile.py | 26 +++++++ .../lazycsv/all/test_package/test_package.cpp | 10 +++ recipes/lazycsv/config.yml | 3 + 6 files changed, 123 insertions(+) create mode 100644 recipes/lazycsv/all/conandata.yml create mode 100644 recipes/lazycsv/all/conanfile.py create mode 100644 recipes/lazycsv/all/test_package/CMakeLists.txt create mode 100644 recipes/lazycsv/all/test_package/conanfile.py create mode 100644 recipes/lazycsv/all/test_package/test_package.cpp create mode 100644 recipes/lazycsv/config.yml diff --git a/recipes/lazycsv/all/conandata.yml b/recipes/lazycsv/all/conandata.yml new file mode 100644 index 00000000000000..1f9c6533da7ceb --- /dev/null +++ b/recipes/lazycsv/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "cci.20221117": + url: "https://github.com/ashtum/lazycsv/archive/844e3f318af2d9ede96039dd9f57ebf4cad59ce2.tar.gz" + sha256: "cb8592fc0b563a1236dfadfc423a91d63e705ff0086941218800abda22530540" diff --git a/recipes/lazycsv/all/conanfile.py b/recipes/lazycsv/all/conanfile.py new file mode 100644 index 00000000000000..f0f8f490335f92 --- /dev/null +++ b/recipes/lazycsv/all/conanfile.py @@ -0,0 +1,72 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc +import os + + +required_conan_version = ">=1.52.0" + + +class LazyCSVConan(ConanFile): + name = "lazycsv" + description = "A fast, lightweight and single-header C++ csv parser library" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ashtum/lazycsv" + topics = ("csv", "csv-parser", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + } + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("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." + ) + if is_msvc(self): + raise ConanInvalidConfiguration( + f"{self.ref} doen't support MSVC." + ) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/lazycsv/all/test_package/CMakeLists.txt b/recipes/lazycsv/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..655f63d80bdcf5 --- /dev/null +++ b/recipes/lazycsv/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(lazycsv REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE lazycsv::lazycsv) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/lazycsv/all/test_package/conanfile.py b/recipes/lazycsv/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/lazycsv/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/lazycsv/all/test_package/test_package.cpp b/recipes/lazycsv/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..c0e33ee18739a8 --- /dev/null +++ b/recipes/lazycsv/all/test_package/test_package.cpp @@ -0,0 +1,10 @@ +#include +#include "lazycsv.hpp" + + +int main(void) { + std::string csv_data{ "name,lastname,age\nPeter,Griffin,45\nchris,Griffin,14\n" }; + + lazycsv::parser parser_a{ csv_data }; + lazycsv::parser parser_b{ csv_data }; +} diff --git a/recipes/lazycsv/config.yml b/recipes/lazycsv/config.yml new file mode 100644 index 00000000000000..4d61dda20e41ab --- /dev/null +++ b/recipes/lazycsv/config.yml @@ -0,0 +1,3 @@ +versions: + "cci.20221117": + folder: all From 4cea876070e9ebaedd6b089b30c9788f6683f49f Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 05:09:44 +0900 Subject: [PATCH 0680/1140] (#19722) ssp: add recipe --- recipes/ssp/all/conandata.yml | 4 ++ recipes/ssp/all/conanfile.py | 68 +++++++++++++++++++ recipes/ssp/all/test_package/CMakeLists.txt | 8 +++ recipes/ssp/all/test_package/conanfile.py | 26 +++++++ recipes/ssp/all/test_package/test_package.cpp | 12 ++++ recipes/ssp/config.yml | 3 + 6 files changed, 121 insertions(+) create mode 100644 recipes/ssp/all/conandata.yml create mode 100644 recipes/ssp/all/conanfile.py create mode 100644 recipes/ssp/all/test_package/CMakeLists.txt create mode 100644 recipes/ssp/all/test_package/conanfile.py create mode 100644 recipes/ssp/all/test_package/test_package.cpp create mode 100644 recipes/ssp/config.yml diff --git a/recipes/ssp/all/conandata.yml b/recipes/ssp/all/conandata.yml new file mode 100644 index 00000000000000..72dce2c480ffe4 --- /dev/null +++ b/recipes/ssp/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.6.1": + url: "https://github.com/red0124/ssp/archive/refs/tags/v1.6.1.tar.gz" + sha256: "4cdf75959b0a5fabd0b3e6ec1bad41d7c3f298d5b7f822d6e12b7e4d7dfcdd34" diff --git a/recipes/ssp/all/conanfile.py b/recipes/ssp/all/conanfile.py new file mode 100644 index 00000000000000..7d75955713fe5e --- /dev/null +++ b/recipes/ssp/all/conanfile.py @@ -0,0 +1,68 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.scm import Version +import os + +required_conan_version = ">=1.52.0" + +class SspConan(ConanFile): + name = "ssp" + description = "C++ CSV parser" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/red0124/ssp" + topics = ("csv", "parser", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + } + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("fast_float/5.2.0") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("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) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/ssp/all/test_package/CMakeLists.txt b/recipes/ssp/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..16a9ddec507217 --- /dev/null +++ b/recipes/ssp/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) + +find_package(ssp REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE ssp::ssp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/ssp/all/test_package/conanfile.py b/recipes/ssp/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e845ae751a3017 --- /dev/null +++ b/recipes/ssp/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/ssp/all/test_package/test_package.cpp b/recipes/ssp/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..f3a0c45ba85136 --- /dev/null +++ b/recipes/ssp/all/test_package/test_package.cpp @@ -0,0 +1,12 @@ +#include "ss/converter.hpp" + +int main() { + auto converter = ss::converter{}; + + auto val = converter.convert("5"); + + if (val == 5) { + return 0; + } + return 1; +} diff --git a/recipes/ssp/config.yml b/recipes/ssp/config.yml new file mode 100644 index 00000000000000..bd3f43d241a52a --- /dev/null +++ b/recipes/ssp/config.yml @@ -0,0 +1,3 @@ +versions: + "1.6.1": + folder: all From c3a7de8bba4b18a75c3e0469981fd255d63c565e Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 06:31:32 +0900 Subject: [PATCH 0681/1140] (#19794) stringzilla: add recipe * stringzilla: add recipe * require C++11 --- recipes/stringzilla/all/conandata.yml | 4 ++ recipes/stringzilla/all/conanfile.py | 48 +++++++++++++++++++ .../all/test_package/CMakeLists.txt | 8 ++++ .../stringzilla/all/test_package/conanfile.py | 26 ++++++++++ .../all/test_package/test_package.cpp | 24 ++++++++++ recipes/stringzilla/config.yml | 3 ++ 6 files changed, 113 insertions(+) create mode 100644 recipes/stringzilla/all/conandata.yml create mode 100644 recipes/stringzilla/all/conanfile.py create mode 100644 recipes/stringzilla/all/test_package/CMakeLists.txt create mode 100644 recipes/stringzilla/all/test_package/conanfile.py create mode 100644 recipes/stringzilla/all/test_package/test_package.cpp create mode 100644 recipes/stringzilla/config.yml diff --git a/recipes/stringzilla/all/conandata.yml b/recipes/stringzilla/all/conandata.yml new file mode 100644 index 00000000000000..f529350a7dc33f --- /dev/null +++ b/recipes/stringzilla/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.1.3": + url: "https://github.com/ashvardanian/StringZilla/archive/refs/tags/v1.1.3.tar.gz" + sha256: "1856c4d780b2c9a12ccd14d04996b35bec9fe537d0a31209000e12777a86e495" diff --git a/recipes/stringzilla/all/conanfile.py b/recipes/stringzilla/all/conanfile.py new file mode 100644 index 00000000000000..bded9fa3b64265 --- /dev/null +++ b/recipes/stringzilla/all/conanfile.py @@ -0,0 +1,48 @@ +from conan import ConanFile +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.build import check_min_cppstd +import os + +required_conan_version = ">=1.52.0" + +class StringZillaConan(ConanFile): + name = "stringzilla" + description = "Fastest string sort, search, split, and shuffle for long strings and multi-gigabyte files in Python and C, leveraging SIMD with Arm Neon and x86 AVX2 & AVX-512 intrinsics." + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ashvardanian/StringZilla/" + topics = ("string", "simd", "sse", "avx", "neon", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "stringzilla"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/stringzilla/all/test_package/CMakeLists.txt b/recipes/stringzilla/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..c0e457af6c08c0 --- /dev/null +++ b/recipes/stringzilla/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(stringzilla REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE stringzilla::stringzilla) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/stringzilla/all/test_package/conanfile.py b/recipes/stringzilla/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/stringzilla/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/stringzilla/all/test_package/test_package.cpp b/recipes/stringzilla/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..6725fc782db3f8 --- /dev/null +++ b/recipes/stringzilla/all/test_package/test_package.cpp @@ -0,0 +1,24 @@ +#include +#include +#include "stringzilla.h" + +int main(void) { + // Initialize your haystack and needle + strzl_haystack_t haystack = { + "Fastest string sort, search, split, " + "and shuffle for long strings and multi-gigabyte files in Python and C, " + "leveraging SIMD with Arm Neon and x86 AVX2 & AVX-512 intrinsics.", + 171}; + strzl_needle_t needle = {"SIMD", 4}; + + // Count occurrences of a character like a boss 😎 + size_t count = strzl_naive_count_char(haystack, 'a'); + + // Find a character like you're searching for treasure 🏴‍☠️ + size_t position = strzl_naive_find_char(haystack, 'a'); + + // Find a substring like it's Waldo 🕵️‍♂️ + size_t substring_position = strzl_naive_find_substr(haystack, needle); + + return EXIT_SUCCESS; +} diff --git a/recipes/stringzilla/config.yml b/recipes/stringzilla/config.yml new file mode 100644 index 00000000000000..e1c4f3be249832 --- /dev/null +++ b/recipes/stringzilla/config.yml @@ -0,0 +1,3 @@ +versions: + "1.1.3": + folder: all From db4a7574cb60ad600cf42e8007edaac4a2a68d92 Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 07:44:09 +0900 Subject: [PATCH 0682/1140] (#19817) xtensor: add version 0.24.6 --- recipes/xtensor/all/conandata.yml | 3 +++ recipes/xtensor/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/xtensor/all/conandata.yml b/recipes/xtensor/all/conandata.yml index 40af805ba9e936..ab5f555ceae44f 100644 --- a/recipes/xtensor/all/conandata.yml +++ b/recipes/xtensor/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.24.6": + url: "https://github.com/xtensor-stack/xtensor/archive/0.24.6.tar.gz" + sha256: "f87259b51aabafdd1183947747edfff4cff75d55375334f2e81cee6dc68ef655" "0.24.3": url: "https://github.com/xtensor-stack/xtensor/archive/0.24.3.tar.gz" sha256: "3acde856b9fb8cf4e2a7b66726da541275d40ab9b002e618ad985ab97f08ca4f" diff --git a/recipes/xtensor/config.yml b/recipes/xtensor/config.yml index 0077748f19ef00..414a96bb9536c9 100644 --- a/recipes/xtensor/config.yml +++ b/recipes/xtensor/config.yml @@ -1,4 +1,6 @@ versions: + "0.24.6": + folder: all "0.24.3": folder: all "0.24.2": From 00ffde026a8af5308792682d309c669eee49e05c Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Tue, 19 Sep 2023 01:00:55 +0200 Subject: [PATCH 0683/1140] (#19832) cryptopp 8.8.0 --- recipes/cryptopp/all/conandata.yml | 7 +++++++ recipes/cryptopp/all/conanfile.py | 1 + recipes/cryptopp/config.yml | 2 ++ 3 files changed, 10 insertions(+) diff --git a/recipes/cryptopp/all/conandata.yml b/recipes/cryptopp/all/conandata.yml index 2bc29cced3bfe2..8b52a60c80d57e 100644 --- a/recipes/cryptopp/all/conandata.yml +++ b/recipes/cryptopp/all/conandata.yml @@ -1,4 +1,11 @@ sources: + "8.8.0": + source: + url: "https://github.com/weidai11/cryptopp/archive/CRYPTOPP_8_8_0.tar.gz" + sha256: "f8b8f632533b279ee297694e651e9204824bba6022ce66e60ebebb08b551fe7a" + cmake: + url: "https://github.com/abdes/cryptopp-cmake/archive/CRYPTOPP_8_8_0.tar.gz" + sha256: "a10068ab47fb46785dfe43ebe45369008855b03f6711ac7d1af6f45aa9238290" "8.7.0": source: url: "https://github.com/weidai11/cryptopp/archive/CRYPTOPP_8_7_0.tar.gz" diff --git a/recipes/cryptopp/all/conanfile.py b/recipes/cryptopp/all/conanfile.py index f16bdf4f4f23d6..d61c97a23b4e49 100644 --- a/recipes/cryptopp/all/conanfile.py +++ b/recipes/cryptopp/all/conanfile.py @@ -97,6 +97,7 @@ def generate(self): tc.cache_variables["CRYPTOPP_USE_INTERMEDIATE_OBJECTS_TARGET"] = False if self.settings.os == "Android": tc.cache_variables["CRYPTOPP_NATIVE_ARCH"] = True + tc.cache_variables["CMAKE_DISABLE_FIND_PACKAGE_Git"] = True tc.generate() def _patch_sources(self): diff --git a/recipes/cryptopp/config.yml b/recipes/cryptopp/config.yml index 0cf6dab66b6c74..58c17b09dbebf5 100644 --- a/recipes/cryptopp/config.yml +++ b/recipes/cryptopp/config.yml @@ -1,4 +1,6 @@ versions: + "8.8.0": + folder: "all" "8.7.0": folder: "all" "8.6.0": From 5186653276f517b3098b36d66675f73ca50a2de8 Mon Sep 17 00:00:00 2001 From: Joakim Haugen Date: Tue, 19 Sep 2023 02:15:53 +0200 Subject: [PATCH 0684/1140] (#19834) fmi2: add new recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fmi2: add new recipe version 2.0.4 * Update recipes/fmi2/all/conandata.yml --------- Co-authored-by: Rubén Rincón Blanco --- recipes/fmi2/all/conandata.yml | 5 ++ recipes/fmi2/all/conanfile.py | 50 +++++++++++++++++++ recipes/fmi2/all/test_package/CMakeLists.txt | 7 +++ recipes/fmi2/all/test_package/conanfile.py | 25 ++++++++++ .../fmi2/all/test_package/test_package.cpp | 10 ++++ recipes/fmi2/config.yml | 3 ++ 6 files changed, 100 insertions(+) create mode 100644 recipes/fmi2/all/conandata.yml create mode 100644 recipes/fmi2/all/conanfile.py create mode 100644 recipes/fmi2/all/test_package/CMakeLists.txt create mode 100644 recipes/fmi2/all/test_package/conanfile.py create mode 100644 recipes/fmi2/all/test_package/test_package.cpp create mode 100644 recipes/fmi2/config.yml diff --git a/recipes/fmi2/all/conandata.yml b/recipes/fmi2/all/conandata.yml new file mode 100644 index 00000000000000..ca22c244cd704b --- /dev/null +++ b/recipes/fmi2/all/conandata.yml @@ -0,0 +1,5 @@ +sources: + "2.0.4": + url: + - https://github.com/modelica/fmi-standard/releases/download/v2.0.4/FMI-Standard-2.0.4.zip + sha256: "79abb211052d28354a0efff0c6b1998b60a973dd75fdcb338db99ae1b970c9b2" diff --git a/recipes/fmi2/all/conanfile.py b/recipes/fmi2/all/conanfile.py new file mode 100644 index 00000000000000..816be50f782afd --- /dev/null +++ b/recipes/fmi2/all/conanfile.py @@ -0,0 +1,50 @@ +from os import path +from conan import ConanFile +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + + +class PackageConan(ConanFile): + name = "fmi2" + description = "Functional Mock-up Interface (FMI)" + license = "BSD-2-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://fmi-standard.org" + topics = ("fmi-standard", "co-simulation", "model-exchange", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=False) + + def build(self): + pass + + def package(self): + copy(self, pattern="LICENSE.txt", dst=path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.h", + src=path.join(self.source_folder, "headers"), + dst=path.join(self.package_folder, "include"), + ) + copy( + self, + pattern="*.xsd", + src=path.join(self.source_folder, "schema"), + dst=path.join(self.package_folder, "res"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = ["res"] diff --git a/recipes/fmi2/all/test_package/CMakeLists.txt b/recipes/fmi2/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..7332dbc8b51974 --- /dev/null +++ b/recipes/fmi2/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C CXX) + +find_package(fmi2 REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE fmi2::fmi2) diff --git a/recipes/fmi2/all/test_package/conanfile.py b/recipes/fmi2/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e730ad6dc0dfc1 --- /dev/null +++ b/recipes/fmi2/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fmi2/all/test_package/test_package.cpp b/recipes/fmi2/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..ec96970349ed1d --- /dev/null +++ b/recipes/fmi2/all/test_package/test_package.cpp @@ -0,0 +1,10 @@ +#include +#include +#include "fmi2Functions.h" + + +int main(void) { + std::cout << fmi2Version << std::endl; + + return EXIT_SUCCESS; +} diff --git a/recipes/fmi2/config.yml b/recipes/fmi2/config.yml new file mode 100644 index 00000000000000..1f2301f1f0282d --- /dev/null +++ b/recipes/fmi2/config.yml @@ -0,0 +1,3 @@ +versions: + "2.0.4": + folder: all From 7471eda2c1afa9616072918d4b8a44a9b0241c66 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 02:55:04 +0200 Subject: [PATCH 0685/1140] (#19845) valijson: add package_type + simplify & fix test package * add package_type * simplify test package * bump nlohmann_json & rapidjson in test package * Revert "bump nlohmann_json & rapidjson in test package" This reverts commit 956dc2c05f28424036912dc8c39bf060bc513938. * fix test v1 package --- recipes/valijson/all/conanfile.py | 10 ++++++---- recipes/valijson/all/test_package/CMakeLists.txt | 12 ++++++------ recipes/valijson/all/test_package/conanfile.py | 13 +++++-------- .../valijson/all/test_v1_package/CMakeLists.txt | 10 +++++----- recipes/valijson/all/test_v1_package/conanfile.py | 15 ++++++--------- 5 files changed, 28 insertions(+), 32 deletions(-) diff --git a/recipes/valijson/all/conanfile.py b/recipes/valijson/all/conanfile.py index 4c1f0676480adf..9e8080a170f305 100644 --- a/recipes/valijson/all/conanfile.py +++ b/recipes/valijson/all/conanfile.py @@ -13,6 +13,7 @@ class ValijsonConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/tristanpenman/valijson" topics = ("json", "validator", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -31,7 +32,7 @@ def validate(self): check_min_cppstd(self, self._min_cppstd) def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass @@ -46,12 +47,10 @@ def package(self): ) def package_info(self): + self.cpp_info.set_property("cmake_target_name", "ValiJSON::valijson") self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - self.cpp_info.set_property("cmake_target_name", "ValiJSON::valijson") - self.cpp_info.components["libvalijson"].set_property("cmake_target_name", "ValiJSON::valijson") - # TODO: to remove in conan v2 once cmake_find_package_* generators removed # self.cpp_info.filenames["cmake_find_package"] = "valijson" # TBA: There's no installed config file # self.cpp_info.filenames["cmake_find_package_multi"] = "valijson" # TBA: There's no installed config file @@ -59,3 +58,6 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "ValiJSON" self.cpp_info.components["libvalijson"].names["cmake_find_package"] = "valijson" self.cpp_info.components["libvalijson"].names["cmake_find_package_multi"] = "valijson" + self.cpp_info.components["libvalijson"].set_property("cmake_target_name", "ValiJSON::valijson") + self.cpp_info.components["libvalijson"].bindirs = [] + self.cpp_info.components["libvalijson"].libdirs = [] diff --git a/recipes/valijson/all/test_package/CMakeLists.txt b/recipes/valijson/all/test_package/CMakeLists.txt index f283c4c7cf92c1..9fa0294a2d6c6e 100644 --- a/recipes/valijson/all/test_package/CMakeLists.txt +++ b/recipes/valijson/all/test_package/CMakeLists.txt @@ -8,11 +8,11 @@ find_package(RapidJSON REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries( - ${PROJECT_NAME} - PRIVATE - ValiJSON::valijson - nlohmann_json::nlohmann_json - picojson::picojson - rapidjson + ${PROJECT_NAME} + PRIVATE + ValiJSON::valijson + nlohmann_json::nlohmann_json + picojson::picojson + rapidjson ) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/valijson/all/test_package/conanfile.py b/recipes/valijson/all/test_package/conanfile.py index 44512632f983b5..81b93054985f72 100644 --- a/recipes/valijson/all/test_package/conanfile.py +++ b/recipes/valijson/all/test_package/conanfile.py @@ -12,7 +12,7 @@ def layout(self): cmake_layout(self) def requirements(self): - self.requires("nlohmann_json/3.9.1") + self.requires("nlohmann_json/3.11.2") self.requires("rapidjson/cci.20200410") self.requires("picojson/1.3.0") self.requires(self.tested_reference_str) @@ -25,10 +25,7 @@ def build(self): def test(self): if can_run(self): bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") - schema_file = os.path.abspath(os.path.join(self.source_folder, "schema.json")) - valid_file = os.path.abspath(os.path.join(self.source_folder, "valid.json")) - invalid_file = os.path.abspath(os.path.join(self.source_folder, "invalid.json")) - self.run( - "{} {} {} {}".format(bin_path, schema_file, valid_file, invalid_file), - run_environment=True - ) + schema_file = os.path.join(self.source_folder, "schema.json") + valid_file = os.path.join(self.source_folder, "valid.json") + invalid_file = os.path.join(self.source_folder, "invalid.json") + self.run(f"{bin_path} {schema_file} {valid_file} {invalid_file}", env="conanrun") diff --git a/recipes/valijson/all/test_v1_package/CMakeLists.txt b/recipes/valijson/all/test_v1_package/CMakeLists.txt index 679bcbb3ab1fd1..a2f6329c538d27 100644 --- a/recipes/valijson/all/test_v1_package/CMakeLists.txt +++ b/recipes/valijson/all/test_v1_package/CMakeLists.txt @@ -11,10 +11,10 @@ find_package(RapidJSON REQUIRED CONFIG) add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) target_link_libraries( - ${PROJECT_NAME} - ValiJSON::valijson - nlohmann_json::nlohmann_json - picojson::picojson - RapidJSON::RapidJSON + ${PROJECT_NAME} + ValiJSON::valijson + nlohmann_json::nlohmann_json + picojson::picojson + RapidJSON::RapidJSON ) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/valijson/all/test_v1_package/conanfile.py b/recipes/valijson/all/test_v1_package/conanfile.py index 1ffe3deaeb51c4..f02d6b2bb83203 100644 --- a/recipes/valijson/all/test_v1_package/conanfile.py +++ b/recipes/valijson/all/test_v1_package/conanfile.py @@ -4,7 +4,7 @@ class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package", "cmake_find_package_multi" + generators = "cmake", "cmake_find_package_multi" def build(self): cmake = CMake(self) @@ -12,17 +12,14 @@ def build(self): cmake.build() def requirements(self): - self.requires("nlohmann_json/3.9.1") + self.requires("nlohmann_json/3.11.2") self.requires("rapidjson/cci.20200410") self.requires("picojson/1.3.0") def test(self): if not tools.cross_building(self.settings): bin_path = os.path.join("bin", "test_package") - schema_file = os.path.abspath(os.path.join(self.source_folder, os.pardir, "test_package", "schema.json")) - valid_file = os.path.abspath(os.path.join(self.source_folder, os.pardir, "test_package", "valid.json")) - invalid_file = os.path.abspath(os.path.join(self.source_folder, os.pardir, "test_package", "invalid.json")) - self.run( - "{} {} {} {}".format(bin_path, schema_file, valid_file, invalid_file), - run_environment=True - ) + schema_file = os.path.join(self.source_folder, os.pardir, "test_package", "schema.json") + valid_file = os.path.join(self.source_folder, os.pardir, "test_package", "valid.json") + invalid_file = os.path.join(self.source_folder, os.pardir, "test_package", "invalid.json") + self.run(f"{bin_path} {schema_file} {valid_file} {invalid_file}", run_environment=True) From 58e4fe875bde569a42e2e81fc5394c88608a9f89 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 03:39:38 +0200 Subject: [PATCH 0686/1140] (#19881) vc: add package_type + modernize a little bit more * add package_type & modernize a little bit more * simplify test v1 package --- recipes/vc/all/conanfile.py | 11 +++++------ recipes/vc/all/test_v1_package/CMakeLists.txt | 11 ++++------- 2 files changed, 9 insertions(+), 13 deletions(-) diff --git a/recipes/vc/all/conanfile.py b/recipes/vc/all/conanfile.py index 7cfaddf7b08382..12e8e45ebe604c 100644 --- a/recipes/vc/all/conanfile.py +++ b/recipes/vc/all/conanfile.py @@ -4,17 +4,17 @@ from conan.tools.files import copy, get, replace_in_file, rmdir import os -required_conan_version = ">=1.51.1" +required_conan_version = ">=1.50.0" class VcConan(ConanFile): name = "vc" description = "SIMD Vector Classes for C++." license = "BSD-3-Clause" - topics = ("vc", "simd", "vectorization", "parallel", "sse", "avx", "neon") + topics = ("simd", "vectorization", "parallel", "sse", "avx", "neon") homepage = "https://github.com/VcDevel/Vc" url = "https://github.com/conan-io/conan-center-index" - + package_type = "static-library" settings = "os", "arch", "compiler", "build_type" options = { "fPIC": [True, False], @@ -31,12 +31,11 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.info.settings.compiler.get_safe("cppstd"): + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/vc/all/test_v1_package/CMakeLists.txt b/recipes/vc/all/test_v1_package/CMakeLists.txt index 492877a81dfa86..0d20897301b68b 100644 --- a/recipes/vc/all/test_v1_package/CMakeLists.txt +++ b/recipes/vc/all/test_v1_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package LANGUAGES CXX) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(Vc REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE Vc::Vc) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 3797812abb1af51e1656968b4fb51522ca3663fc Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 11:33:43 +0900 Subject: [PATCH 0687/1140] (#19887) libnl: add version 3.8.0 --- recipes/libnl/all/conandata.yml | 11 ++++++--- recipes/libnl/all/conanfile.py | 44 +++++++++++++++++---------------- recipes/libnl/config.yml | 2 ++ 3 files changed, 32 insertions(+), 25 deletions(-) diff --git a/recipes/libnl/all/conandata.yml b/recipes/libnl/all/conandata.yml index cf3856e1f84ca3..c4437c5cec3bc6 100644 --- a/recipes/libnl/all/conandata.yml +++ b/recipes/libnl/all/conandata.yml @@ -1,7 +1,10 @@ sources: + "3.8.0": + url: "https://github.com/thom311/libnl/releases/download/libnl3_8_0/libnl-3.8.0.tar.gz" + sha256: "bb726c6d7a08b121978d73ff98425bf313fa26a27a331d465e4f1d7ec5b838c6" "3.7.0": - sha256: 9fe43ccbeeea72c653bdcf8c93332583135cda46a79507bfd0a483bb57f65939 - url: https://github.com/thom311/libnl/releases/download/libnl3_7_0/libnl-3.7.0.tar.gz + url: "https://github.com/thom311/libnl/releases/download/libnl3_7_0/libnl-3.7.0.tar.gz" + sha256: "9fe43ccbeeea72c653bdcf8c93332583135cda46a79507bfd0a483bb57f65939" "3.2.25": - sha256: 8beb7590674957b931de6b7f81c530b85dc7c1ad8fbda015398bc1e8d1ce8ec5 - url: https://github.com/thom311/libnl/releases/download/libnl3_2_25/libnl-3.2.25.tar.gz + url: "https://github.com/thom311/libnl/releases/download/libnl3_2_25/libnl-3.2.25.tar.gz" + sha256: "8beb7590674957b931de6b7f81c530b85dc7c1ad8fbda015398bc1e8d1ce8ec5" diff --git a/recipes/libnl/all/conanfile.py b/recipes/libnl/all/conanfile.py index 2dd67d7ee45afd..a355e8b21201e2 100644 --- a/recipes/libnl/all/conanfile.py +++ b/recipes/libnl/all/conanfile.py @@ -7,38 +7,42 @@ required_conan_version = ">=1.53.0" - class LibNlConan(ConanFile): name = "libnl" description = "A collection of libraries providing APIs to netlink protocol based Linux kernel interfaces." - topics = ("netlink") - url = "https://github.com/conan-io/conan-center-index" - homepage = "https://www.infradead.org/~tgr/libnl/" license = "LGPL-2.1-only" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/thom311/libnl" + topics = ("netlink") settings = "os", "arch", "compiler", "build_type" - options = {"fPIC": [True, False], "shared": [True, False]} - default_options = {"fPIC": True, "shared": False} - - def build_requirements(self): - self.tool_requires("bison/3.8.2") - self.tool_requires("flex/2.6.4") - - def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root=True) + options = { + "fPIC": [True, False], + "shared": [True, False], + } + default_options = { + "fPIC": True, + "shared": False, + } def configure(self): if self.options.shared: self.options.rm_safe("fPIC") - # This is a pure C library self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def layout(self): + basic_layout(self, src_folder="src") + def validate(self): if self.settings.os != "Linux": - raise ConanInvalidConfiguration("Libnl is only supported on Linux") + raise ConanInvalidConfiguration(f"{self.ref} is only supported on Linux") - def layout(self): - basic_layout(self, src_folder="src") + def build_requirements(self): + self.tool_requires("bison/3.8.2") + self.tool_requires("flex/2.6.4") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = AutotoolsToolchain(self) @@ -61,8 +65,7 @@ def package(self): def package_info(self): self.cpp_info.components["nl"].libs = ["nl-3"] self.cpp_info.components["nl"].includedirs = [os.path.join('include', 'libnl3')] - if self.settings.os != "Windows": - self.cpp_info.components["nl"].system_libs = ["pthread", "m"] + self.cpp_info.components["nl"].system_libs = ["pthread", "m"] self.cpp_info.components["nl-route"].libs = ["nl-route-3"] self.cpp_info.components["nl-route"].requires = ["nl"] self.cpp_info.components["nl-genl"].libs = ["nl-genl-3"] @@ -71,7 +74,6 @@ def package_info(self): self.cpp_info.components["nl-nf"].requires = ["nl-route"] self.cpp_info.components["nl-cli"].libs = ["nl-cli-3"] self.cpp_info.components["nl-cli"].requires = ["nl-nf", "nl-genl"] - if self.settings.os != "Windows": - self.cpp_info.components["nl-cli"].system_libs = ["dl"] + self.cpp_info.components["nl-cli"].system_libs = ["dl"] self.cpp_info.components["nl-idiag"].libs = ["nl-idiag-3"] self.cpp_info.components["nl-idiag"].requires = ["nl"] diff --git a/recipes/libnl/config.yml b/recipes/libnl/config.yml index 3901cc1eb7ac99..20abb72c5e1b94 100644 --- a/recipes/libnl/config.yml +++ b/recipes/libnl/config.yml @@ -1,4 +1,6 @@ versions: + 3.8.0: + folder: all 3.7.0: folder: all 3.2.25: From 4bbdcd26871a7d16e1ebecd33c0fed3c70ecef06 Mon Sep 17 00:00:00 2001 From: Sergey Bobrenok Date: Tue, 19 Sep 2023 06:12:59 +0300 Subject: [PATCH 0688/1140] (#19888) sdbus-cpp/all: Fix patch_types "backport" is not a valid patch_type anymore. The closest type the documentation provides is "bugfix". Technically, it's really a bugfix to the build files. --- recipes/sdbus-cpp/all/conandata.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/sdbus-cpp/all/conandata.yml b/recipes/sdbus-cpp/all/conandata.yml index 97d55c77fac397..ac3e9f3df91887 100644 --- a/recipes/sdbus-cpp/all/conandata.yml +++ b/recipes/sdbus-cpp/all/conandata.yml @@ -19,10 +19,10 @@ patches: "1.0.0": - patch_file: "patches/0002-correct-readme-cpack-resource-path.patch" patch_description: "fix out of tree build by using proper paths in cmake file" - patch_type: "backport" + patch_type: "bugfix" patch_source: "https://github.com/Kistler-Group/sdbus-cpp/commit/0b8f2d97524f354bcaf816b27b6139a5b0c480ba" "0.8.3": - patch_file: "patches/0001-xml2cpp-Add-missing-EXPAT-include-dirs-136.patch" patch_description: "fix build error by adding missing headers" - patch_type: "backport" + patch_type: "bugfix" patch_source: "https://github.com/Kistler-Group/sdbus-cpp/commit/fb008445b15b452f461c34667f4991f5ce06e481" From 4398cf6f145c500e75d259ead85f34e061102418 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 05:51:42 +0200 Subject: [PATCH 0689/1140] (#19890) mathfu: add package_type --- recipes/mathfu/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/mathfu/all/conanfile.py b/recipes/mathfu/all/conanfile.py index 1b35d3c154c774..ec12916dc298be 100644 --- a/recipes/mathfu/all/conanfile.py +++ b/recipes/mathfu/all/conanfile.py @@ -13,6 +13,7 @@ class MathfuConan(ConanFile): license = "Apache-2.0" homepage = "https://github.com/google/mathfu" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -20,14 +21,13 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("vectorial/cci.20190628", transitive_headers=True, transitive_libs=True) + self.requires("vectorial/cci.20190628") def package_id(self): self.info.clear() def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From 17b1daff84f3574b43fffbada0c212afb7f50dd0 Mon Sep 17 00:00:00 2001 From: Sergey Bobrenok Date: Tue, 19 Sep 2023 07:10:59 +0300 Subject: [PATCH 0690/1140] (#19891) libsystemd/all: Fix v2 migration linter warnings The original warning: "Using open without explicitly specifying an encoding" --- recipes/libsystemd/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libsystemd/all/conanfile.py b/recipes/libsystemd/all/conanfile.py index 7d0c3d3c0590fa..0836b21234ebc0 100644 --- a/recipes/libsystemd/all/conanfile.py +++ b/recipes/libsystemd/all/conanfile.py @@ -82,7 +82,7 @@ def source(self): @property def _so_version(self): meson_build = os.path.join(self.source_folder, "meson.build") - with open(meson_build, "r") as build_file: + with open(meson_build, "r", encoding="utf-8") as build_file: for line in build_file: match = re.match(r"^libsystemd_version = '(.*)'$", line) if match: From 437280b5cc8eee998ad2977f5794c243480e8daf Mon Sep 17 00:00:00 2001 From: toge Date: Tue, 19 Sep 2023 13:52:58 +0900 Subject: [PATCH 0691/1140] (#19892) elfio: add version 3.12, use C++11 in test_package of elfio<3.11 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * elfio: add version 3.12 * elfio/3.12 requires C++17 * Update recipes/elfio/all/conanfile.py Co-authored-by: Pau Farré --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Pau Farré --- recipes/elfio/all/conandata.yml | 19 +++++---- recipes/elfio/all/conanfile.py | 39 +++++++++++++++---- recipes/elfio/all/test_package/CMakeLists.txt | 8 +++- recipes/elfio/config.yml | 2 + 4 files changed, 52 insertions(+), 16 deletions(-) diff --git a/recipes/elfio/all/conandata.yml b/recipes/elfio/all/conandata.yml index f57351ff19434e..fec8473460a71e 100644 --- a/recipes/elfio/all/conandata.yml +++ b/recipes/elfio/all/conandata.yml @@ -1,13 +1,16 @@ sources: + "3.12": + url: "https://github.com/serge1/ELFIO/releases/download/Release_3.12/elfio-3.12.tar.gz" + sha256: "caf49f3bf55a9c99c98ebea4b05c79281875783802e892729eea0415505f68c4" "3.11": - sha256: 3307b104c205399786edbba203906de9517e36297709fe747faf9478d55fbb91 - url: https://github.com/serge1/ELFIO/releases/download/Release_3.11/elfio-3.11.tar.gz + url: "https://github.com/serge1/ELFIO/releases/download/Release_3.11/elfio-3.11.tar.gz" + sha256: "3307b104c205399786edbba203906de9517e36297709fe747faf9478d55fbb91" "3.10": - sha256: cdc6362ede2e0c8d1d6db15d7da4b526f461d9cfae6f6337369e416a8bc60234 - url: https://github.com/serge1/ELFIO/releases/download/Release_3.10/elfio-3.10.tar.gz + url: "https://github.com/serge1/ELFIO/releases/download/Release_3.10/elfio-3.10.tar.gz" + sha256: "cdc6362ede2e0c8d1d6db15d7da4b526f461d9cfae6f6337369e416a8bc60234" "3.9": - sha256: 767b269063fc35aba6d361139f830aa91c45dc6b77942f082666876c1aa0be0f - url: https://github.com/serge1/ELFIO/releases/download/Release_3.9/elfio-3.9.tar.gz + url: "https://github.com/serge1/ELFIO/releases/download/Release_3.9/elfio-3.9.tar.gz" + sha256: "767b269063fc35aba6d361139f830aa91c45dc6b77942f082666876c1aa0be0f" "3.8": - sha256: 9553ce2b8d8aa2fb43f0e9be9bcbd10cd52f40b385110ea54173889c982f9ac4 - url: https://github.com/serge1/ELFIO/releases/download/Release_3.8/elfio-3.8.tar.gz + url: "https://github.com/serge1/ELFIO/releases/download/Release_3.8/elfio-3.8.tar.gz" + sha256: "9553ce2b8d8aa2fb43f0e9be9bcbd10cd52f40b385110ea54173889c982f9ac4" diff --git a/recipes/elfio/all/conanfile.py b/recipes/elfio/all/conanfile.py index eef05956d72825..db0b0c7ba0af5e 100644 --- a/recipes/elfio/all/conanfile.py +++ b/recipes/elfio/all/conanfile.py @@ -1,4 +1,5 @@ from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.files import copy, get from conan.tools.layout import basic_layout @@ -10,15 +11,37 @@ class ElfioConan(ConanFile): name = "elfio" - url = "https://github.com/conan-io/conan-center-index" - homepage = "http://elfio.sourceforge.net" description = "A header-only C++ library that provides a simple interface for reading and generating files in ELF binary format." - topics = ("elfio", "elf") license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://elfio.sourceforge.net" + topics = ("elf", "header-only") package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True + @property + def _min_cppstd(self): + if Version(self.version) < "3.11": + return "11" + elif Version(self.version) < "3.12": + return "14" + else: + return "17" + + @property + def _compilers_minimum_version(self): + return { + # while elfio<3.12 requires C++14, elfio still supports GCC 5 + "17": { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + }, + }.get(self._min_cppstd, {}) + def layout(self): basic_layout(self, src_folder="src") @@ -27,10 +50,12 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - if Version(self.version) < "3.11": - check_min_cppstd(self, 11) - else: - check_min_cppstd(self, 14) + 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) diff --git a/recipes/elfio/all/test_package/CMakeLists.txt b/recipes/elfio/all/test_package/CMakeLists.txt index 6fa586f7cb9435..50113becf9a2c0 100755 --- a/recipes/elfio/all/test_package/CMakeLists.txt +++ b/recipes/elfio/all/test_package/CMakeLists.txt @@ -5,4 +5,10 @@ find_package(elfio REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE elfio::elfio) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) +if (elfio_VERSION VERSION_LESS "3.11") + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) +elseif (elfio_VERSION VERSION_LESS "3.12") + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) +else() + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +endif() diff --git a/recipes/elfio/config.yml b/recipes/elfio/config.yml index 387fbf23f814ba..2d1b3203b5c132 100644 --- a/recipes/elfio/config.yml +++ b/recipes/elfio/config.yml @@ -1,4 +1,6 @@ versions: + "3.12": + folder: all "3.11": folder: all "3.10": From 17d36f408ff857552cf9d5e9cc6e460c9742ff07 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 07:31:58 +0200 Subject: [PATCH 0692/1140] (#19896) oboe: add package_type --- recipes/oboe/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/oboe/all/conanfile.py b/recipes/oboe/all/conanfile.py index a70215ca04760d..ee8b970e7d9a35 100644 --- a/recipes/oboe/all/conanfile.py +++ b/recipes/oboe/all/conanfile.py @@ -15,7 +15,7 @@ class OboeConan(ConanFile): topics = ("android", "audio") homepage = "https://github.com/google/oboe" url = "https://github.com/conan-io/conan-center-index" - + package_type = "library" settings = "os", "arch", "compiler", "build_type", options = { "shared": [True, False], @@ -33,15 +33,15 @@ def configure(self): if self.options.shared: self.options.rm_safe("fPIC") + def layout(self): + cmake_layout(self, src_folder="src") + def validate(self): if self.settings.os != "Android": raise ConanInvalidConfiguration("oboe supports Android only") if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, 17) - def layout(self): - cmake_layout(self, src_folder="src") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From ce24b23a39d6c086f41d774601fa9f83b00e7376 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 08:20:01 +0200 Subject: [PATCH 0693/1140] (#19900) platform.equality: no warning for msvc or unknown compilers --- recipes/platform.equality/all/conanfile.py | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/recipes/platform.equality/all/conanfile.py b/recipes/platform.equality/all/conanfile.py index 8aa89e267366d6..aa27ad1916e7f8 100644 --- a/recipes/platform.equality/all/conanfile.py +++ b/recipes/platform.equality/all/conanfile.py @@ -26,7 +26,7 @@ class PlatformInterfacesConan(ConanFile): no_copy_source = True @property - def _minimum_cpp_standard(self): + def _min_cppstd(self): return 20 @property @@ -38,6 +38,7 @@ def _compilers_minimum_version(self): return { "gcc": "10", "Visual Studio": "16", + "msvc": "192", "clang": "11", "apple-clang": "11", } @@ -50,15 +51,12 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) - if not minimum_version: - self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") - elif Version(self.settings.compiler.version) < minimum_version: + if minimum_version and Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration( - f"{self.ref} requires C++{self._minimum_cpp_standard} with {self.settings.compiler}, " - f"which is not supported by {self.settings.compiler} {self.settings.compiler.version}." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) if self.settings.compiler in ["clang", "apple-clang"] and not str(self.settings.compiler.libcxx).startswith("libstdc++"): From 32b7b0631c0dad4844634c0b0c53152e32daa7ec Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 08:54:59 +0200 Subject: [PATCH 0694/1140] (#19901) redboltz-mqtt_cpp: no warning for msvc or unknown compilers --- recipes/redboltz-mqtt_cpp/all/conanfile.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/recipes/redboltz-mqtt_cpp/all/conanfile.py b/recipes/redboltz-mqtt_cpp/all/conanfile.py index 5ca0f086f35bf9..2b3717a2d67c0f 100644 --- a/recipes/redboltz-mqtt_cpp/all/conanfile.py +++ b/recipes/redboltz-mqtt_cpp/all/conanfile.py @@ -30,7 +30,8 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "gcc": "6", - "Visual Studio": "15.0", + "Visual Studio": "15", + "msvc": "191", "clang": "5", "apple-clang": "10", } @@ -49,11 +50,10 @@ def validate(self): check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version: - if Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration(f"{self.name} requires C++14, which your compiler does not support.") - else: - self.output.warning(f"{self.name} requires C++14. Your compiler is unknown. Assuming it supports C++14.") + 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) From 317cb874ffd79bd921189b34c4987c8b45654a55 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 09:32:40 +0200 Subject: [PATCH 0695/1140] (#19902) lely-core: add missing build requirements + cleanup recipe * add libtool to build requirements since autoreconf is called * cleanup recipe * fix pkg_config_name of components --- recipes/lely-core/all/conanfile.py | 61 ++++++++++++------------------ 1 file changed, 24 insertions(+), 37 deletions(-) diff --git a/recipes/lely-core/all/conanfile.py b/recipes/lely-core/all/conanfile.py index f57056df761975..9ed8f191a0a192 100644 --- a/recipes/lely-core/all/conanfile.py +++ b/recipes/lely-core/all/conanfile.py @@ -1,33 +1,23 @@ import os from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import copy, get, rm, rmdir from conan.tools.gnu import AutotoolsToolchain, Autotools from conan.tools.layout import basic_layout -from conan.tools.apple import fix_apple_shared_install_name -from conan.tools.files import ( - export_conandata_patches, - apply_conandata_patches, - get, - copy, - rmdir, - rm, -) -from conan.errors import ConanInvalidConfiguration required_conan_version = ">=1.53.0" class LelyConan(ConanFile): name = "lely-core" - - # Optional metadata license = "Apache-2.0" homepage = "https://gitlab.com/lely_industries/lely-core/" url = "https://github.com/conan-io/conan-center-index" description = "The Lely core libraries are a collection of C and C++ libraries and tools, providing high-performance I/O and sensor/actuator control for robotics and IoT applications. The libraries are cross-platform and have few dependencies. They can be even be used on bare-metal microcontrollers with as little as 32 kB RAM." topics = ("canopen",) - - # Binary configuration + package_type = "library" settings = "os", "compiler", "build_type", "arch" options = { "shared": [True, False], @@ -108,13 +98,17 @@ class LelyConan(ConanFile): "coapp-slave": True, } - def export_sources(self): - export_conandata_patches(self) - def config_options(self): if self.settings.os == "Windows": self.options.rm_safe("fPIC") + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + basic_layout(self, src_folder="src") + def validate(self): if self.settings.os != "Linux": raise ConanInvalidConfiguration( @@ -127,20 +121,18 @@ def validate(self): f"{self.ref} can only be compiled with GCC currently" ) - def source(self): - get( - self, - **self.conan_data["sources"][self.version], - destination=self.source_folder, - strip_root=True, - ) + def build_requirements(self): + self.tool_requires("libtool/2.4.7") - def layout(self): - basic_layout(self, src_folder="src") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): - at_toolchain = AutotoolsToolchain(self) - at_toolchain.configure_args += [ + env = VirtualBuildEnv(self) + env.generate() + + tc = AutotoolsToolchain(self) + tc.configure_args += [ "--disable-cython", "--disable-python", "--disable-tools", @@ -148,7 +140,7 @@ def generate(self): "--disable-maintainer-mode", ] if self.options.get_safe("ecss-compliance"): - at_toolchain.configure_args.append("--enable-ecss-compliance") + tc.configure_args.append("--enable-ecss-compliance") disable_options = { "threads", @@ -188,16 +180,11 @@ def generate(self): } for option in disable_options: if not self.options.get_safe(option): - at_toolchain.configure_args.append(f"--disable-{option}") - - at_toolchain.generate() + tc.configure_args.append(f"--disable-{option}") - def configure(self): - if self.options.shared: - self.options.rm_safe("fPIC") + tc.generate() def build(self): - apply_conandata_patches(self) autotools = Autotools(self) autotools.autoreconf() autotools.configure() @@ -206,7 +193,6 @@ def build(self): def package(self): autotools = Autotools(self) autotools.install() - fix_apple_shared_install_name(self) copy( self, @@ -232,6 +218,7 @@ def package_info(self): "util": {"requires": ["libc"], "system_libs": ["m"]}, } for component, dependencies in components.items(): + self.cpp_info.components[component].set_property("pkg_config_name", f"liblely-{component}") self.cpp_info.components[component].libs = [f"lely-{component}"] self.cpp_info.components[component].requires = dependencies.get( "requires", [] From aebb3c5e2f51302148d2e5191af9af2b471d31d5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 10:10:09 +0200 Subject: [PATCH 0696/1140] (#19910) cminpack: modernize more for conan v2 * modernize more for conan v2 * small change --- recipes/cminpack/all/conanfile.py | 57 +++++++------------ .../cminpack/all/test_package/CMakeLists.txt | 6 +- .../cminpack/all/test_package/conanfile.py | 7 ++- .../all/test_v1_package/CMakeLists.txt | 16 ++---- 4 files changed, 33 insertions(+), 53 deletions(-) diff --git a/recipes/cminpack/all/conanfile.py b/recipes/cminpack/all/conanfile.py index a1da35f69dd6af..e6918dedc922aa 100644 --- a/recipes/cminpack/all/conanfile.py +++ b/recipes/cminpack/all/conanfile.py @@ -1,9 +1,9 @@ -from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools import files from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir import os -required_conan_version = ">=1.45.0" +required_conan_version = ">=1.54.0" class CMinpackConan(ConanFile): @@ -14,7 +14,7 @@ class CMinpackConan(ConanFile): topics = ("nonlinear", "solver") homepage = "http://devernay.free.fr/hacks/cminpack/" license = "LicenseRef-CopyrightMINPACK.txt" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -25,40 +25,27 @@ class CMinpackConan(ConanFile): "fPIC": True, } - def generate(self): - tc = CMakeToolchain(self) - tc.variables["BUILD_EXAMPLES"] = "OFF" - tc.variables["CMINPACK_LIB_INSTALL_DIR"] = "lib" - tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" - tc.generate() - - def layout(self): - cmake_layout(self) - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass - - # cminpack is a c library - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - files.get(self, **self.conan_data["sources"][self.version], - strip_root=True, destination=self.source_folder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_EXAMPLES"] = "OFF" + tc.variables["CMINPACK_LIB_INSTALL_DIR"] = "lib" + tc.generate() def build(self): cmake = CMake(self) @@ -66,12 +53,11 @@ def build(self): cmake.build() def package(self): + copy(self, "CopyrightMINPACK.txt", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) cmake = CMake(self) cmake.install() - - files.rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) - files.copy(self, "CopyrightMINPACK.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) - files.rmdir(self, os.path.join(self.package_folder, "share")) # contains cmake config files + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) # contains cmake config files def _library_postfix(self): postfix = "" @@ -92,7 +78,7 @@ def package_info(self): self.cpp_info.components["cminpack-double"].names["cmake_find_package"] = "cminpack" self.cpp_info.components["cminpack-double"].names["cmake_find_package_multi"] = "cminpack" self.cpp_info.components["cminpack-double"].names["pkg_config"] = "cminpack" - + # the single precision version self.cpp_info.components['cminpack-single'].libs = ['cminpacks' + self._library_postfix()] self.cpp_info.components['cminpack-single'].includedirs.append(minpack_include_dir) @@ -102,7 +88,6 @@ def package_info(self): self.cpp_info.components["cminpack-single"].names["cmake_find_package_multi"] = "cminpacks" self.cpp_info.components["cminpack-single"].names["pkg_config"] = "cminpacks" - if self.settings.os != "Windows": self.cpp_info.components['cminpack-double'].system_libs.append("m") self.cpp_info.components['cminpack-single'].system_libs.append("m") diff --git a/recipes/cminpack/all/test_package/CMakeLists.txt b/recipes/cminpack/all/test_package/CMakeLists.txt index fa33c20512fe46..cc33b8b3543efd 100644 --- a/recipes/cminpack/all/test_package/CMakeLists.txt +++ b/recipes/cminpack/all/test_package/CMakeLists.txt @@ -1,7 +1,7 @@ -cmake_minimum_required(VERSION 3.12) -project(CMinPack-Conan-TestPackage C) +cmake_minimum_required(VERSION 3.1) +project(test_package LANGUAGES C) -find_package(CMinpack REQUIRED) +find_package(CMinpack REQUIRED CONFIG) # This builds one of the original cminpack examples against # both types of the library diff --git a/recipes/cminpack/all/test_package/conanfile.py b/recipes/cminpack/all/test_package/conanfile.py index db7d5f7ac5bc33..434bb3861fb76b 100644 --- a/recipes/cminpack/all/test_package/conanfile.py +++ b/recipes/cminpack/all/test_package/conanfile.py @@ -1,17 +1,20 @@ - from conan import ConanFile -from conan.tools.cmake import CMake, cmake_layout from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() diff --git a/recipes/cminpack/all/test_v1_package/CMakeLists.txt b/recipes/cminpack/all/test_v1_package/CMakeLists.txt index 124290cb0ab4b9..0d20897301b68b 100644 --- a/recipes/cminpack/all/test_v1_package/CMakeLists.txt +++ b/recipes/cminpack/all/test_v1_package/CMakeLists.txt @@ -1,16 +1,8 @@ -cmake_minimum_required(VERSION 3.1.2) -project(CMinPack-ConanV1-TestPackage C) +cmake_minimum_required(VERSION 3.1) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(CMinpack REQUIRED CONFIG) - -# This builds one of the original cminpack examples against -# both types of the library - -add_executable(cminpack_test_double ../test_package/tchkderc.c) -target_link_libraries(cminpack_test_double PRIVATE cminpack::cminpack) - -add_executable(cminpack_test_float ../test_package/tchkderc.c) -target_link_libraries(cminpack_test_float PRIVATE cminpack::cminpacks) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From e1e14ff9faaa1358b1e65be6b05ca368abb19b5a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 10:51:36 +0200 Subject: [PATCH 0697/1140] (#19912) crc_cpp: conan v2 support * conan v2 support * add test_v1_package --- recipes/crc_cpp/all/conandata.yml | 18 ++--- recipes/crc_cpp/all/conanfile.py | 67 +++++++++++-------- .../crc_cpp/all/test_package/CMakeLists.txt | 9 +-- recipes/crc_cpp/all/test_package/conanfile.py | 22 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../crc_cpp/all/test_v1_package/conanfile.py | 17 +++++ recipes/crc_cpp/config.yml | 8 +-- 7 files changed, 94 insertions(+), 55 deletions(-) create mode 100644 recipes/crc_cpp/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/crc_cpp/all/test_v1_package/conanfile.py diff --git a/recipes/crc_cpp/all/conandata.yml b/recipes/crc_cpp/all/conandata.yml index 09ada265a56575..ae324a0321c623 100644 --- a/recipes/crc_cpp/all/conandata.yml +++ b/recipes/crc_cpp/all/conandata.yml @@ -1,13 +1,13 @@ sources: - "1.0.0": - url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.0.0.tar.gz" - sha256: "035ed616e0662eddbe7db7c920faaef99bbeb8953ebf98c3bb76cb81a2c4de2b" - "1.0.1": - url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.0.1.tar.gz" - sha256: "865a0e110bf7e94061ceef1683947a7788b54f932c7ce3848edc89d36e1aea26" - "1.1.0": - url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.1.0.tar.gz" - sha256: "50e46e3c44eb39809f6697b253f7b36c089642d7b7f2ebe2f75adf23c50676be" "1.2.0": url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.2.0.tar.gz" sha256: "508a609d9ef12c3088ed17a8ed820c965161a36dd90738c7358333fbfbe96af5" + "1.1.0": + url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.1.0.tar.gz" + sha256: "50e46e3c44eb39809f6697b253f7b36c089642d7b7f2ebe2f75adf23c50676be" + "1.0.1": + url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.0.1.tar.gz" + sha256: "865a0e110bf7e94061ceef1683947a7788b54f932c7ce3848edc89d36e1aea26" + "1.0.0": + url: "https://github.com/AshleyRoll/crc_cpp/archive/refs/tags/v1.0.0.tar.gz" + sha256: "035ed616e0662eddbe7db7c920faaef99bbeb8953ebf98c3bb76cb81a2c4de2b" diff --git a/recipes/crc_cpp/all/conanfile.py b/recipes/crc_cpp/all/conanfile.py index 4ccb993ef97a21..c77936e91ebeab 100644 --- a/recipes/crc_cpp/all/conanfile.py +++ b/recipes/crc_cpp/all/conanfile.py @@ -1,6 +1,9 @@ -from conan import ConanFile, tools -from conan.tools.scm import Version +from conan import ConanFile from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os required_conan_version = ">=1.50.0" @@ -9,45 +12,51 @@ class Crc_CppConan(ConanFile): name = "crc_cpp" description = "A header only constexpr / compile time small-table based CRC library for C++17 and newer" - topics = "crc_cpp", "crc", "constexpr", "cpp17", "cpp20", "header-only" - settings = "compiler", "os" + topics = ("crc", "constexpr", "cpp17", "cpp20", "header-only") url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/AshleyRoll/crc_cpp" license = "MIT" + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return "17" @property - def _supported_compiler(self): - compiler = str(self.settings.compiler) - version = Version(self.settings.compiler.version) - if compiler == "Visual Studio" and version >= "15": - return True - elif compiler == "gcc" and version >= "9": - return True - elif compiler == "clang" and version >= "5": - return True - elif compiler == "apple-clang" and version >= "10": - return True - else: - self.output.warn("{} recipe lacks information about the {} compiler standard version support".format(self.name, compiler)) - return False + def _compilers_minimum_version(self): + return { + "gcc": "9", + "clang": "5", + "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", + } + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.build.check_min_cppstd(self, "17") - if not self._supported_compiler: - raise ConanInvalidConfiguration("crc_cpp: Unsupported compiler: {}-{} " - "Minimum C++17 constexpr features required.".format(self.settings.compiler, self.settings.compiler.version)) + 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): - tools.files.get(self, **self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - self.copy(pattern="*", dst="include", src=os.path.join(self._source_subfolder, "include")) + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, "*", src=os.path.join(self.source_folder, "include"), dst=os.path.join(self.package_folder, "include")) - def package_id(self): - self.info.header_only() + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/crc_cpp/all/test_package/CMakeLists.txt b/recipes/crc_cpp/all/test_package/CMakeLists.txt index d41bc6dd30265f..ba67401c34bccb 100644 --- a/recipes/crc_cpp/all/test_package/CMakeLists.txt +++ b/recipes/crc_cpp/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ cmake_minimum_required(VERSION 3.8) project(test_package LANGUAGES CXX) -set(CMAKE_CXX_STANDARD 17) -set(CMAKE_CXX_STANDARD_REQUIRED ON) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(crc_cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE crc_cpp::crc_cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/crc_cpp/all/test_package/conanfile.py b/recipes/crc_cpp/all/test_package/conanfile.py index 34a0bcae95438f..0a6bc68712d901 100644 --- a/recipes/crc_cpp/all/test_package/conanfile.py +++ b/recipes/crc_cpp/all/test_package/conanfile.py @@ -1,11 +1,19 @@ -from conan import ConanFile, tools -from conans import CMake +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.build.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/crc_cpp/all/test_v1_package/CMakeLists.txt b/recipes/crc_cpp/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..0d20897301b68b --- /dev/null +++ b/recipes/crc_cpp/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.1) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/crc_cpp/all/test_v1_package/conanfile.py b/recipes/crc_cpp/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/crc_cpp/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/crc_cpp/config.yml b/recipes/crc_cpp/config.yml index 0d463a277e7325..de59a653e157c9 100644 --- a/recipes/crc_cpp/config.yml +++ b/recipes/crc_cpp/config.yml @@ -1,9 +1,9 @@ versions: - "1.0.0": - folder: "all" - "1.0.1": + "1.2.0": folder: "all" "1.1.0": folder: "all" - "1.2.0": + "1.0.1": + folder: "all" + "1.0.0": folder: "all" From a59adadadfc85c3b918ed836db28134a98f69af8 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 11:34:14 +0200 Subject: [PATCH 0698/1140] (#19883) octo-logger-cpp: fix msvc min version & few minor fixes * fix msvc min version & few minor fixes * sort methods by order of execution * remove explicit cmake & pkgconfig properties in package_info() since upstream doesn't export CMake targets or pkgconfig file * restore target name to not break other libs, but it's a lie * fix msvc runtime check --- recipes/octo-logger-cpp/all/conanfile.py | 63 +++++++++++------------- 1 file changed, 28 insertions(+), 35 deletions(-) diff --git a/recipes/octo-logger-cpp/all/conanfile.py b/recipes/octo-logger-cpp/all/conanfile.py index 042c94eec1f926..d8b77698e6f0db 100644 --- a/recipes/octo-logger-cpp/all/conanfile.py +++ b/recipes/octo-logger-cpp/all/conanfile.py @@ -1,10 +1,10 @@ from conan import ConanFile -from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout -from conan.tools.files import get, copy -from conan.tools.build import check_min_cppstd from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.microsoft import is_msvc_static_runtime from conan.tools.scm import Version -from conan.tools.microsoft import is_msvc import os required_conan_version = ">=1.50.0" @@ -37,7 +37,7 @@ def _compilers_minimum_version(self): "clang": "9", "apple-clang": "11", "Visual Studio": "16", - "msvc": "1923", + "msvc": "192", } @property @@ -48,46 +48,46 @@ def configure(self): if not self._aws_supported: del self.options.with_aws - def generate(self): - tc = CMakeToolchain(self) - tc.variables["DISABLE_TESTS"] = True - tc.variables["DISABLE_EXAMPLES"] = True - if self.options.get_safe("with_aws"): - tc.variables["WITH_AWS"] = True - tc.generate() - cd = CMakeDeps(self) - cd.generate() - def layout(self): cmake_layout(self, src_folder="src") + def requirements(self): + self.requires("fmt/10.1.1", transitive_headers=True) + if self.options.get_safe("with_aws"): + self.requires("nlohmann_json/3.11.2") + self.requires("aws-sdk-cpp/1.9.234") + def validate(self): - if self.info.settings.compiler.get_safe("cppstd"): + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) - minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) - if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: + 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." ) if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": raise ConanInvalidConfiguration(f"{self.ref} does not support clang with libc++. Use libstdc++ instead.") - if is_msvc(self) and self.settings.compiler.runtime in ["MTd", "MT"]: - raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC MT/MTd configurations, only MD/MDd is supported") + if is_msvc_static_runtime(self): + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC static runtime. Use dynamic runtime instead.") if self.options.get_safe("with_aws"): if not self.dependencies["aws-sdk-cpp"].options.logs: raise ConanInvalidConfiguration(f"{self.ref} requires the option aws-sdk-cpp:logs=True") + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) - def requirements(self): - self.requires("fmt/10.1.1", transitive_headers=True) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["DISABLE_TESTS"] = True + tc.variables["DISABLE_EXAMPLES"] = True if self.options.get_safe("with_aws"): - self.requires("nlohmann_json/3.11.2") - self.requires("aws-sdk-cpp/1.9.234") - - def build_requirements(self): - self.tool_requires("cmake/[>=3.16 <4]") + tc.variables["WITH_AWS"] = True + tc.generate() + cd = CMakeDeps(self) + cd.generate() def build(self): cmake = CMake(self) @@ -100,19 +100,12 @@ def package(self): cmake.install() def package_info(self): - self.cpp_info.libs = ["octo-logger-cpp"] - self.cpp_info.set_property("cmake_file_name", "octo-logger-cpp") self.cpp_info.set_property("cmake_target_name", "octo::octo-logger-cpp") - self.cpp_info.set_property("pkg_config_name", "octo-logger-cpp") + self.cpp_info.libs = ["octo-logger-cpp"] self.cpp_info.requires = ["fmt::fmt"] if self.options.get_safe("with_aws"): self.cpp_info.requires.extend([ "nlohmann_json::nlohmann_json", "aws-sdk-cpp::monitoring" ]) - - # TODO: to remove in conan v2 once cmake_find_package_* generators removed - self.cpp_info.names["cmake_find_package"] = "octo-logger-cpp" - self.cpp_info.names["cmake_find_package_multi"] = "octo-logger-cpp" - self.cpp_info.names["pkg_config"] = "octo-logger-cpp" From 9d860ee5be136ce62a86205667ab185e19a91346 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 19 Sep 2023 11:57:41 +0200 Subject: [PATCH 0699/1140] Add/remove users to Access Request (#19939) --- .c3i/authorized_users.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 212a9101efacf8..cc585bf78c5cf3 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1231,3 +1231,5 @@ authorized_users: - alfred-sa - leducp - mrjoel +- Nerixyz +- irieger From 9a7351b4bf05f26c1326024071e9b703b3aaf75f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 12:15:42 +0200 Subject: [PATCH 0700/1140] (#19884) octo-wildcardmatching-cpp: fix several issues and modernize * fix several issues and modernize - fix msvc min version - don't use self.info in validate() - use version range for cmake - use tool_requires instead of legacy build_requires - remove pkgconf properties in package_info() since upstream doesn't create pkgconfig file * fix test package --- .../all/conanfile.py | 58 +++++++++---------- .../all/test_package/CMakeLists.txt | 8 +-- .../all/test_package/conanfile.py | 19 +++--- 3 files changed, 40 insertions(+), 45 deletions(-) diff --git a/recipes/octo-wildcardmatching-cpp/all/conanfile.py b/recipes/octo-wildcardmatching-cpp/all/conanfile.py index f22d6f51767b8a..c8622ee725469f 100644 --- a/recipes/octo-wildcardmatching-cpp/all/conanfile.py +++ b/recipes/octo-wildcardmatching-cpp/all/conanfile.py @@ -1,8 +1,9 @@ from conan import ConanFile -from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout -from conan.tools.files import get, copy -from conan.tools.build import check_min_cppstd from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get +from conan.tools.microsoft import is_msvc_static_runtime from conan.tools.scm import Version import os @@ -16,8 +17,13 @@ class OctoWildcardMatchingCPPConan(ConanFile): homepage = "https://github.com/ofiriluz/octo-wildcardmatching-cpp" description = "Octo wildcardmatching library" topics = ("wildcard", "regex", "patterns", "cpp") + package_type = "static-library" settings = "os", "compiler", "build_type", "arch" + @property + def _min_cppstd(self): + return "17" + @property def _compilers_minimum_version(self): return { @@ -25,42 +31,38 @@ def _compilers_minimum_version(self): "clang": "9", "apple-clang": "11", "Visual Studio": "16", - "msvc": "1923", + "msvc": "192", } - def generate(self): - tc = CMakeToolchain(self) - tc.variables["DISABLE_TESTS"] = True - tc.variables["DISABLE_EXAMPLES"] = True - tc.generate() - cd = CMakeDeps(self) - cd.generate() - def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.info.settings.compiler.cppstd: - check_min_cppstd(self, "17") + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) - minimum_version = self._compilers_minimum_version.get(str(self.info.settings.compiler), False) - if minimum_version and Version(self.info.settings.compiler.version) < minimum_version: + 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.name} requires C++17, which your compiler does not support." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - else: - self.output.warn(f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17.") + if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libc++": - raise ConanInvalidConfiguration(f"{self.name} does not support clang with libc++. Use libstdc++ instead.") - if self.settings.compiler == "Visual Studio" and self.settings.compiler.runtime in ["MTd", "MT"]: - raise ConanInvalidConfiguration(f"{self.name} does not support MSVC MT/MTd configurations, only MD/MDd is supported") + raise ConanInvalidConfiguration(f"{self.ref} does not support clang with libc++. Use libstdc++ instead.") + if is_msvc_static_runtime(self): + raise ConanInvalidConfiguration(f"{self.ref} does not support MSVC static runtime. Use dynamic runtime instead.") + + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build_requirements(self): - self.build_requires("cmake/3.24.0") + def generate(self): + tc = CMakeToolchain(self) + tc.variables["DISABLE_TESTS"] = True + tc.variables["DISABLE_EXAMPLES"] = True + tc.generate() def build(self): cmake = CMake(self) @@ -75,8 +77,4 @@ def package(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "octo-wildcardmatching-cpp") self.cpp_info.set_property("cmake_target_name", "octo::octo-wildcardmatching-cpp") - self.cpp_info.set_property("pkg_config_name", "octo-wildcardmatching-cpp") self.cpp_info.libs = ["octo-wildcardmatching-cpp"] - self.cpp_info.names["cmake_find_package"] = "octo-wildcardmatching-cpp" - self.cpp_info.names["cmake_find_package_multi"] = "octo-wildcardmatching-cpp" - self.cpp_info.names["pkg_config"] = "octo-wildcardmatching-cpp" diff --git a/recipes/octo-wildcardmatching-cpp/all/test_package/CMakeLists.txt b/recipes/octo-wildcardmatching-cpp/all/test_package/CMakeLists.txt index d02959b9b71e55..10219d5afbaa21 100644 --- a/recipes/octo-wildcardmatching-cpp/all/test_package/CMakeLists.txt +++ b/recipes/octo-wildcardmatching-cpp/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package CXX) +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) find_package(octo-wildcardmatching-cpp REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} octo::octo-wildcardmatching-cpp) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 17) +target_link_libraries(${PROJECT_NAME} PRIVATE octo::octo-wildcardmatching-cpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/octo-wildcardmatching-cpp/all/test_package/conanfile.py b/recipes/octo-wildcardmatching-cpp/all/test_package/conanfile.py index 62e07ce5add598..254feca1042876 100644 --- a/recipes/octo-wildcardmatching-cpp/all/test_package/conanfile.py +++ b/recipes/octo-wildcardmatching-cpp/all/test_package/conanfile.py @@ -1,23 +1,20 @@ -from conans import ConanFile -from conan.tools.cmake import CMake, CMakeToolchain +from conan import ConanFile from conan.tools.build import can_run -from conan.tools.cmake import cmake_layout +from conan.tools.cmake import CMake, cmake_layout import os -required_conan_version = ">=1.43.0" - class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "CMakeDeps", "VirtualRunEnv" - - def generate(self): - tc = CMakeToolchain(self) - tc.generate() + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() From ac793941802a86a541ff74089952f05df5999fcd Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 12:52:24 +0200 Subject: [PATCH 0701/1140] (#19915) namedtype: fix msvc min version & few improvements - fix msvc min version - cleanup bindirs & libdirs - remove useless export & apply of patches --- recipes/namedtype/all/conanfile.py | 17 +++++++---------- .../namedtype/all/test_package/CMakeLists.txt | 2 +- .../test_package/{main.cpp => test_package.cpp} | 0 3 files changed, 8 insertions(+), 11 deletions(-) rename recipes/namedtype/all/test_package/{main.cpp => test_package.cpp} (100%) diff --git a/recipes/namedtype/all/conanfile.py b/recipes/namedtype/all/conanfile.py index ff8826be0c227e..14c646bee4f479 100644 --- a/recipes/namedtype/all/conanfile.py +++ b/recipes/namedtype/all/conanfile.py @@ -1,13 +1,14 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.files import copy, get from conan.tools.layout import basic_layout from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" + class NamedTypeConan(ConanFile): name = "namedtype" @@ -17,7 +18,7 @@ class NamedTypeConan(ConanFile): description = "Implementation of strong types in C++" topics = ("strong types", "header-only") package_type = "header-library" - settings = "compiler" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property @@ -28,15 +29,12 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15", - "msvc": "14.1", + "msvc": "191", "gcc": "5", "clang": "3.4", "apple-clang": "5.1", } - def export_sources(self): - export_conandata_patches(self) - def layout(self): basic_layout(self, src_folder="src") @@ -55,9 +53,6 @@ def validate(self): def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build(self): - apply_conandata_patches(self) - def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) if self.version == "20190324": @@ -76,5 +71,7 @@ def package(self): ) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] if self.version == "20190324": self.cpp_info.includedirs.append(os.path.join("include", "NamedType")) diff --git a/recipes/namedtype/all/test_package/CMakeLists.txt b/recipes/namedtype/all/test_package/CMakeLists.txt index a56821d0dc1a63..c88bbff306fb55 100644 --- a/recipes/namedtype/all/test_package/CMakeLists.txt +++ b/recipes/namedtype/all/test_package/CMakeLists.txt @@ -3,6 +3,6 @@ project(test_package LANGUAGES CXX) find_package(namedtype REQUIRED CONFIG) -add_executable(${PROJECT_NAME} main.cpp) +add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE namedtype::namedtype) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/namedtype/all/test_package/main.cpp b/recipes/namedtype/all/test_package/test_package.cpp similarity index 100% rename from recipes/namedtype/all/test_package/main.cpp rename to recipes/namedtype/all/test_package/test_package.cpp From 405c7f23b4b9aef71f0bf88336b77048135dfc9c Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 19 Sep 2023 13:29:21 +0200 Subject: [PATCH 0702/1140] (#19955) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 31 ++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index 8b4cb97448cab5..bd4640c99ef65b 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -207,6 +207,7 @@ required_for_references: - crc32c - create-dmg - croncpp +- crowcpp-crow - crunch - cryptopp - cs_libguarded @@ -710,6 +711,7 @@ required_for_references: - mariadb-connector-c - marisa - matchit +- mathfu - mathter - matio - mattiasgustavsson-libs @@ -826,6 +828,7 @@ required_for_references: - onnx - onnxruntime - open-dis-cpp +- open62541 - openal - openal-soft - openapi-generator @@ -894,7 +897,9 @@ required_for_references: - pipes - pixman - pkgconf +- platform.converters - platform.delegates +- platform.equality - platform.exceptions - platform.hashing - platform.interfaces @@ -975,6 +980,7 @@ required_for_references: - reckless - rectanglebinpack - rectpack2d +- redboltz-mqtt_cpp - redis-plus-plus - refl-cpp - replxx @@ -1051,6 +1057,7 @@ required_for_references: - soxr - span-lite - spdlog +- spectra - spirv-cross - spirv-headers - spirv-tools @@ -1089,6 +1096,7 @@ required_for_references: - taocpp-operators - taocpp-pegtl - taocpp-sequences +- taocpp-taopq - taocpp-tuple - taskflow - taywee-args @@ -1126,6 +1134,7 @@ required_for_references: - tinyspline - tinyxml - tinyxml2 +- tk - tl - tl-expected - tl-function-ref @@ -1160,6 +1169,7 @@ required_for_references: - uncrustify - uni-algo - unicorn +- units - unity - univalue - unordered_dense @@ -1169,14 +1179,21 @@ required_for_references: - uriparser - usockets - usrsctp +- utf8.h - utf8proc - utfcpp - util-linux-libuuid - uvw - uwebsockets +- v-hacd - vaapi +- valijson - variant-lite +- vc +- vcglib - vdpau +- vectorclass +- vectorial - veque - vincentlaucsb-csv-parser - vir-simd @@ -1184,6 +1201,7 @@ required_for_references: - vo-amrwbenc - volk - vorbis +- voropp - vsg - vtu11 - vulkan-headers @@ -1205,18 +1223,22 @@ required_for_references: - whereami - whisper-cpp - wil +- wildmidi - winflexbison +- winmd - wiringpi - wise_enum - wolfssl - wslay - wt - wtl +- wyhash - xapian-core - xbyak - xerces-c - xkbcommon - xkeyboard-config +- xlnt - xlsxio - xmlsec - xnnpack @@ -1226,7 +1248,10 @@ required_for_references: - xorg-macros - xorg-makedepend - xorg-proto +- xorstr - xoshiro-cpp +- xpack +- xproperty - xsd - xsimd - xtensor @@ -1240,19 +1265,25 @@ required_for_references: - yaml-cpp - yas - yasm +- yder - yyjson - z3 - zbar - zeromq - zfp - zimg +- zint - zlib - zlib-ng - zmarok-semver - zmqpp - zookeeper-client-c +- zopfli - zpp_bits +- zpp_throwing - zstd +- zstr - zug - zulu-openjdk - zxing-cpp +- zziplib From a91c01dcffff99499193099286070d3c0b3bb9e4 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 14:06:01 +0200 Subject: [PATCH 0703/1140] (#19916) rpclib: relax min C++ standard & min compiler versions + cleanup recipe * fix msvc min version * relax C++11 min standard and min compiler versions * remove useless export_conandata_patches() * small improvement in package_info() --- recipes/rpclib/all/conanfile.py | 36 ++++++------------- .../rpclib/all/test_package/CMakeLists.txt | 10 +++--- recipes/rpclib/all/test_package/conanfile.py | 8 ++--- .../{example.cpp => test_package.cpp} | 0 .../rpclib/all/test_v1_package/conanfile.py | 2 +- 5 files changed, 20 insertions(+), 36 deletions(-) rename recipes/rpclib/all/test_package/{example.cpp => test_package.cpp} (100%) diff --git a/recipes/rpclib/all/conanfile.py b/recipes/rpclib/all/conanfile.py index f7ea155c14f7cf..09e7e84ca393f7 100644 --- a/recipes/rpclib/all/conanfile.py +++ b/recipes/rpclib/all/conanfile.py @@ -1,12 +1,10 @@ import os from conan import ConanFile -from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import copy, export_conandata_patches, get, rmdir, rename, mkdir +from conan.tools.files import copy, get, mkdir, rename, rmdir from conan.tools.microsoft import is_msvc_static_runtime -from conan.tools.scm import Version required_conan_version = ">=1.53.0" @@ -32,20 +30,7 @@ class rpclibConan(ConanFile): @property def _min_cppstd(self): - return 14 - - @property - def _compilers_minimum_version(self): - return { - "Visual Studio": "15", - "msvc": "14.1", - "gcc": "5", - "clang": "5", - "apple-clang": "5.1", - } - - def export_sources(self): - export_conandata_patches(self) + return "11" def config_options(self): if self.settings.os == "Windows": @@ -59,13 +44,8 @@ def layout(self): cmake_layout(self, src_folder="src") def validate(self): - if self.settings.compiler.cppstd: + if self.settings.compiler.get_safe("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) @@ -102,9 +82,13 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "rpclib::rpc") self.cpp_info.set_property("pkg_config_name", "rpclib") + # TODO: back to global scope after Conan 2.0 + self.cpp_info.components["_rpc"].libs = ["rpc"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["_rpc"].system_libs.append("pthread") + # TODO: Remove after Conan 2.0 self.cpp_info.components["_rpc"].names["cmake_find_package"] = "rpc" self.cpp_info.components["_rpc"].names["cmake_find_package_multi"] = "rpc" - self.cpp_info.components["_rpc"].libs = ["rpc"] - if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["_rpc"].system_libs = ["pthread"] + self.cpp_info.components["_rpc"].set_property("cmake_target_name", "rpclib::rpc") + self.cpp_info.components["_rpc"].set_property("pkg_config_name", "rpclib") diff --git a/recipes/rpclib/all/test_package/CMakeLists.txt b/recipes/rpclib/all/test_package/CMakeLists.txt index 81dbfad0943b63..6ea9e950e13d6a 100644 --- a/recipes/rpclib/all/test_package/CMakeLists.txt +++ b/recipes/rpclib/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ -cmake_minimum_required(VERSION 3.15) -project(PackageTest CXX) +cmake_minimum_required(VERSION 3.8) +project(test_package CXX) find_package(rpclib REQUIRED CONFIG) -add_executable(example example.cpp) -set_target_properties(example PROPERTIES CXX_STANDARD 14) -target_link_libraries(example rpclib::rpc) +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE rpclib::rpc) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/rpclib/all/test_package/conanfile.py b/recipes/rpclib/all/test_package/conanfile.py index 8d52b7021efe14..3a91c9439218e3 100644 --- a/recipes/rpclib/all/test_package/conanfile.py +++ b/recipes/rpclib/all/test_package/conanfile.py @@ -9,12 +9,12 @@ class TestPackageConan(ConanFile): generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" test_type = "explicit" - def requirements(self): - self.requires(self.tested_reference_str) - def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() @@ -22,5 +22,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindir, "example") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") self.run(bin_path, env="conanrun") diff --git a/recipes/rpclib/all/test_package/example.cpp b/recipes/rpclib/all/test_package/test_package.cpp similarity index 100% rename from recipes/rpclib/all/test_package/example.cpp rename to recipes/rpclib/all/test_package/test_package.cpp diff --git a/recipes/rpclib/all/test_v1_package/conanfile.py b/recipes/rpclib/all/test_v1_package/conanfile.py index 67c12602a84f3a..d2f62e670fcd21 100644 --- a/recipes/rpclib/all/test_v1_package/conanfile.py +++ b/recipes/rpclib/all/test_v1_package/conanfile.py @@ -12,4 +12,4 @@ def build(self): def test(self): if not tools.cross_building(self): - self.run( os.path.join("bin", "example"), run_environment=True ) + self.run( os.path.join("bin", "test_package"), run_environment=True ) From 400dc950fd0056b55222778ec04a7cce9bb3933a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 14:19:41 +0200 Subject: [PATCH 0704/1140] (#19917) vir-simd: fix msvc min version & cleanup recipe --- recipes/vir-simd/all/conandata.yml | 4 +--- recipes/vir-simd/all/conanfile.py | 23 ++++--------------- .../vir-simd/all/test_package/conanfile.py | 1 - 3 files changed, 6 insertions(+), 22 deletions(-) diff --git a/recipes/vir-simd/all/conandata.yml b/recipes/vir-simd/all/conandata.yml index e21aa490a4d135..f9462ed3ee48fa 100644 --- a/recipes/vir-simd/all/conandata.yml +++ b/recipes/vir-simd/all/conandata.yml @@ -1,6 +1,4 @@ sources: - # Newer versions at the top "0.2.0": - url: - - "https://github.com/mattkretz/vir-simd/archive/refs/tags/v0.2.0.tar.gz" + url: "https://github.com/mattkretz/vir-simd/archive/refs/tags/v0.2.0.tar.gz" sha256: "197432196ec73009051188ba686124a469d75d639fc5408613b30ed2981f0b70" diff --git a/recipes/vir-simd/all/conanfile.py b/recipes/vir-simd/all/conanfile.py index 830132a2e93bd1..b79fe3dc61b1b2 100644 --- a/recipes/vir-simd/all/conanfile.py +++ b/recipes/vir-simd/all/conanfile.py @@ -1,13 +1,13 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy +from conan.tools.files import copy, get from conan.tools.layout import basic_layout from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" class VirSIMDConan(ConanFile): @@ -29,7 +29,7 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15", - "msvc": "19.15", + "msvc": "191", "gcc": "7", "clang": "5", "apple-clang": "5.1", @@ -38,7 +38,6 @@ def _compilers_minimum_version(self): def layout(self): basic_layout(self, src_folder="src") - # same package ID for any package def package_id(self): self.info.clear() @@ -71,19 +70,7 @@ def package(self): ) def package_info(self): - # Folders not used for header-only - self.cpp_info.bindirs = [] - self.cpp_info.libdirs = [] - - # Set these to the appropriate values if the package has an official FindPACKAGE.cmake - # listed in https://cmake.org/cmake/help/latest/manual/cmake-modules.7.html#find-modules - # examples: bzip2, freetype, gdal, icu, libcurl, libjpeg, libpng, libtiff, openssl, sqlite3, zlib... - self.cpp_info.set_property("cmake_module_file_name", "vir-simd") - self.cpp_info.set_property("cmake_module_target_name", "vir-simd::vir-simd") - # Set these to the appropriate values if package provides a CMake config file - # (package-config.cmake or packageConfig.cmake, with package::package target, usually installed in /lib/cmake//) self.cpp_info.set_property("cmake_file_name", "vir-simd") self.cpp_info.set_property("cmake_target_name", "vir-simd::vir-simd") - # Set this to the appropriate value if the package provides a pkgconfig file - # (package.pc, usually installed in /lib/pkgconfig/) - self.cpp_info.set_property("pkg_config_name", "vir-simd") + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/vir-simd/all/test_package/conanfile.py b/recipes/vir-simd/all/test_package/conanfile.py index 0a808db45f2453..3a91c9439218e3 100644 --- a/recipes/vir-simd/all/test_package/conanfile.py +++ b/recipes/vir-simd/all/test_package/conanfile.py @@ -4,7 +4,6 @@ import os -# It will become the standard on Conan 2.x class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" From b914a9c5ef8d2007e1ae427ea38e2c18cf5df573 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 14:50:45 +0200 Subject: [PATCH 0705/1140] (#19919) gurkenlaeufer: relax min compiler versions --- recipes/gurkenlaeufer/all/conanfile.py | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) diff --git a/recipes/gurkenlaeufer/all/conanfile.py b/recipes/gurkenlaeufer/all/conanfile.py index 07fa4de3d08f1f..50934895c439f6 100644 --- a/recipes/gurkenlaeufer/all/conanfile.py +++ b/recipes/gurkenlaeufer/all/conanfile.py @@ -1,9 +1,7 @@ from conan import ConanFile -from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.files import get, copy, rmdir +from conan.tools.files import copy, get, rmdir from conan.tools.layout import basic_layout -from conan.tools.scm import Version import os @@ -25,16 +23,6 @@ class GurkenlaeuferConan(ConanFile): def _min_cppstd(self): return 11 - @property - def _compilers_minimum_version(self): - return { - "Visual Studio": "15", - "msvc": "14.1", - "gcc": "5", - "clang": "5", - "apple-clang": "5.1", - } - def layout(self): basic_layout(self, src_folder="src") @@ -47,11 +35,6 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("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) From ab1846bdd75b46cc02e6dd3b8ceff73c13dc1f18 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 15:10:38 +0200 Subject: [PATCH 0706/1140] (#19922) cub: fix msvc min version & cleanup recipe --- recipes/cub/all/conanfile.py | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/recipes/cub/all/conanfile.py b/recipes/cub/all/conanfile.py index 2cde129243380d..0576f4a61be0df 100644 --- a/recipes/cub/all/conanfile.py +++ b/recipes/cub/all/conanfile.py @@ -7,7 +7,7 @@ from conan.tools.layout import basic_layout from conan.tools.scm import Version -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" class CubConan(ConanFile): @@ -29,7 +29,7 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "Visual Studio": "15", - "msvc": "14.1", + "msvc": "191", "gcc": "5", "clang": "5", "apple-clang": "5.1", @@ -73,10 +73,8 @@ def package_info(self): # Follows the naming conventions of the official CMake config file: # https://github.com/NVIDIA/cub/blob/main/cub/cmake/cub-config.cmake - self.cpp_info.set_property("cmake_file_name", "cub") self.cpp_info.set_property("cmake_target_name", "CUB::CUB") - self.cpp_info.set_property("pkg_config_name", "cub") # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "cub" From f6721333d60270829b8a4ce158e1c94ea3639e2d Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 19 Sep 2023 15:31:12 +0200 Subject: [PATCH 0707/1140] (#19663) protobuf: use version range for zlib + add package_type MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * add package_type * Proper range --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Daniel --- recipes/protobuf/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/protobuf/all/conanfile.py b/recipes/protobuf/all/conanfile.py index d12aca6f2317cc..b83d4db6fde567 100644 --- a/recipes/protobuf/all/conanfile.py +++ b/recipes/protobuf/all/conanfile.py @@ -19,7 +19,7 @@ class ProtobufConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/protocolbuffers/protobuf" license = "BSD-3-Clause" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -70,7 +70,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.options.shared and is_msvc_static_runtime(self): From 290daf671b6f04f797e173f9ccef110ad466a2d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 16:23:29 +0200 Subject: [PATCH 0708/1140] (#19684) Bump gnutls's zlib requirement to [>=1.2.11 <2] range --- recipes/gnutls/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/gnutls/all/conanfile.py b/recipes/gnutls/all/conanfile.py index 9f3b2e2521c516..d60649f4b2c09c 100644 --- a/recipes/gnutls/all/conanfile.py +++ b/recipes/gnutls/all/conanfile.py @@ -69,7 +69,7 @@ def requirements(self): self.requires("gmp/6.2.1") self.requires("libiconv/1.17") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.4") if self.options.with_brotli: From 967f767caf020fd04b280976653af8401cc64dd5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 17:02:46 +0200 Subject: [PATCH 0709/1140] (#19686) Bump zziplib's zlib requirement to [>=1.2.11 <2] range --- recipes/zziplib/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/zziplib/all/conanfile.py b/recipes/zziplib/all/conanfile.py index 140fd9378eebde..bb584cb53822b6 100644 --- a/recipes/zziplib/all/conanfile.py +++ b/recipes/zziplib/all/conanfile.py @@ -49,7 +49,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], From 75b573ed596a65b11ca0cb36e84e1e7873c68c97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 17:43:31 +0200 Subject: [PATCH 0710/1140] (#19742) Bump uwebsockets's zlib requirement to [>=1.2.11 <2] range --- recipes/uwebsockets/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/uwebsockets/all/conanfile.py b/recipes/uwebsockets/all/conanfile.py index 1ef8ede49e7675..4598157564ebae 100644 --- a/recipes/uwebsockets/all/conanfile.py +++ b/recipes/uwebsockets/all/conanfile.py @@ -51,7 +51,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.get_safe("with_libdeflate"): self.requires("libdeflate/1.14") From 3c09cb48d85093c326d7d3a329cc795ae57b3687 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 18:25:01 +0200 Subject: [PATCH 0711/1140] (#19743) Bump openssl-3.x.x's zlib requirement to [>=1.2.11 <2] range --- recipes/openssl/3.x.x/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/openssl/3.x.x/conanfile.py b/recipes/openssl/3.x.x/conanfile.py index f2c81b311e8fd9..bd2227abc9b73e 100644 --- a/recipes/openssl/3.x.x/conanfile.py +++ b/recipes/openssl/3.x.x/conanfile.py @@ -113,7 +113,7 @@ def configure(self): def requirements(self): if not self.options.no_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def build_requirements(self): if self._settings_build.os == "Windows": From f92692d251fe90c2046a7f88c4c4d012f0f7d27b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 19:03:44 +0200 Subject: [PATCH 0712/1140] (#19744) Bump librdkafka's zlib requirement to [>=1.2.11 <2] range --- recipes/librdkafka/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/librdkafka/all/conanfile.py b/recipes/librdkafka/all/conanfile.py index fbd6361872d879..a26ad90b5400db 100644 --- a/recipes/librdkafka/all/conanfile.py +++ b/recipes/librdkafka/all/conanfile.py @@ -65,7 +65,7 @@ def layout(self): def requirements(self): self.requires("lz4/1.9.4") if self.options.zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.zstd: self.requires("zstd/1.5.5") if self.options.ssl: From 3170e570fe6787799f3a08a281064e388c23f5c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 20:03:08 +0200 Subject: [PATCH 0713/1140] (#19745) Bump civetweb's zlib requirement to [>=1.2.11 <2] range --- recipes/civetweb/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/civetweb/all/conanfile.py b/recipes/civetweb/all/conanfile.py index 4d048e6a27d5bf..a2b502ff165bbb 100644 --- a/recipes/civetweb/all/conanfile.py +++ b/recipes/civetweb/all/conanfile.py @@ -87,7 +87,7 @@ def requirements(self): else: self.requires("openssl/[>=1 <4]") if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.options.get_safe("ssl_dynamic_loading") and not self.dependencies["openssl"].options.shared: From b00a464053e33fb779641dde8afa663edd79fc53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 20:23:55 +0200 Subject: [PATCH 0714/1140] (#19746) Bump cpp-httplib's zlib requirement to [>=1.2.11 <2] range --- recipes/cpp-httplib/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cpp-httplib/all/conanfile.py b/recipes/cpp-httplib/all/conanfile.py index ce51d51a2071d7..a9367f94e5c405 100644 --- a/recipes/cpp-httplib/all/conanfile.py +++ b/recipes/cpp-httplib/all/conanfile.py @@ -38,7 +38,7 @@ def requirements(self): if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.get_safe("with_brotli"): self.requires("brotli/1.0.9") From 52c06f687df15eff7e418269c04b87727b2b3985 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 20:43:06 +0200 Subject: [PATCH 0715/1140] (#19750) Bump libtar's zlib requirement to [>=1.2.11 <2] range --- recipes/libtar/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libtar/all/conanfile.py b/recipes/libtar/all/conanfile.py index ee12aac6802ccf..18b7b52de3166f 100644 --- a/recipes/libtar/all/conanfile.py +++ b/recipes/libtar/all/conanfile.py @@ -46,7 +46,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os == "Windows": From 5e05edfc3face5f954249a9a728f4b3c79fac103 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 21:03:43 +0200 Subject: [PATCH 0716/1140] (#19781) Bump cfitsio's zlib requirement to [>=1.2.11 <2] range --- recipes/cfitsio/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cfitsio/all/conanfile.py b/recipes/cfitsio/all/conanfile.py index b5849b0ae29466..72a03672b23c24 100644 --- a/recipes/cfitsio/all/conanfile.py +++ b/recipes/cfitsio/all/conanfile.py @@ -56,7 +56,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.threadsafe and self.settings.os == "Windows" and \ self.settings.compiler.get_safe("threads") != "posix": self.requires("pthreads4w/3.0.0") From 1785ede8ba34b6d1f2664026492da740bbe52e18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 22:03:40 +0200 Subject: [PATCH 0717/1140] (#19682) Bump highs's zlib requirement to [>=1.2.11 <2] range --- recipes/highs/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/highs/all/conanfile.py b/recipes/highs/all/conanfile.py index 8758bb90904fef..bba181cddafd79 100644 --- a/recipes/highs/all/conanfile.py +++ b/recipes/highs/all/conanfile.py @@ -41,7 +41,7 @@ def configure(self): self.options.rm_safe("fPIC") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def layout(self): cmake_layout(self, src_folder="src") From dc848f02cba142c5e8464a1d3f7a76f5005f5cc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 22:46:17 +0200 Subject: [PATCH 0718/1140] (#19782) Bump libdwarf's zlib requirement to [>=1.2.11 <2] range --- recipes/libdwarf/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libdwarf/all/conanfile.py b/recipes/libdwarf/all/conanfile.py index ddc9a73438a95f..aa284382df444c 100644 --- a/recipes/libdwarf/all/conanfile.py +++ b/recipes/libdwarf/all/conanfile.py @@ -48,7 +48,7 @@ def layout(self): def requirements(self): self.requires("libelf/0.8.13") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From ece7279dadb44300621cc44928b0e620505b919b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 19 Sep 2023 23:06:48 +0200 Subject: [PATCH 0719/1140] (#19783) Bump c-blosc's zlib requirement to [>=1.2.11 <2] range --- recipes/c-blosc/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/c-blosc/all/conanfile.py b/recipes/c-blosc/all/conanfile.py index 5967507ab8e974..9f604b7efb4910 100644 --- a/recipes/c-blosc/all/conanfile.py +++ b/recipes/c-blosc/all/conanfile.py @@ -60,7 +60,7 @@ def requirements(self): if self.options.with_snappy: self.requires("snappy/1.1.10") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.5") From cc5709458e61d877a43e2383bc3937027ba38cd1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 00:05:37 +0200 Subject: [PATCH 0720/1140] (#19784) Bump libunwind's zlib requirement to [>=1.2.11 <2] range --- recipes/libunwind/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libunwind/all/conanfile.py b/recipes/libunwind/all/conanfile.py index bf9a535448738c..e0054d21df520c 100644 --- a/recipes/libunwind/all/conanfile.py +++ b/recipes/libunwind/all/conanfile.py @@ -55,7 +55,7 @@ def requirements(self): if self.options.minidebuginfo: self.requires("xz_utils/5.4.2") if self.options.zlibdebuginfo: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os not in ["Linux", "FreeBSD"]: From c6ee7a7f06678d7a3abfc8eca41ee3bf22840c88 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 00:45:31 +0200 Subject: [PATCH 0721/1140] (#19785) Bump coin-utils's zlib requirement to [>=1.2.11 <2] range --- recipes/coin-utils/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/coin-utils/all/conanfile.py b/recipes/coin-utils/all/conanfile.py index e953f7c06f6759..98f96c3d122012 100644 --- a/recipes/coin-utils/all/conanfile.py +++ b/recipes/coin-utils/all/conanfile.py @@ -54,7 +54,7 @@ def layout(self): def requirements(self): self.requires("bzip2/1.0.8") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os == "Windows" and self.options.shared: From b99f71df0f9e1f1d33fe75bb593ed5d0d75c1e7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 01:23:23 +0200 Subject: [PATCH 0722/1140] (#19786) Bump readosm's zlib requirement to [>=1.2.11 <2] range --- recipes/readosm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/readosm/all/conanfile.py b/recipes/readosm/all/conanfile.py index b9c04661624b42..b9c849a5528870 100644 --- a/recipes/readosm/all/conanfile.py +++ b/recipes/readosm/all/conanfile.py @@ -55,7 +55,7 @@ def layout(self): def requirements(self): self.requires("expat/2.5.0") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def build_requirements(self): if not is_msvc(self): From 48838f248c9270919a2e843ecb90a7726465df49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 02:06:46 +0200 Subject: [PATCH 0723/1140] (#19788) Bump libmicrohttpd's zlib requirement to [>=1.2.11 <2] range --- recipes/libmicrohttpd/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libmicrohttpd/all/conanfile.py b/recipes/libmicrohttpd/all/conanfile.py index 82ca43a61b7adc..c81f9e360d523c 100644 --- a/recipes/libmicrohttpd/all/conanfile.py +++ b/recipes/libmicrohttpd/all/conanfile.py @@ -71,7 +71,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if is_msvc(self) and self.settings.arch not in ("x86", "x86_64"): From a83f072a99e8c05a0cc6e7b0183583dc89fdb9ec Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 03:16:50 +0200 Subject: [PATCH 0724/1140] (#19789) Bump ptex's zlib requirement to [>=1.2.11 <2] range --- recipes/ptex/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/ptex/all/conanfile.py b/recipes/ptex/all/conanfile.py index f8059fec65c6b2..48fcf6593c820d 100644 --- a/recipes/ptex/all/conanfile.py +++ b/recipes/ptex/all/conanfile.py @@ -40,7 +40,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], From 06cfff0011779772a822a3569b3ef672271eaf3b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 04:07:47 +0200 Subject: [PATCH 0725/1140] (#19790) Bump tcl's zlib requirement to [>=1.2.11 <2] range --- recipes/tcl/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tcl/all/conanfile.py b/recipes/tcl/all/conanfile.py index c81bc94de1c844..af981d1a0dba9f 100644 --- a/recipes/tcl/all/conanfile.py +++ b/recipes/tcl/all/conanfile.py @@ -50,7 +50,7 @@ def layout(self): self.folders.generators = "conan" def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os not in ("FreeBSD", "Linux", "Macos", "Windows"): From d75e48f3149b85ed22f61b7c5fa614460982688f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 04:42:50 +0200 Subject: [PATCH 0726/1140] (#19791) Bump restinio's zlib requirement to [>=1.2.11 <2] range --- recipes/restinio/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/restinio/all/conanfile.py b/recipes/restinio/all/conanfile.py index f9c52830c3a32e..576da558e85baf 100644 --- a/recipes/restinio/all/conanfile.py +++ b/recipes/restinio/all/conanfile.py @@ -53,7 +53,7 @@ def requirements(self): self.requires("openssl/[>=1.1 <4]") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_pcre == 1: self.requires("pcre/8.45") From 25ac564e790811538df1dc6b9e0c1b584ad3c800 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 05:03:24 +0200 Subject: [PATCH 0727/1140] (#19797) Bump libgd's zlib requirement to [>=1.2.11 <2] range --- recipes/libgd/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libgd/all/conanfile.py b/recipes/libgd/all/conanfile.py index 169f9e3ba1f8c7..965fc900c6e3b3 100644 --- a/recipes/libgd/all/conanfile.py +++ b/recipes/libgd/all/conanfile.py @@ -51,7 +51,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_png: self.requires("libpng/1.6.39") if is_msvc(self): From 020c4d4cf46c92006e94a295fe0f2ccfb6da42ad Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 05:42:38 +0200 Subject: [PATCH 0728/1140] (#19798) Bump cnpy's zlib requirement to [>=1.2.11 <2] range --- recipes/cnpy/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cnpy/all/conanfile.py b/recipes/cnpy/all/conanfile.py index 93cc4c7d5cadca..f6babc5b8b09b8 100644 --- a/recipes/cnpy/all/conanfile.py +++ b/recipes/cnpy/all/conanfile.py @@ -41,7 +41,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True, transitive_libs=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): From d359d4784f1a3086b91ca58bd1ce3218a5f711bf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 06:03:41 +0200 Subject: [PATCH 0729/1140] (#19801) Bump libpng's zlib requirement to [>=1.2.11 <2] range --- recipes/libpng/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libpng/all/conanfile.py b/recipes/libpng/all/conanfile.py index f8d672f0bb237c..f5410a3afa2d7a 100644 --- a/recipes/libpng/all/conanfile.py +++ b/recipes/libpng/all/conanfile.py @@ -92,7 +92,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if Version(self.version) < "1.6" and self.settings.arch == "armv8" and is_apple_os(self): From ab77920cea908466471c9ad55a56dd79a7aaae65 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 06:43:17 +0200 Subject: [PATCH 0730/1140] (#19802) Bump tinyexr's zlib requirement to [>=1.2.11 <2] range --- recipes/tinyexr/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tinyexr/all/conanfile.py b/recipes/tinyexr/all/conanfile.py index 26a07647634a18..cf57d86c163643 100644 --- a/recipes/tinyexr/all/conanfile.py +++ b/recipes/tinyexr/all/conanfile.py @@ -40,7 +40,7 @@ def requirements(self): if self.options.with_z == "miniz": self.requires("miniz/3.0.2") else: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zfp: self.requires("zfp/1.0.0") From 31c5fdb7fbda676372f50fa2dc216b993200af92 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 07:03:55 +0200 Subject: [PATCH 0731/1140] (#19803) Bump arrow's zlib requirement to [>=1.2.11 <2] range Co-authored-by: Carlos Zoido --- recipes/arrow/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index 2edf070a224e05..cb60b5bb95dea0 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -336,7 +336,7 @@ def requirements(self): self.options.get_safe("runtime_simd_level") != None: self.requires("xsimd/9.0.1") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.2") if self.options.with_re2: From a09b490f2be526dc8200227f46da572c2721b8c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 07:43:11 +0200 Subject: [PATCH 0732/1140] (#19804) Bump xapian-core's zlib requirement to [>=1.2.11 <2] range --- recipes/xapian-core/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/xapian-core/all/conanfile.py b/recipes/xapian-core/all/conanfile.py index f4278ec4f019a0..e5d0241981b9f7 100644 --- a/recipes/xapian-core/all/conanfile.py +++ b/recipes/xapian-core/all/conanfile.py @@ -54,7 +54,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.settings.os != "Windows": self.requires("util-linux-libuuid/2.39") From fccc28d9e53084fd9eb449d24baffebfbd741f18 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 08:03:30 +0200 Subject: [PATCH 0733/1140] (#19741) Bump crowcpp-crow's zlib requirement to [>=1.2.11 <2] range * Bump crowcpp-crow's zlib requirement to [>=1.2.11 <2] range * Fix test_package --- recipes/crowcpp-crow/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/crowcpp-crow/all/conanfile.py b/recipes/crowcpp-crow/all/conanfile.py index baeed2070acd2d..ff4bbd7ba2b660 100644 --- a/recipes/crowcpp-crow/all/conanfile.py +++ b/recipes/crowcpp-crow/all/conanfile.py @@ -49,7 +49,7 @@ def requirements(self): if self.options.with_ssl: self.requires("openssl/[>=1.1 <3]") if self.options.with_compression: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def package_id(self): self.info.settings.clear() From 11058609c2ccad79cded162740c18d79ed2109bc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 08:30:51 +0200 Subject: [PATCH 0734/1140] (#19751) Bump libbpf's zlib requirement to [>=1.2.11 <2] range * Bump libbpf's zlib requirement to [>=1.2.11 <2] range * Add missing package_type, use set_property for pkg_config_name too * wip --------- Co-authored-by: czoido --- recipes/libbpf/all/conanfile.py | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/recipes/libbpf/all/conanfile.py b/recipes/libbpf/all/conanfile.py index fcb6be22798a81..6ed8f1c59f1d08 100644 --- a/recipes/libbpf/all/conanfile.py +++ b/recipes/libbpf/all/conanfile.py @@ -14,6 +14,8 @@ class LibbpfConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/libbpf/libbpf" topics = ("berkeley-packet-filter", "bpf", "ebpf", "network", "tracing") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -38,9 +40,9 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("linux-headers-generic/5.14.9") + self.requires("linux-headers-generic/5.14.9", transitive_headers=True) self.requires("libelf/0.8.13") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os != "Linux": @@ -88,5 +90,9 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): - self.cpp_info.names["pkg_config"] = "libbpf" self.cpp_info.libs = ["bpf"] + self.cpp_info.set_property("pkg_config_name", "libbpf") + + # TODO: Remove once v1 is no longer needed + self.cpp_info.names["pkg_config"] = "libbpf" + From 8192451ad3f20c641d2508b820881ebd7a9ecddd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 08:42:26 +0200 Subject: [PATCH 0735/1140] (#19861) Bump gzip-hpp's zlib requirement to [>=1.2.11 <2] range --- recipes/gzip-hpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/gzip-hpp/all/conanfile.py b/recipes/gzip-hpp/all/conanfile.py index 9401872c82770b..54790b6d2c5642 100644 --- a/recipes/gzip-hpp/all/conanfile.py +++ b/recipes/gzip-hpp/all/conanfile.py @@ -27,7 +27,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13", transitive_headers=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True) def package_id(self): self.info.clear() From f3f319a13f0355d3f84cba97e44f359ec37896b6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 09:02:21 +0200 Subject: [PATCH 0736/1140] (#19862) Bump minisat's zlib requirement to [>=1.2.11 <2] range --- recipes/minisat/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/minisat/all/conanfile.py b/recipes/minisat/all/conanfile.py index 6dccb7f8528034..fdfbb6316a9635 100644 --- a/recipes/minisat/all/conanfile.py +++ b/recipes/minisat/all/conanfile.py @@ -41,7 +41,7 @@ def layout(self): def requirements(self): # https://github.com/niklasso/minisat/blob/37dc6c67e2af26379d88ce349eb9c4c6160e8543/minisat/utils/ParseUtils.h#L27 - self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True, transitive_libs=True) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 2925ccf10da21b509bea06a4ae0dde8e6447ef2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 09:23:24 +0200 Subject: [PATCH 0737/1140] (#19863) Bump tng's zlib requirement to [>=1.2.11 <2] range --- recipes/tng/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tng/all/conanfile.py b/recipes/tng/all/conanfile.py index 4a409ba3da2e22..326cababad6b68 100644 --- a/recipes/tng/all/conanfile.py +++ b/recipes/tng/all/conanfile.py @@ -41,7 +41,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], From f2066a807dadb5169de911ebefef016e6bffab80 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 10:03:04 +0200 Subject: [PATCH 0738/1140] (#19864) Bump taglib's zlib requirement to [>=1.2.11 <2] range --- recipes/taglib/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/taglib/all/conanfile.py b/recipes/taglib/all/conanfile.py index 23a0beef8e8854..816397a133c86f 100644 --- a/recipes/taglib/all/conanfile.py +++ b/recipes/taglib/all/conanfile.py @@ -44,7 +44,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 2b64af4c72ed728d43555bc14169ac647910cba4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 10:23:15 +0200 Subject: [PATCH 0739/1140] (#19865) Bump seasocks's zlib requirement to [>=1.2.11 <2] range --- recipes/seasocks/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/seasocks/all/conanfile.py b/recipes/seasocks/all/conanfile.py index 5a35a2a904c834..1662f1e11775fc 100644 --- a/recipes/seasocks/all/conanfile.py +++ b/recipes/seasocks/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os not in ["Linux", "FreeBSD"]: From 122b937d39f7e87d048a85d6d22babf8e6dff9e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 10:43:16 +0200 Subject: [PATCH 0740/1140] (#19867) Bump libnghttp2's zlib requirement to [>=1.2.11 <2] range --- recipes/libnghttp2/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libnghttp2/all/conanfile.py b/recipes/libnghttp2/all/conanfile.py index 00a7398f662464..3f994abf9ab852 100644 --- a/recipes/libnghttp2/all/conanfile.py +++ b/recipes/libnghttp2/all/conanfile.py @@ -67,7 +67,7 @@ def requirements(self): self.requires("libev/4.33") self.requires("libevent/2.1.12") self.requires("libxml2/2.11.4") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_jemalloc: self.requires("jemalloc/5.3.0") if self.options.with_hpack: From fe31521d7ea2d5f223f360543cc703ccd9d75f7d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 11:24:40 +0200 Subject: [PATCH 0741/1140] (#19868) Bump libcurl's zlib requirement to [>=1.2.11 <2] range --- recipes/libcurl/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libcurl/all/conanfile.py b/recipes/libcurl/all/conanfile.py index 40176f8f84e3b9..1496108f12e8d4 100644 --- a/recipes/libcurl/all/conanfile.py +++ b/recipes/libcurl/all/conanfile.py @@ -189,7 +189,7 @@ def requirements(self): if self.options.with_libssh2: self.requires("libssh2/1.11.0") if self.options.with_zlib: - self.requires("zlib/[>=1.2.10 <2]") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_brotli: self.requires("brotli/1.1.0") if self.options.with_zstd: From c529128b901a03f9e2fc74ced7f1e187654792fc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 12:24:10 +0200 Subject: [PATCH 0742/1140] =?UTF-8?q?(#19869)=20Bump=20kaitai=5Fstruct=5Fc?= =?UTF-8?q?pp=5Fstl=5Fruntime's=20zlib=20requirement=20to=20[>=3D1.2.11=20?= =?UTF-8?q?<2=E2=80=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * Bump kaitai_struct_cpp_stl_runtime's zlib requirement to [>=1.2.11 <2] range * add package_type = "shared-library" --------- Co-authored-by: czoido --- recipes/kaitai_struct_cpp_stl_runtime/all/conanfile.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/kaitai_struct_cpp_stl_runtime/all/conanfile.py b/recipes/kaitai_struct_cpp_stl_runtime/all/conanfile.py index 4940a6da6e8575..0c56efed668cb9 100644 --- a/recipes/kaitai_struct_cpp_stl_runtime/all/conanfile.py +++ b/recipes/kaitai_struct_cpp_stl_runtime/all/conanfile.py @@ -12,6 +12,7 @@ class KaitaiStructCppStlRuntimeConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://kaitai.io/" topics = ("parsers", "streams", "dsl", "kaitai struct") + package_type = "shared-library" settings = "os", "arch", "compiler", "build_type" options = { "with_zlib": [True, False], @@ -31,7 +32,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_iconv: self.requires("libiconv/1.17") From 626e4b4501b51a46eb7ce6ba17c619bde55a35d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 12:43:01 +0200 Subject: [PATCH 0743/1140] (#19870) Bump hdrhistogram-c's zlib requirement to [>=1.2.11 <2] range --- recipes/hdrhistogram-c/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/hdrhistogram-c/all/conanfile.py b/recipes/hdrhistogram-c/all/conanfile.py index dafe5ff3618bc9..f9f345becdeab3 100644 --- a/recipes/hdrhistogram-c/all/conanfile.py +++ b/recipes/hdrhistogram-c/all/conanfile.py @@ -42,7 +42,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 08598b454a349410e17cb9259daa0cdf02455434 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 13:03:54 +0200 Subject: [PATCH 0744/1140] (#19871) Bump hdf5's zlib requirement to [>=1.2.11 <2] range --- recipes/hdf5/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/hdf5/all/conanfile.py b/recipes/hdf5/all/conanfile.py index e4e17863639bf7..439507ce9f6f25 100644 --- a/recipes/hdf5/all/conanfile.py +++ b/recipes/hdf5/all/conanfile.py @@ -75,7 +75,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.szip_support == "with_libaec": self.requires("libaec/1.0.6") elif self.options.szip_support == "with_szip": From d733818167c4fc8725ee4ac5087723da8928b1ae Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 20 Sep 2023 13:38:02 +0200 Subject: [PATCH 0745/1140] (#19872) Bump hdf4's zlib requirement to [>=1.2.11 <2] range --- recipes/hdf4/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/hdf4/all/conanfile.py b/recipes/hdf4/all/conanfile.py index f3f6af54d2d434..161143820d8621 100644 --- a/recipes/hdf4/all/conanfile.py +++ b/recipes/hdf4/all/conanfile.py @@ -52,7 +52,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.jpegturbo: self.requires("libjpeg-turbo/3.0.0") else: From 92a857da97f4925488932ce54f2cf1526c754679 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 20 Sep 2023 21:12:21 +0900 Subject: [PATCH 0746/1140] (#19426) libaesgm: add recipe * libaesgm: add recipe * fix test_package.c * fixed license Co-authored-by: Uilian Ries --------- Co-authored-by: Uilian Ries --- recipes/libaesgm/all/CMakeLists.txt | 48 +++++++++++++ recipes/libaesgm/all/conandata.yml | 4 ++ recipes/libaesgm/all/conanfile.py | 72 +++++++++++++++++++ .../libaesgm/all/test_package/CMakeLists.txt | 7 ++ .../libaesgm/all/test_package/conanfile.py | 25 +++++++ .../libaesgm/all/test_package/test_package.c | 10 +++ recipes/libaesgm/config.yml | 3 + 7 files changed, 169 insertions(+) create mode 100644 recipes/libaesgm/all/CMakeLists.txt create mode 100644 recipes/libaesgm/all/conandata.yml create mode 100644 recipes/libaesgm/all/conanfile.py create mode 100644 recipes/libaesgm/all/test_package/CMakeLists.txt create mode 100644 recipes/libaesgm/all/test_package/conanfile.py create mode 100644 recipes/libaesgm/all/test_package/test_package.c create mode 100644 recipes/libaesgm/config.yml diff --git a/recipes/libaesgm/all/CMakeLists.txt b/recipes/libaesgm/all/CMakeLists.txt new file mode 100644 index 00000000000000..423d807676428b --- /dev/null +++ b/recipes/libaesgm/all/CMakeLists.txt @@ -0,0 +1,48 @@ +cmake_minimum_required(VERSION 3.8) +project(LibAesgm LANGUAGES C) + +add_library(Aesgm + #sources + ${LIBAESGM_SRC_DIR}/aescrypt.c + ${LIBAESGM_SRC_DIR}/aeskey.c + ${LIBAESGM_SRC_DIR}/aes_modes.c + ${LIBAESGM_SRC_DIR}/aes_ni.c + ${LIBAESGM_SRC_DIR}/aestab.c + #headers + ${LIBAESGM_SRC_DIR}/aescpp.h + ${LIBAESGM_SRC_DIR}/aes.h + ${LIBAESGM_SRC_DIR}/aes_ni.h + ${LIBAESGM_SRC_DIR}/aesopt.h + ${LIBAESGM_SRC_DIR}/aestab.h + ${LIBAESGM_SRC_DIR}/aes_via_ace.h + ${LIBAESGM_SRC_DIR}/brg_endian.h + ${LIBAESGM_SRC_DIR}/brg_types.h +) + +target_include_directories(Aesgm + INTERFACE + $ + $ +) + +if(WIN32 AND BUILD_SHARED_LIBS) + target_compile_definitions(Aesgm PRIVATE DLL_EXPORT) +endif() + +install(TARGETS Aesgm + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} +) +install( + FILES + ${LIBAESGM_SRC_DIR}/aes.h + ${LIBAESGM_SRC_DIR}/aes_ni.h + ${LIBAESGM_SRC_DIR}/aes_via_ace.h + ${LIBAESGM_SRC_DIR}/aescpp.h + ${LIBAESGM_SRC_DIR}/aesopt.h + ${LIBAESGM_SRC_DIR}/aestab.h + ${LIBAESGM_SRC_DIR}/brg_endian.h + ${LIBAESGM_SRC_DIR}/brg_types.h + DESTINATION include +) diff --git a/recipes/libaesgm/all/conandata.yml b/recipes/libaesgm/all/conandata.yml new file mode 100644 index 00000000000000..5a2d1592cd3739 --- /dev/null +++ b/recipes/libaesgm/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "2013.1.1": + url: "https://github.com/xmake-mirror/libaesgm/archive/refs/tags/2013.1.1.tar.gz" + sha256: "102353a486126c91ccab791c3e718d056d8fbb1be488da81b26561bc7ef4f363" diff --git a/recipes/libaesgm/all/conanfile.py b/recipes/libaesgm/all/conanfile.py new file mode 100644 index 00000000000000..17f6f991a5f99d --- /dev/null +++ b/recipes/libaesgm/all/conanfile.py @@ -0,0 +1,72 @@ +from conan import ConanFile +from conan.tools.files import get, copy, load, save +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +import os + + +required_conan_version = ">=1.53.0" + +class LibaesgmConan(ConanFile): + name = "libaesgm" + description = "Library implementation of AES (Rijndael) cryptographic methods" + license = "LicenseRef-libaesgm-BSD" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/xmake-mirror/libaesgm" + topics = ("aes", "cryptographic") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LIBAESGM_SRC_DIR"] = self.source_folder.replace("\\", "/") + tc.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + cmake = CMake(self) + cmake.configure(build_script_folder=os.path.join(self.source_folder, os.pardir)) + cmake.build() + + def package(self): + filename = os.path.join(self.source_folder, "aes.h") + file_content = load(self, filename) + license_end = "*/" + license_contents = file_content[:file_content.find(license_end)].replace("/*", "") + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_contents) + + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["Aesgm"] + + self.cpp_info.set_property("cmake_file_name", "Aesgm") + self.cpp_info.set_property("cmake_target_name", "Aesgm::Aesgm") diff --git a/recipes/libaesgm/all/test_package/CMakeLists.txt b/recipes/libaesgm/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..ed4bf02743021a --- /dev/null +++ b/recipes/libaesgm/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package C) + +find_package(Aesgm REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE Aesgm::Aesgm) diff --git a/recipes/libaesgm/all/test_package/conanfile.py b/recipes/libaesgm/all/test_package/conanfile.py new file mode 100644 index 00000000000000..f5cf204295e195 --- /dev/null +++ b/recipes/libaesgm/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libaesgm/all/test_package/test_package.c b/recipes/libaesgm/all/test_package/test_package.c new file mode 100644 index 00000000000000..af965724829275 --- /dev/null +++ b/recipes/libaesgm/all/test_package/test_package.c @@ -0,0 +1,10 @@ +#include + +int main() { + aes_encrypt_ctx ctx; + char message[] = "test"; + char key[] = "0123456789ABCDEF"; + aes_encrypt(message, key, &ctx); + + return 0; +} diff --git a/recipes/libaesgm/config.yml b/recipes/libaesgm/config.yml new file mode 100644 index 00000000000000..97cadcf3a32278 --- /dev/null +++ b/recipes/libaesgm/config.yml @@ -0,0 +1,3 @@ +versions: + "2013.1.1": + folder: all From a6fa5c6b852d0a55dfb54ccf1c8880a35d503421 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 14:33:07 +0200 Subject: [PATCH 0747/1140] (#19660) libtiff: use version range for zlib + bump mozjpeg * use version range for zlib * bump mozjpeg * fix version range zlib * bump xz_utils --- recipes/libtiff/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libtiff/all/conanfile.py b/recipes/libtiff/all/conanfile.py index 9d1f6de079291e..3393b9d3d4cd6f 100644 --- a/recipes/libtiff/all/conanfile.py +++ b/recipes/libtiff/all/conanfile.py @@ -63,17 +63,17 @@ def layout(self): def requirements(self): if self.options.zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.libdeflate: self.requires("libdeflate/1.18") if self.options.lzma: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.jpeg == "libjpeg-turbo": self.requires("libjpeg-turbo/3.0.0") elif self.options.jpeg == "mozjpeg": - self.requires("mozjpeg/4.1.1") + self.requires("mozjpeg/4.1.3") if self.options.jbig: self.requires("jbig/20160605") if self.options.zstd: From d69826d56a61bb94045ed34f2b4b8a41f1e40958 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 14:56:42 +0200 Subject: [PATCH 0748/1140] (#19661) libxml2: use version range for zlib + bump icu & pkgconf MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * use version range for zlib * bump icu & pkgconf * Update recipes/libxml2/all/conanfile.py * bump xz_utils * bump pkgconf --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libxml2/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/libxml2/all/conanfile.py b/recipes/libxml2/all/conanfile.py index becdc73f93c9c5..3a2832d9da9e76 100644 --- a/recipes/libxml2/all/conanfile.py +++ b/recipes/libxml2/all/conanfile.py @@ -95,19 +95,19 @@ def layout(self): def requirements(self): if self.options.zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.lzma: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.iconv: self.requires("libiconv/1.17", transitive_headers=True, transitive_libs=True) if self.options.icu: - self.requires("icu/73.1") + self.requires("icu/73.2") def build_requirements(self): if not (is_msvc(self) or self._is_mingw_windows): if self.options.zlib or self.options.lzma or self.options.icu: if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From 55ae5651153809730fac016d8b027ad6d81dec03 Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Wed, 20 Sep 2023 16:14:38 +0200 Subject: [PATCH 0749/1140] (#19718) libarchive: add v3.7.1, update requirements * Bump version * Fix typo * Use zlib/[>=1.2.11 <2] * Bugfix * Bump xz_utils * Update patches * Bugfix --- recipes/libarchive/all/conandata.yml | 18 +++++- recipes/libarchive/all/conanfile.py | 11 ++-- .../all/patches/0001-3.7.1-zlib-winapi.patch | 27 +++++++++ .../all/patches/0003-3.7.1-cmake.patch | 58 +++++++++++++++++++ .../0005-3.7.1-try-compile-cmakedeps.patch | 32 ++++++++++ ....patch => 0006-3.6.2-fix-msvc-build.patch} | 0 .../patches/0006-3.7.1-fix-msvc-build.patch | 45 ++++++++++++++ recipes/libarchive/config.yml | 2 + 8 files changed, 188 insertions(+), 5 deletions(-) create mode 100644 recipes/libarchive/all/patches/0001-3.7.1-zlib-winapi.patch create mode 100644 recipes/libarchive/all/patches/0003-3.7.1-cmake.patch create mode 100644 recipes/libarchive/all/patches/0005-3.7.1-try-compile-cmakedeps.patch rename recipes/libarchive/all/patches/{0006-fix-msvc-build.patch => 0006-3.6.2-fix-msvc-build.patch} (100%) create mode 100644 recipes/libarchive/all/patches/0006-3.7.1-fix-msvc-build.patch diff --git a/recipes/libarchive/all/conandata.yml b/recipes/libarchive/all/conandata.yml index 3853b8ec0aa668..7a29ca28110b50 100644 --- a/recipes/libarchive/all/conandata.yml +++ b/recipes/libarchive/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.7.1": + url: "https://github.com/libarchive/libarchive/releases/download/v3.7.1/libarchive-3.7.1.tar.xz" + sha256: "b17403ce670ff18d8e06fea05a9ea9accf70678c88f1b9392a2e29b51127895f" "3.6.2": url: "https://github.com/libarchive/libarchive/releases/download/v3.6.2/libarchive-3.6.2.tar.xz" sha256: "9e2c1b80d5fbe59b61308fdfab6c79b5021d7ff4ff2489fb12daf0a96a83551d" @@ -21,6 +24,19 @@ sources: url: "https://github.com/libarchive/libarchive/releases/download/v3.4.0/libarchive-3.4.0.tar.gz" sha256: "8643d50ed40c759f5412a3af4e353cffbce4fdf3b5cf321cb72cacf06b2d825e" patches: + "3.7.1": + - patch_file: "patches/0001-3.7.1-zlib-winapi.patch" + patch_description: "Remove broken ZLIB WINAPI check" + patch_type: "portability" + - patch_file: "patches/0003-3.7.1-cmake.patch" + patch_description: "Make CMake build-system compatible with Conan" + patch_type: "conan" + - patch_file: "patches/0005-3.7.1-try-compile-cmakedeps.patch" + patch_description: "Patch try_compile check to work with imported CMake targets from Conan packages" + patch_type: "conan" + - patch_file: "patches/0006-3.7.1-fix-msvc-build.patch" + patch_description: "Fix MSVC build" + patch_type: "conan" "3.6.2": - patch_file: "patches/0001-3.6.2-zlib-winapi.patch" patch_description: "Remove broken ZLIB WINAPI check" @@ -31,7 +47,7 @@ patches: - patch_file: "patches/0005-3.6.2-try-compile-cmakedeps.patch" patch_description: "Patch try_compile check to work with imported CMake targets from Conan packages" patch_type: "conan" - - patch_file: "patches/0006-fix-msvc-build.patch" + - patch_file: "patches/0006-3.6.2-fix-msvc-build.patch" patch_description: "Fix MSVC build" patch_type: "conan" "3.6.1": diff --git a/recipes/libarchive/all/conanfile.py b/recipes/libarchive/all/conanfile.py index c6970f8d631a8b..68c352dbc326ae 100644 --- a/recipes/libarchive/all/conanfile.py +++ b/recipes/libarchive/all/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile from conan.tools.cmake import CMake, cmake_layout, CMakeDeps, CMakeToolchain -from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, rmdir +from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, rm, rmdir from conan.tools.microsoft import is_msvc from conan.tools.scm import Version from conan.errors import ConanInvalidConfiguration @@ -81,7 +81,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.with_libxml2: @@ -91,7 +91,7 @@ def requirements(self): if self.options.with_iconv: self.requires("libiconv/1.17") if self.options.with_pcreposix: - self.requires("pcre/10.42") + self.requires("pcre2/10.42") if self.options.with_nettle: self.requires("nettle/3.8.1") if self.options.with_openssl: @@ -103,7 +103,7 @@ def requirements(self): if self.options.with_lzo: self.requires("lzo/2.10") if self.options.with_lzma: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.with_zstd: self.requires("zstd/1.5.5") if self.options.get_safe("with_mbedtls"): @@ -172,6 +172,9 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "share")) + if self.options.shared: + rm(self, "*.a", os.path.join(self.package_folder, "lib")) + def package_info(self): self.cpp_info.set_property("cmake_find_mode", "both") self.cpp_info.set_property("cmake_file_name", "LibArchive") diff --git a/recipes/libarchive/all/patches/0001-3.7.1-zlib-winapi.patch b/recipes/libarchive/all/patches/0001-3.7.1-zlib-winapi.patch new file mode 100644 index 00000000000000..beb5f743fa31fb --- /dev/null +++ b/recipes/libarchive/all/patches/0001-3.7.1-zlib-winapi.patch @@ -0,0 +1,27 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6849ce40..57cf7f8f 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -444,14 +444,14 @@ IF(ZLIB_FOUND) + INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR}) + LIST(APPEND ADDITIONAL_LIBS ${ZLIB_LIBRARIES}) + IF(WIN32 AND NOT CYGWIN) +- # +- # Test if ZLIB_WINAPI macro is needed to use. +- # +- TRY_MACRO_FOR_LIBRARY( +- "${ZLIB_INCLUDE_DIR}" "${ZLIB_LIBRARIES}" +- RUNS +- "#include \nint main() {uLong f = zlibCompileFlags(); return (f&(1U<<10))?0:-1; }" +- ZLIB_WINAPI) ++ ++ ++ ++ ++ ++ ++ ++ SET(ZLIB_WINAPI yes) + IF(ZLIB_WINAPI) + ADD_DEFINITIONS(-DZLIB_WINAPI) + ELSE(ZLIB_WINAPI) diff --git a/recipes/libarchive/all/patches/0003-3.7.1-cmake.patch b/recipes/libarchive/all/patches/0003-3.7.1-cmake.patch new file mode 100644 index 00000000000000..d4c2879103cd6f --- /dev/null +++ b/recipes/libarchive/all/patches/0003-3.7.1-cmake.patch @@ -0,0 +1,58 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6849ce40..8d5b6018 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -9,7 +9,7 @@ endif() + # + PROJECT(libarchive C) + # +-SET(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/build/cmake") ++LIST(APPEND CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/build/cmake") + if(NOT CMAKE_RUNTIME_OUTPUT_DIRECTORY) + set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${libarchive_BINARY_DIR}/bin) + endif() +@@ -442,7 +442,7 @@ IF(ZLIB_FOUND) + SET(HAVE_LIBZ 1) + SET(HAVE_ZLIB_H 1) + INCLUDE_DIRECTORIES(${ZLIB_INCLUDE_DIR}) +- LIST(APPEND ADDITIONAL_LIBS ${ZLIB_LIBRARIES}) ++ LIST(APPEND ADDITIONAL_LIBS ZLIB::ZLIB) + IF(WIN32 AND NOT CYGWIN) + + +@@ -511,7 +511,7 @@ IF(LIBLZMA_FOUND) + SET(HAVE_LIBLZMA 1) + SET(HAVE_LZMA_H 1) + CMAKE_PUSH_CHECK_STATE() +- SET(CMAKE_REQUIRED_INCLUDES ${LIBLZMA_INCLUDE_DIR}) ++ SET(CMAKE_REQUIRED_INCLUDES ${LIBLZMA_INCLUDE_DIRS}) + SET(CMAKE_REQUIRED_LIBRARIES ${LIBLZMA_LIBRARIES}) + INCLUDE_DIRECTORIES(${LIBLZMA_INCLUDE_DIRS}) + LIST(APPEND ADDITIONAL_LIBS ${LIBLZMA_LIBRARIES}) +@@ -532,7 +532,7 @@ ELSE(LIBLZMA_FOUND) + # LZMA not found and will not be used. + SET(HAVE_LZMA_STREAM_ENCODER_MT 0) + ENDIF(LIBLZMA_FOUND) +-MARK_AS_ADVANCED(CLEAR LIBLZMA_INCLUDE_DIR) ++MARK_AS_ADVANCED(CLEAR LIBLZMA_INCLUDE_DIRS) + MARK_AS_ADVANCED(CLEAR LIBLZMA_LIBRARY) + + # +@@ -603,7 +603,7 @@ IF(ENABLE_LZ4) + ENDIF (LZ4_INCLUDE_DIR) + + FIND_PATH(LZ4_INCLUDE_DIR lz4.h) +- FIND_LIBRARY(LZ4_LIBRARY NAMES lz4 liblz4) ++ FIND_LIBRARY(LZ4_LIBRARY NAMES lz4 liblz4 lz4_static liblz4_static) + INCLUDE(FindPackageHandleStandardArgs) + FIND_PACKAGE_HANDLE_STANDARD_ARGS(LZ4 DEFAULT_MSG LZ4_LIBRARY LZ4_INCLUDE_DIR) + ELSE(ENABLE_LZ4) +@@ -827,7 +827,7 @@ ENDIF(ENABLE_NETTLE) + # Find OpenSSL + # (Except on Mac, where OpenSSL is deprecated.) + # +-IF(ENABLE_OPENSSL AND NOT CMAKE_SYSTEM_NAME MATCHES "Darwin") ++IF(ENABLE_OPENSSL) + FIND_PACKAGE(OpenSSL) + IF(OPENSSL_FOUND) + SET(HAVE_LIBCRYPTO 1) diff --git a/recipes/libarchive/all/patches/0005-3.7.1-try-compile-cmakedeps.patch b/recipes/libarchive/all/patches/0005-3.7.1-try-compile-cmakedeps.patch new file mode 100644 index 00000000000000..c71291d02944a7 --- /dev/null +++ b/recipes/libarchive/all/patches/0005-3.7.1-try-compile-cmakedeps.patch @@ -0,0 +1,32 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6849ce40..e7c9fbee 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -854,14 +854,14 @@ IF(NOT OPENSSL_FOUND) + ENDIF(LIBMD_FOUND) + ENDIF(NOT OPENSSL_FOUND) + +-# + # How to prove that CRYPTO functions, which have several names on various + # platforms, just see if archive_digest.c can compile and link against + # required libraries. +-# + MACRO(CHECK_CRYPTO ALGORITHMS IMPLEMENTATION) ++ include(CMakePushCheckState) + FOREACH(ALGORITHM ${ALGORITHMS}) + IF(NOT ARCHIVE_CRYPTO_${ALGORITHM}) ++ cmake_push_check_state() + STRING(TOLOWER "${ALGORITHM}" lower_algorithm) + STRING(TOUPPER "${ALGORITHM}" algorithm) + IF ("${IMPLEMENTATION}" MATCHES "^OPENSSL$" AND NOT OPENSSL_FOUND) +@@ -881,8 +881,8 @@ MACRO(CHECK_CRYPTO ALGORITHMS IMPLEMENTATION) + IF ("${IMPLEMENTATION}" MATCHES "^OPENSSL$" AND OPENSSL_FOUND) + SET(TRY_CRYPTO_REQUIRED_INCLUDES + "${TRY_CRYPTO_REQUIRED_INCLUDES};${OPENSSL_INCLUDE_DIR}") +- SET(TRY_CRYPTO_REQUIRED_LIBS +- "-DLINK_LIBRARIES:STRING=${OPENSSL_LIBRARIES}") ++ SET(CMAKE_REQUIRED_LIBRARIES ${OPENSSL_LIBRARIES}) ++ + ELSEIF("${IMPLEMENTATION}" MATCHES "^MBEDTLS$" AND MBEDTLS_FOUND) + SET(TRY_CRYPTO_REQUIRED_INCLUDES + "${TRY_CRYPTO_REQUIRED_INCLUDES};${MBEDTLS_INCLUDE_DIRS}") diff --git a/recipes/libarchive/all/patches/0006-fix-msvc-build.patch b/recipes/libarchive/all/patches/0006-3.6.2-fix-msvc-build.patch similarity index 100% rename from recipes/libarchive/all/patches/0006-fix-msvc-build.patch rename to recipes/libarchive/all/patches/0006-3.6.2-fix-msvc-build.patch diff --git a/recipes/libarchive/all/patches/0006-3.7.1-fix-msvc-build.patch b/recipes/libarchive/all/patches/0006-3.7.1-fix-msvc-build.patch new file mode 100644 index 00000000000000..04ec53a2e20baf --- /dev/null +++ b/recipes/libarchive/all/patches/0006-3.7.1-fix-msvc-build.patch @@ -0,0 +1,45 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 6849ce40..d5dac48b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1401,7 +1401,7 @@ CHECK_FUNCTION_EXISTS_GLIBC(localtime_r HAVE_LOCALTIME_R) + CHECK_FUNCTION_EXISTS_GLIBC(lstat HAVE_LSTAT) + CHECK_FUNCTION_EXISTS_GLIBC(lutimes HAVE_LUTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(mbrtowc HAVE_MBRTOWC) +-CHECK_FUNCTION_EXISTS_GLIBC(memmove HAVE_MEMMOVE) ++SET(HAVE_MEMMOVE 1) + CHECK_FUNCTION_EXISTS_GLIBC(mkdir HAVE_MKDIR) + CHECK_FUNCTION_EXISTS_GLIBC(mkfifo HAVE_MKFIFO) + CHECK_FUNCTION_EXISTS_GLIBC(mknod HAVE_MKNOD) +@@ -1434,11 +1434,11 @@ CHECK_FUNCTION_EXISTS_GLIBC(utime HAVE_UTIME) + CHECK_FUNCTION_EXISTS_GLIBC(utimes HAVE_UTIMES) + CHECK_FUNCTION_EXISTS_GLIBC(utimensat HAVE_UTIMENSAT) + CHECK_FUNCTION_EXISTS_GLIBC(vfork HAVE_VFORK) +-CHECK_FUNCTION_EXISTS_GLIBC(wcrtomb HAVE_WCRTOMB) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscmp HAVE_WCSCMP) +-CHECK_FUNCTION_EXISTS_GLIBC(wcscpy HAVE_WCSCPY) +-CHECK_FUNCTION_EXISTS_GLIBC(wcslen HAVE_WCSLEN) +-CHECK_FUNCTION_EXISTS_GLIBC(wctomb HAVE_WCTOMB) ++SET(HAVE_WCRTOMB 1) ++SET(HAVE_WCSCMP 1) ++SET(HAVE_WCSCPY 1) ++SET(HAVE_WCSLEN 1) ++SET(HAVE_WCTOMB 1) + CHECK_FUNCTION_EXISTS_GLIBC(_fseeki64 HAVE__FSEEKI64) + CHECK_FUNCTION_EXISTS_GLIBC(_get_timezone HAVE__GET_TIMEZONE) + CHECK_SYMBOL_EXISTS(ctime_s "time.h" HAVE_CTIME_S) +@@ -1451,10 +1451,10 @@ CHECK_FUNCTION_EXISTS(cygwin_conv_path HAVE_CYGWIN_CONV_PATH) + CHECK_FUNCTION_EXISTS(fseeko HAVE_FSEEKO) + CHECK_FUNCTION_EXISTS(strerror_r HAVE_STRERROR_R) + CHECK_FUNCTION_EXISTS(strftime HAVE_STRFTIME) +-CHECK_FUNCTION_EXISTS(vprintf HAVE_VPRINTF) +-CHECK_FUNCTION_EXISTS(wmemcmp HAVE_WMEMCMP) +-CHECK_FUNCTION_EXISTS(wmemcpy HAVE_WMEMCPY) +-CHECK_FUNCTION_EXISTS(wmemmove HAVE_WMEMMOVE) ++SET(HAVE_VPRINTF 1) ++SET(HAVE_WMEMCMP 1) ++SET(HAVE_WMEMCPY 1) ++SET(HAVE_WMEMMOVE 1) + + CMAKE_POP_CHECK_STATE() # Restore the state of the variables + diff --git a/recipes/libarchive/config.yml b/recipes/libarchive/config.yml index 2cfb62acf52281..3abc948fc71614 100644 --- a/recipes/libarchive/config.yml +++ b/recipes/libarchive/config.yml @@ -1,4 +1,6 @@ versions: + "3.7.1": + folder: all "3.6.2": folder: all "3.6.1": From 88804f87b1a911a289ad13a787051f44001b7f89 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 16:27:16 +0200 Subject: [PATCH 0750/1140] (#19859) zstr: add package_type + use version range for zlib * add package_type * use version range for zlib --- recipes/zstr/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/zstr/all/conanfile.py b/recipes/zstr/all/conanfile.py index 512be7c200256b..97a53cde0de88b 100644 --- a/recipes/zstr/all/conanfile.py +++ b/recipes/zstr/all/conanfile.py @@ -14,6 +14,7 @@ class ZstrConan(ConanFile): topics = ("zlib", "wrapper", "compression") homepage = "https://github.com/mateidavid/zstr" url = "https://github.com/conan-io/conan-center-index" + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -21,7 +22,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def package_id(self): self.info.clear() @@ -31,8 +32,7 @@ def validate(self): check_min_cppstd(self, 11) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def build(self): pass From 0d4437320031a7956d8588c410c39fb1be6b24ee Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 16:54:28 +0200 Subject: [PATCH 0751/1140] (#19908) ccfits: add package_type + bump cfitsio MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add package_type & modernize more * simplify test v1 package * bump cfitsio * fix traits * check that C++ std is not 17 or higher for ccfits < 2.6 ccfits < 2.6 uses auto_ptr, removed since C++17 * Test better import way that is less hacky * Revert, should not recompile :) --------- Co-authored-by: Rubén Rincón Blanco --- recipes/ccfits/all/conanfile.py | 29 ++++++++++--------- .../ccfits/all/test_v1_package/CMakeLists.txt | 8 ++--- 2 files changed, 19 insertions(+), 18 deletions(-) diff --git a/recipes/ccfits/all/conanfile.py b/recipes/ccfits/all/conanfile.py index c9d53caa2f748a..d767889c1ed3bf 100644 --- a/recipes/ccfits/all/conanfile.py +++ b/recipes/ccfits/all/conanfile.py @@ -1,21 +1,21 @@ -from conan import ConanFile +from conan import ConanFile, conan_version from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.54.0" class CcfitsConan(ConanFile): name = "ccfits" description = "CCfits is an object oriented interface to the cfitsio library." license = "ISC" - topics = ("ccfits", "fits", "image", "nasa", "astronomy", "astrophysics", "space") + topics = ("fits", "image", "nasa", "astronomy", "astrophysics", "space") homepage = "https://heasarc.gsfc.nasa.gov/fitsio/ccfits" url = "https://github.com/conan-io/conan-center-index" - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -35,32 +35,35 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass + self.options.rm_safe("fPIC") def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("cfitsio/4.1.0") + # transitive_headers: CCfits/CCfits.h includes fitsio.h + self.requires("cfitsio/4.2.0", transitive_headers=True) def validate_build(self): if Version(self.version) >= "2.6": if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, 11) + else: + if conan_version >= "2": + # FIXME: c3i linter complains, but function is there + # https://docs.conan.io/2.0/reference/tools/build.html?highlight=check_min_cppstd#conan-tools-build-check-max-cppstd + import sys + check_max_cppstd = getattr(sys.modules["conan.tools.build"], "check_max_cppstd") + # C++17 and higher not supported in ccfits < 2.6 due to auto_ptr + check_max_cppstd(self, 14) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) # Export symbols for msvc shared tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True - # Honor BUILD_SHARED_LIBS from conan_toolchain (see https://github.com/conan-io/conan/issues/11840) - tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" tc.generate() deps = CMakeDeps(self) deps.generate() diff --git a/recipes/ccfits/all/test_v1_package/CMakeLists.txt b/recipes/ccfits/all/test_v1_package/CMakeLists.txt index 20c81e8e8eb120..0d20897301b68b 100644 --- a/recipes/ccfits/all/test_v1_package/CMakeLists.txt +++ b/recipes/ccfits/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES CXX) +project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(ccfits REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE ccfits::ccfits) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From d661fc09f096d3f1292b3b4cb92fc6be7d670dc1 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 17:37:11 +0200 Subject: [PATCH 0752/1140] (#19923) cprocessing: fix min msvc version + do not suggest unofficial CMake names + bump glfw & stb - fix msvc min version - do not suggest unofficial CMake names - bump glfw & stb - remove no_copy_source since there is a patch --- recipes/cprocessing/all/conanfile.py | 17 +++-------------- .../cprocessing/all/test_package/CMakeLists.txt | 4 ++-- .../all/test_v1_package/conanfile.py | 7 +++---- 3 files changed, 8 insertions(+), 20 deletions(-) diff --git a/recipes/cprocessing/all/conanfile.py b/recipes/cprocessing/all/conanfile.py index c9ae209b2576ff..cfb3a6e0339a8f 100644 --- a/recipes/cprocessing/all/conanfile.py +++ b/recipes/cprocessing/all/conanfile.py @@ -18,10 +18,8 @@ class CProcessingConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/maksmakuta/CProcessing" topics = ("processing", "opengl", "sketch", "header-only") - package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - no_copy_source = True @property def _min_cppstd(self): @@ -32,7 +30,7 @@ def _compilers_minimum_version(self): return { "gcc": "9", "Visual Studio": "16.2", - "msvc": "19.22", + "msvc": "192", "clang": "10", "apple-clang": "11", } @@ -41,10 +39,10 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("glfw/3.3.7") + self.requires("glfw/3.3.8") self.requires("glm/0.9.9.8") self.requires("glew/2.2.0") - self.requires("stb/cci.20210910") + self.requires("stb/cci.20220909") self.requires("opengl/system") def package_id(self): @@ -80,12 +78,3 @@ def package(self): def package_info(self): self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - - self.cpp_info.set_property("cmake_file_name", "CProcessing") - self.cpp_info.set_property("cmake_target_name", "CProcessing::CProcessing") - - # TODO: to remove in conan v2 once cmake_find_package_* generators removed - self.cpp_info.filenames["cmake_find_package"] = "CProcessing" - self.cpp_info.filenames["cmake_find_package_multi"] = "CProcessing" - self.cpp_info.names["cmake_find_package"] = "CProcessing" - self.cpp_info.names["cmake_find_package_multi"] = "CProcessing" diff --git a/recipes/cprocessing/all/test_package/CMakeLists.txt b/recipes/cprocessing/all/test_package/CMakeLists.txt index eeeb2f9006cc86..81c78689deb641 100644 --- a/recipes/cprocessing/all/test_package/CMakeLists.txt +++ b/recipes/cprocessing/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.15) project(test_package CXX) -find_package(CProcessing REQUIRED CONFIG) +find_package(cprocessing REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} CProcessing::CProcessing) +target_link_libraries(${PROJECT_NAME} cprocessing::cprocessing) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20) diff --git a/recipes/cprocessing/all/test_v1_package/conanfile.py b/recipes/cprocessing/all/test_v1_package/conanfile.py index 51cf79f1d6887b..38f4483872d47f 100644 --- a/recipes/cprocessing/all/test_v1_package/conanfile.py +++ b/recipes/cprocessing/all/test_v1_package/conanfile.py @@ -12,7 +12,6 @@ def build(self): cmake.build() def test(self): - test_file = os.path.join("bin", "test_package") - if self.settings.os == "Windows": - test_file += ".exe" - assert os.path.exists(test_file) + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 87dd8783f0e24c5217ce7d1feabc8b4a4015d24b Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 21 Sep 2023 00:53:27 +0900 Subject: [PATCH 0753/1140] (#19925) patchelf: add version 0.18.0 * patchelf: add version 0.18.0 * C++17 is required in 0.18 * drop support gcc 6,7 --- recipes/patchelf/all/conandata.yml | 3 +++ recipes/patchelf/all/conanfile.py | 30 ++++++++++++++++++++++++++++-- recipes/patchelf/config.yml | 2 ++ 3 files changed, 33 insertions(+), 2 deletions(-) diff --git a/recipes/patchelf/all/conandata.yml b/recipes/patchelf/all/conandata.yml index 9385c94daf7b23..0a5b78dee92b92 100644 --- a/recipes/patchelf/all/conandata.yml +++ b/recipes/patchelf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.18": + url: "https://github.com/NixOS/patchelf/releases/download/0.18.0/patchelf-0.18.0.tar.bz2" + sha256: "1952b2a782ba576279c211ee942e341748fdb44997f704dd53def46cd055470b" "0.13": url: "https://github.com/NixOS/patchelf/archive/0.13.tar.gz" sha256: "60c6aeadb673de9cc1838b630c81f61e31c501de324ef7f1e8094a2431197d09" diff --git a/recipes/patchelf/all/conanfile.py b/recipes/patchelf/all/conanfile.py index 904e2cf4472dbe..b41b9ff27f4773 100644 --- a/recipes/patchelf/all/conanfile.py +++ b/recipes/patchelf/all/conanfile.py @@ -1,11 +1,12 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.apple import is_apple_os -from conan.tools.build import cross_building +from conan.tools.build import cross_building, check_min_cppstd from conan.tools.env import VirtualBuildEnv, VirtualRunEnv from conan.tools.files import copy, get, rmdir from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain from conan.tools.layout import basic_layout +from conan.tools.scm import Version import os @@ -21,6 +22,23 @@ class PatchElfConan(ConanFile): license = "GPL-3.0-or-later" settings = "os", "arch", "compiler", "build_type" + @property + def _min_cppstd(self): + return "11" if Version(self.version) < "0.18" else "17" + + @property + def _compilers_minimum_version(self): + return { + "17": { + # patchelf/0.18.0 requires gcc >= 8 + "gcc": "8", + "clang": "5", + "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", + }, + }.get(self._min_cppstd, {}) + def layout(self): basic_layout(self, src_folder="src") @@ -29,7 +47,15 @@ def build_requirements(self): def validate(self): if not is_apple_os(self) and self.settings.os not in ("FreeBSD", "Linux"): - raise ConanInvalidConfiguration("PatchELF is only available for GNU-like operating systems (e.g. Linux)") + raise ConanInvalidConfiguration(f"{self.ref} is only available for GNU-like operating systems (e.g. Linux)") + + if self.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) diff --git a/recipes/patchelf/config.yml b/recipes/patchelf/config.yml index 0782807cb46ce3..f1bedb2bb26d8e 100644 --- a/recipes/patchelf/config.yml +++ b/recipes/patchelf/config.yml @@ -1,4 +1,6 @@ versions: + "0.18": + folder: all "0.13": folder: all "0.12": From 93bb4bdb7db44535300688284c596620210bf4a5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 18:07:50 +0200 Subject: [PATCH 0754/1140] (#19926) wyhash: add package_type --- recipes/wyhash/all/conanfile.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/wyhash/all/conanfile.py b/recipes/wyhash/all/conanfile.py index 34e8d0350c888c..5ef173786f6ec2 100644 --- a/recipes/wyhash/all/conanfile.py +++ b/recipes/wyhash/all/conanfile.py @@ -4,7 +4,7 @@ import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" class WyhashConan(ConanFile): name = "wyhash" @@ -13,6 +13,7 @@ class WyhashConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/wangyi-fudan/wyhash" topics = ("bloom-filter", "hash", "random-number-generators", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -23,7 +24,7 @@ def package_id(self): self.info.clear() def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) From 15694abde045ecc46d652795d7d91d4758015cf3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 20 Sep 2023 18:20:15 +0200 Subject: [PATCH 0755/1140] (#19928) beauty: use version range for openssl * use version range for openssl * fix traits * fix openssl traits * fix openssl traits again --- recipes/beauty/all/conanfile.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/recipes/beauty/all/conanfile.py b/recipes/beauty/all/conanfile.py index db4a11b8cb7245..2c01e08705dd5b 100644 --- a/recipes/beauty/all/conanfile.py +++ b/recipes/beauty/all/conanfile.py @@ -57,8 +57,11 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.79.0"), - self.requires("openssl/1.1.1s") + # beauty public headers include some boost headers. + # For example beauty/application.hpp includes boost/asio.hpp + self.requires("boost/1.79.0", transitive_headers=True) + # dependency of asio in boost, exposed in boost/asio/ssl/detail/openssl_types.hpp + self.requires("openssl/[>=1.1 <4]", transitive_headers=True, transitive_libs=True) def validate(self): if self.settings.compiler.get_safe("cppstd"): From 1ede4d191660c9fcc0b7848744a8bcfb14cff626 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 20 Sep 2023 19:22:12 +0200 Subject: [PATCH 0756/1140] (#19937) libselinux/all: bump deps * libselinux/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libselinux/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/libselinux/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libselinux/all/conanfile.py b/recipes/libselinux/all/conanfile.py index b6e6523df64530..b2c0ccb43ccfa9 100644 --- a/recipes/libselinux/all/conanfile.py +++ b/recipes/libselinux/all/conanfile.py @@ -54,7 +54,7 @@ def validate(self): def build_requirements(self): self.tool_requires("flex/2.6.4") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") def source(self): for download in self.conan_data["sources"][self.version]: From 87595db65de1c4314b1f401759a40136643be74a Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Tue, 26 Sep 2023 17:04:30 +0200 Subject: [PATCH 0757/1140] (#20062) Bump xz_utils for ffmpeg * bump version * range for zlib * revert zlib version * bump zlib --- recipes/ffmpeg/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/ffmpeg/all/conanfile.py b/recipes/ffmpeg/all/conanfile.py index 0ebfa544b38e23..05d36e30042e7b 100644 --- a/recipes/ffmpeg/all/conanfile.py +++ b/recipes/ffmpeg/all/conanfile.py @@ -257,11 +257,11 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/1.3") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.with_lzma: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.with_libiconv: self.requires("libiconv/1.17") if self.options.with_freetype: From 86fb18340f9ea290b0fc7d95b5c0779b8a0ef56a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 18:11:43 +0200 Subject: [PATCH 0758/1140] (#20147) Bump rsync's zlib requirement to [>=1.2.11 <2] range --- recipes/rsync/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/rsync/all/conanfile.py b/recipes/rsync/all/conanfile.py index 959c1c6253bb0d..c1c2765fe7084d 100644 --- a/recipes/rsync/all/conanfile.py +++ b/recipes/rsync/all/conanfile.py @@ -53,7 +53,7 @@ def requirements(self): self.requires("openssl/[>=1.1 <4]") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.5") From c873a00f074cc30c5bc3ea8e1af4431887bdee0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 18:28:14 +0200 Subject: [PATCH 0759/1140] (#20113) Bump tmx's zlib requirement to [>=1.2.11 <2] range --- recipes/tmx/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/tmx/all/conanfile.py b/recipes/tmx/all/conanfile.py index 5a3b3214bc42f6..53b614a724111f 100644 --- a/recipes/tmx/all/conanfile.py +++ b/recipes/tmx/all/conanfile.py @@ -54,7 +54,7 @@ def layout(self): def requirements(self): self.requires("libxml2/2.9.14") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.2") From 0f516b5106383302120e539ca7b0a4b9f3050f10 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 18:29:28 +0200 Subject: [PATCH 0760/1140] (#20115) Bump vtu11's zlib requirement to [>=1.2.11 <2] range * Bump vtu11's zlib requirement to [>=1.2.11 <2] range * Fix C++17 compilation --- recipes/vtu11/all/conandata.yml | 5 --- recipes/vtu11/all/conanfile.py | 22 ++++++------- ...0001-use-CPP17-filesystem-by-default.patch | 33 ------------------- 3 files changed, 11 insertions(+), 49 deletions(-) delete mode 100644 recipes/vtu11/all/patches/0001-use-CPP17-filesystem-by-default.patch diff --git a/recipes/vtu11/all/conandata.yml b/recipes/vtu11/all/conandata.yml index d079b9a80f8269..bb58ee7fddaeec 100644 --- a/recipes/vtu11/all/conandata.yml +++ b/recipes/vtu11/all/conandata.yml @@ -3,8 +3,3 @@ sources: url: - "https://github.com/phmkopp/vtu11/archive/refs/tags/v1.2.tar.gz" sha256: "c2b560d397c1a86c10e13f029b4ef08621f70ca4c897c44c19e7d025f11baec3" -patches: - "1.2": - - patch_file: "patches/0001-use-CPP17-filesystem-by-default.patch" - patch_description: "Use C++17 filesystem by default when compiling with C++17" - patch_type: "portability" diff --git a/recipes/vtu11/all/conanfile.py b/recipes/vtu11/all/conanfile.py index 389169052faba6..db420586fda774 100644 --- a/recipes/vtu11/all/conanfile.py +++ b/recipes/vtu11/all/conanfile.py @@ -1,9 +1,10 @@ from conan import ConanFile -from conan.tools.build import check_min_cppstd, valid_min_cppstd -from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy from conan.tools.layout import basic_layout import os +from conan.tools.microsoft import is_msvc required_conan_version = ">=1.53.0" @@ -14,7 +15,9 @@ class PackageConan(ConanFile): license = "BSD-3-Clause" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/phmkopp/vtu11" - topics = ("vtu", "c++11") + topics = ("vtu", "c++11", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True options = { @@ -28,15 +31,12 @@ class PackageConan(ConanFile): def _min_cppstd(self): return 11 - def export_sources(self): - export_conandata_patches(self) - def layout(self): basic_layout(self, src_folder="src") def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13", transitive_headers=True) + self.requires("zlib/[>=1.2.11 <2]") def package_id(self): self.info.clear() @@ -48,10 +48,6 @@ def validate(self): def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) - def build(self): - if valid_min_cppstd(self, 17): - apply_conandata_patches(self) - def package(self): copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) copy( @@ -68,6 +64,10 @@ def package_info(self): if self.options.with_zlib: self.cpp_info.defines = ["VTU11_ENABLE_ZLIB"] + # The library uses __cplusplus for feature detection, ensure vs returns the proper one + if is_msvc(self): + self.cpp_info.cxxflags.append("/Zc:__cplusplus") + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "vtu11" self.cpp_info.filenames["cmake_find_package_multi"] = "vtu11" diff --git a/recipes/vtu11/all/patches/0001-use-CPP17-filesystem-by-default.patch b/recipes/vtu11/all/patches/0001-use-CPP17-filesystem-by-default.patch deleted file mode 100644 index eb80c0e4f2b2f3..00000000000000 --- a/recipes/vtu11/all/patches/0001-use-CPP17-filesystem-by-default.patch +++ /dev/null @@ -1,33 +0,0 @@ ---- a/vtu11/inc/alias.hpp -+++ b/vtu11/inc/alias.hpp -@@ -40,20 +40,14 @@ using Byte = unsigned char; - #define VTU11_ASCII_FLOATING_POINT_FORMAT "%.6g" - #endif - --// To dynamically select std::filesystem where available, you could use: --#if defined(__cplusplus) && __cplusplus >= 201703L -- #if __has_include() // has_include is C++17 -- #include -- namespace vtu11fs = std::filesystem; -- #elif __has_include() -- #include -- namespace vtu11fs = std::experimental::filesystem; -- #else -- #include "inc/filesystem.hpp" -- namespace vtu11fs = ghc::filesystem; -- #endif -+#if __has_include() // has_include is C++17 -+ #include -+ namespace vtu11fs = std::filesystem; -+#elif __has_include() -+ #include -+ namespace vtu11fs = std::experimental::filesystem; - #else -- #include "vtu11/inc/filesystem.hpp" -+ #include "inc/filesystem.hpp" - namespace vtu11fs = ghc::filesystem; - #endif - --- -2.34.1 - From 83b27f5c733da6d4371dd1fe477109d52d022a6d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 18:38:51 +0200 Subject: [PATCH 0761/1140] (#20144) Bump freeimage's zlib requirement to [>=1.2.11 <2] range --- recipes/freeimage/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/freeimage/all/conanfile.py b/recipes/freeimage/all/conanfile.py index 5f0684be02c517..8ea9581a8d7f16 100644 --- a/recipes/freeimage/all/conanfile.py +++ b/recipes/freeimage/all/conanfile.py @@ -67,7 +67,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": From 70157ec8ae44e8a02aa429f7733478dcdc8ba5ba Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Tue, 26 Sep 2023 21:45:48 +0400 Subject: [PATCH 0762/1140] (#19681) openvino: add 2023.1.0 version * [openvino] new recipe * addressed review comments --- recipes/openvino/all/conandata.yml | 34 ++ recipes/openvino/all/conanfile.py | 381 ++++++++++++++++++ .../0001-cpu-plugin-compilation-c++17.patch | 16 + .../0002-core-compilation-c++17.patch | 46 +++ .../0003-fixed-gpu-with-onednn-build.patch | 56 +++ .../openvino/all/test_package/CMakeLists.txt | 48 +++ .../openvino/all/test_package/conanfile.py | 49 +++ .../all/test_package/test_package.cpp | 102 +++++ recipes/openvino/config.yml | 3 + 9 files changed, 735 insertions(+) create mode 100644 recipes/openvino/all/conandata.yml create mode 100644 recipes/openvino/all/conanfile.py create mode 100644 recipes/openvino/all/patches/2023.1.0/0001-cpu-plugin-compilation-c++17.patch create mode 100644 recipes/openvino/all/patches/2023.1.0/0002-core-compilation-c++17.patch create mode 100644 recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch create mode 100644 recipes/openvino/all/test_package/CMakeLists.txt create mode 100644 recipes/openvino/all/test_package/conanfile.py create mode 100644 recipes/openvino/all/test_package/test_package.cpp create mode 100644 recipes/openvino/config.yml diff --git a/recipes/openvino/all/conandata.yml b/recipes/openvino/all/conandata.yml new file mode 100644 index 00000000000000..375c797c46fca2 --- /dev/null +++ b/recipes/openvino/all/conandata.yml @@ -0,0 +1,34 @@ +sources: + "2023.1.0": + "openvino": + url: "https://github.com/openvinotoolkit/openvino/archive/47b736f63edda256d66e2bbb572f42a9d6549f6e.tar.gz" + sha256: "8a1dd5b35fe4b60440e97ee61e12e01aa4dd78b5be30550aa08fcd96c416e1d7" + "arm_compute": + url: "https://github.com/ARM-software/ComputeLibrary/archive/refs/tags/v23.02.1.tar.gz" + sha256: "c3a443e26539f866969242e690cf0651ef629149741ee18732f954c734da6763" + "onednn_cpu": + url: "https://github.com/openvinotoolkit/oneDNN/archive/ae825539bd850d1ad5c83d4bb0d56c65d46d5842.tar.gz" + sha256: "1204df17785c8603f9dfa1f4f91e91e5ffd4391bf7680d2b256de2513490ebee" + "mlas": + url: "https://github.com/openvinotoolkit/mlas/archive/c7c8a631315000f17c650af34431009d2f22129c.tar.gz" + sha256: "7b790dfeef8e1dd612f920c85186c52ad3a3e2245e2a2afd6cc91ce4b1dc64a9" + "onednn_gpu": + url: "https://github.com/oneapi-src/oneDNN/archive/4b82a66ed38ecaa993352e5cc6ed7753656b8a26.tar.gz" + sha256: "cb17c003fe51bc9b4e20189573956b4446468162adf0fc4cea2ee0820cff0cd0" +patches: + "2023.1.0": + - patch_file: "patches/2023.1.0/0001-cpu-plugin-compilation-c++17.patch" + patch_description: "Fixed CPU plugin compilation with C++17" + patch_type: "portability" + patch_source: "https://github.com/openvinotoolkit/openvino/pull/19628" + - patch_file: "patches/2023.1.0/0002-core-compilation-c++17.patch" + patch_description: "Fixed OpenVINO Core compilation with C++17" + patch_type: "portability" + patch_source: "https://github.com/openvinotoolkit/openvino/pull/19707" + - patch_file: "patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch" + patch_description: "Fixed Intel GPU plugin with oneDNN" + patch_type: "portability" + # severals PR are merged into a single patch including: + # https://github.com/openvinotoolkit/openvino/pull/19668, + # https://github.com/openvinotoolkit/openvino/pull/19715 and + patch_source: "https://github.com/openvinotoolkit/openvino/pull/19716" diff --git a/recipes/openvino/all/conanfile.py b/recipes/openvino/all/conanfile.py new file mode 100644 index 00000000000000..de1677f7edab65 --- /dev/null +++ b/recipes/openvino/all/conanfile.py @@ -0,0 +1,381 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd, cross_building +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, rmdir +import os + +required_conan_version = ">=1.60.0 <2.0 || >=2.0.8" + +class OpenvinoConan(ConanFile): + name = "openvino" + + # Optional metadata + license = "Apache-2.0" + homepage = "https://github.com/openvinotoolkit/openvino" + url = "https://github.com/conan-io/conan-center-index" + description = "Open Visual Inference And Optimization toolkit for AI inference" + topics = ("nlp", "natural-language-processing", "ai", "computer-vision", "deep-learning", "transformers", "inference", + "speech-recognition", "yolo", "performance-boost", "diffusion-models", "recommendation-system", "stable-diffusion", + "generative-ai", "llm-inference", "optimize-ai", "deploy-ai") + package_id_non_embed_mode = "patch_mode" + package_type = "library" + short_paths = True + no_copy_source = True + + # Binary configuration + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + # HW plugins + "enable_cpu": [True, False], + "enable_gpu": [True, False], + # SW plugins + "enable_auto": [True, False], + "enable_hetero": [True, False], + "enable_auto_batch": [True, False], + # Frontends + "enable_ir_frontend": [True, False], + "enable_onnx_frontend": [True, False], + "enable_tf_frontend": [True, False], + "enable_tf_lite_frontend": [True, False], + "enable_paddle_frontend": [True, False], + "enable_pytorch_frontend": [True, False] + } + default_options = { + "shared": False, + "fPIC": True, + # HW plugins + "enable_cpu": True, + "enable_gpu": True, + # SW plugins + "enable_auto": True, + "enable_hetero": True, + "enable_auto_batch": True, + # Frontends + "enable_ir_frontend": True, + "enable_onnx_frontend": True, + "enable_tf_frontend": True, + "enable_tf_lite_frontend": True, + "enable_paddle_frontend": True, + "enable_pytorch_frontend": True + } + + @property + def _protobuf_required(self): + return self.options.enable_tf_frontend or self.options.enable_onnx_frontend or self.options.enable_paddle_frontend + + @property + def _target_arm(self): + return "arm" in self.settings.arch + + @property + def _target_x86_64(self): + return self.settings.arch == "x86_64" + + @property + def _gna_option_available(self): + return self.settings.os in ["Linux", "Windows"] and self._target_x86_64 and Version(self.version) < "2024.0.0" + + @property + def _gpu_option_available(self): + return self.settings.os != "Macos" and self._target_x86_64 + + @property + def _preprocessing_available(self): + return Version(self.version) < "2023.2.0" + + @property + def _onnx_version(self): + if Version(self.version) == "2023.1.0": + return "1.13.1" + + @property + def _compilers_minimum_version(self): + return { + "gcc": "7", + "clang": "9", + "apple-clang": "11", + "Visual Studio": "16", + "msvc": "192", + } + + def source(self): + get(self, **self.conan_data["sources"][self.version]["openvino"], strip_root=True) + get(self, **self.conan_data["sources"][self.version]["onednn_cpu"], strip_root=True, + destination=f"{self.source_folder}/src/plugins/intel_cpu/thirdparty/onednn") + get(self, **self.conan_data["sources"][self.version]["mlas"], strip_root=True, + destination=f"{self.source_folder}/src/plugins/intel_cpu/thirdparty/mlas") + get(self, **self.conan_data["sources"][self.version]["arm_compute"], strip_root=True, + destination=f"{self.source_folder}/src/plugins/intel_cpu/thirdparty/ComputeLibrary") + get(self, **self.conan_data["sources"][self.version]["onednn_gpu"], strip_root=True, + destination=f"{self.source_folder}/src/plugins/intel_gpu/thirdparty/onednn_gpu") + apply_conandata_patches(self) + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + if not self._gpu_option_available: + del self.options.enable_gpu + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + if self._protobuf_required: + # we need to use static protobuf to overcome potential issues with multiple registrations inside + # protobuf when frontends (implemented as plugins) are loaded multiple times in runtime + self.options["protobuf"].shared = False + # disable GPU plugin when clang is used; plugin has issues with static variables initialization + if self.settings.compiler == "clang" and self.options.get_safe("enable_gpu"): + self.options.enable_gpu = False + + def build_requirements(self): + if self._target_arm: + self.tool_requires("scons/[>=4.2.0]") + if cross_building(self): + if self._protobuf_required: + self.tool_requires("protobuf/") + if self.options.enable_tf_lite_frontend: + self.tool_requires("flatbuffers/") + if not self.options.shared: + self.tool_requires("cmake/[>=3.18]") + + def requirements(self): + self.requires("onetbb/2021.9.0") + self.requires("pugixml/1.13") + if self._target_x86_64: + self.requires("xbyak/6.73") + if self.options.get_safe("enable_gpu"): + self.requires("opencl-icd-loader/2023.04.17") + if self._protobuf_required: + self.requires("protobuf/3.21.12") + if self.options.enable_tf_frontend: + self.requires("snappy/1.1.10") + if self.options.enable_onnx_frontend: + self.requires(f"onnx/{self._onnx_version}") + if self.options.enable_tf_lite_frontend: + self.requires("flatbuffers/22.9.24") + if self._preprocessing_available: + self.requires("ade/0.1.2c") + + def layout(self): + cmake_layout(self, src_folder="src") + + def generate(self): + deps = CMakeDeps(self) + deps.generate() + + toolchain = CMakeToolchain(self) + # HW plugins + toolchain.cache_variables["ENABLE_INTEL_CPU"] = self.options.enable_cpu + if self._gpu_option_available: + toolchain.cache_variables["ENABLE_INTEL_GPU"] = self.options.enable_gpu + toolchain.cache_variables["ENABLE_ONEDNN_FOR_GPU"] = self.options.shared + if self._gna_option_available: + toolchain.cache_variables["ENABLE_INTEL_GNA"] = False + # SW plugins + toolchain.cache_variables["ENABLE_AUTO"] = self.options.enable_auto + toolchain.cache_variables["ENABLE_MULTI"] = self.options.enable_auto + toolchain.cache_variables["ENABLE_AUTO_BATCH"] = self.options.enable_auto_batch + toolchain.cache_variables["ENABLE_HETERO"] = self.options.enable_hetero + # Frontends + toolchain.cache_variables["ENABLE_OV_IR_FRONTEND"] = self.options.enable_ir_frontend + toolchain.cache_variables["ENABLE_OV_PADDLE_FRONTEND"] = self.options.enable_paddle_frontend + toolchain.cache_variables["ENABLE_OV_TF_FRONTEND"] = self.options.enable_tf_frontend + toolchain.cache_variables["ENABLE_OV_TF_LITE_FRONTEND"] = self.options.enable_tf_lite_frontend + toolchain.cache_variables["ENABLE_OV_ONNX_FRONTEND"] = self.options.enable_onnx_frontend + toolchain.cache_variables["ENABLE_OV_PYTORCH_FRONTEND"] = self.options.enable_pytorch_frontend + # Dependencies + toolchain.cache_variables["ENABLE_SYSTEM_TBB"] = True + toolchain.cache_variables["ENABLE_TBBBIND_2_5"] = False + toolchain.cache_variables["ENABLE_SYSTEM_PUGIXML"] = True + if self._protobuf_required: + toolchain.cache_variables["ENABLE_SYSTEM_PROTOBUF"] = True + if self.options.enable_tf_frontend: + toolchain.cache_variables["ENABLE_SYSTEM_SNAPPY"] = True + if self.options.enable_tf_lite_frontend: + toolchain.cache_variables["ENABLE_SYSTEM_FLATBUFFERS"] = True + if self.options.get_safe("enable_gpu"): + toolchain.cache_variables["ENABLE_SYSTEM_OPENCL"] = True + # misc + if self._preprocessing_available: + toolchain.cache_variables["ENABLE_GAPI_PREPROCESSING"] = True + toolchain.cache_variables["BUILD_SHARED_LIBS"] = self.options.shared + toolchain.cache_variables["CPACK_GENERATOR"] = "CONAN" + toolchain.cache_variables["ENABLE_PROFILING_ITT"] = False + toolchain.cache_variables["ENABLE_PYTHON"] = False + toolchain.cache_variables["ENABLE_PROXY"] = False + toolchain.cache_variables["ENABLE_WHEEL"] = False + toolchain.cache_variables["ENABLE_CPPLINT"] = False + toolchain.cache_variables["ENABLE_NCC_STYLE"] = False + toolchain.cache_variables["ENABLE_SAMPLES"] = False + toolchain.cache_variables["ENABLE_TEMPLATE"] = False + toolchain.generate() + + def validate_build(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, "11") + + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) + compiler_version = Version(self.settings.compiler.version) + if minimum_version and compiler_version < minimum_version: + raise ConanInvalidConfiguration( + f"{self.ref} requires {self.settings.compiler} ver. {minimum_version}, provided ver. {compiler_version}.", + ) + + # OpenVINO has unresolved symbols, when clang is used with libc++ + if self.settings.compiler == "clang" and self.settings.compiler.libcxx == "libc++": + raise ConanInvalidConfiguration( + f"{self.ref} cannot be built with clang and libc++ due to unresolved symbols. " + f"Please, use libstdc++ instead." + ) + + if self.settings.os == "Emscripten": + raise ConanInvalidConfiguration(f"{self.ref} does not support Emscripten") + + # TODO: resolve it later, since it is not critical for now + # Conan Center CI fails with our of memory error when building OpenVINO + if self.settings.build_type == "Debug": + raise ConanInvalidConfiguration(f"{self.ref} does not support Debug build type") + + def validate(self): + # dynamically compiled frontends cannot be run against dynamic protobuf + if self._protobuf_required and self.options.shared and self.dependencies["protobuf"].options.shared: + raise ConanInvalidConfiguration(f"{self.ref}:shared=True requires protobuf:shared=False for correct work.") + + if self.options.get_safe("enable_gpu"): + # GPU does not support oneDNN in static build configuration, warn about it + if not self.options.shared: + self.output.warning(f"{self.name} recipe builds GPU plugin without oneDNN (dGPU) support during static build.") + + # GPU plugin is currently not stable when compiled with clang compiler + if self.settings.compiler == "clang": + raise ConanInvalidConfiguration( + "GPU plugin cannot be built with clang compiler." + "Please, disable GPU plugin (openvino/*:enable_gpu=False) or change the compiler" + ) + + def build(self): + cmake = CMake(self) + cmake.configure() + for target in ["ov_frontends", "ov_plugins", "openvino_c"]: + cmake.build(target=target) + + def package(self): + cmake = CMake(self) + cmake.install() + # remove cmake and .pc files, since they will be generated later by Conan itself in package_info() + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + self.cpp_info.set_property("cmake_find_mode", "config") + self.cpp_info.set_property("cmake_file_name", "OpenVINO") + self.cpp_info.set_property("pkg_config_name", "openvino") + + openvino_runtime = self.cpp_info.components["Runtime"] + openvino_runtime.set_property("cmake_target_name", "openvino::runtime") + openvino_runtime.requires = ["onetbb::libtbb", "pugixml::pugixml"] + openvino_runtime.libs = ["openvino_c", "openvino"] + if self._preprocessing_available: + openvino_runtime.requires.append("ade::ade") + if self._target_x86_64: + openvino_runtime.requires.append("xbyak::xbyak") + if self.settings.os in ["Linux", "Android", "FreeBSD", "SunOS", "AIX"]: + openvino_runtime.system_libs = ["m", "dl", "pthread"] + if self.settings.os == "Windows": + openvino_runtime.system_libs.append("shlwapi") + if self._preprocessing_available: + openvino_runtime.system_libs.extend(["wsock32", "ws2_32"]) + + # Have to expose all internal libraries for static libraries case + if not self.options.shared: + # HW plugins + if self.options.enable_cpu: + openvino_runtime.libs.append("openvino_arm_cpu_plugin" if self._target_arm else \ + "openvino_intel_cpu_plugin") + openvino_runtime.libs.extend(["openvino_onednn_cpu", "openvino_snippets", "mlas"]) + if self._target_arm: + openvino_runtime.libs.append("arm_compute-static") + if self.options.get_safe("enable_gpu"): + openvino_runtime.libs.extend(["openvino_intel_gpu_plugin", "openvino_intel_gpu_graph", + "openvino_intel_gpu_runtime", "openvino_intel_gpu_kernels"]) + # SW plugins + if self.options.enable_auto: + openvino_runtime.libs.append("openvino_auto_plugin") + if self.options.enable_hetero: + openvino_runtime.libs.append("openvino_hetero_plugin") + if self.options.enable_auto_batch: + openvino_runtime.libs.append("openvino_auto_batch_plugin") + # Preprocessing should come after plugins, because plugins depend on it + if self._preprocessing_available: + openvino_runtime.libs.extend(["openvino_gapi_preproc", "fluid"]) + # Frontends + if self.options.enable_ir_frontend: + openvino_runtime.libs.append("openvino_ir_frontend") + if self.options.enable_onnx_frontend: + openvino_runtime.libs.extend(["openvino_onnx_frontend", "openvino_onnx_common"]) + openvino_runtime.requires.extend(["protobuf::libprotobuf", "onnx::onnx"]) + if self.options.enable_tf_frontend: + openvino_runtime.libs.extend(["openvino_tensorflow_frontend", "openvino_tensorflow_common"]) + openvino_runtime.requires.extend(["protobuf::libprotobuf", "snappy::snappy"]) + if self.options.enable_tf_lite_frontend: + openvino_runtime.libs.extend(["openvino_tensorflow_lite_frontend", "openvino_tensorflow_common"]) + openvino_runtime.requires.extend(["flatbuffers::flatbuffers"]) + if self.options.enable_paddle_frontend: + openvino_runtime.libs.append("openvino_paddle_frontend") + openvino_runtime.requires.append("protobuf::libprotobuf") + if self.options.enable_pytorch_frontend: + openvino_runtime.libs.append("openvino_pytorch_frontend") + # Common private dependencies should go last, because they satisfy dependencies for all other libraries + openvino_runtime.libs.extend(["openvino_reference", "openvino_builders", + "openvino_shape_inference", "openvino_itt", + # utils goes last since all others depend on it + "openvino_util"]) + # set 'openvino' once again for transformations objects files (cyclic dependency) + # openvino_runtime.libs.append("openvino") + full_openvino_lib_path = os.path.join(self.package_folder, "lib", "openvino.lib").replace("\\", "/") if self.settings.os == "Windows" else \ + os.path.join(self.package_folder, "lib", "libopenvino.a") + openvino_runtime.system_libs.insert(0, full_openvino_lib_path) + # Add definition to prevent symbols importing + openvino_runtime.defines = ["OPENVINO_STATIC_LIBRARY"] + + if self.options.get_safe("enable_gpu"): + openvino_runtime.requires.append("opencl-icd-loader::opencl-icd-loader") + if self.settings.os == "Windows": + openvino_runtime.system_libs.append("setupapi") + + if self.options.enable_onnx_frontend: + openvino_onnx = self.cpp_info.components["ONNX"] + openvino_onnx.set_property("cmake_target_name", "openvino::frontend::onnx") + openvino_onnx.libs = ["openvino_onnx_frontend"] + openvino_onnx.requires = ["Runtime", "onnx::onnx", "protobuf::libprotobuf"] + + if self.options.enable_paddle_frontend: + openvino_paddle = self.cpp_info.components["Paddle"] + openvino_paddle.set_property("cmake_target_name", "openvino::frontend::paddle") + openvino_paddle.libs = ["openvino_paddle_frontend"] + openvino_paddle.requires = ["Runtime", "protobuf::libprotobuf"] + + if self.options.enable_tf_frontend: + openvino_tensorflow = self.cpp_info.components["TensorFlow"] + openvino_tensorflow.set_property("cmake_target_name", "openvino::frontend::tensorflow") + openvino_tensorflow.libs = ["openvino_tensorflow_frontend"] + openvino_tensorflow.requires = ["Runtime", "protobuf::libprotobuf", "snappy::snappy"] + + if self.options.enable_pytorch_frontend: + openvino_pytorch = self.cpp_info.components["PyTorch"] + openvino_pytorch.set_property("cmake_target_name", "openvino::frontend::pytorch") + openvino_pytorch.libs = ["openvino_pytorch_frontend"] + openvino_pytorch.requires = ["Runtime"] + + if self.options.enable_tf_lite_frontend: + openvino_tensorflow_lite = self.cpp_info.components["TensorFlowLite"] + openvino_tensorflow_lite.set_property("cmake_target_name", "openvino::frontend::tensorflow_lite") + openvino_tensorflow_lite.libs = ["openvino_tensorflow_lite_frontend"] + openvino_tensorflow_lite.requires = ["Runtime", "flatbuffers::flatbuffers"] diff --git a/recipes/openvino/all/patches/2023.1.0/0001-cpu-plugin-compilation-c++17.patch b/recipes/openvino/all/patches/2023.1.0/0001-cpu-plugin-compilation-c++17.patch new file mode 100644 index 00000000000000..da6548b7c91159 --- /dev/null +++ b/recipes/openvino/all/patches/2023.1.0/0001-cpu-plugin-compilation-c++17.patch @@ -0,0 +1,16 @@ +diff --git a/src/plugins/intel_cpu/src/cpu_tensor.cpp b/src/plugins/intel_cpu/src/cpu_tensor.cpp +index 48d8fdd4be..815edd9309 100644 +--- a/src/plugins/intel_cpu/src/cpu_tensor.cpp ++++ b/src/plugins/intel_cpu/src/cpu_tensor.cpp +@@ -68,8 +68,9 @@ void Tensor::update_strides() const { + OPENVINO_ASSERT(blocked_desc, "not a valid blocked memory descriptor."); + auto& strides = blocked_desc->getStrides(); + m_strides.resize(strides.size()); +- std::transform(strides.cbegin(), strides.cend(), m_strides.begin(), +- std::bind1st(std::multiplies(), m_element_type.size())); ++ std::transform(strides.cbegin(), strides.cend(), m_strides.begin(), [this] (const size_t stride) { ++ return stride * m_element_type.size(); ++ }); + } + + void* Tensor::data(const element::Type& element_type) const { diff --git a/recipes/openvino/all/patches/2023.1.0/0002-core-compilation-c++17.patch b/recipes/openvino/all/patches/2023.1.0/0002-core-compilation-c++17.patch new file mode 100644 index 00000000000000..2df86d8ed0ec68 --- /dev/null +++ b/recipes/openvino/all/patches/2023.1.0/0002-core-compilation-c++17.patch @@ -0,0 +1,46 @@ +diff --git a/src/frontends/common/src/utils.cpp b/src/frontends/common/src/utils.cpp +index 8ef7481551..3a0db585fd 100644 +--- a/src/frontends/common/src/utils.cpp ++++ b/src/frontends/common/src/utils.cpp +@@ -12,10 +12,6 @@ + # include + # include + # include +-# ifdef OPENVINO_ENABLE_UNICODE_PATH_SUPPORT +-# include +-# include +-# endif + #else + # if defined(WINAPI_FAMILY) && !WINAPI_PARTITION_DESKTOP + # error "Only WINAPI_PARTITION_DESKTOP is supported, because of GetModuleHandleEx[A|W]" +diff --git a/src/frontends/paddle/src/input_model.cpp b/src/frontends/paddle/src/input_model.cpp +index 6987b3285e..287fa5e54a 100644 +--- a/src/frontends/paddle/src/input_model.cpp ++++ b/src/frontends/paddle/src/input_model.cpp +@@ -13,14 +13,10 @@ + #include "openvino/frontend/paddle/node_context.hpp" + #include "openvino/opsets/opset7.hpp" + #include "openvino/util/common_util.hpp" ++#include "openvino/util/file_util.hpp" + #include "paddle_utils.hpp" + #include "place.hpp" + +-#if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT) && defined(_WIN32) +-# include +-# include +-#endif +- + namespace ov { + namespace frontend { + namespace paddle { +@@ -169,9 +165,7 @@ std::basic_string get_const_path(const std::basic_string& folder_with_weig + #if defined(OPENVINO_ENABLE_UNICODE_PATH_SUPPORT) && defined(_WIN32) + template <> + std::basic_string get_const_path(const std::basic_string& folder, const std::string& name) { +- std::wstring_convert> converter; +- std::wstring _name = converter.from_bytes(name); +- return folder + paddle::get_path_sep() + _name; ++ return folder + paddle::get_path_sep() + ov::util::string_to_wstring(name); + } + #endif + diff --git a/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch b/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch new file mode 100644 index 00000000000000..fc7beb3b5ec368 --- /dev/null +++ b/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch @@ -0,0 +1,56 @@ +diff --git a/src/plugins/intel_gpu/thirdparty/CMakeLists.txt b/src/plugins/intel_gpu/thirdparty/CMakeLists.txt +index c7c616d0df..63eeade1f1 100644 +--- a/src/plugins/intel_gpu/thirdparty/CMakeLists.txt ++++ b/src/plugins/intel_gpu/thirdparty/CMakeLists.txt +@@ -88,17 +88,12 @@ if(ENABLE_ONEDNN_FOR_GPU) + endif() + + ExternalProject_Add(onednn_gpu_build ++ # Directory Options: ++ PREFIX "${ONEDNN_PREFIX_DIR}" + SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/onednn_gpu" + BINARY_DIR "${ONEDNN_BUILD_DIR}" + INSTALL_DIR "${ONEDNN_INSTALL_DIR}" +- PREFIX "${ONEDNN_PREFIX_DIR}" +- EXCLUDE_FROM_ALL ON +- CMAKE_CACHE_ARGS +- # The arguments below requires list to be passed as argument +- # which doesn't work properly when passed to CMAKE_ARGS. +- # Thus we pass it via CMAKE_CACHE_ARGS +- "-DDNNL_ENABLE_PRIMITIVE:STRING=${ONEDNN_ENABLED_PRIMITIVES}" +- "-DDNNL_ENABLE_PRIMITIVE_GPU_ISA:STRING=${ONEDNN_ENABLED_ISA}" ++ # Configure Step Options: + CMAKE_ARGS + ${cmake_extra_args} + "-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}" +@@ -114,7 +109,6 @@ if(ENABLE_ONEDNN_FOR_GPU) + "-DDNNL_GPU_RUNTIME=OCL" + "-DDNNL_LIBRARY_NAME=openvino_onednn_gpu" + "-DCMAKE_INSTALL_PREFIX=${ONEDNN_INSTALL_DIR}" +- "-DCMAKE_INSTALL_LIBDIR=lib/$" + "-DDNNL_ENABLE_CONCURRENT_EXEC=ON" + "-DDNNL_ENABLE_PRIMITIVE_CACHE=OFF" + "-DDNNL_ENABLE_WORKLOAD=INFERENCE" +@@ -129,10 +123,21 @@ if(ENABLE_ONEDNN_FOR_GPU) + # specifically for Conan, because it overrides CMAKE_PREFIX_PATH and oneDNN's FindOpenCL.cmake is ignored + # Conan's FindOpenCL.cmake module does not set OpenCL_INCLUDE_DIRS, so we need to set it manually + "-DOpenCL_INCLUDE_DIRS=$" ++ # Conan calls cmake with default value for CMP0091, so we have to bypass it to oneDNN build ++ # because we bypass conan_toolchain.cmake via CMAKE_TOOLCHAIN_FILE ++ "-DCMAKE_POLICY_DEFAULT_CMP0091=NEW" ++ CMAKE_CACHE_ARGS ++ # The arguments below requires list to be passed as argument ++ # which doesn't work properly when passed to CMAKE_ARGS. ++ # Thus we pass it via CMAKE_CACHE_ARGS ++ "-DDNNL_ENABLE_PRIMITIVE:STRING=${ONEDNN_ENABLED_PRIMITIVES}" ++ "-DDNNL_ENABLE_PRIMITIVE_GPU_ISA:STRING=${ONEDNN_ENABLED_ISA}" ++ # Target Options: ++ EXCLUDE_FROM_ALL ON + ) + add_library(onednn_gpu_tgt INTERFACE) + set_target_properties(onednn_gpu_tgt PROPERTIES +- INTERFACE_LINK_DIRECTORIES "${ONEDNN_INSTALL_DIR}/lib/$" ++ INTERFACE_LINK_DIRECTORIES "${ONEDNN_INSTALL_DIR}/lib" + INTERFACE_LINK_LIBRARIES "openvino_onednn_gpu" + INTERFACE_INCLUDE_DIRECTORIES "${ONEDNN_INSTALL_DIR}/include" + INTERFACE_COMPILE_DEFINITIONS ENABLE_ONEDNN_FOR_GPU diff --git a/recipes/openvino/all/test_package/CMakeLists.txt b/recipes/openvino/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..032463e0d1754a --- /dev/null +++ b/recipes/openvino/all/test_package/CMakeLists.txt @@ -0,0 +1,48 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +macro(add_component def comp) + if(${def}) + list(APPEND OpenVINO_COMPONENTS ${comp}) + endif() +endmacro() + +add_component(ENABLE_ONNX_FRONTEND ONNX) +add_component(ENABLE_PADDLE_FRONTEND Paddle) +add_component(ENABLE_TF_FRONTEND TensorFlow) +add_component(ENABLE_TF_LITE_FRONTEND TensorFlowLite) +add_component(ENABLE_PYTORCH_FRONTEND PyTroch) + +find_package(OpenVINO REQUIRED COMPONENTS Runtime ${OpenVINO_COMPONENTS}) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE openvino::runtime) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) + +function(add_plugin def) + if(${def}) + target_compile_definitions(${PROJECT_NAME} PRIVATE ${def}) + endif() +endfunction() + +add_plugin(ENABLE_INTEL_CPU) +add_plugin(ENABLE_INTEL_GPU) +add_plugin(ENABLE_AUTO) +add_plugin(ENABLE_HETERO) +add_plugin(ENABLE_AUTO_BATCH) + +function(add_frontend def frontend) + if(${def}) + target_compile_definitions(${PROJECT_NAME} PRIVATE ${def}) + if(NOT TARGET openvino::frontend::${frontend}) + message(FATAL_ERROR "Target for ${frontend} has not been created") + endif() + endif() +endfunction() + +add_plugin(ENABLE_IR_FRONTEND) +add_frontend(ENABLE_ONNX_FRONTEND onnx) +add_frontend(ENABLE_PADDLE_FRONTEND paddle) +add_frontend(ENABLE_TF_FRONTEND tensorflow) +add_frontend(ENABLE_TF_LITE_FRONTEND tensorflow_lite) +add_frontend(ENABLE_PYTORCH_FRONTEND pytorch) diff --git a/recipes/openvino/all/test_package/conanfile.py b/recipes/openvino/all/test_package/conanfile.py new file mode 100644 index 00000000000000..2cbd00abf5b8b9 --- /dev/null +++ b/recipes/openvino/all/test_package/conanfile.py @@ -0,0 +1,49 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def generate(self): + deps = CMakeDeps(self) + # deps.check_components_exist = True + deps.generate() + + tc = CMakeToolchain(self) + tc.variables["CMAKE_VERBOSE_MAKEFILE"] = True + # HW plugins + tc.variables["ENABLE_INTEL_CPU"] = self.dependencies[self.tested_reference_str].options.enable_cpu + tc.variables["ENABLE_INTEL_GPU"] = self.dependencies[self.tested_reference_str].options.get_safe("enable_gpu", False) + # SW plugins + tc.variables["ENABLE_AUTO"] = self.dependencies[self.tested_reference_str].options.enable_auto + tc.variables["ENABLE_HETERO"] = self.dependencies[self.tested_reference_str].options.enable_hetero + tc.variables["ENABLE_AUTO_BATCH"] = self.dependencies[self.tested_reference_str].options.enable_auto_batch + # Frontends + tc.variables["ENABLE_IR_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_ir_frontend + tc.variables["ENABLE_ONNX_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_onnx_frontend + tc.variables["ENABLE_TF_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_tf_frontend + tc.variables["ENABLE_TF_LITE_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_tf_lite_frontend + tc.variables["ENABLE_PADDLE_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_paddle_frontend + tc.variables["ENABLE_PYTORCH_FRONTEND"] = self.dependencies[self.tested_reference_str].options.enable_pytorch_frontend + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/openvino/all/test_package/test_package.cpp b/recipes/openvino/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..4160d5eb98fcc8 --- /dev/null +++ b/recipes/openvino/all/test_package/test_package.cpp @@ -0,0 +1,102 @@ +#include +#include +#include + +#define OV_SUCCESS(statement) \ + if ((statement) != 0) \ + return 1; + +#define OV_FAIL(statement) \ + if ((statement) == 0) \ + return 1; + +int test_available_devices() { + ov_core_t* core = NULL; + char* ret = NULL; + OV_SUCCESS(ov_core_create(&core)); +#ifdef ENABLE_INTEL_CPU + OV_SUCCESS(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); +#endif +#ifdef ENABLE_INTEL_GPU + OV_SUCCESS(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); +#endif +#ifdef ENABLE_AUTO + OV_SUCCESS(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); + OV_SUCCESS(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); + OV_FAIL(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); +#endif +#ifdef ENABLE_HETERO + OV_SUCCESS(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); +#endif +#ifdef ENABLE_AUTO_BATCH + OV_SUCCESS(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); +#endif + ov_core_free(core); + return 0; +} + +int test_available_frontends() { + ov::frontend::FrontEndManager manager; + auto frontend_found = [&] (const std::string & name) -> int { + try { + manager.load_by_framework(name); + } catch (const std::exception & e) { + return 1; + } + return 0; + }; + +#ifdef ENABLE_IR_FRONTEND + OV_SUCCESS(frontend_found("ir")); +#else + OV_FAIL(frontend_found("ir")); +#endif +#ifdef ENABLE_TF_LITE_FRONTEND + OV_SUCCESS(frontend_found("tflite")); +#else + OV_FAIL(frontend_found("tflite")); +#endif +#ifdef ENABLE_PYTORCH_FRONTEND + OV_SUCCESS(frontend_found("pytorch")); +#else + OV_FAIL(frontend_found("pytorch")); +#endif +#ifdef ENABLE_ONNX_FRONTEND + OV_SUCCESS(frontend_found("onnx")); +#else + OV_FAIL(frontend_found("onnx")); +#endif +#ifdef ENABLE_TF_FRONTEND + OV_SUCCESS(frontend_found("tf")); +#else + OV_FAIL(frontend_found("tf")); +#endif +#ifdef ENABLE_PADDLE_FRONTEND + OV_SUCCESS(frontend_found("paddle")); +#else + OV_FAIL(frontend_found("paddle")); +#endif + return 0; +} + +int main() { + OV_SUCCESS(test_available_devices()); + OV_SUCCESS(test_available_frontends()); + + // Deinitialize OpenVINO. Important for old systems like Ubuntu 16.04 with obsolete glibc, + // where application deinit can lead to the following issue on exit: + // Inconsistency detected by ld.so: dl-close.c: 811: _dl_close: Assertion `map->l_init_called' failed! + ov::shutdown(); + + return 0; +} diff --git a/recipes/openvino/config.yml b/recipes/openvino/config.yml new file mode 100644 index 00000000000000..ab4b77f9729467 --- /dev/null +++ b/recipes/openvino/config.yml @@ -0,0 +1,3 @@ +versions: + "2023.1.0": + folder: "all" From 76f9b5b5d04fe3423ce9cf9c5054421e5f88a4e3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 19:55:18 +0200 Subject: [PATCH 0763/1140] (#20143) Bump qdbm's zlib requirement to [>=1.2.11 <2] range --- recipes/qdbm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/qdbm/all/conanfile.py b/recipes/qdbm/all/conanfile.py index 4341f35ed3bb7d..583704293b76fc 100644 --- a/recipes/qdbm/all/conanfile.py +++ b/recipes/qdbm/all/conanfile.py @@ -53,7 +53,7 @@ def requirements(self): if self.options.with_iconv: self.requires("libiconv/1.17") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 46d8497561ec465385316e3ed805379a35874a6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 26 Sep 2023 20:14:30 +0200 Subject: [PATCH 0764/1140] (#20138) Bump qpdf's zlib requirement to [>=1.2.11 <2] range --- recipes/qpdf/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/qpdf/all/conanfile.py b/recipes/qpdf/all/conanfile.py index d5b0654a5d1792..2ec6c272a6287d 100644 --- a/recipes/qpdf/all/conanfile.py +++ b/recipes/qpdf/all/conanfile.py @@ -62,7 +62,7 @@ def layout(self): def requirements(self): # https://qpdf.readthedocs.io/en/stable/installation.html#basic-dependencies - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") if self.options.with_jpeg == "libjpeg": From 1d42534a413c6f4f30489e43e91bf9f1768d7fe0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 07:13:54 +0200 Subject: [PATCH 0765/1140] (#20128) Bump opencv's zlib requirement to [>=1.2.11 <2] range * Bump opencv's zlib requirement to [>=1.2.11 <2] range * Merge both PRs into one --- recipes/opencv/3.x/conanfile.py | 2 +- recipes/opencv/4.x/conanfile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/opencv/3.x/conanfile.py b/recipes/opencv/3.x/conanfile.py index 40d745d3074f7d..0abc75587237cb 100644 --- a/recipes/opencv/3.x/conanfile.py +++ b/recipes/opencv/3.x/conanfile.py @@ -76,7 +76,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": diff --git a/recipes/opencv/4.x/conanfile.py b/recipes/opencv/4.x/conanfile.py index 96c7055a75aa04..12bcded86e10ee 100644 --- a/recipes/opencv/4.x/conanfile.py +++ b/recipes/opencv/4.x/conanfile.py @@ -1008,7 +1008,7 @@ def layout(self): def requirements(self): # core module dependencies - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_eigen: self.requires("eigen/3.4.0") if self.options.parallel == "tbb": From 7d8982fc472aba56be99ac0f27948d90fed43168 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 09:25:00 +0200 Subject: [PATCH 0766/1140] (#20124) Bump libharu's zlib requirement to [>=1.2.11 <2] range --- recipes/libharu/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libharu/all/conanfile.py b/recipes/libharu/all/conanfile.py index 73045d8d62bce7..c35f205e346da7 100644 --- a/recipes/libharu/all/conanfile.py +++ b/recipes/libharu/all/conanfile.py @@ -47,7 +47,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") self.requires("libpng/1.6.40") def source(self): From a20023de45f8fedddd9b31a7f23895eeae20794c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 09:58:59 +0200 Subject: [PATCH 0767/1140] (#20146) Bump gdcm's zlib requirement to [>=1.2.11 <2] range --- recipes/gdcm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/gdcm/all/conanfile.py b/recipes/gdcm/all/conanfile.py index bccb6132bf5678..1990e92be0217a 100644 --- a/recipes/gdcm/all/conanfile.py +++ b/recipes/gdcm/all/conanfile.py @@ -62,7 +62,7 @@ def requirements(self): if self.options.with_zlibng: self.requires("zlib-ng/2.0.7") else: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.settings.os != "Windows": self.requires("util-linux-libuuid/2.39") if Version(self.version) >= Version("3.0.20"): From 3b37eee82ca783507cbe510c704599f870278d5a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 10:16:05 +0200 Subject: [PATCH 0768/1140] (#20135) Bump libxlsxwriter's zlib requirement to [>=1.2.11 <2] range * Bump libxlsxwriter's zlib requirement to [>=1.2.11 <2] range * Add openssl range too --- recipes/libxlsxwriter/all/conanfile.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/libxlsxwriter/all/conanfile.py b/recipes/libxlsxwriter/all/conanfile.py index 0d8e6136fd0e5e..1c65ddbb9e2471 100644 --- a/recipes/libxlsxwriter/all/conanfile.py +++ b/recipes/libxlsxwriter/all/conanfile.py @@ -17,6 +17,7 @@ class LibxlsxwriterConan(ConanFile): topics = ("excel", "xlsx") description = "A C library for creating Excel XLSX files" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -55,9 +56,9 @@ def layout(self): def requirements(self): self.requires("minizip/1.2.13") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.md5 == "openssl": - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") def validate(self): if Version(self.version) < "1.0.6" and self.info.options.md5 == "openssl": From 0a39b4ec457b6e55d975295cda4ca4770c6da91b Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 27 Sep 2023 10:31:55 +0200 Subject: [PATCH 0769/1140] (#19856) zint: add package_type + fix test package for conan v2 + use version range for zlib * add package_type & modernize more * fix test package for conan v2 * bump libpng & qt * use version range for zlib --- recipes/zint/all/conanfile.py | 30 +++++++------------ recipes/zint/all/test_package/CMakeLists.txt | 12 +++++--- recipes/zint/all/test_package/conanfile.py | 9 ++---- .../zint/all/test_v1_package/CMakeLists.txt | 18 +++-------- recipes/zint/all/test_v1_package/conanfile.py | 7 +---- 5 files changed, 26 insertions(+), 50 deletions(-) diff --git a/recipes/zint/all/conanfile.py b/recipes/zint/all/conanfile.py index 61596c6c982a74..f9c54ff2b86cf0 100644 --- a/recipes/zint/all/conanfile.py +++ b/recipes/zint/all/conanfile.py @@ -5,7 +5,7 @@ from conan.tools.scm import Version import os -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.53.0" class ZintConan(ConanFile): @@ -15,7 +15,7 @@ class ZintConan(ConanFile): homepage = "https://sourceforge.net/p/zint/code" license = "GPL-3.0" topics = ("barcode", "qt") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -39,37 +39,27 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass + self.options.rm_safe("fPIC") if not self.options.with_qt: - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def layout(self): cmake_layout(self, src_folder="src") def requirements(self): if self.options.with_libpng: - self.requires("libpng/1.6.38") - self.requires("zlib/1.2.13") + self.requires("libpng/1.6.40") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_qt: - self.requires("qt/5.15.6") + self.requires("qt/5.15.10") def validate(self): - if self.info.options.with_qt and not self.dependencies["qt"].options.gui: + if self.options.with_qt and not self.dependencies["qt"].options.gui: raise ConanInvalidConfiguration(f"{self.ref} needs qt:gui=True") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/zint/all/test_package/CMakeLists.txt b/recipes/zint/all/test_package/CMakeLists.txt index 14bd143a5e4a68..d4ac6daa22c07f 100644 --- a/recipes/zint/all/test_package/CMakeLists.txt +++ b/recipes/zint/all/test_package/CMakeLists.txt @@ -1,6 +1,8 @@ cmake_minimum_required(VERSION 3.1) project(test_package LANGUAGES C) +enable_testing() + option(ZINT_WITH_QT "Zint has been built with Qt support") if(ZINT_WITH_QT) enable_language(CXX) @@ -8,10 +10,12 @@ endif() find_package(Zint REQUIRED CONFIG) -add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE Zint::Zint) +add_executable(test_package test_package.c) +target_link_libraries(test_package PRIVATE Zint::Zint) +add_test(NAME test_package COMMAND test_package) if(ZINT_WITH_QT) - add_executable(${PROJECT_NAME}_cpp test_package.cpp) - target_link_libraries(${PROJECT_NAME}_cpp PRIVATE Zint::QZint) + add_executable(test_package_cpp test_package.cpp) + target_link_libraries(test_package_cpp PRIVATE Zint::QZint) + add_test(NAME test_package_cpp COMMAND test_package_cpp) endif() diff --git a/recipes/zint/all/test_package/conanfile.py b/recipes/zint/all/test_package/conanfile.py index 1617e37109bc27..9523fb1ef2b635 100644 --- a/recipes/zint/all/test_package/conanfile.py +++ b/recipes/zint/all/test_package/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.tools.build import can_run from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -import os +from conan.tools.files import chdir class TestPackageConan(ConanFile): @@ -27,8 +27,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") - self.run(bin_path, env="conanrun") - if self.options["zint"].with_qt: - bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package_cpp") - self.run(bin_path, env="conanrun") + with chdir(self, self.build_folder): + self.run(f"ctest --output-on-failure -C {self.settings.build_type}", env="conanrun") diff --git a/recipes/zint/all/test_v1_package/CMakeLists.txt b/recipes/zint/all/test_v1_package/CMakeLists.txt index d155f1e77d4aaf..c23ed5cfe6d983 100644 --- a/recipes/zint/all/test_v1_package/CMakeLists.txt +++ b/recipes/zint/all/test_v1_package/CMakeLists.txt @@ -1,20 +1,10 @@ cmake_minimum_required(VERSION 3.1) -project(test_package LANGUAGES C) +project(test_v1_package) -option(ZINT_WITH_QT "Zint has been built with Qt support") -if(ZINT_WITH_QT) - enable_language(CXX) -endif() +enable_testing() include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(Zint REQUIRED CONFIG) - -add_executable(${PROJECT_NAME} ../test_package/test_package.c) -target_link_libraries(${PROJECT_NAME} PRIVATE Zint::Zint) - -if(ZINT_WITH_QT) - add_executable(${PROJECT_NAME}_cpp ../test_package/test_package.cpp) - target_link_libraries(${PROJECT_NAME}_cpp PRIVATE Zint::QZint) -endif() +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/zint/all/test_v1_package/conanfile.py b/recipes/zint/all/test_v1_package/conanfile.py index 1ce37b6a52e778..723b5e4a6fa800 100644 --- a/recipes/zint/all/test_v1_package/conanfile.py +++ b/recipes/zint/all/test_v1_package/conanfile.py @@ -1,5 +1,4 @@ from conans import ConanFile, CMake, tools -import os class TestPackageConan(ConanFile): @@ -14,8 +13,4 @@ def build(self): def test(self): if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) - if self.options["zint"].with_qt: - bin_path = os.path.join("bin", "test_package_cpp") - self.run(bin_path, run_environment=True) + self.run(f"ctest --output-on-failure -C {self.settings.build_type}", run_environment=True) From 7aa6570a2cf0a5c810a9912aff5b2261e499e8c2 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Wed, 27 Sep 2023 11:28:56 +0200 Subject: [PATCH 0770/1140] (#20106) [docs] Add changelog September, 25 2023 Signed-off-by: Uilian Ries --- docs/changelog.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 1511b584ab7db2..167e8aafcbc3ea 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,13 @@ # Changelog +### 25-Sep-2023 - 14:33 CEST + +- [feature] Label PRs that have missing dependencies. +- [feature] Remove check regression for Conan v2 pipeline. +- [feature] Start deprecating epochs support in profile configurations. +- [fix] Run TapaholesRepo job only once per week. +- [fix] Run ListPackages job only once per week. + ### 01-Sep-2023 - 19:58 CEST - [fix] Use Unix separators for Windows folder path when creating CI workspace. From 1b666b90ee5a21c8de5a7fa73f20faaac42f335a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 11:34:20 +0200 Subject: [PATCH 0771/1140] (#20125) Bump libbigwig's zlib requirement to [>=1.2.11 <2] range --- recipes/libbigwig/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libbigwig/all/conanfile.py b/recipes/libbigwig/all/conanfile.py index cf0ba30f73906f..abb1b4a35b398b 100644 --- a/recipes/libbigwig/all/conanfile.py +++ b/recipes/libbigwig/all/conanfile.py @@ -49,7 +49,7 @@ def requirements(self): if self.options.with_zlibng: self.requires("zlib-ng/2.1.3") else: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.info.settings.os == "Windows": From ff52c1bba6584447efb5be766a89630266899b2f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 12:38:01 +0200 Subject: [PATCH 0772/1140] (#20111) Bump exiv2's zlib requirement to [>=1.2.11 <2] range --- recipes/exiv2/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/exiv2/all/conanfile.py b/recipes/exiv2/all/conanfile.py index b5c3445fd34dae..19688c15f33b3a 100644 --- a/recipes/exiv2/all/conanfile.py +++ b/recipes/exiv2/all/conanfile.py @@ -76,7 +76,7 @@ def requirements(self): self.requires("libiconv/1.17") if self.options.with_png: self.requires("libpng/1.6.40") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_xmp == "bundled": self.requires("expat/2.5.0") if self.options.with_curl: From a42b17de66f98abc525b381972c52b96fb9a183f Mon Sep 17 00:00:00 2001 From: Guillaume Egles Date: Wed, 27 Sep 2023 04:35:42 -0700 Subject: [PATCH 0773/1140] (#19965) openssl: add 3.1.3 & 3.0.11 --- recipes/openssl/3.x.x/conandata.yml | 10 ++++++++++ recipes/openssl/config.yml | 5 ++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/recipes/openssl/3.x.x/conandata.yml b/recipes/openssl/3.x.x/conandata.yml index f1fe5a2743364d..ba41f8413304ee 100644 --- a/recipes/openssl/3.x.x/conandata.yml +++ b/recipes/openssl/3.x.x/conandata.yml @@ -1,4 +1,9 @@ sources: + 3.1.3: + url: + - "https://www.openssl.org/source/openssl-3.1.3.tar.gz" + - "https://github.com/openssl/openssl/releases/download/openssl-3.1.3/openssl-3.1.3.tar.gz" + sha256: f0316a2ebd89e7f2352976445458689f80302093788c466692fb2a188b2eacf6 3.1.2: url: - "https://www.openssl.org/source/openssl-3.1.2.tar.gz" @@ -14,6 +19,11 @@ sources: - "https://www.openssl.org/source/openssl-3.1.0.tar.gz" - "https://github.com/openssl/openssl/releases/download/openssl-3.1.0/openssl-3.1.0.tar.gz" sha256: aaa925ad9828745c4cad9d9efeb273deca820f2cdcf2c3ac7d7c1212b7c497b4 + 3.0.11: + url: + - "https://www.openssl.org/source/openssl-3.0.11.tar.gz" + - "https://github.com/openssl/openssl/releases/download/openssl-3.0.11/openssl-3.0.11.tar.gz" + sha256: b3425d3bb4a2218d0697eb41f7fc0cdede016ed19ca49d168b78e8d947887f55 3.0.10: url: - "https://www.openssl.org/source/openssl-3.0.10.tar.gz" diff --git a/recipes/openssl/config.yml b/recipes/openssl/config.yml index 67834781567eb0..74041e09b8d673 100644 --- a/recipes/openssl/config.yml +++ b/recipes/openssl/config.yml @@ -1,5 +1,7 @@ versions: # 3.1.x releases + 3.1.3: + folder: "3.x.x" 3.1.2: folder: "3.x.x" 3.1.1: @@ -7,13 +9,14 @@ versions: 3.1.0: folder: "3.x.x" # 3.0.x releases + 3.0.11: + folder: "3.x.x" 3.0.10: folder: "3.x.x" 3.0.9: folder: "3.x.x" 3.0.8: folder: "3.x.x" - # 1.1.1x releases 1.1.1w: folder: "1.x.x" From 387f45df3598d2d3b66761d989e284ccacac46ee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 14:01:54 +0200 Subject: [PATCH 0774/1140] (#20137) Bump binutils's zlib requirement to [>=1.2.11 <2] range --- recipes/binutils/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/binutils/all/conanfile.py b/recipes/binutils/all/conanfile.py index c5bddfc4331b08..1e04fbc03a87b2 100644 --- a/recipes/binutils/all/conanfile.py +++ b/recipes/binutils/all/conanfile.py @@ -138,7 +138,7 @@ def build_requirements(self): self.tool_requires("flex/2.6.4") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From a00ad6c020e80824d59a1e0cceb2e000c985bcc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 14:18:29 +0200 Subject: [PATCH 0775/1140] Bump libzip's zlib requirement to [>=1.2.11 <2] range (#20136) --- recipes/libzip/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libzip/all/conanfile.py b/recipes/libzip/all/conanfile.py index ef5f90cd053cb1..a9d0b3b828fe89 100644 --- a/recipes/libzip/all/conanfile.py +++ b/recipes/libzip/all/conanfile.py @@ -62,7 +62,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") From 46cd764d637889a73eeec11b53835099b1f11bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 15:20:16 +0200 Subject: [PATCH 0776/1140] (#20140) Bump matio's zlib requirement to [>=1.2.11 <2] range --- recipes/matio/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/matio/all/conanfile.py b/recipes/matio/all/conanfile.py index 127218a42d2774..199bb98823415b 100644 --- a/recipes/matio/all/conanfile.py +++ b/recipes/matio/all/conanfile.py @@ -56,7 +56,7 @@ def requirements(self): if self.options.with_hdf5: self.requires("hdf5/1.14.1") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if not self.options.with_hdf5 and self.options.mat73: From 174d314cb1e21e713c80a3b3e3c7c8d534ac0fe8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 15:46:45 +0200 Subject: [PATCH 0777/1140] Bump mold's zlib requirement to [>=1.2.11 <2] range (#20132) --- recipes/mold/1.3.1/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mold/1.3.1/conanfile.py b/recipes/mold/1.3.1/conanfile.py index 132186858b019f..628628b349c7b5 100644 --- a/recipes/mold/1.3.1/conanfile.py +++ b/recipes/mold/1.3.1/conanfile.py @@ -66,7 +66,7 @@ def _patch_sources(self): self.deps_cpp_info["mimalloc"].lib_paths[0])) def requirements(self): - self.requires("zlib/1.2.12") + self.requires("zlib/[>=1.2.11 <2]") self.requires("openssl/1.1.1q") self.requires("xxhash/0.8.1") self.requires("onetbb/2021.3.0") From 24e52e90d904d7fc4eec7e4633b68694c5fcde47 Mon Sep 17 00:00:00 2001 From: tankeco Date: Wed, 27 Sep 2023 22:49:03 +0800 Subject: [PATCH 0778/1140] =?UTF-8?q?(#19470)=20mimalloc:=20relax=20cppstd?= =?UTF-8?q?=20requirements=20because=20we=20don=E2=80=99t=20compile=20test?= =?UTF-8?q?s?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * mimalloc: relax cppstd requirements because we don’t compile tests * remove cpp version check totally * remove unused import --- recipes/mimalloc/all/conanfile.py | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/recipes/mimalloc/all/conanfile.py b/recipes/mimalloc/all/conanfile.py index af2bccdab3572f..eaa8e6193ea4e1 100644 --- a/recipes/mimalloc/all/conanfile.py +++ b/recipes/mimalloc/all/conanfile.py @@ -1,6 +1,5 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rm, rmdir, replace_in_file, save, collect_libs from conan.tools.microsoft import is_msvc, is_msvc_static_runtime, VCVars @@ -38,20 +37,6 @@ class MimallocConan(ConanFile): "single_object": False, } - @property - def _min_cppstd(self): - return 17 - - @property - def _compilers_minimum_version(self): - return { - "gcc": "7", - "Visual Studio": "15", - "msvc": "191", - "clang": "5", - "apple-clang": "10", - } - def export_sources(self): export_conandata_patches(self) @@ -109,14 +94,6 @@ def validate(self): self.options.get_safe("inject"): raise ConanInvalidConfiguration("Single object is incompatible with library injection") - if self.settings.compiler.get_safe("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) From 38fae335c04f0a8fe10d52e58412e96f0ef02854 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 19:46:47 +0200 Subject: [PATCH 0779/1140] (#19787) Bump libzippp's zlib requirement to [>=1.2.11 <2] range --- recipes/libzippp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libzippp/all/conanfile.py b/recipes/libzippp/all/conanfile.py index 9699cb890e5fcf..b6ec87350a23e2 100644 --- a/recipes/libzippp/all/conanfile.py +++ b/recipes/libzippp/all/conanfile.py @@ -45,7 +45,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if Version(self.version) == "4.0": self.requires("libzip/1.7.3") else: From dd8ffaf414ea5eacd5dd4bd3913f6ad6784cd585 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 20:06:05 +0200 Subject: [PATCH 0780/1140] (#20139) Bump cassandra-cpp-driver's zlib requirement to [>=1.2.11 <2] range * Bump cassandra-cpp-driver's zlib requirement to [>=1.2.11 <2] range * Fix rpath for mac Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/cassandra-cpp-driver/all/conanfile.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/cassandra-cpp-driver/all/conanfile.py b/recipes/cassandra-cpp-driver/all/conanfile.py index 57fdb66f78e3f3..91a6e9ffd905ae 100644 --- a/recipes/cassandra-cpp-driver/all/conanfile.py +++ b/recipes/cassandra-cpp-driver/all/conanfile.py @@ -3,6 +3,7 @@ from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, replace_in_file, rm from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.build import check_min_cppstd +from conan.tools.apple import fix_apple_shared_install_name import os required_conan_version = ">=1.53.0" @@ -66,7 +67,7 @@ def requirements(self): if self.options.with_zlib: self.requires("minizip/1.2.13") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.use_atomic == "boost": self.requires("boost/1.82.0") @@ -146,6 +147,7 @@ def package(self): copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) cmake = CMake(self) cmake.install() + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["cassandra" if self.options.shared else "cassandra_static"] @@ -155,3 +157,6 @@ def package_info(self): "crypt32", "ws2_32", "userenv", "version"]) if not self.options.shared: self.cpp_info.defines = ["CASS_STATIC"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m"] + From acf04aabf8397374b206b60010670bc40b109b6c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Wed, 27 Sep 2023 20:46:27 +0200 Subject: [PATCH 0781/1140] (#20130) Bump mariadb-connector-c's zlib requirement to [>=1.2.11 <2] range * Bump mariadb-connector-c's zlib requirement to [>=1.2.11 <2] range * Bump libcurl --- recipes/mariadb-connector-c/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/mariadb-connector-c/all/conanfile.py b/recipes/mariadb-connector-c/all/conanfile.py index 13b1525cfce346..2a47e8904ad348 100644 --- a/recipes/mariadb-connector-c/all/conanfile.py +++ b/recipes/mariadb-connector-c/all/conanfile.py @@ -54,11 +54,11 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.get_safe("with_iconv"): self.requires("libiconv/1.17") if self.options.with_curl: - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.1.2") if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") From d139df6002f3fd68f4a55fe9a1920b9d724e7eac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 01:10:52 +0200 Subject: [PATCH 0782/1140] (#20133) Bump sentry-crashpad's zlib requirement to [>=1.2.11 <2] range --- recipes/sentry-crashpad/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/sentry-crashpad/all/conanfile.py b/recipes/sentry-crashpad/all/conanfile.py index af63a7ade4f9dc..4217d488f0b1c3 100644 --- a/recipes/sentry-crashpad/all/conanfile.py +++ b/recipes/sentry-crashpad/all/conanfile.py @@ -60,7 +60,7 @@ def build_requirements(self): self.tool_requires("jwasm/2.13") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.settings.os in ("Linux", "FreeBSD"): self.requires("libcurl/8.2.0") if self.options.get_safe("with_tls"): From 97559d32110e28aabc6aecf4bf29d556ab7c93c2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 09:07:22 +0200 Subject: [PATCH 0783/1140] (#20110) Bump openssl's zlib requirement to [>=1.2.11 <2] range --- recipes/openssl/1.x.x/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/openssl/1.x.x/conanfile.py b/recipes/openssl/1.x.x/conanfile.py index c6f1558ac1cf1c..6a4aa390c92eba 100644 --- a/recipes/openssl/1.x.x/conanfile.py +++ b/recipes/openssl/1.x.x/conanfile.py @@ -228,7 +228,7 @@ def layout(self): def requirements(self): if self._full_version < "1.1.0" and not self.options.get_safe("no_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os == "Emscripten": From 6c6472e4a3e81d74c3aef7e2218fb7d40e1fb397 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 09:38:55 +0200 Subject: [PATCH 0784/1140] (#20112) Bump libssh2's zlib requirement to [>=1.2.11 <2] range --- recipes/libssh2/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libssh2/all/conanfile.py b/recipes/libssh2/all/conanfile.py index eb8b1cad9c233d..6da888df38a6f6 100644 --- a/recipes/libssh2/all/conanfile.py +++ b/recipes/libssh2/all/conanfile.py @@ -80,7 +80,7 @@ def configure(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.crypto_backend == "openssl": self.requires("openssl/[>=1.1 <4]") elif self.options.crypto_backend == "mbedtls": From 4d1a53b91ee01681a72cdab0ca259da9ef735783 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 10:28:19 +0200 Subject: [PATCH 0785/1140] (#20116) Bump mongo-c-driver's zlib requirement to [>=1.2.11 <2] range --- recipes/mongo-c-driver/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mongo-c-driver/all/conanfile.py b/recipes/mongo-c-driver/all/conanfile.py index c67766ae04dd2f..75cc9a3fd0fcdb 100644 --- a/recipes/mongo-c-driver/all/conanfile.py +++ b/recipes/mongo-c-driver/all/conanfile.py @@ -74,7 +74,7 @@ def requirements(self): if self.options.with_snappy: self.requires("snappy/1.1.10") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.5") if self.options.with_icu: From fa4fea20a048710c4163bb5f7930265c94c80f14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 11:13:27 +0200 Subject: [PATCH 0786/1140] (#20117) Bump minizip-ng's zlib requirement to [>=1.2.11 <2] range --- recipes/minizip-ng/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/minizip-ng/all/conanfile.py b/recipes/minizip-ng/all/conanfile.py index 9dec1a6119509d..73516f1e0155c2 100644 --- a/recipes/minizip-ng/all/conanfile.py +++ b/recipes/minizip-ng/all/conanfile.py @@ -81,7 +81,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.with_lzma: From dd0509fb512939e3d47bcf0ec3a61a2bd46a96a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 12:21:11 +0200 Subject: [PATCH 0787/1140] (#20122) Bump libwebsockets's zlib requirement to [>=1.2.11 <2] range * Bump libwebsockets's zlib requirement to [>=1.2.11 <2] range * Add package_type --- recipes/libwebsockets/all/conanfile.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/recipes/libwebsockets/all/conanfile.py b/recipes/libwebsockets/all/conanfile.py index 12c738824025cf..fbda27117b43ef 100644 --- a/recipes/libwebsockets/all/conanfile.py +++ b/recipes/libwebsockets/all/conanfile.py @@ -16,8 +16,9 @@ class LibwebsocketsConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/warmcat/libwebsockets" license = "MIT" - topics = ("libwebsockets", "websocket") + topics = ("websocket") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -212,7 +213,7 @@ def requirements(self): self.requires("libev/4.33") if self.options.with_zlib == "zlib": - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") elif self.options.with_zlib == "miniz": self.requires("miniz/2.2.0") @@ -270,7 +271,7 @@ def _cmakify_path_list(self, paths): def _find_library(self, libname, dep): prefix = "lib" if self.settings.os != "Windows" else "" - for path in self.dependencies[dep].cpp_info.libdirs: + for path in self.dependencies[dep].cpp_info.libdirs: lib_fullpath = os.path.join(path, prefix + libname + self._get_library_extension(dep)) self.output.info("Dependency library full path : " + str(lib_fullpath)) if os.path.isfile(lib_fullpath): @@ -426,13 +427,13 @@ def generate(self): def _patch_sources(self): cmakelists = os.path.join(self.source_folder, "CMakeLists.txt") - replace_in_file(self, + replace_in_file(self, cmakelists, "SET(CMAKE_INSTALL_NAME_DIR \"${CMAKE_INSTALL_PREFIX}/${LWS_INSTALL_LIB_DIR}${LIB_SUFFIX}\")", "", ) if Version(self.version) == "4.0.15" and self.options.with_ssl: - replace_in_file(self, + replace_in_file(self, cmakelists, "list(APPEND LIB_LIST ws2_32.lib userenv.lib psapi.lib iphlpapi.lib)", "list(APPEND LIB_LIST ws2_32.lib userenv.lib psapi.lib iphlpapi.lib crypt32.lib)" From ce24a0767b804ba490f7542a7f0c150e1e435f4c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 12:51:18 +0200 Subject: [PATCH 0788/1140] (#20131) Bump h5pp's zlib requirement to [>=1.2.11 <2] range --- recipes/h5pp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/h5pp/all/conanfile.py b/recipes/h5pp/all/conanfile.py index 572f56191b2524..9c9caa28d810ef 100644 --- a/recipes/h5pp/all/conanfile.py +++ b/recipes/h5pp/all/conanfile.py @@ -70,7 +70,7 @@ def requirements(self): if Version(self.version) < "1.10.0" or self.options.get_safe('with_spdlog'): self.requires("spdlog/1.11.0", transitive_headers=True, transitive_libs=True) if Version(self.version) >= "1.10.0" and self.options.with_zlib: - self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True, transitive_libs=True) def layout(self): basic_layout(self,src_folder="src") From 7677532035a6e8e9f4a608cf2f7d0369ec865e6b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 13:15:18 +0200 Subject: [PATCH 0789/1140] (#20142) Bump libmediainfo's zlib requirement to [>=1.2.11 <2] range * Bump libmediainfo's zlib requirement to [>=1.2.11 <2] range * bump libcurl --- recipes/libmediainfo/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/libmediainfo/all/conanfile.py b/recipes/libmediainfo/all/conanfile.py index 88fc1cba470649..d68e2deed8e875 100644 --- a/recipes/libmediainfo/all/conanfile.py +++ b/recipes/libmediainfo/all/conanfile.py @@ -49,10 +49,10 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.1.2") self.requires("libzen/0.4.38", transitive_headers=True, transitive_libs=True) self.requires("tinyxml2/9.0.0") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if not self.dependencies["libzen"].options.enable_unicode: From 3d640e524537bdb9c962fa494014613b5b673b72 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 28 Sep 2023 13:34:04 +0200 Subject: [PATCH 0790/1140] (#19662) boost: use version range zlib + bump icu & b2 * use version range for zlib * bump icu * bump b2 * fix version range zlib * bump xz_utils --- recipes/boost/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/boost/all/conanfile.py b/recipes/boost/all/conanfile.py index d24854dcb4b47c..5bab9c6c7ebdd4 100644 --- a/recipes/boost/all/conanfile.py +++ b/recipes/boost/all/conanfile.py @@ -531,18 +531,18 @@ def _with_stacktrace_backtrace(self): def requirements(self): if self._with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self._with_bzip2: self.requires("bzip2/1.0.8") if self._with_lzma: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self._with_zstd: self.requires("zstd/1.5.5") if self._with_stacktrace_backtrace: self.requires("libbacktrace/cci.20210118", transitive_headers=True, transitive_libs=True) if self._with_icu: - self.requires("icu/72.1") + self.requires("icu/73.2") if self._with_iconv: self.requires("libiconv/1.17") @@ -561,7 +561,7 @@ def package_id(self): def build_requirements(self): if not self.options.header_only: - self.tool_requires("b2/4.9.6") + self.tool_requires("b2/4.10.1") def source(self): get(self, **self.conan_data["sources"][self.version], From 2ef14738a0c42c0a0c69b133f052d4ae561ed3e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 15:34:20 +0200 Subject: [PATCH 0791/1140] (#19873) libmysqlcient: Disable doxxygen generation * Disable doxxygen generation * Better way to disable * Cmake way to disable find * Add zlib range --- recipes/libmysqlclient/all/conanfile.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/recipes/libmysqlclient/all/conanfile.py b/recipes/libmysqlclient/all/conanfile.py index 80776aaf0f0374..8d96f1dd528287 100644 --- a/recipes/libmysqlclient/all/conanfile.py +++ b/recipes/libmysqlclient/all/conanfile.py @@ -66,7 +66,7 @@ def requirements(self): self.requires("openssl/1.1.1u") else: self.requires("openssl/[>=1.1 <4]") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") self.requires("zstd/1.5.5") self.requires("lz4/1.9.4") if self.settings.os == "FreeBSD": @@ -229,6 +229,9 @@ def generate(self): tc.cache_variables["WITH_SSL"] = self.dependencies["openssl"].package_folder.replace("\\", "/") tc.cache_variables["WITH_ZLIB"] = "system" + + # Remove to ensure reproducible build, this only affects docs generation + tc.cache_variables["CMAKE_DISABLE_FIND_PACKAGE_Doxygen"] = True tc.generate() deps = CMakeDeps(self) From 2eaf5724ef39e1ffd9faef0b0eb687ec5606a099 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 16:11:59 +0200 Subject: [PATCH 0792/1140] (#20126) Bump leptonica's zlib requirement to [>=1.2.11 <2] range --- recipes/leptonica/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/leptonica/all/conanfile.py b/recipes/leptonica/all/conanfile.py index d072baae99b619..2603c7965bfb49 100644 --- a/recipes/leptonica/all/conanfile.py +++ b/recipes/leptonica/all/conanfile.py @@ -66,7 +66,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_gif: self.requires("giflib/5.2.1") if self.options.with_jpeg == "libjpeg": From 77629be56f445507efd9405fd07e1dd13047d918 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 16:48:48 +0200 Subject: [PATCH 0793/1140] (#20109) Bump assimp's zlib requirement to [>=1.2.11 <2] range --- recipes/assimp/5.x/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/assimp/5.x/conanfile.py b/recipes/assimp/5.x/conanfile.py index e821ffefdeea3e..375b192d925232 100644 --- a/recipes/assimp/5.x/conanfile.py +++ b/recipes/assimp/5.x/conanfile.py @@ -179,7 +179,7 @@ def requirements(self): if self._depends_on_rapidjson: self.requires("rapidjson/cci.20220822") if self._depends_on_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self._depends_on_draco: self.requires("draco/1.5.6") if self._depends_on_clipper: From c318f0a3e0903376dc6fd09e0fc93d4590d5dbcd Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 28 Sep 2023 17:19:13 +0200 Subject: [PATCH 0794/1140] (#19899) tcl: relocatable shared libs on macos + use version range for zlib * relocatable shared lib on macOS * cleanup topics * use version range for zlib * less verbose package_info() * ensure to link to zlib from conan instead of system * sipplify package_info() --- recipes/tcl/all/conanfile.py | 79 ++++++++++++++++++++---------------- 1 file changed, 43 insertions(+), 36 deletions(-) diff --git a/recipes/tcl/all/conanfile.py b/recipes/tcl/all/conanfile.py index af981d1a0dba9f..1722816dbfb147 100644 --- a/recipes/tcl/all/conanfile.py +++ b/recipes/tcl/all/conanfile.py @@ -1,12 +1,15 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.apple import fix_apple_shared_install_name, is_apple_os +from conan.tools.build import cross_building +from conan.tools.env import VirtualBuildEnv, VirtualRunEnv from conan.tools.files import apply_conandata_patches, chdir, collect_libs, copy, export_conandata_patches, get, replace_in_file, rmdir -from conan.tools.gnu import Autotools, AutotoolsToolchain -from conan.tools.microsoft import is_msvc, is_msvc_static_runtime, msvc_runtime_flag, NMakeToolchain +from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime, msvc_runtime_flag, NMakeToolchain, NMakeDeps +from conan.tools.scm import Version import os -required_conan_version = ">=1.54.0" +required_conan_version = ">=1.55.0" class TclConan(ConanFile): @@ -15,7 +18,7 @@ class TclConan(ConanFile): license = "TCL" url = "https://github.com/conan-io/conan-center-index" homepage = "https://tcl.tk" - topics = ("tcl", "scripting", "programming") + topics = ("scripting", "programming") package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -69,7 +72,16 @@ def generate(self): if is_msvc(self): tc = NMakeToolchain(self) tc.generate() + + deps = NMakeDeps(self) + deps.generate() else: + env = VirtualBuildEnv(self) + env.generate() + if not cross_building(self): + env = VirtualRunEnv(self) + env.generate(scope="build") + tc = AutotoolsToolchain(self, prefix=self.package_folder) def yes_no(v): return "yes" if v else "no" tc.configure_args.extend([ @@ -79,6 +91,9 @@ def yes_no(v): return "yes" if v else "no" ]) tc.generate() + deps = AutotoolsDeps(self) + deps.generate() + def _get_default_build_system_subdir(self): return { "Macos": "macosx", @@ -198,54 +213,46 @@ def package(self): "\nTCL_SRC_DIR", "\n#TCL_SRC_DIR") - #fix_apple_shared_install_name(self) + fix_apple_shared_install_name(self) def package_info(self): + self.cpp_info.set_property("cmake_file_name", "TCL") + libs = [] - systemlibs = [] libdirs = [] for root, _, _ in os.walk(os.path.join(self.package_folder, "lib"), topdown=False): newlibs = collect_libs(self, root) if newlibs: libs.extend(newlibs) libdirs.append(root) + self.cpp_info.libs = libs + self.cpp_info.libdirs = libdirs + if self.settings.os == "Windows": - systemlibs.extend(["ws2_32", "netapi32", "userenv"]) + self.cpp_info.system_libs.extend(["ws2_32", "netapi32", "userenv"]) elif self.settings.os in ("FreeBSD", "Linux"): - systemlibs.extend(["dl", "m", "pthread"]) - - defines = [] - if not self.options.shared: - defines.append("STATIC_BUILD") - self.cpp_info.defines = defines - - self.cpp_info.libdirs = libdirs - self.cpp_info.libs = libs - self.cpp_info.system_libs = systemlibs - self.cpp_info.set_property("cmake_file_name", "TCL") - self.cpp_info.names["cmake_find_package"] = "TCL" - self.cpp_info.names["cmake_find_package_multi"] = "TCL" + self.cpp_info.system_libs.extend(["dl", "m", "pthread"]) + elif is_apple_os(self): + self.cpp_info.frameworks.append("CoreFoundation") - if self.settings.os == "Macos": - self.cpp_info.frameworks = ["CoreFoundation"] - self.cpp_info.sharedlinkflags = self.cpp_info.exelinkflags + if is_msvc(self) and not self.options.shared: + self.cpp_info.defines.append("STATIC_BUILD") - tcl_library = os.path.join(self.package_folder, "lib", "{}{}".format(self.name, ".".join(self.version.split(".")[:2]))) - self.output.info("Setting TCL_LIBRARY environment variable to {}".format(tcl_library)) - self.runenv_info.define_path('TCL_LIBRARY', tcl_library) - self.env_info.TCL_LIBRARY = tcl_library + tcl_version = Version(self.version) + tcl_library = os.path.join(self.package_folder, "lib", f"tcl{tcl_version.major}.{tcl_version.minor}") + self.runenv_info.define_path("TCL_LIBRARY", tcl_library) tcl_root = self.package_folder - self.output.info("Setting TCL_ROOT environment variable to {}".format(tcl_root)) - self.runenv_info.define_path('TCL_ROOT', tcl_root) - self.env_info.TCL_ROOT = tcl_root + self.runenv_info.define_path("TCL_ROOT", tcl_root) tclsh_list = list(filter(lambda fn: fn.startswith("tclsh"), os.listdir(os.path.join(self.package_folder, "bin")))) tclsh = os.path.join(self.package_folder, "bin", tclsh_list[0]) - self.output.info("Setting TCLSH environment variable to {}".format(tclsh)) - self.runenv_info.define_path('TCLSH', tclsh) - self.env_info.TCLSH = tclsh + self.runenv_info.define_path("TCLSH", tclsh) - bindir = os.path.join(self.package_folder, "bin") - self.output.info("Adding PATH environment variable: {}".format(bindir)) - self.env_info.PATH.append(bindir) + # TODO: to remove in conan v2 + self.cpp_info.names["cmake_find_package"] = "TCL" + self.cpp_info.names["cmake_find_package_multi"] = "TCL" + self.env_info.TCL_LIBRARY = tcl_library + self.env_info.TCL_ROOT = tcl_root + self.env_info.TCLSH = tclsh + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) From c23909001379ddbeec321896d7f9237bf5b4bc55 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 17:47:20 +0200 Subject: [PATCH 0795/1140] (#20129) Bump capnproto's zlib requirement to [>=1.2.11 <2] range --- recipes/capnproto/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/capnproto/all/conanfile.py b/recipes/capnproto/all/conanfile.py index 72462e3198e714..5c1f1850cd6c9f 100644 --- a/recipes/capnproto/all/conanfile.py +++ b/recipes/capnproto/all/conanfile.py @@ -79,7 +79,7 @@ def requirements(self): if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.compiler.get_safe("cppstd"): From 1eeea64751628b5b738bee480a6f727118cc475f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 28 Sep 2023 18:49:42 +0300 Subject: [PATCH 0796/1140] (#19620) mbedtls: add v3.4.1, v.2.28.4, simplify recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * mbedtls: add v3.4.1, v.2.28.4, simplify recipe * mbedtls: add v2.16.12 * mbedtls: fix error in conandata.yml * mbedtls: remove exported .cmake file * Add zlib range --------- Co-authored-by: Rubén Rincón Blanco --- recipes/mbedtls/all/CMakeLists.txt | 16 --------------- recipes/mbedtls/all/conandata.yml | 19 +++++++++++++----- recipes/mbedtls/all/conanfile.py | 20 ++++++++++++++----- .../mbedtls/all/test_package/CMakeLists.txt | 2 +- .../all/test_v1_package/CMakeLists.txt | 2 +- recipes/mbedtls/config.yml | 6 ++++++ 6 files changed, 37 insertions(+), 28 deletions(-) delete mode 100644 recipes/mbedtls/all/CMakeLists.txt diff --git a/recipes/mbedtls/all/CMakeLists.txt b/recipes/mbedtls/all/CMakeLists.txt deleted file mode 100644 index 3d32ee21cb1d7a..00000000000000 --- a/recipes/mbedtls/all/CMakeLists.txt +++ /dev/null @@ -1,16 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -if(MSVC) - if(MSVC_VERSION LESS 1900) - add_definitions(-DMBEDTLS_PLATFORM_SNPRINTF_MACRO=MBEDTLS_PLATFORM_STD_SNPRINTF) - else() - add_definitions(-DMBEDTLS_PLATFORM_SNPRINTF_MACRO=snprintf) - endif() - if(BUILD_SHARED_LIBS) - add_definitions(-DX509_BUILD_SHARED) - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - endif() -endif() - -add_subdirectory(src) diff --git a/recipes/mbedtls/all/conandata.yml b/recipes/mbedtls/all/conandata.yml index 2e2a89aefe3118..f923ca0c489a5d 100644 --- a/recipes/mbedtls/all/conandata.yml +++ b/recipes/mbedtls/all/conandata.yml @@ -1,19 +1,28 @@ sources: + "3.4.1": + url: "https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/v3.4.1.tar.gz" + sha256: "a420fcf7103e54e775c383e3751729b8fb2dcd087f6165befd13f28315f754f5" "3.2.1": - url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-3.2.1.tar.gz" + url: "https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-3.2.1.tar.gz" sha256: "5850089672560eeaca03dc36678ee8573bb48ef6e38c94f5ce349af60c16da33" "3.1.0": - url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-3.1.0.tar.gz" + url: "https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-3.1.0.tar.gz" sha256: "64d01a3b22b91cf3a25630257f268f11bc7bfa37981ae6d397802dd4ccec4690" "3.0.0": - url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-3.0.0.tar.gz" + url: "https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-3.0.0.tar.gz" sha256: "377d376919be19f07c7e7adeeded088a525be40353f6d938a78e4f986bce2ae0" + "2.28.4": + url: "https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/v2.28.4.tar.gz" + sha256: "578c4dcd15bbff3f5cd56aa07cd4f850fc733634e3d5947be4f7157d5bfd81ac" "2.25.0": url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-2.25.0.tar.gz" sha256: "ea2049c2dd4868693998d5a9780e198194be5aea1706ff4a9d4f882f18c0a101" "2.24.0": - url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-2.24.0.tar.gz" + url: "https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-2.24.0.tar.gz" sha256: "b5a779b5f36d5fc4cba55faa410685f89128702423ad07b36c5665441a06a5f3" "2.23.0": - url: "https://github.com/ARMmbed/mbedtls/archive/mbedtls-2.23.0.tar.gz" + url: "https://github.com/Mbed-TLS/mbedtls/archive/mbedtls-2.23.0.tar.gz" sha256: "5c8998217402aa1fc734f4afaeac38fad2421470fac4b3abc112bd46391054fe" + "2.16.12": + url: "https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/mbedtls-2.16.12.tar.gz" + sha256: "0afb4a4ce5b771f2fb86daee786362fbe48285f05b73cd205f46a224ec031783" diff --git a/recipes/mbedtls/all/conanfile.py b/recipes/mbedtls/all/conanfile.py index 84a6a1f32ace2d..b5af5483b03f42 100644 --- a/recipes/mbedtls/all/conanfile.py +++ b/recipes/mbedtls/all/conanfile.py @@ -1,7 +1,8 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout from conan.tools.files import copy, get, rmdir +from conan.tools.microsoft import is_msvc, check_min_vs from conan.tools.scm import Version import os @@ -32,8 +33,6 @@ class MBedTLSConan(ConanFile): "with_zlib": True, } - exports_sources = "CMakeLists.txt" - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -52,7 +51,7 @@ def layout(self): def requirements(self): if self.options.get_safe("with_zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.settings.os == "Windows" and self.options.shared: @@ -65,10 +64,13 @@ def validate(self): ) def source(self): - get(self, **self.conan_data["sources"][self.version], strip_root = True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): tc = CMakeToolchain(self) + if self.options.shared: + tc.preprocessor_definitions["X509_BUILD_SHARED"] = "1" + tc.cache_variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True tc.variables["USE_SHARED_MBEDTLS_LIBRARY"] = self.options.shared tc.variables["USE_STATIC_MBEDTLS_LIBRARY"] = not self.options.shared if Version(self.version) < "3.0.0": @@ -79,6 +81,13 @@ def generate(self): if Version(self.version) < "3.0.0": # relocatable shared libs on macOS tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" + if is_msvc(self): + if check_min_vs(self, 190, raise_invalid=False): + tc.preprocessor_definitions["MBEDTLS_PLATFORM_SNPRINTF_MACRO"] = "snprintf" + else: + tc.preprocessor_definitions["MBEDTLS_PLATFORM_SNPRINTF_MACRO"] = "MBEDTLS_PLATFORM_STD_SNPRINTF" + tc.generate() + tc = CMakeDeps(self) tc.generate() def build(self): @@ -90,6 +99,7 @@ def package(self): copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) cmake = CMake(self) cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) rmdir(self, os.path.join(self.package_folder, "cmake")) def package_info(self): diff --git a/recipes/mbedtls/all/test_package/CMakeLists.txt b/recipes/mbedtls/all/test_package/CMakeLists.txt index 708448e53f1705..5fa9b94ca1217c 100644 --- a/recipes/mbedtls/all/test_package/CMakeLists.txt +++ b/recipes/mbedtls/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(MbedTLS REQUIRED CONFIG) diff --git a/recipes/mbedtls/all/test_v1_package/CMakeLists.txt b/recipes/mbedtls/all/test_v1_package/CMakeLists.txt index 0d20897301b68b..b21cc49efde95c 100644 --- a/recipes/mbedtls/all/test_v1_package/CMakeLists.txt +++ b/recipes/mbedtls/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) diff --git a/recipes/mbedtls/config.yml b/recipes/mbedtls/config.yml index 114a3e62d619dc..6d346411f4a8a4 100644 --- a/recipes/mbedtls/config.yml +++ b/recipes/mbedtls/config.yml @@ -1,13 +1,19 @@ versions: + "3.4.1": + folder: all "3.2.1": folder: all "3.1.0": folder: all "3.0.0": folder: all + "2.28.4": + folder: all "2.25.0": folder: all "2.24.0": folder: all "2.23.0": folder: all + "2.16.12": + folder: all From 43a772a5b3225c288194a5e2bd0b362332043bd6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 18:53:16 +0200 Subject: [PATCH 0797/1140] (#20141) Bump prometheus-cpp's zlib requirement to [>=1.2.11 <2] range --- recipes/prometheus-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/prometheus-cpp/all/conanfile.py b/recipes/prometheus-cpp/all/conanfile.py index 77a024b271ec11..42d1c971e35ee4 100644 --- a/recipes/prometheus-cpp/all/conanfile.py +++ b/recipes/prometheus-cpp/all/conanfile.py @@ -68,7 +68,7 @@ def requirements(self): if self.options.with_push: self.requires("libcurl/8.0.1") if self.options.get_safe("with_compression"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.info.settings.compiler.cppstd: From 4ab2ecf88c562bee7c979225eab0650dfbf46c14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Thu, 28 Sep 2023 19:32:21 +0200 Subject: [PATCH 0798/1140] (#20123) Bump c-blosc2's zlib requirement to [>=1.2.11 <2] range Co-authored-by: Uilian Ries --- recipes/c-blosc2/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/c-blosc2/all/conanfile.py b/recipes/c-blosc2/all/conanfile.py index 9cfb0264ed537a..e0435a75fa5222 100644 --- a/recipes/c-blosc2/all/conanfile.py +++ b/recipes/c-blosc2/all/conanfile.py @@ -69,7 +69,7 @@ def requirements(self): if self.options.with_zlib in ["zlib-ng", "zlib-ng-compat"]: self.requires("zlib-ng/2.1.3") elif self.options.with_zlib == "zlib": - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: self.requires("zstd/1.5.5") From 328d8a0595b3443ea4b1bc80625b2466002d9097 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 04:18:02 +0900 Subject: [PATCH 0799/1140] (#19512) watcher: add version 0.9.2, remove older versions * watcher: add version 0.9.0 * include atomic * fix patch_description * fix msvc compilation error * fix cxx_flags * add permissive- for alternative tokens * fix cxxflags name * improve patch for 0.9.0 * update 0.9.2 --- recipes/watcher/all/conandata.yml | 17 ++-------- recipes/watcher/all/conanfile.py | 32 ++++++++++++------- .../all/patches/0.3.1-fix-include.patch | 12 ------- .../watcher/all/test_package/CMakeLists.txt | 29 +++++++++-------- .../watcher/all/test_package/test_package.cpp | 10 ++++-- recipes/watcher/config.yml | 8 ++--- 6 files changed, 48 insertions(+), 60 deletions(-) delete mode 100644 recipes/watcher/all/patches/0.3.1-fix-include.patch diff --git a/recipes/watcher/all/conandata.yml b/recipes/watcher/all/conandata.yml index 80ba8ba329e37b..61b03ba30a80dc 100644 --- a/recipes/watcher/all/conandata.yml +++ b/recipes/watcher/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.9.2": + url: "https://github.com/e-dant/watcher/archive/release/0.9.2.tar.gz" + sha256: "d728960cbf5cebb05e1e0b7d61482b1cfd10b6bc616f9e494168f7d5d2e689cf" "0.8.8": url: "https://github.com/e-dant/watcher/archive/release/0.8.8.tar.gz" sha256: "51e61a096d072ae5c78df9318dec50fb5718c88b672305fc4b6bd2c7ba264bbe" @@ -23,22 +26,8 @@ sources: "0.4.3": url: "https://github.com/e-dant/watcher/archive/release/0.4.3.tar.gz" sha256: "8603b45edfa5023752d9e2fdd731efe5a556a542aaf03f6be0e69c68f552b25a" - "0.3.3": - url: "https://github.com/e-dant/watcher/archive/release/0.3.3.tar.gz" - sha256: "1cb4a898741306bb9089bd24175bcbb2cb434531eac6bbcfe1a3679b8bf1f44c" - "0.3.2": - url: "https://github.com/e-dant/watcher/archive/release/0.3.2.tar.gz" - sha256: "f00247ad8ee492cb70143917bd19f80056227f4ebd4263015727f02750e4fbd5" - "0.3.1": - url: "https://github.com/e-dant/watcher/archive/release/0.3.1.tar.gz" - sha256: "0fa79d21ac16c96b7ca50f2563aed9d8841e5b8f139af27d0b2cf199d0d281dc" patches: "0.5.5": - patch_file: "patches/0.5.5-fix-limits_max.patch" patch_description: "fix max macro error in windows" patch_type: "portability" - "0.3.1": - - patch_file: "patches/0.3.1-fix-include.patch" - patch_description: "add missing include headers for some compilers" - patch_type: "portability" - patch_source: "https://github.com/e-dant/watcher/pull/18" diff --git a/recipes/watcher/all/conanfile.py b/recipes/watcher/all/conanfile.py index 31b1acc6f58858..a860da1f34772a 100644 --- a/recipes/watcher/all/conanfile.py +++ b/recipes/watcher/all/conanfile.py @@ -4,6 +4,8 @@ from conan.tools.build import check_min_cppstd from conan.tools.apple import is_apple_os from conan.tools.layout import basic_layout +from conan.tools.scm import Version +from conan.tools.microsoft import is_msvc import os required_conan_version = ">=1.49.0" @@ -19,18 +21,27 @@ class WatcherConan(ConanFile): settings = "os", "arch", "compiler", "build_type" @property - def _minimum_cpp_standard(self): - return 20 + def _min_cppstd(self): + return "20" if Version(self.version) < "0.9.0" else "17" @property def _compilers_minimum_version(self): return { - "gcc": "11", - "clang": "13", - "apple-clang": "13.1", - "Visual Studio": "16", - "msvc": "192", - } + "17": { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + }, + "20": { + "gcc": "11", + "clang": "13", + "apple-clang": "13.1", + "Visual Studio": "16", + "msvc": "192", + }, + }.get(self._min_cppstd, {}) def export_sources(self): export_conandata_patches(self) @@ -43,7 +54,7 @@ def package_id(self): def validate(self): if self.settings.get_safe("compiler.cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._min_cppstd) def loose_lt_semver(v1, v2): lv1 = [int(v) for v in v1.split(".")] @@ -54,7 +65,7 @@ def loose_lt_semver(v1, v2): minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version and loose_lt_semver(str(self.settings.compiler.version), minimum_version): raise ConanInvalidConfiguration( - f"{self.ref} requires C++{self._minimum_cpp_standard}, which your compiler does not support.", + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support.", ) def source(self): @@ -78,6 +89,5 @@ def package_info(self): if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs.append("m") - if is_apple_os(self): self.cpp_info.frameworks = ["CoreFoundation", "CoreServices"] diff --git a/recipes/watcher/all/patches/0.3.1-fix-include.patch b/recipes/watcher/all/patches/0.3.1-fix-include.patch deleted file mode 100644 index 1c3d12d2130dea..00000000000000 --- a/recipes/watcher/all/patches/0.3.1-fix-include.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/include/watcher/adapter/linux/watch.hpp b/include/watcher/adapter/linux/watch.hpp -index 1b6b61a..a3e6aa9 100644 ---- a/include/watcher/adapter/linux/watch.hpp -+++ b/include/watcher/adapter/linux/watch.hpp -@@ -11,6 +11,7 @@ - - #include - #include -+#include - #include - #include - #include diff --git a/recipes/watcher/all/test_package/CMakeLists.txt b/recipes/watcher/all/test_package/CMakeLists.txt index 01b429a54beb88..7cb2b32a687ee5 100644 --- a/recipes/watcher/all/test_package/CMakeLists.txt +++ b/recipes/watcher/all/test_package/CMakeLists.txt @@ -1,5 +1,4 @@ cmake_minimum_required(VERSION 3.12) - project(test_package LANGUAGES CXX) find_package(watcher REQUIRED CONFIG) @@ -7,22 +6,24 @@ find_package(Threads REQUIRED) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE watcher::watcher Threads::Threads) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20) -if(watcher_VERSION VERSION_LESS "0.4.0") - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_NAMESPACE=water) - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_NAMESPACE=water::watcher::event) - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_KIND_NAMESPACE=water::watcher::event) + +if(watcher_VERSION VERSION_GREATER_EQUAL "0.9.0") + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) +else() + target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_20) +endif() + +if(watcher_VERSION VERSION_LESS "0.8.1") + target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_NAMESPACE=wtr::watcher::event) + target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_KIND_NAMESPACE=wtr::watcher::event) else() - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_NAMESPACE=wtr) - if(watcher_VERSION VERSION_LESS "0.8.1") - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_NAMESPACE=wtr::watcher::event) - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_KIND_NAMESPACE=wtr::watcher::event) - else() - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_NAMESPACE=wtr::watcher) - target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_KIND_NAMESPACE=wtr::watcher::event) - endif() + target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_NAMESPACE=wtr::watcher) + target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_EVENT_KIND_NAMESPACE=wtr::watcher::event) endif() +if(watcher_VERSION VERSION_GREATER_EQUAL "0.9.0") + target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_RAII_SAFE) +endif() if(watcher_VERSION VERSION_GREATER_EQUAL "0.6.0") target_compile_definitions(${PROJECT_NAME} PRIVATE WATCHER_WATCH_OBJECT) elseif(watcher_VERSION VERSION_GREATER_EQUAL "0.5.0") diff --git a/recipes/watcher/all/test_package/test_package.cpp b/recipes/watcher/all/test_package/test_package.cpp index 3216b6f2e2ca31..6e1dd6a280cc9c 100644 --- a/recipes/watcher/all/test_package/test_package.cpp +++ b/recipes/watcher/all/test_package/test_package.cpp @@ -15,7 +15,11 @@ int main(int argc, char** argv) { auto const show_event_json = [](const WATCHER_EVENT_NAMESPACE::event& this_event) { std::cout << " " << this_event; +#ifdef WATCHER_RAII_SAFE + if (this_event.path_type != WATCHER_EVENT_KIND_NAMESPACE::path_type::watcher) { +#else if (this_event.kind != WATCHER_EVENT_KIND_NAMESPACE::kind::watcher) { +#endif std::cout << ","; } std::cout << "\n"; @@ -28,12 +32,12 @@ int main(int argc, char** argv) { std::this_thread::sleep_for(time_until_death); auto const is_watch_dead = lifetime.close(); #else - std::thread([&]() { WATCHER_NAMESPACE::watcher::watch(".", show_event_json); }).detach(); + std::thread([&]() { wtr::watcher::watch(".", show_event_json); }).detach(); std::this_thread::sleep_for(time_until_death); # ifdef WATCHER_DIE_WITH_PATH - auto const is_watch_dead = WATCHER_NAMESPACE::watcher::die(".", show_event_json); + auto const is_watch_dead = wtr::watcher::die(".", show_event_json); # else - auto const is_watch_dead = WATCHER_NAMESPACE::watcher::die(show_event_json); + auto const is_watch_dead = wtr::watcher::die(show_event_json); # endif #endif diff --git a/recipes/watcher/config.yml b/recipes/watcher/config.yml index 61b409d5231609..e770c710dc9cfb 100644 --- a/recipes/watcher/config.yml +++ b/recipes/watcher/config.yml @@ -1,4 +1,6 @@ versions: + "0.9.2": + folder: all "0.8.8": folder: all "0.8.7": @@ -15,9 +17,3 @@ versions: folder: all "0.4.3": folder: all - "0.3.3": - folder: all - "0.3.2": - folder: all - "0.3.1": - folder: all From 22ac35f78f3a941038686fe02c3da274a91e465c Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Fri, 29 Sep 2023 01:24:38 +0400 Subject: [PATCH 0800/1140] (#19652) onetbb: moved check for shared hwloc to validate method --- recipes/onetbb/all/conanfile.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/recipes/onetbb/all/conanfile.py b/recipes/onetbb/all/conanfile.py index 742e204c36a4f2..5317849db9bac1 100644 --- a/recipes/onetbb/all/conanfile.py +++ b/recipes/onetbb/all/conanfile.py @@ -85,16 +85,16 @@ def configure(self): if self._tbbbind_explicit_hwloc: self.options["hwloc"].shared = True + def layout(self): + cmake_layout(self, src_folder="src") + def requirements(self): if self._tbbbind_build: self.requires("hwloc/2.9.2") def build_requirements(self): if not self._tbbbind_explicit_hwloc and not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.build_requires("pkgconf/1.9.5") - - def layout(self): - cmake_layout(self, src_folder="src") + self.tool_requires("pkgconf/1.9.5") def package_id(self): if Version(self.version) < "2021.5.0": @@ -113,6 +113,8 @@ def validate_build(self): "Please consider fixing at least the aforementioned issue in upstream." ) self.output.warning("oneTBB strongly discourages usage of static linkage") + + def validate(self): if self._tbbbind_explicit_hwloc and not self.dependencies["hwloc"].options.shared: raise ConanInvalidConfiguration(f"{self.ref} requires hwloc:shared=True to be built.") From 80804cd77f53595241a7a2f157494533fd60f166 Mon Sep 17 00:00:00 2001 From: Joakim Haugen Date: Fri, 29 Sep 2023 01:16:31 +0200 Subject: [PATCH 0801/1140] (#19833) fmi1: Add new recipe for fmi * fmi1: Add version 1.0.1 * Extract license text from header file --- recipes/fmi1/all/conandata.yml | 10 +++ recipes/fmi1/all/conanfile.py | 72 +++++++++++++++++++ recipes/fmi1/all/test_package/CMakeLists.txt | 7 ++ recipes/fmi1/all/test_package/conanfile.py | 25 +++++++ .../fmi1/all/test_package/test_package.cpp | 10 +++ recipes/fmi1/config.yml | 3 + 6 files changed, 127 insertions(+) create mode 100644 recipes/fmi1/all/conandata.yml create mode 100644 recipes/fmi1/all/conanfile.py create mode 100644 recipes/fmi1/all/test_package/CMakeLists.txt create mode 100644 recipes/fmi1/all/test_package/conanfile.py create mode 100644 recipes/fmi1/all/test_package/test_package.cpp create mode 100644 recipes/fmi1/config.yml diff --git a/recipes/fmi1/all/conandata.yml b/recipes/fmi1/all/conandata.yml new file mode 100644 index 00000000000000..3605e7f8bb5d7c --- /dev/null +++ b/recipes/fmi1/all/conandata.yml @@ -0,0 +1,10 @@ +sources: + "1.0.1": + co-simulation: + url: + - https://fmi-standard.org/assets/releases/FMI_for_CoSimulation_v1.0.1.zip + sha256: "81c87527febece29b5bb00bac89f9a58c5aed976aeb0afbfd357cf5aeebabd21" + model-exchange: + url: + - https://fmi-standard.org/assets/releases/FMI_for_ModelExchange_v1.0.1.zip + sha256: "966c948707531c5a764b70fa7bbe23030da962d8a939e01dc8bc9af9d8264cd1" diff --git a/recipes/fmi1/all/conanfile.py b/recipes/fmi1/all/conanfile.py new file mode 100644 index 00000000000000..e0cf988f8107d7 --- /dev/null +++ b/recipes/fmi1/all/conanfile.py @@ -0,0 +1,72 @@ +from os import path +from conan import ConanFile +from conan.errors import ConanException +from conan.tools.files import copy, get, load, save +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + + +class PackageConan(ConanFile): + name = "fmi1" + description = "Functional Mock-up Interface (FMI) for Co-Simulation" + license = "BSD-2-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://fmi-standard.org" + topics = ("fmi-standard", "co-simulation", "model-exchange", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True # True OK because patch only adds new file + + def _extract_copyright(self): + fmiFunctions_h = load(self, path.join(self.source_folder, "cosim", "fmiFunctions.h")) + copyright_start = "Copyright(c)" + copyright_end = "DAMAGE." + start_index = fmiFunctions_h.find(copyright_start) + stop_index = fmiFunctions_h.find(copyright_end) + if start_index == -1 or stop_index == -1: + raise ConanException("Could not extract license from fmiFunctions.h file.") + return fmiFunctions_h[start_index:stop_index+len(copyright_end)] + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def source(self): + get(self, **self.conan_data["sources"][self.version]["co-simulation"], + destination="cosim", strip_root=True) + get(self, **self.conan_data["sources"][self.version]["model-exchange"], + destination="modex", strip_root=True) + + def build(self): + pass + + def package(self): + save(self, path.join(self.package_folder, "licenses", "LICENSE"), self._extract_copyright()) + for comp in ["modex", "cosim"]: + copy( + self, + pattern="*.h", + src=path.join(self.source_folder, comp), + dst=path.join(self.package_folder, "include", comp) + ) + copy( + self, + pattern="*.xsd", + src=path.join(self.source_folder, comp), + dst=path.join(self.package_folder, "res", comp) + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = ["res"] + + self.cpp_info.components["cosim"].set_property("cmake_target_name", "fmi1::cosim") + self.cpp_info.components["cosim"].includedirs = ["include/cosim"] + self.cpp_info.components["cosim"].resdirs = ["res/cosim"] + self.cpp_info.components["modex"].set_property("cmake_target_name", "fmi1::modex") + self.cpp_info.components["modex"].includedirs = ["include/modex"] + self.cpp_info.components["modex"].resdirs = ["res/modex"] diff --git a/recipes/fmi1/all/test_package/CMakeLists.txt b/recipes/fmi1/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..7e700e5046782a --- /dev/null +++ b/recipes/fmi1/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C CXX) + +find_package(fmi1 REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE fmi1::cosim) diff --git a/recipes/fmi1/all/test_package/conanfile.py b/recipes/fmi1/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e730ad6dc0dfc1 --- /dev/null +++ b/recipes/fmi1/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fmi1/all/test_package/test_package.cpp b/recipes/fmi1/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..96872e2ca1ec71 --- /dev/null +++ b/recipes/fmi1/all/test_package/test_package.cpp @@ -0,0 +1,10 @@ +#include +#include +#include "fmiFunctions.h" + + +int main(void) { + std::cout << fmiVersion << std::endl; + + return EXIT_SUCCESS; +} diff --git a/recipes/fmi1/config.yml b/recipes/fmi1/config.yml new file mode 100644 index 00000000000000..715e55357a17be --- /dev/null +++ b/recipes/fmi1/config.yml @@ -0,0 +1,3 @@ +versions: + "1.0.1": + folder: all From 26709193101afb7d34d8b3ed6afc80c1959b4142 Mon Sep 17 00:00:00 2001 From: Joakim Haugen Date: Fri, 29 Sep 2023 02:11:35 +0200 Subject: [PATCH 0802/1140] (#19837) fmi3: new package * fmi3: add new recipe * Remove empty patches in conandata --- recipes/fmi3/all/conandata.yml | 5 ++ recipes/fmi3/all/conanfile.py | 50 +++++++++++++++++++ recipes/fmi3/all/test_package/CMakeLists.txt | 7 +++ recipes/fmi3/all/test_package/conanfile.py | 25 ++++++++++ .../fmi3/all/test_package/test_package.cpp | 10 ++++ recipes/fmi3/config.yml | 3 ++ 6 files changed, 100 insertions(+) create mode 100644 recipes/fmi3/all/conandata.yml create mode 100644 recipes/fmi3/all/conanfile.py create mode 100644 recipes/fmi3/all/test_package/CMakeLists.txt create mode 100644 recipes/fmi3/all/test_package/conanfile.py create mode 100644 recipes/fmi3/all/test_package/test_package.cpp create mode 100644 recipes/fmi3/config.yml diff --git a/recipes/fmi3/all/conandata.yml b/recipes/fmi3/all/conandata.yml new file mode 100644 index 00000000000000..b12c4c988ee8b5 --- /dev/null +++ b/recipes/fmi3/all/conandata.yml @@ -0,0 +1,5 @@ +sources: + "3.0.1": + url: + - https://github.com/modelica/fmi-standard/releases/download/v3.0.1/FMI-Standard-3.0.1.zip + sha256: "181a8a377ccfafa92167019bd3099227f8bf44192444bcb1a2d42aba65fbffe2" diff --git a/recipes/fmi3/all/conanfile.py b/recipes/fmi3/all/conanfile.py new file mode 100644 index 00000000000000..3d5c1d773f7ef2 --- /dev/null +++ b/recipes/fmi3/all/conanfile.py @@ -0,0 +1,50 @@ +from os import path +from conan import ConanFile +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.52.0" + + +class PackageConan(ConanFile): + name = "fmi3" + description = "Functional Mock-up Interface (FMI)" + license = "BSD-2-Clause" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://fmi-standard.org" + topics = ("fmi-standard", "co-simulation", "model-exchange", "scheduled execution", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=False) + + def build(self): + pass + + def package(self): + copy(self, pattern="LICENSE.txt", dst=path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.h", + src=path.join(self.source_folder, "headers"), + dst=path.join(self.package_folder, "include"), + ) + copy( + self, + pattern="*.xsd", + src=path.join(self.source_folder, "schema"), + dst=path.join(self.package_folder, "res"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.resdirs = ["res"] diff --git a/recipes/fmi3/all/test_package/CMakeLists.txt b/recipes/fmi3/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..24b88e3db471de --- /dev/null +++ b/recipes/fmi3/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C CXX) + +find_package(fmi3 REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE fmi3::fmi3) diff --git a/recipes/fmi3/all/test_package/conanfile.py b/recipes/fmi3/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e730ad6dc0dfc1 --- /dev/null +++ b/recipes/fmi3/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fmi3/all/test_package/test_package.cpp b/recipes/fmi3/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..ea4bf3fd0194a4 --- /dev/null +++ b/recipes/fmi3/all/test_package/test_package.cpp @@ -0,0 +1,10 @@ +#include +#include +#include "fmi3Functions.h" + + +int main(void) { + std::cout << fmi3Version << std::endl; + + return EXIT_SUCCESS; +} diff --git a/recipes/fmi3/config.yml b/recipes/fmi3/config.yml new file mode 100644 index 00000000000000..f1eca9cdf76de8 --- /dev/null +++ b/recipes/fmi3/config.yml @@ -0,0 +1,3 @@ +versions: + "3.0.1": + folder: all From 1b75cd57b102cdcf0e78e55646a7a9221432fb99 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 09:31:59 +0900 Subject: [PATCH 0803/1140] (#19906) yyjson: add with_utf8_validation for yyjson>=0.8.0 * yyjson: add with_utf8_validation for yyjson>=0.8.0 * Update recipes/yyjson/all/conanfile.py --------- Co-authored-by: Carlos Zoido --- recipes/yyjson/all/conanfile.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/recipes/yyjson/all/conanfile.py b/recipes/yyjson/all/conanfile.py index 041f3c54d28f4d..3574d26b2c7d54 100644 --- a/recipes/yyjson/all/conanfile.py +++ b/recipes/yyjson/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import copy, get, rmdir +from conan.tools.scm import Version import os required_conan_version = ">=1.53.0" @@ -18,15 +19,19 @@ class YyjsonConan(ConanFile): options = { "shared": [True, False], "fPIC": [True, False], + "with_utf8_validation": [True, False], } default_options = { "shared": False, "fPIC": True, + "with_utf8_validation": True, } def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if Version(self.version) < "0.8.0": + del self.options.with_utf8_validation def configure(self): if self.options.shared: @@ -42,6 +47,8 @@ def source(self): def generate(self): tc = CMakeToolchain(self) + if Version(self.version) >= "0.8.0": + tc.variables["YYJSON_DISABLE_UTF8_VALIDATION"] = not bool(self.options.with_utf8_validation) tc.generate() def build(self): From b3f2d572277847c0dffa911ed89b60b23d2f19b2 Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Fri, 29 Sep 2023 11:02:19 +0930 Subject: [PATCH 0804/1140] (#19907) [armadillo] Add version 12.6.4 * [armadillo] Add version 12.6.4 * [armadillo] Propagate hdf5 headers transitively This is necessary because armadillo_buts/include_hdf5.h includes the hdf5 headers. When a consumer links armadillo with hdf5 and then includes the armadillo headers, they need to be able to discover them. * [armadillo] Propagate shared obejct requirements transitively This is necessary to avoid linker errors as of binutils 2.22, which gives errors similar to `libhdf5.so.310: error adding symbols: DSO missing from command line`. This more strict requirement in binutils requires that `-lhdf5` or `-lopenblas` be added to the consumer linker command line invocation, which passing these libraries transitively does. --- recipes/armadillo/all/conandata.yml | 7 + recipes/armadillo/all/conanfile.py | 4 +- ...04-Guard-dependency-discovery-12.6.x.patch | 121 ++++++++++++++++++ recipes/armadillo/config.yml | 2 + 4 files changed, 132 insertions(+), 2 deletions(-) create mode 100644 recipes/armadillo/all/patches/0004-Guard-dependency-discovery-12.6.x.patch diff --git a/recipes/armadillo/all/conandata.yml b/recipes/armadillo/all/conandata.yml index 0d2a3540e26f26..fafd7b841d70bd 100644 --- a/recipes/armadillo/all/conandata.yml +++ b/recipes/armadillo/all/conandata.yml @@ -11,6 +11,9 @@ sources: "12.2.0": url: "https://sourceforge.net/projects/arma/files/armadillo-12.2.0.tar.xz" sha256: "b0dce042297e865add3351dad77f78c2c7638d6632f58357b015e50edcbd2186" + "12.6.4": + url: "https://sourceforge.net/projects/arma/files/armadillo-12.6.4.tar.xz" + sha256: "eb7f243ffc32f18324bc7fa978d0358637e7357ca7836bec55b4eb56e9749380" patches: "10.7.0": @@ -29,3 +32,7 @@ patches: - patch_file: "patches/0003-Guard-dependency-discovery-12.2.x.patch" patch_description: "Add find_package statements to inject conan dependencies" patch_type: "conan" + "12.6.4": + - patch_file: "patches/0004-Guard-dependency-discovery-12.6.x.patch" + patch_description: "Add find_package statements to inject conan dependencies" + patch_type: "conan" diff --git a/recipes/armadillo/all/conanfile.py b/recipes/armadillo/all/conanfile.py index 5638fc2428e265..ef77af6e7bf330 100644 --- a/recipes/armadillo/all/conanfile.py +++ b/recipes/armadillo/all/conanfile.py @@ -186,10 +186,10 @@ def requirements(self): # See https://gitlab.com/conradsnicta/armadillo-code/-/issues/227 for more information. if self.options.use_hdf5 and Version(self.version) < "12": # Use the conan dependency if the system lib isn't being used - self.requires("hdf5/1.14.0") + self.requires("hdf5/1.14.0", transitive_headers=True, transitive_libs=True) if self.options.use_blas == "openblas": - self.requires("openblas/0.3.20") + self.requires("openblas/0.3.20", transitive_libs=True) if ( self.options.use_blas == "intel_mkl" and self.options.use_lapack == "intel_mkl" diff --git a/recipes/armadillo/all/patches/0004-Guard-dependency-discovery-12.6.x.patch b/recipes/armadillo/all/patches/0004-Guard-dependency-discovery-12.6.x.patch new file mode 100644 index 00000000000000..f374782089ebfd --- /dev/null +++ b/recipes/armadillo/all/patches/0004-Guard-dependency-discovery-12.6.x.patch @@ -0,0 +1,121 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index a67ef80..91ef979 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -259,7 +259,11 @@ if(APPLE) + set(ARMA_USE_ACCELERATE true) + + if(ALLOW_OPENBLAS_MACOS) +- include(ARMA_FindOpenBLAS) ++ if(USE_OPENBLAS) ++ find_package(OpenBLAS) ++ else() ++ set(OpenBLAS_FOUND NO) ++ endif() + message(STATUS "OpenBLAS_FOUND = ${OpenBLAS_FOUND}") + message(STATUS "") + message(STATUS "*** If use of OpenBLAS is causing problems,") +@@ -274,8 +278,16 @@ if(APPLE) + endif() + + if(ALLOW_BLAS_LAPACK_MACOS) +- include(ARMA_FindBLAS) +- include(ARMA_FindLAPACK) ++ if(USE_SYSTEM_BLAS) ++ include(ARMA_FindBLAS) ++ else() ++ set(BLAS_FOUND NO) ++ endif() ++ if(USE_SYSTEM_LAPACK) ++ include(ARMA_FindLAPACK) ++ else() ++ set(LAPACK_FOUND NO) ++ endif() + message(STATUS " BLAS_FOUND = ${BLAS_FOUND}" ) + message(STATUS "LAPACK_FOUND = ${LAPACK_FOUND}") + message(STATUS "") +@@ -314,19 +326,45 @@ if(APPLE) + + else() + +- if(ALLOW_FLEXIBLAS_LINUX AND (${CMAKE_SYSTEM_NAME} MATCHES "Linux")) +- include(ARMA_FindFlexiBLAS) ++ if(USE_MKL) ++ find_package(MKL) + else() +- set(FlexiBLAS_FOUND false) ++ set(MKL_FOUND NO) ++ endif() ++ ++ if(USE_OPENBLAS) ++ find_package(OpenBLAS) ++ else() ++ set(OpenBLAS_FOUND NO) ++ endif() ++ ++ if(USE_SYSTEM_ATLAS) ++ include(ARMA_FindATLAS) ++ else() ++ set(ATLAS_FOUND NO) ++ endif() ++ ++ if(USE_SYSTEM_BLAS) ++ include(ARMA_FindBLAS) ++ else() ++ set(BLAS_FOUND NO) ++ endif() ++ ++ if(USE_SYSTEM_LAPACK) ++ include(ARMA_FindLAPACK) ++ else() ++ set(LAPACK_FOUND NO) + endif() + +- include(ARMA_FindMKL) +- include(ARMA_FindOpenBLAS) +- include(ARMA_FindATLAS) # TODO: remove support for ATLAS in next major version +- include(ARMA_FindBLAS) +- include(ARMA_FindLAPACK) +- +- message(STATUS "FlexiBLAS_FOUND = ${FlexiBLAS_FOUND}" ) ++ if(ALLOW_FLEXIBLAS_LINUX AND (${CMAKE_SYSTEM_NAME} MATCHES "Linux")) ++ if(USE_SYSTEM_FLEXIBLAS) ++ include(ARMA_FindFlexiBLAS) ++ else() ++ set(FlexiBLAS_FOUND NO) ++ endif() ++ endif() ++ ++ message(STATUS "FlexiBLAS_FOUND = ${FlexiBLAS_FOUND}" ) + message(STATUS " MKL_FOUND = ${MKL_FOUND}" ) + message(STATUS " OpenBLAS_FOUND = ${OpenBLAS_FOUND}" ) + message(STATUS " ATLAS_FOUND = ${ATLAS_FOUND}" ) +@@ -438,7 +476,11 @@ else() + endif() + + +-include(ARMA_FindARPACK) ++if(USE_SYSTEM_ARPACK) ++ include(ARMA_FindARPACK) ++else() ++ set(ARPACK_FOUND NO) ++endif() + message(STATUS "ARPACK_FOUND = ${ARPACK_FOUND}") + + if(ARPACK_FOUND) +@@ -446,7 +488,11 @@ if(ARPACK_FOUND) + set(ARMA_LIBS ${ARMA_LIBS} ${ARPACK_LIBRARY}) + endif() + +-include(ARMA_FindSuperLU5) ++if(USE_SYSTEM_SUPERLU) ++ include(ARMA_FindSuperLU5) ++else() ++ set(SuperLU_FOUND NO) ++endif() + message(STATUS "SuperLU_FOUND = ${SuperLU_FOUND}") + + if(SuperLU_FOUND) +-- +2.42.0 + diff --git a/recipes/armadillo/config.yml b/recipes/armadillo/config.yml index 3d54bf4d2f283f..7dfcb07b6f44b0 100644 --- a/recipes/armadillo/config.yml +++ b/recipes/armadillo/config.yml @@ -7,3 +7,5 @@ versions: folder: all "12.2.0": folder: all + "12.6.4": + folder: all From 464ac13dae25d60ff24d558307524002c2406e58 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 04:09:55 +0200 Subject: [PATCH 0805/1140] (#19940) apr/1.7.4: add patch apr-config-prefix-env in order to fix build of apr-util --- recipes/apr/all/conandata.yml | 23 +++++++++++-------- ...0001-cmake-build-only-shared-static.patch} | 0 ...=> 1.7.0-0002-apr-config-prefix-env.patch} | 0 ...0003-cmake-gen_test_char-use-target.patch} | 0 ...patch => 1.7.0-0004-autotools-mingw.patch} | 0 ...e.patch => 1.7.0-0005-clang12-apple.patch} | 0 ...patch => 1.7.0-0006-sys_siglist-fix.patch} | 0 ...> 1.7.0-0007-cmake-minimum-required.patch} | 0 ...0001-cmake-build-only-shared-static.patch} | 0 9 files changed, 14 insertions(+), 9 deletions(-) rename recipes/apr/all/patches/{0001-cmake-build-only-shared-static.patch => 1.7.0-0001-cmake-build-only-shared-static.patch} (100%) rename recipes/apr/all/patches/{0002-apr-config-prefix-env.patch => 1.7.0-0002-apr-config-prefix-env.patch} (100%) rename recipes/apr/all/patches/{0003-cmake-gen_test_char-use-target.patch => 1.7.0-0003-cmake-gen_test_char-use-target.patch} (100%) rename recipes/apr/all/patches/{0004-autotools-mingw.patch => 1.7.0-0004-autotools-mingw.patch} (100%) rename recipes/apr/all/patches/{0005-clang12-apple.patch => 1.7.0-0005-clang12-apple.patch} (100%) rename recipes/apr/all/patches/{0006-sys_siglist-fix.patch => 1.7.0-0006-sys_siglist-fix.patch} (100%) rename recipes/apr/all/patches/{0007-cmake-minimum-required.patch => 1.7.0-0007-cmake-minimum-required.patch} (100%) rename recipes/apr/all/patches/{0401-cmake-build-only-shared-static.patch => 1.7.4-0001-cmake-build-only-shared-static.patch} (100%) diff --git a/recipes/apr/all/conandata.yml b/recipes/apr/all/conandata.yml index 0e388265ecf5f4..6ce547b4ee2f4f 100644 --- a/recipes/apr/all/conandata.yml +++ b/recipes/apr/all/conandata.yml @@ -7,21 +7,26 @@ sources: sha256: "e2e148f0b2e99b8e5c6caa09f6d4fb4dd3e83f744aa72a952f94f5a14436f7ea" patches: "1.7.4": - - patch_file: "patches/0401-cmake-build-only-shared-static.patch" + - patch_file: "patches/1.7.4-0001-cmake-build-only-shared-static.patch" patch_type: "conan" patch_description: "Use BUILD_SHARED_LIBS to conditionally build static/dynamic libs" - - patch_file: "patches/0006-sys_siglist-fix.patch" + - patch_file: "patches/1.7.0-0002-apr-config-prefix-env.patch" + patch_type: "conan" + patch_description: "Allow downtream recipes to detect some helpr build files of apr in a relocatalbe context" + - patch_file: "patches/1.7.0-0006-sys_siglist-fix.patch" patch_type: "bugfix" patch_description: "Replace deprecated sys_siglist[] with strsignal()" "1.7.0": - - patch_file: "patches/0001-cmake-build-only-shared-static.patch" + - patch_file: "patches/1.7.0-0001-cmake-build-only-shared-static.patch" patch_type: "conan" patch_description: "Use BUILD_SHARED_LIBS to conditionally build static/dynamic libs" - - patch_file: "patches/0002-apr-config-prefix-env.patch" - - patch_file: "patches/0003-cmake-gen_test_char-use-target.patch" - - patch_file: "patches/0004-autotools-mingw.patch" - - patch_file: "patches/0005-clang12-apple.patch" - - patch_file: "patches/0006-sys_siglist-fix.patch" + - patch_file: "patches/1.7.0-0002-apr-config-prefix-env.patch" + patch_type: "conan" + patch_description: "Allow downtream recipes to detect some helpr build files of apr in a relocatalbe context" + - patch_file: "patches/1.7.0-0003-cmake-gen_test_char-use-target.patch" + - patch_file: "patches/1.7.0-0004-autotools-mingw.patch" + - patch_file: "patches/1.7.0-0005-clang12-apple.patch" + - patch_file: "patches/1.7.0-0006-sys_siglist-fix.patch" patch_type: "bugfix" patch_description: "Replace deprecated sys_siglist[] with strsignal()" - - patch_file: "patches/0007-cmake-minimum-required.patch" + - patch_file: "patches/1.7.0-0007-cmake-minimum-required.patch" diff --git a/recipes/apr/all/patches/0001-cmake-build-only-shared-static.patch b/recipes/apr/all/patches/1.7.0-0001-cmake-build-only-shared-static.patch similarity index 100% rename from recipes/apr/all/patches/0001-cmake-build-only-shared-static.patch rename to recipes/apr/all/patches/1.7.0-0001-cmake-build-only-shared-static.patch diff --git a/recipes/apr/all/patches/0002-apr-config-prefix-env.patch b/recipes/apr/all/patches/1.7.0-0002-apr-config-prefix-env.patch similarity index 100% rename from recipes/apr/all/patches/0002-apr-config-prefix-env.patch rename to recipes/apr/all/patches/1.7.0-0002-apr-config-prefix-env.patch diff --git a/recipes/apr/all/patches/0003-cmake-gen_test_char-use-target.patch b/recipes/apr/all/patches/1.7.0-0003-cmake-gen_test_char-use-target.patch similarity index 100% rename from recipes/apr/all/patches/0003-cmake-gen_test_char-use-target.patch rename to recipes/apr/all/patches/1.7.0-0003-cmake-gen_test_char-use-target.patch diff --git a/recipes/apr/all/patches/0004-autotools-mingw.patch b/recipes/apr/all/patches/1.7.0-0004-autotools-mingw.patch similarity index 100% rename from recipes/apr/all/patches/0004-autotools-mingw.patch rename to recipes/apr/all/patches/1.7.0-0004-autotools-mingw.patch diff --git a/recipes/apr/all/patches/0005-clang12-apple.patch b/recipes/apr/all/patches/1.7.0-0005-clang12-apple.patch similarity index 100% rename from recipes/apr/all/patches/0005-clang12-apple.patch rename to recipes/apr/all/patches/1.7.0-0005-clang12-apple.patch diff --git a/recipes/apr/all/patches/0006-sys_siglist-fix.patch b/recipes/apr/all/patches/1.7.0-0006-sys_siglist-fix.patch similarity index 100% rename from recipes/apr/all/patches/0006-sys_siglist-fix.patch rename to recipes/apr/all/patches/1.7.0-0006-sys_siglist-fix.patch diff --git a/recipes/apr/all/patches/0007-cmake-minimum-required.patch b/recipes/apr/all/patches/1.7.0-0007-cmake-minimum-required.patch similarity index 100% rename from recipes/apr/all/patches/0007-cmake-minimum-required.patch rename to recipes/apr/all/patches/1.7.0-0007-cmake-minimum-required.patch diff --git a/recipes/apr/all/patches/0401-cmake-build-only-shared-static.patch b/recipes/apr/all/patches/1.7.4-0001-cmake-build-only-shared-static.patch similarity index 100% rename from recipes/apr/all/patches/0401-cmake-build-only-shared-static.patch rename to recipes/apr/all/patches/1.7.4-0001-cmake-build-only-shared-static.patch From a2cd0b69e9b4c5108db3aa7809ff8a5a9178b9fc Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 11:49:29 +0900 Subject: [PATCH 0806/1140] (#19946) coost: add recipe * coost: add recipe * remove component definition --- recipes/coost/all/conandata.yml | 4 + recipes/coost/all/conanfile.py | 105 ++++++++++++++++++ recipes/coost/all/test_package/CMakeLists.txt | 8 ++ recipes/coost/all/test_package/conanfile.py | 26 +++++ .../coost/all/test_package/test_package.cpp | 7 ++ recipes/coost/config.yml | 3 + 6 files changed, 153 insertions(+) create mode 100644 recipes/coost/all/conandata.yml create mode 100644 recipes/coost/all/conanfile.py create mode 100644 recipes/coost/all/test_package/CMakeLists.txt create mode 100644 recipes/coost/all/test_package/conanfile.py create mode 100644 recipes/coost/all/test_package/test_package.cpp create mode 100644 recipes/coost/config.yml diff --git a/recipes/coost/all/conandata.yml b/recipes/coost/all/conandata.yml new file mode 100644 index 00000000000000..86d6db4c792cea --- /dev/null +++ b/recipes/coost/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "3.0.1": + url: "https://github.com/idealvin/coost/archive/refs/tags/v3.0.1.tar.gz" + sha256: "f2285d59dc8317dd2494d7628a56f10de9b814d90b86aedf93a3305f94c6ae1a" diff --git a/recipes/coost/all/conanfile.py b/recipes/coost/all/conanfile.py new file mode 100644 index 00000000000000..6bdf895367ac51 --- /dev/null +++ b/recipes/coost/all/conanfile.py @@ -0,0 +1,105 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +import os + +required_conan_version = ">=1.53.0" + +class CoostConan(ConanFile): + name = "coost" + description = "A tiny boost library in C++11." + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/idealvin/coost" + topics = ("coroutine", "cpp11", "boost") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_libcurl": [True, False], + "with_openssl": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + "with_libcurl": False, + "with_openssl": False, + } + + @property + def _min_cppstd(self): + return 11 + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def requirements(self): + if self.options.with_libcurl: + self.requires("libcurl/8.2.1") + if self.options.with_libcurl or self.options.with_openssl: + self.requires("openssl/[>=1.1 <4]") + if self.settings.os == "Linux": + self.requires("libbacktrace/cci.20210118") + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + if self.info.options.with_libcurl: + if not self.info.options.with_openssl: + raise ConanInvalidConfiguration(f"{self.ref} requires with_openssl=True when using with_libcurl=True") + if self.dependencies["libcurl"].options.with_ssl != "openssl": + raise ConanInvalidConfiguration(f"{self.ref} requires libcurl/*:with_ssl='openssl' to be enabled") + if not self.dependencies["libcurl"].options.with_zlib: + raise ConanInvalidConfiguration(f"{self.ref} requires libcurl/*:with_zlib=True to be enabled") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + if is_msvc(self): + tc.variables["STATIC_VS_CRT"] = is_msvc_static_runtime(self) + tc.variables["WITH_LIBCURL"] = self.options.with_libcurl + tc.variables["WITH_OPENSSL"] = self.options.with_openssl + tc.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, "LICENSE.md", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + self.cpp_info.libs = ["co"] + + self.cpp_info.set_property("cmake_file_name", "coost") + self.cpp_info.set_property("cmake_target_name", "coost::co") + self.cpp_info.set_property("pkg_config_name", "coost") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["pthread", "dl", "m"] + if self.settings.os == "Linux": + self.cpp_info.requires.append("libbacktrace::libbacktrace") + if self.settings.os == "Windows": + self.cpp_info.system_libs = ["ws2_32"] diff --git a/recipes/coost/all/test_package/CMakeLists.txt b/recipes/coost/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..f7ac5b551babf3 --- /dev/null +++ b/recipes/coost/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) + +find_package(coost REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE coost::co) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/coost/all/test_package/conanfile.py b/recipes/coost/all/test_package/conanfile.py new file mode 100644 index 00000000000000..ef5d7042163ecc --- /dev/null +++ b/recipes/coost/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/coost/all/test_package/test_package.cpp b/recipes/coost/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..46b92d23f68309 --- /dev/null +++ b/recipes/coost/all/test_package/test_package.cpp @@ -0,0 +1,7 @@ +#include "co/str.h" +#include + +int main() { + std::cout << str::from(123) << std::endl; + return 0; +} diff --git a/recipes/coost/config.yml b/recipes/coost/config.yml new file mode 100644 index 00000000000000..f1eca9cdf76de8 --- /dev/null +++ b/recipes/coost/config.yml @@ -0,0 +1,3 @@ +versions: + "3.0.1": + folder: all From 576e884462c022964972e4dea109f7c86202d770 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 12:31:26 +0900 Subject: [PATCH 0807/1140] (#19948) cimg: add version 3.3.0, update libtiff/4.6.0 --- recipes/cimg/all/conandata.yml | 3 +++ recipes/cimg/all/conanfile.py | 2 +- recipes/cimg/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/cimg/all/conandata.yml b/recipes/cimg/all/conandata.yml index 7139132fb19a98..110b573ab51e18 100644 --- a/recipes/cimg/all/conandata.yml +++ b/recipes/cimg/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.3.0": + url: "https://cimg.eu/files/CImg_3.3.0.zip" + sha256: "d5eecb3551fc1966a9aac8637dc643bf6049e2b1b1a1f9deec3069e289ee1d65" "3.2.6": url: "https://cimg.eu/files/CImg_3.2.6.zip" sha256: "8da3aa995027231bb18f97bb986e12788ef464b3ab8a34151650bf1217baeda7" diff --git a/recipes/cimg/all/conanfile.py b/recipes/cimg/all/conanfile.py index 01ef66f480f653..9e8fee941b0eb9 100644 --- a/recipes/cimg/all/conanfile.py +++ b/recipes/cimg/all/conanfile.py @@ -72,7 +72,7 @@ def requirements(self): if self.options.enable_png: self.requires("libpng/1.6.40") if self.options.enable_tiff: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") if self.options.enable_ffmpeg: if self.options.enable_opencv: self.requires("ffmpeg/4.4") diff --git a/recipes/cimg/config.yml b/recipes/cimg/config.yml index a0c4dfee0ab1c7..9b44fb64c63a13 100644 --- a/recipes/cimg/config.yml +++ b/recipes/cimg/config.yml @@ -1,4 +1,6 @@ versions: + "3.3.0": + folder: all "3.2.6": folder: all "3.2.5": From ec093bfa702447e086b8fbbd0b42afef9ccf43ba Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 13:10:14 +0900 Subject: [PATCH 0808/1140] (#19962) stringzilla: add version 1.2.2 --- recipes/stringzilla/all/conandata.yml | 3 +++ recipes/stringzilla/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/stringzilla/all/conandata.yml b/recipes/stringzilla/all/conandata.yml index f529350a7dc33f..413ad483bbe6ed 100644 --- a/recipes/stringzilla/all/conandata.yml +++ b/recipes/stringzilla/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.2": + url: "https://github.com/ashvardanian/StringZilla/archive/refs/tags/v1.2.2.tar.gz" + sha256: "2e17c49965841647a1c371247f53b2f576e5fb32fe4b84a080d425b12f17703c" "1.1.3": url: "https://github.com/ashvardanian/StringZilla/archive/refs/tags/v1.1.3.tar.gz" sha256: "1856c4d780b2c9a12ccd14d04996b35bec9fe537d0a31209000e12777a86e495" diff --git a/recipes/stringzilla/config.yml b/recipes/stringzilla/config.yml index e1c4f3be249832..a86fcfcd6fd284 100644 --- a/recipes/stringzilla/config.yml +++ b/recipes/stringzilla/config.yml @@ -1,3 +1,5 @@ versions: + "1.2.2": + folder: all "1.1.3": folder: all From 657a91a3d725632e082f5602d8637a23818f67ae Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 13:30:00 +0900 Subject: [PATCH 0809/1140] (#19967) glaze: add version 1.5.0 * glaze: add version 1.4.2 * update 1.4.3 * update 1.4.4 * update 1.5.0 --- recipes/glaze/all/conandata.yml | 3 +++ recipes/glaze/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index 98ea7dc8d11505..2840b2eed5cbb1 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.0": + url: "https://github.com/stephenberry/glaze/archive/v1.5.0.tar.gz" + sha256: "9ab1cc5faa3a1a46b478c884207e6c364e4b6ae9c09f96cbf9f2ef620b3bb3b5" "1.4.1": url: "https://github.com/stephenberry/glaze/archive/v1.4.1.tar.gz" sha256: "fae4188004d383f79225db26e41060aaae9a3eff92da7637aa467749e9590ee6" diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index 73f9b337cba86e..dfc0e2b2fc07ab 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.0": + folder: all "1.4.1": folder: all "1.4.0": From 20ff13bb7ebbc9860ac494608f8d1ecb990c9e87 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 06:51:53 +0200 Subject: [PATCH 0810/1140] (#19968) cgif: bump meson --- recipes/cgif/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cgif/all/conanfile.py b/recipes/cgif/all/conanfile.py index ef47a850d95dc7..0f4eab97dfc4f8 100644 --- a/recipes/cgif/all/conanfile.py +++ b/recipes/cgif/all/conanfile.py @@ -47,7 +47,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} doesn't support shared build with Visual Studio") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 956202028ba8bbcc49c2ffcfa6f6fe8ab2168a0f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 07:20:32 +0200 Subject: [PATCH 0811/1140] (#19969) dav1d: bump meson --- recipes/dav1d/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/dav1d/all/conanfile.py b/recipes/dav1d/all/conanfile.py index 8a1651ceed7087..5882f930a7dbde 100644 --- a/recipes/dav1d/all/conanfile.py +++ b/recipes/dav1d/all/conanfile.py @@ -58,7 +58,7 @@ def layout(self): basic_layout(self, src_folder="src") def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.1") if self.options.assembly: self.tool_requires("nasm/2.15.05") From 80b1db8497e33d3807bfa994aa0aebb9ee10950f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 07:29:28 +0200 Subject: [PATCH 0812/1140] (#19970) fribidi: bump meson --- recipes/fribidi/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/fribidi/all/conanfile.py b/recipes/fribidi/all/conanfile.py index 0867aa984f255b..4c363828a67c84 100644 --- a/recipes/fribidi/all/conanfile.py +++ b/recipes/fribidi/all/conanfile.py @@ -48,7 +48,7 @@ def layout(self): basic_layout(self, src_folder="src") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From b3c767e756e894663fc5195e0dacd643554e1472 Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 29 Sep 2023 14:47:16 +0900 Subject: [PATCH 0813/1140] (#20052) libunwind: update xz_utils/5.4.4 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/libunwind/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libunwind/all/conanfile.py b/recipes/libunwind/all/conanfile.py index e0054d21df520c..4739138df383bf 100644 --- a/recipes/libunwind/all/conanfile.py +++ b/recipes/libunwind/all/conanfile.py @@ -53,7 +53,7 @@ def layout(self): def requirements(self): if self.options.minidebuginfo: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.zlibdebuginfo: self.requires("zlib/[>=1.2.11 <2]") From 8b2a8967fcb994e27e24b3596182ae0578cb2c8d Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 08:30:38 +0200 Subject: [PATCH 0814/1140] (#19974) inih: bump meson --- recipes/inih/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/inih/all/conanfile.py b/recipes/inih/all/conanfile.py index 7b43c7f01710cf..559726ced856f6 100644 --- a/recipes/inih/all/conanfile.py +++ b/recipes/inih/all/conanfile.py @@ -62,7 +62,7 @@ def validate(self): raise ConanInvalidConfiguration("Shared inih is not supported with msvc") def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 683bf159d1ce4fef21bcca9521c3e3213c68c8f8 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 09:09:45 +0200 Subject: [PATCH 0815/1140] (#19975) lcms: bump meson --- recipes/lcms/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/lcms/all/conanfile.py b/recipes/lcms/all/conanfile.py index 6a996a28f1758b..bc10e97d6f1111 100644 --- a/recipes/lcms/all/conanfile.py +++ b/recipes/lcms/all/conanfile.py @@ -45,7 +45,7 @@ def layout(self): basic_layout(self, src_folder="src") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 4a0694cc67ae589422b078fbe5c95c2e0e6a26fe Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 10:20:55 +0200 Subject: [PATCH 0816/1140] (#19977) libepoxy: bump meson --- recipes/libepoxy/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libepoxy/all/conanfile.py b/recipes/libepoxy/all/conanfile.py index c8c1d778cd3603..2f9f112de0a990 100644 --- a/recipes/libepoxy/all/conanfile.py +++ b/recipes/libepoxy/all/conanfile.py @@ -70,7 +70,7 @@ def validate(self): raise ConanInvalidConfiguration("Static builds on Windows are not supported") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 4a591f222440ebd651efb11b5e4a620b8dcda9d7 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 29 Sep 2023 11:26:12 +0200 Subject: [PATCH 0817/1140] (#20201) [kmod] Bump zlib requirement to [>=1.2.11 <2] range MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón --- recipes/kmod/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/kmod/all/conanfile.py b/recipes/kmod/all/conanfile.py index f60d2ebc28242b..ab20789f1833a2 100644 --- a/recipes/kmod/all/conanfile.py +++ b/recipes/kmod/all/conanfile.py @@ -49,7 +49,7 @@ def requirements(self): if self.options.with_xz: self.requires("xz_utils/5.4.2") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") From 4484db4bb8712fd19106b4049114d6d402e74bd9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 29 Sep 2023 12:04:47 +0200 Subject: [PATCH 0818/1140] (#20191) Bump pcl's zlib requirement to [>=1.2.11 <2] range --- recipes/pcl/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pcl/all/conanfile.py b/recipes/pcl/all/conanfile.py index c957981fea188d..fc423168869ea5 100644 --- a/recipes/pcl/all/conanfile.py +++ b/recipes/pcl/all/conanfile.py @@ -384,7 +384,7 @@ def requirements(self): if self._is_enabled("opencv"): self.requires("opencv/4.5.5", transitive_headers=True) if self._is_enabled("zlib"): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") # TODO: # self.requires("vtk/9.x.x", transitive_headers=True) # self.requires("openni/x.x.x", transitive_headers=True) From 864e2fba08e7ed988845c70f9f28d62570132c03 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 29 Sep 2023 12:10:15 +0200 Subject: [PATCH 0819/1140] (#20192) Bump soplex's zlib requirement to [>=1.2.11 <2] range --- recipes/soplex/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/soplex/all/conanfile.py b/recipes/soplex/all/conanfile.py index 5e4c8355aefd44..d14308917f562f 100644 --- a/recipes/soplex/all/conanfile.py +++ b/recipes/soplex/all/conanfile.py @@ -77,7 +77,7 @@ def configure(self): def requirements(self): # transitive libs as anything using soplex requires gzread, gzwrite, gzclose, gzopen - self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True, transitive_libs=True) if self.options.with_gmp: # transitive libs as anything using soplex requires __gmpz_init_set_si # see https://github.com/conan-io/conan-center-index/pull/16017#issuecomment-1495688452 From 615255dd350615167697e0b8d7164d563e56bd9a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 29 Sep 2023 13:02:57 +0200 Subject: [PATCH 0820/1140] (#20193) Bump libkml's zlib requirement to [>=1.2.11 <2] range --- recipes/libkml/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libkml/all/conanfile.py b/recipes/libkml/all/conanfile.py index 1b2a9bb8fba8b7..1a9d0a90947d11 100644 --- a/recipes/libkml/all/conanfile.py +++ b/recipes/libkml/all/conanfile.py @@ -46,7 +46,7 @@ def requirements(self): self.requires("expat/2.5.0") self.requires("minizip/1.2.13") self.requires("uriparser/0.9.7") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.options.shared and is_msvc(self) and is_msvc_static_runtime(self): From f14a0451df812ec18ca62a306630f99b37d50593 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 29 Sep 2023 13:22:55 +0200 Subject: [PATCH 0821/1140] (#20202) [websocketpp] Bump zlib requirement to [>=1.2.11 <2] range MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón --- recipes/websocketpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/websocketpp/all/conanfile.py b/recipes/websocketpp/all/conanfile.py index fc666b73d6c250..8bc3d40999ef3d 100644 --- a/recipes/websocketpp/all/conanfile.py +++ b/recipes/websocketpp/all/conanfile.py @@ -37,7 +37,7 @@ def requirements(self): self.requires("openssl/[>=1.1 <4]", transitive_headers=True, transitive_libs=True) if self.options.with_zlib: - self.requires("zlib/1.2.13", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True, transitive_libs=True) if self.options.asio == "standalone": self.requires("asio/1.28.1", transitive_headers=True) From 44410539a8b210a80c56570ecb2b59c30fe5fc6c Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 29 Sep 2023 14:00:26 +0200 Subject: [PATCH 0822/1140] (#20200) [itk] Bump zlib requirement to [>=1.2.11 <2] range MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón --- recipes/itk/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/itk/all/conanfile.py b/recipes/itk/all/conanfile.py index 432d4013dd2a62..c9a9ded1e49f49 100644 --- a/recipes/itk/all/conanfile.py +++ b/recipes/itk/all/conanfile.py @@ -78,7 +78,7 @@ def requirements(self): self.requires("libtiff/4.5.1") self.requires("openjpeg/2.5.0") self.requires("onetbb/2021.9.0") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") def validate(self): if self.options.shared and not self.dependencies["hdf5"].options.shared: From 085f1025894a34392dbbb7bfd3a834c0099261fb Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 29 Sep 2023 14:06:26 +0200 Subject: [PATCH 0823/1140] (#18416) libwebp: remove old versions * libwebp: remove old versions * remove 1.3.0 --- recipes/libwebp/all/conandata.yml | 52 +------------------ recipes/libwebp/all/conanfile.py | 5 +- .../patches/1.0.3-0002-build-libwebpmux.patch | 11 ---- ....patch => 1.1.0-0001-fix-dll-export.patch} | 0 .../patches/1.2.0-0003-build-libwebpmux.patch | 11 ---- .../all/patches/1.3.0-0001-fix-cmake.patch | 21 -------- recipes/libwebp/config.yml | 12 ----- 7 files changed, 3 insertions(+), 109 deletions(-) delete mode 100644 recipes/libwebp/all/patches/1.0.3-0002-build-libwebpmux.patch rename recipes/libwebp/all/patches/{1.0.3-0001-fix-dll-export.patch => 1.1.0-0001-fix-dll-export.patch} (100%) delete mode 100644 recipes/libwebp/all/patches/1.2.0-0003-build-libwebpmux.patch delete mode 100644 recipes/libwebp/all/patches/1.3.0-0001-fix-cmake.patch diff --git a/recipes/libwebp/all/conandata.yml b/recipes/libwebp/all/conandata.yml index 47f77300daa6a3..0aaa6446c54828 100644 --- a/recipes/libwebp/all/conandata.yml +++ b/recipes/libwebp/all/conandata.yml @@ -5,30 +5,12 @@ sources: "1.3.1": url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.3.1.tar.gz" sha256: "b3779627c2dfd31e3d8c4485962c2efe17785ef975e2be5c8c0c9e6cd3c4ef66" - "1.3.0": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.3.0.tar.gz" - sha256: "64ac4614db292ae8c5aa26de0295bf1623dbb3985054cb656c55e67431def17c" "1.2.4": url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.2.4.tar.gz" sha256: "7bf5a8a28cc69bcfa8cb214f2c3095703c6b73ac5fba4d5480c205331d9494df" - "1.2.3": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.2.3.tar.gz" - sha256: "f5d7ab2390b06b8a934a4fc35784291b3885b557780d099bd32f09241f9d83f9" - "1.2.2": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.2.2.tar.gz" - sha256: "7656532f837af5f4cec3ff6bafe552c044dc39bf453587bd5b77450802f4aee6" - "1.2.1": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.2.1.tar.gz" - sha256: "808b98d2f5b84e9b27fdef6c5372dac769c3bda4502febbfa5031bd3c4d7d018" - "1.2.0": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.2.0.tar.gz" - sha256: "2fc8bbde9f97f2ab403c0224fb9ca62b2e6852cbc519e91ceaa7c153ffd88a0c" "1.1.0": url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.1.0.tar.gz" sha256: "98a052268cc4d5ece27f76572a7f50293f439c17a98e67c4ea0c7ed6f50ef043" - "1.0.3": - url: "https://storage.googleapis.com/downloads.webmproject.org/releases/webp/libwebp-1.0.3.tar.gz" - sha256: "e20a07865c8697bba00aebccc6f54912d6bc333bb4d604e6b07491c1a226b34f" patches: "1.3.2": - patch_file: "patches/1.3.1-0001-fix-cmake.patch" @@ -38,35 +20,12 @@ patches: - patch_file: "patches/1.3.1-0001-fix-cmake.patch" patch_description: "disable PIC, disable prefix library name on MSVC" patch_type: "conan" - "1.3.0": - - patch_file: "patches/1.3.0-0001-fix-cmake.patch" - patch_description: "disable PIC, disable prefix library name on MSVC" - patch_type: "conan" "1.2.4": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" - patch_description: "define WEBP_EXTERN for windows shared build" - patch_type: "portability" - "1.2.3": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" - patch_description: "define WEBP_EXTERN for windows shared build" - patch_type: "portability" - "1.2.2": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" - patch_description: "define WEBP_EXTERN for windows shared build" - patch_type: "portability" - "1.2.1": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" + - patch_file: "patches/1.1.0-0001-fix-dll-export.patch" patch_description: "define WEBP_EXTERN for windows shared build" patch_type: "portability" - "1.2.0": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" - patch_description: "define WEBP_EXTERN for windows shared build" - patch_type: "portability" - - patch_file: "patches/1.2.0-0003-build-libwebpmux.patch" - patch_description: "always build libwebpmux" - patch_type: "conan" "1.1.0": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" + - patch_file: "patches/1.1.0-0001-fix-dll-export.patch" patch_description: "define WEBP_EXTERN for windows shared build" patch_type: "portability" - patch_file: "patches/1.1.0-0002-qnx.patch" @@ -76,10 +35,3 @@ patches: - patch_file: "patches/1.1.0-0003-build-libwebpmux.patch" patch_description: "always build libwebpmux" patch_type: "conan" - "1.0.3": - - patch_file: "patches/1.0.3-0001-fix-dll-export.patch" - patch_description: "define WEBP_EXTERN for windows shared build" - patch_type: "portability" - - patch_file: "patches/1.0.3-0002-build-libwebpmux.patch" - patch_description: "always build libwebpmux" - patch_type: "conan" diff --git a/recipes/libwebp/all/conanfile.py b/recipes/libwebp/all/conanfile.py index 0044f425b95b10..5e7c1354176a42 100644 --- a/recipes/libwebp/all/conanfile.py +++ b/recipes/libwebp/all/conanfile.py @@ -55,10 +55,7 @@ def generate(self): tc = CMakeToolchain(self) # should be an option but it doesn't work yet tc.variables["WEBP_ENABLE_SIMD"] = self.options.with_simd - if Version(self.version) >= "1.0.0": - tc.variables["WEBP_NEAR_LOSSLESS"] = self.options.near_lossless - else: - tc.variables["WEBP_ENABLE_NEAR_LOSSLESS"] = self.options.near_lossless + tc.variables["WEBP_NEAR_LOSSLESS"] = self.options.near_lossless tc.variables["WEBP_ENABLE_SWAP_16BIT_CSP"] = self.options.swap_16bit_csp # avoid finding system libs tc.variables["CMAKE_DISABLE_FIND_PACKAGE_GIF"] = True diff --git a/recipes/libwebp/all/patches/1.0.3-0002-build-libwebpmux.patch b/recipes/libwebp/all/patches/1.0.3-0002-build-libwebpmux.patch deleted file mode 100644 index 0892ee3bdacd99..00000000000000 --- a/recipes/libwebp/all/patches/1.0.3-0002-build-libwebpmux.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -401,7 +401,7 @@ if(WEBP_BUILD_CWEBP) - install(TARGETS cwebp RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - endif() - --if(WEBP_BUILD_GIF2WEBP OR WEBP_BUILD_IMG2WEBP) -+if(1) - parse_makefile_am(${CMAKE_CURRENT_SOURCE_DIR}/src/mux "WEBP_MUX_SRCS" "") - add_library(libwebpmux ${WEBP_MUX_SRCS}) - target_link_libraries(libwebpmux webp) diff --git a/recipes/libwebp/all/patches/1.0.3-0001-fix-dll-export.patch b/recipes/libwebp/all/patches/1.1.0-0001-fix-dll-export.patch similarity index 100% rename from recipes/libwebp/all/patches/1.0.3-0001-fix-dll-export.patch rename to recipes/libwebp/all/patches/1.1.0-0001-fix-dll-export.patch diff --git a/recipes/libwebp/all/patches/1.2.0-0003-build-libwebpmux.patch b/recipes/libwebp/all/patches/1.2.0-0003-build-libwebpmux.patch deleted file mode 100644 index 5f228670d57c89..00000000000000 --- a/recipes/libwebp/all/patches/1.2.0-0003-build-libwebpmux.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -449,7 +449,7 @@ if(WEBP_BUILD_CWEBP) - install(TARGETS cwebp RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - endif() - --if(WEBP_BUILD_GIF2WEBP OR WEBP_BUILD_IMG2WEBP) -+if(1) - parse_makefile_am(${CMAKE_CURRENT_SOURCE_DIR}/src/mux "WEBP_MUX_SRCS" "") - add_library(libwebpmux ${WEBP_MUX_SRCS}) - target_link_libraries(libwebpmux webp) diff --git a/recipes/libwebp/all/patches/1.3.0-0001-fix-cmake.patch b/recipes/libwebp/all/patches/1.3.0-0001-fix-cmake.patch deleted file mode 100644 index f9c41d4f6a5417..00000000000000 --- a/recipes/libwebp/all/patches/1.3.0-0001-fix-cmake.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/a/CMakeLists.txt b/b/CMakeLists.txt -index 0a5af42..781f4c7 100644 ---- a/a/CMakeLists.txt -+++ b/b/CMakeLists.txt -@@ -58,7 +58,6 @@ if(WEBP_LINK_STATIC) - else() - set(CMAKE_FIND_LIBRARY_SUFFIXES .a ${CMAKE_FIND_LIBRARY_SUFFIXES}) - endif() -- set(CMAKE_POSITION_INDEPENDENT_CODE ON) - # vwebp does not compile on Ubuntu with static libraries so disabling it for - # now. - set(WEBP_BUILD_VWEBP OFF) -@@ -142,7 +141,7 @@ endif() - set(PTHREAD_LIBS ${CMAKE_THREAD_LIBS_INIT}) - set(INSTALLED_LIBRARIES) - --if(MSVC) -+if(0) - # match the naming convention used by nmake - set(webp_libname_prefix "lib") - set(CMAKE_SHARED_LIBRARY_PREFIX "${webp_libname_prefix}") diff --git a/recipes/libwebp/config.yml b/recipes/libwebp/config.yml index 5efe9c8c34aa9f..e184761fe568e1 100644 --- a/recipes/libwebp/config.yml +++ b/recipes/libwebp/config.yml @@ -3,19 +3,7 @@ versions: folder: all "1.3.1": folder: all - "1.3.0": - folder: all "1.2.4": folder: all - "1.2.3": - folder: all - "1.2.2": - folder: all - "1.2.1": - folder: all - "1.2.0": - folder: all "1.1.0": folder: all - "1.0.3": - folder: all From e3c830c25f8b467206a744afb4b0c84095427a71 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 29 Sep 2023 14:44:22 +0200 Subject: [PATCH 0824/1140] (#20194) Bump poco's zlib requirement to [>=1.2.11 <2] range --- recipes/poco/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/poco/all/conanfile.py b/recipes/poco/all/conanfile.py index a9fe39975ab8a2..db83584f38915e 100644 --- a/recipes/poco/all/conanfile.py +++ b/recipes/poco/all/conanfile.py @@ -112,7 +112,7 @@ def requirements(self): self.requires("pcre/8.45") else: self.requires("pcre2/10.42") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.enable_xml: self.requires("expat/2.5.0") if self.options.enable_data_sqlite: From bb3ed99d94fcc6b5a0cba7343276d0bfd1d9ce3d Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 29 Sep 2023 15:49:14 +0200 Subject: [PATCH 0825/1140] (#19230) openjpeg: add missing CMake vars in CMakeDeps of openjpeg * add missing CMake vars in CMakeDeps of openjpeg * fix test of CMakeDeps vars in test package * drop test v1 package --- recipes/openjpeg/all/conanfile.py | 33 ++++++++++++++++--- .../openjpeg/all/test_package/CMakeLists.txt | 18 ++++++++++ .../all/test_v1_package/CMakeLists.txt | 8 ----- .../openjpeg/all/test_v1_package/conanfile.py | 17 ---------- 4 files changed, 46 insertions(+), 30 deletions(-) delete mode 100644 recipes/openjpeg/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/openjpeg/all/test_v1_package/conanfile.py diff --git a/recipes/openjpeg/all/conanfile.py b/recipes/openjpeg/all/conanfile.py index d4b1a9482f6b76..f51919fe29fc0a 100644 --- a/recipes/openjpeg/all/conanfile.py +++ b/recipes/openjpeg/all/conanfile.py @@ -82,13 +82,31 @@ def package(self): cmake = CMake(self) cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", self._openjpeg_subdir)) - + self._create_cmake_module_variables( + os.path.join(self.package_folder, self._module_vars_rel_path) + ) # TODO: to remove in conan v2 once cmake_find_package* & pkg_config generators removed self._create_cmake_module_alias_targets( - os.path.join(self.package_folder, self._module_file_rel_path), + os.path.join(self.package_folder, self._module_target_rel_path), {"openjp2": "OpenJPEG::OpenJPEG"} ) + def _create_cmake_module_variables(self, module_file): + content = textwrap.dedent(f"""\ + set(OPENJPEG_FOUND TRUE) + if(DEFINED OpenJPEG_INCLUDE_DIRS) + set(OPENJPEG_INCLUDE_DIRS ${{OpenJPEG_INCLUDE_DIRS}}) + endif() + if(DEFINED OpenJPEG_LIBRARIES) + set(OPENJPEG_LIBRARIES ${{OpenJPEG_LIBRARIES}}) + endif() + set(OPENJPEG_MAJOR_VERSION "{Version(self.version).major}") + set(OPENJPEG_MINOR_VERSION "{Version(self.version).minor}") + set(OPENJPEG_BUILD_VERSION "{Version(self.version).patch}") + set(OPENJPEG_BUILD_SHARED_LIBS {"TRUE" if self.options.shared else "FALSE"}) + """) + save(self, module_file, content) + def _create_cmake_module_alias_targets(self, module_file, targets): content = "" for alias, aliased in targets.items(): @@ -101,7 +119,11 @@ def _create_cmake_module_alias_targets(self, module_file, targets): save(self, module_file, content) @property - def _module_file_rel_path(self): + def _module_vars_rel_path(self): + return os.path.join("lib", "cmake", f"conan-official-{self.name}-variables.cmake") + + @property + def _module_target_rel_path(self): return os.path.join("lib", "cmake", f"conan-official-{self.name}-targets.cmake") @property @@ -112,6 +134,7 @@ def _openjpeg_subdir(self): def package_info(self): self.cpp_info.set_property("cmake_file_name", "OpenJPEG") self.cpp_info.set_property("cmake_target_name", "openjp2") + self.cpp_info.set_property("cmake_build_modules", [self._module_vars_rel_path]) self.cpp_info.set_property("pkg_config_name", "libopenjp2") self.cpp_info.includedirs.append(os.path.join("include", self._openjpeg_subdir)) self.cpp_info.libs = ["openjp2"] @@ -125,6 +148,6 @@ def package_info(self): # TODO: to remove in conan v2 once cmake_find_package* & pkg_config generators removed self.cpp_info.names["cmake_find_package"] = "OpenJPEG" self.cpp_info.names["cmake_find_package_multi"] = "OpenJPEG" - self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] + self.cpp_info.build_modules["cmake_find_package"] = [self._module_target_rel_path] + self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_target_rel_path] self.cpp_info.names["pkg_config"] = "libopenjp2" diff --git a/recipes/openjpeg/all/test_package/CMakeLists.txt b/recipes/openjpeg/all/test_package/CMakeLists.txt index eccda132e4efef..08c910c90a70d5 100644 --- a/recipes/openjpeg/all/test_package/CMakeLists.txt +++ b/recipes/openjpeg/all/test_package/CMakeLists.txt @@ -5,3 +5,21 @@ find_package(OpenJPEG REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} PRIVATE openjp2) + +# Test whether variables from https://github.com/uclouvain/openjpeg/blob/master/cmake/OpenJPEGConfig.cmake.in are properly defined +set(_custom_vars + OPENJPEG_FOUND + OPENJPEG_INCLUDE_DIRS + OPENJPEG_LIBRARIES + OPENJPEG_MAJOR_VERSION + OPENJPEG_MINOR_VERSION + OPENJPEG_BUILD_VERSION + OPENJPEG_BUILD_SHARED_LIBS +) +foreach(_custom_var ${_custom_vars}) + if(DEFINED ${_custom_var}) + message(STATUS "${_custom_var}: ${${_custom_var}}") + else() + message(FATAL_ERROR "${_custom_var} not defined") + endif() +endforeach() diff --git a/recipes/openjpeg/all/test_v1_package/CMakeLists.txt b/recipes/openjpeg/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 0d20897301b68b..00000000000000 --- a/recipes/openjpeg/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package - ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/openjpeg/all/test_v1_package/conanfile.py b/recipes/openjpeg/all/test_v1_package/conanfile.py deleted file mode 100644 index 38f4483872d47f..00000000000000 --- a/recipes/openjpeg/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,17 +0,0 @@ -from conans import ConanFile, CMake, tools -import os - - -class TestPackageConan(ConanFile): - settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) From 46655bba2f8cbff382ff7316af6d5a2cb2ebbb8a Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 29 Sep 2023 16:40:08 +0200 Subject: [PATCH 0826/1140] Bump podofo's zlib requirement to [>=1.2.11 <2] range (#20203) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón --- recipes/podofo/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/podofo/all/conanfile.py b/recipes/podofo/all/conanfile.py index b3f7dffd4c0717..87fbb60fe26b7e 100644 --- a/recipes/podofo/all/conanfile.py +++ b/recipes/podofo/all/conanfile.py @@ -63,7 +63,7 @@ def layout(self): def requirements(self): self.requires("freetype/2.13.0") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.settings.os != "Windows": self.requires("fontconfig/2.14.2") if self.options.with_openssl: From 14994aab62f6e811a27e04cff603111dae7e182b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Fri, 29 Sep 2023 17:24:27 +0200 Subject: [PATCH 0827/1140] (#20196) Bump opencv's zlib requirement to [>=1.2.11 <2] range * Bump opencv's zlib requirement to [>=1.2.11 <2] range * OpenCV 2.x does not support C++17 Signed-off-by: Uilian Ries * Skip linter error Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/opencv/2.x/conanfile.py | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/recipes/opencv/2.x/conanfile.py b/recipes/opencv/2.x/conanfile.py index 2dc9254ee3172c..4b96731d9f7b2b 100644 --- a/recipes/opencv/2.x/conanfile.py +++ b/recipes/opencv/2.x/conanfile.py @@ -1,10 +1,11 @@ -from conan import ConanFile +from conan import ConanFile, conan_version from conan.errors import ConanInvalidConfiguration from conan.tools.apple import is_apple_os from conan.tools.build import valid_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rm, rmdir, save from conan.tools.microsoft import is_msvc, is_msvc_static_runtime +import sys import os import textwrap @@ -352,7 +353,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_eigen: self.requires("eigen/3.4.0") if self.options.with_tbb: @@ -409,6 +410,13 @@ def validate(self): raise ConanInvalidConfiguration( "viz module can't be enabled yet. It requires VTK which is not available in conan-center." ) + # FIXME: check_max_cppstd is only available for Conan 2.x. Remove it after dropping support for Conan 1.x + if conan_version.major == 2: + # FIXME: linter complains, but function is there + # https://docs.conan.io/2.0/reference/tools/build.html?highlight=check_min_cppstd#conan-tools-build-check-max-cppstd + check_max_cppstd = getattr(sys.modules['conan.tools.build'], 'check_max_cppstd') + # INFO: OpenCV 2.x uses std::random_shuffle and mem_fun_ref. Both removed in C++17. + check_max_cppstd(self, 14) def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From ed50ae4e61ad210d7e163d41b412a437936bc58b Mon Sep 17 00:00:00 2001 From: Christopher Bradfield <11827031+cjbradfield@users.noreply.github.com> Date: Fri, 29 Sep 2023 11:17:32 -0500 Subject: [PATCH 0828/1140] (#19533) Add a recipe for nghttp3 * Add a recipe for nghttp3 * Remove unnused import * Remove gcc version restrictions. * Remove CMakeDeps --- recipes/nghttp3/all/conandata.yml | 4 + recipes/nghttp3/all/conanfile.py | 79 +++++++++++++++++++ .../nghttp3/all/test_package/CMakeLists.txt | 7 ++ recipes/nghttp3/all/test_package/conanfile.py | 26 ++++++ .../nghttp3/all/test_package/test_package.cpp | 19 +++++ recipes/nghttp3/config.yml | 3 + 6 files changed, 138 insertions(+) create mode 100644 recipes/nghttp3/all/conandata.yml create mode 100644 recipes/nghttp3/all/conanfile.py create mode 100644 recipes/nghttp3/all/test_package/CMakeLists.txt create mode 100644 recipes/nghttp3/all/test_package/conanfile.py create mode 100644 recipes/nghttp3/all/test_package/test_package.cpp create mode 100644 recipes/nghttp3/config.yml diff --git a/recipes/nghttp3/all/conandata.yml b/recipes/nghttp3/all/conandata.yml new file mode 100644 index 00000000000000..44235cb3f54de9 --- /dev/null +++ b/recipes/nghttp3/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.15.0": + url: "https://github.com/ngtcp2/nghttp3/releases/download/v0.15.0/nghttp3-0.15.0.tar.gz" + sha256: "3c56d9fa6f1b58b37bd7b1b53eaf16cd71118bc2d5cadbc904f09d6f6466b42f" diff --git a/recipes/nghttp3/all/conanfile.py b/recipes/nghttp3/all/conanfile.py new file mode 100644 index 00000000000000..c7b6057509787e --- /dev/null +++ b/recipes/nghttp3/all/conanfile.py @@ -0,0 +1,79 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import get, rmdir, copy +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version +import os + + +required_conan_version = ">=1.53.0" + + +class Nghttp3Conan(ConanFile): + name = "nghttp3" + description = "HTTP/2 C Library and tools" + topics = ("http", "http3") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://nghttp2.org/nghttp3/" + license = "MIT" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def build_requirements(self): + self.tool_requires("cmake/[>=3.20 <4]") + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["ENABLE_SHARED_LIB"] = self.options.shared + tc.variables["ENABLE_STATIC_LIB"] = not self.options.shared + tc.variables["ENABLE_LIB_ONLY"] = True + if is_apple_os(self): + # workaround for: install TARGETS given no BUNDLE DESTINATION for MACOSX_BUNDLE executable + tc.cache_variables["CMAKE_MACOSX_BUNDLE"] = False + tc.generate() + tc = VirtualBuildEnv(self) + tc.generate(scope="build") + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + self.cpp_info.libs = ["nghttp3"] + if is_msvc(self) and not self.options.shared: + self.cpp_info.defines.append("NGHTTP3_STATICLIB") + + self.cpp_info.set_property("pkg_config_name", "nghttp3") diff --git a/recipes/nghttp3/all/test_package/CMakeLists.txt b/recipes/nghttp3/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..0b418770cdb55f --- /dev/null +++ b/recipes/nghttp3/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package) + +find_package(nghttp3 REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE nghttp3::nghttp3) diff --git a/recipes/nghttp3/all/test_package/conanfile.py b/recipes/nghttp3/all/test_package/conanfile.py new file mode 100644 index 00000000000000..a9fb96656f2039 --- /dev/null +++ b/recipes/nghttp3/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/nghttp3/all/test_package/test_package.cpp b/recipes/nghttp3/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..1455f3ae65f551 --- /dev/null +++ b/recipes/nghttp3/all/test_package/test_package.cpp @@ -0,0 +1,19 @@ +#include + +#if defined(_MSC_VER) +// nghttp2 defaults to int +typedef int ssize_t; +#endif +#include +#include + +int main() +{ + const nghttp3_info* info = nghttp3_version(NGHTTP3_VERSION_NUM); + if (info) { + printf("nghttp3 ver=%d version=%s\n", info->version_num, info->version_str); + } else { + printf("nghttp3: cannot get version\n"); + } + return 0; +} diff --git a/recipes/nghttp3/config.yml b/recipes/nghttp3/config.yml new file mode 100644 index 00000000000000..e3fd6190a5166c --- /dev/null +++ b/recipes/nghttp3/config.yml @@ -0,0 +1,3 @@ +versions: + "0.15.0": + folder: all From 1569eebd11d6e93a4e2b34dab4db662567ee5349 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 29 Sep 2023 18:54:29 +0200 Subject: [PATCH 0829/1140] (#20198) Bump wt's zlib requirement to [>=1.2.11 <2] range MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón --- recipes/wt/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/wt/all/conanfile.py b/recipes/wt/all/conanfile.py index 23c11c902b6f8b..7316afc0682193 100644 --- a/recipes/wt/all/conanfile.py +++ b/recipes/wt/all/conanfile.py @@ -98,7 +98,7 @@ def requirements(self): else: self.requires("boost/1.83.0", transitive_headers = True) if self.options.connector_http: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_ssl: self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_sqlite"): From 97eaead59fbf69d305ca9472783d219ef7210d19 Mon Sep 17 00:00:00 2001 From: xyz1001 Date: Sat, 30 Sep 2023 01:30:59 +0800 Subject: [PATCH 0830/1140] (#19611) libheif: fix dependencies cannot be found --- recipes/libheif/all/conandata.yml | 1 + .../all/patches/0001-cmake_1.16.2.patch | 12 +++++++ .../patches/0002-plugins_cmake_1.16.2.patch | 31 +++++++++++++++++++ 3 files changed, 44 insertions(+) create mode 100644 recipes/libheif/all/patches/0002-plugins_cmake_1.16.2.patch diff --git a/recipes/libheif/all/conandata.yml b/recipes/libheif/all/conandata.yml index 3ec98d8c37e22d..e7a2fc9ba8c253 100644 --- a/recipes/libheif/all/conandata.yml +++ b/recipes/libheif/all/conandata.yml @@ -17,6 +17,7 @@ sources: patches: "1.16.2": - patch_file: "patches/0001-cmake_1.16.2.patch" + - patch_file: "patches/0002-plugins_cmake_1.16.2.patch" "1.13.0": - patch_file: "patches/0001-cmake_1.13.0.patch" "1.12.0": diff --git a/recipes/libheif/all/patches/0001-cmake_1.16.2.patch b/recipes/libheif/all/patches/0001-cmake_1.16.2.patch index 27432951605509..957b6fe2587f27 100644 --- a/recipes/libheif/all/patches/0001-cmake_1.16.2.patch +++ b/recipes/libheif/all/patches/0001-cmake_1.16.2.patch @@ -20,6 +20,18 @@ index de15948..589eab5 100644 option(ENABLE_PLUGIN_LOADING "Support loading of plugins" ON) set(PLUGIN_DIRECTORY "${CMAKE_INSTALL_FULL_LIBDIR}/libheif" CACHE STRING "Plugin install directory") +@@ -74,9 +74,9 @@ + find_package(${packageName}) + endif () + +- if (${variableName}_FOUND AND WITH_${variableName}_PLUGIN AND PLUGIN_LOADING_SUPPORTED_AND_ENABLED) ++ if (${packageName}_FOUND AND WITH_${packageName}_PLUGIN AND PLUGIN_LOADING_SUPPORTED_AND_ENABLED) + set(msg "found (plugin)") +- elseif (${variableName}_FOUND) ++ elseif (${packageName}_FOUND) + set(msg "found (built-in)") + elseif (WITH_${variableName}) + set(msg "not found") @@ -88,11 +88,11 @@ macro(plugin_option variableName packageName displayName displayType defaultPlug unset(msg) endmacro() diff --git a/recipes/libheif/all/patches/0002-plugins_cmake_1.16.2.patch b/recipes/libheif/all/patches/0002-plugins_cmake_1.16.2.patch new file mode 100644 index 00000000000000..ca167755d4ece0 --- /dev/null +++ b/recipes/libheif/all/patches/0002-plugins_cmake_1.16.2.patch @@ -0,0 +1,31 @@ +--- a/libheif/plugins/CMakeLists.txt ++++ b/libheif/plugins/CMakeLists.txt +@@ -44,23 +44,23 @@ + + set(X265_sources encoder_x265.h encoder_x265.cc) + set(X265_extra_plugin_sources) +-plugin_compilation(x265 X265 X265 X265) ++plugin_compilation(x265 x265 X265 X265) + + set(LIBDE265_sources decoder_libde265.cc decoder_libde265.h) + set(LIBDE265_extra_plugin_sources ../error.cc) +-plugin_compilation(libde265 LIBDE265 LIBDE265 LIBDE265) ++plugin_compilation(libde265 libde265 LIBDE265 LIBDE265) + + set(DAV1D_sources decoder_dav1d.cc decoder_dav1d.h) + set(DAV1D_extra_plugin_sources ../common_utils.cc ../common_utils.h) +-plugin_compilation(dav1d DAV1D DAV1D DAV1D) ++plugin_compilation(dav1d Dav1d DAV1D DAV1D) + + set(AOM_DECODER_sources decoder_aom.cc decoder_aom.h) + set(AOM_DECODER_extra_plugin_sources) +-plugin_compilation(aomdec AOM AOM_DECODER AOM_DECODER) ++plugin_compilation(aomdec libaom-av1 AOM_DECODER AOM_DECODER) + + set(AOM_ENCODER_sources encoder_aom.cc encoder_aom.h) + set(AOM_ENCODER_extra_plugin_sources ../error.cc ../common_utils.cc ../common_utils.h) +-plugin_compilation(aomenc AOM AOM_ENCODER AOM_ENCODER) ++plugin_compilation(aomenc libaom-av1 AOM_ENCODER AOM_ENCODER) + + set(SvtEnc_sources encoder_svt.cc encoder_svt.h) + set(SvtEnc_extra_plugin_sources) From 70febdf937547722894d8a3bf8886f9b3acceb5b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 29 Sep 2023 21:11:42 +0300 Subject: [PATCH 0831/1140] (#19653) libpq: bump minor versions, remove old versions --- recipes/libpq/all/conandata.yml | 69 +++++++------------ .../002-mingw-build-static-libraries.patch | 0 .../002-mingw-build-static-libraries.patch | 39 ----------- .../002-mingw-build-static-libraries.patch | 0 .../13.3/001-Remove-thread-safety-check.patch | 65 ----------------- .../002-mingw-build-static-libraries.patch | 0 .../002-mingw-build-static-libraries.patch | 39 ----------- .../002-mingw-build-static-libraries.patch | 39 ----------- .../002-mingw-build-static-libraries.patch | 39 ----------- .../002-mingw-build-static-libraries.patch | 0 recipes/libpq/all/test_package/CMakeLists.txt | 2 +- .../libpq/all/test_v1_package/CMakeLists.txt | 2 +- recipes/libpq/config.yml | 16 ++--- 13 files changed, 33 insertions(+), 277 deletions(-) rename recipes/libpq/all/patches/{10.20 => 10}/002-mingw-build-static-libraries.patch (100%) delete mode 100644 recipes/libpq/all/patches/11.15/002-mingw-build-static-libraries.patch rename recipes/libpq/all/patches/{12.10 => 12}/002-mingw-build-static-libraries.patch (100%) delete mode 100644 recipes/libpq/all/patches/13.3/001-Remove-thread-safety-check.patch rename recipes/libpq/all/patches/{13.6 => 13}/002-mingw-build-static-libraries.patch (100%) delete mode 100644 recipes/libpq/all/patches/14.2/002-mingw-build-static-libraries.patch delete mode 100644 recipes/libpq/all/patches/14.5/002-mingw-build-static-libraries.patch delete mode 100644 recipes/libpq/all/patches/14.7/002-mingw-build-static-libraries.patch rename recipes/libpq/all/patches/{9.6.24 => 9.6}/002-mingw-build-static-libraries.patch (100%) diff --git a/recipes/libpq/all/conandata.yml b/recipes/libpq/all/conandata.yml index cf627d10addbc9..04f5a5493155d0 100644 --- a/recipes/libpq/all/conandata.yml +++ b/recipes/libpq/all/conandata.yml @@ -5,63 +5,46 @@ sources: "15.3": url: "https://ftp.postgresql.org/pub/source/v15.3/postgresql-15.3.tar.bz2" sha256: "ffc7d4891f00ffbf5c3f4eab7fbbced8460b8c0ee63c5a5167133b9e6599d932" - "14.8": - url: "https://ftp.postgresql.org/pub/source/v14.8/postgresql-14.8.tar.bz2" - sha256: "39d38f0030737ed03835debeefee3b37d335462ce4995e2497bc38d621ebe45a" - "14.7": - url: "https://ftp.postgresql.org/pub/source/v14.7/postgresql-14.7.tar.bz2" - sha256: "cef60f0098fa8101c1546f4254e45b722af5431337945b37af207007630db331" - "14.5": - url: "https://ftp.postgresql.org/pub/source/v14.5/postgresql-14.5.tar.bz2" - sha256: "d4f72cb5fb857c9a9f75ec8cf091a1771272802f2178f0b2e65b7b6ff64f4a30" - "14.2": - url: "https://ftp.postgresql.org/pub/source/v14.2/postgresql-14.2.tar.bz2" - sha256: "2cf78b2e468912f8101d695db5340cf313c2e9f68a612fb71427524e8c9a977a" - "13.6": - url: "https://ftp.postgresql.org/pub/source/v13.6/postgresql-13.6.tar.gz" - sha256: "42dcde620b627d35bf51dfc2c1d0f7f25f44d3dbedd81cc459da2d2c9e859059" - "12.10": - url: "https://ftp.postgresql.org/pub/source/v12.10/postgresql-12.10.tar.gz" - sha256: "987e008699d52d5de4bae0580416f6c75aa28016b11543c42f5fbde5efbdfb56" - "11.15": - url: "https://ftp.postgresql.org/pub/source/v11.15/postgresql-11.15.tar.gz" - sha256: "5f6ef2add1acb93d69012a55c3f276b91f4f0c91aa9a91243d9c5737ed5b5541" - "10.20": - url: "https://ftp.postgresql.org/pub/source/v10.20/postgresql-10.20.tar.gz" - sha256: "403bdad47101f7c0a15824627dd0fa0ad4abf1fa26d2bde77dea8921da25a48e" + "14.9": + url: "https://ftp.postgresql.org/pub/source/v14.9/postgresql-14.9.tar.bz2" + sha256: "b1fe3ba9b1a7f3a9637dd1656dfdad2889016073fd4d35f13b50143cbbb6a8ef" + "13.12": + url: "https://ftp.postgresql.org/pub/source/v13.12/postgresql-13.12.tar.gz" + sha256: "3aef84ff557087bd01df4365a7a85e11678faa55ab6fb6c4283d57e41997a80c" + "12.16": + url: "https://ftp.postgresql.org/pub/source/v12.16/postgresql-12.16.tar.gz" + sha256: "5cca6efb649bce91d9b3637f935ce8714a86b87b3b1092010f50349a6edde0e9" + "11.21": + url: "https://ftp.postgresql.org/pub/source/v11.21/postgresql-11.21.tar.gz" + sha256: "e48b5d5dc68cd5549ef6258facaaf7941ae8bd1cde56709203846167aa20af04" + "10.23": + url: "https://ftp.postgresql.org/pub/source/v10.23/postgresql-10.23.tar.gz" + sha256: "39886b7fbf375fdd79e94b676d8346a62c3c190ccf00b3f763002c8fc8fb71f0" "9.6.24": url: "https://ftp.postgresql.org/pub/source/v9.6.24/postgresql-9.6.24.tar.gz" sha256: "52947ecc119846eace5164399d173576c0d4a47ec116ae58a46a8fd0c576c7c3" patches: - "14.7": - - patch_file: "patches/14.7/002-mingw-build-static-libraries.patch" + "14.9": + - patch_file: "patches/13/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" - "14.5": - - patch_file: "patches/14.5/002-mingw-build-static-libraries.patch" + "13.12": + - patch_file: "patches/13/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" - "14.2": - - patch_file: "patches/14.2/002-mingw-build-static-libraries.patch" + "12.16": + - patch_file: "patches/12/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" - "13.6": - - patch_file: "patches/13.6/002-mingw-build-static-libraries.patch" + "11.21": + - patch_file: "patches/10/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" - "12.10": - - patch_file: "patches/12.10/002-mingw-build-static-libraries.patch" - patch_description: "port MinGW: Enable building static libraries in MinGW." - patch_type: "portability" - "11.15": - - patch_file: "patches/11.15/002-mingw-build-static-libraries.patch" - patch_description: "port MinGW: Enable building static libraries in MinGW." - patch_type: "portability" - "10.20": - - patch_file: "patches/10.20/002-mingw-build-static-libraries.patch" + "10.23": + - patch_file: "patches/10/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" "9.6.24": - - patch_file: "patches/9.6.24/002-mingw-build-static-libraries.patch" + - patch_file: "patches/9.6/002-mingw-build-static-libraries.patch" patch_description: "port MinGW: Enable building static libraries in MinGW." patch_type: "portability" diff --git a/recipes/libpq/all/patches/10.20/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/10/002-mingw-build-static-libraries.patch similarity index 100% rename from recipes/libpq/all/patches/10.20/002-mingw-build-static-libraries.patch rename to recipes/libpq/all/patches/10/002-mingw-build-static-libraries.patch diff --git a/recipes/libpq/all/patches/11.15/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/11.15/002-mingw-build-static-libraries.patch deleted file mode 100644 index bfa322133c73cd..00000000000000 --- a/recipes/libpq/all/patches/11.15/002-mingw-build-static-libraries.patch +++ /dev/null @@ -1,39 +0,0 @@ ---- a/src/Makefile.shlib -+++ b/src/Makefile.shlib -@@ -371,7 +371,10 @@ else - # Win32 case - - # See notes in src/backend/parser/Makefile about the following two rules --$(stlib): $(shlib) -+$(stlib): $(OBJS) | $(SHLIB_PREREQS) -+ rm -f $@ -+ $(LINK.static) $@ $^ -+ $(RANLIB) $@ - touch $@ - - # XXX A backend that loads a module linked with libgcc_s_dw2-1.dll will exit -@@ -384,12 +387,12 @@ $(stlib): $(shlib) - # Else we just use --export-all-symbols. - ifeq (,$(SHLIB_EXPORTS)) - $(shlib): $(OBJS) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=lib$(NAME).dll.a - else - DLL_DEFFILE = lib$(NAME)dll.def - - $(shlib): $(OBJS) $(DLL_DEFFILE) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=lib$(NAME).dll.a - endif - - endif # PORTNAME == cygwin -@@ -484,6 +487,9 @@ endif # not aix - ifneq (,$(findstring $(PORTNAME),win32 cygwin)) - $(INSTALL_SHLIB) $< '$(DESTDIR)$(bindir)/$(shlib)' - endif -+ifneq (,$(findstring $(PORTNAME),win32)) -+ $(INSTALL_SHLIB) $< '$(DESTDIR)$(libdir)/lib$(NAME).dll.a' -+endif - else # no soname - $(INSTALL_SHLIB) $< '$(DESTDIR)$(pkglibdir)/$(shlib)' - endif diff --git a/recipes/libpq/all/patches/12.10/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/12/002-mingw-build-static-libraries.patch similarity index 100% rename from recipes/libpq/all/patches/12.10/002-mingw-build-static-libraries.patch rename to recipes/libpq/all/patches/12/002-mingw-build-static-libraries.patch diff --git a/recipes/libpq/all/patches/13.3/001-Remove-thread-safety-check.patch b/recipes/libpq/all/patches/13.3/001-Remove-thread-safety-check.patch deleted file mode 100644 index c650bf767f6d5c..00000000000000 --- a/recipes/libpq/all/patches/13.3/001-Remove-thread-safety-check.patch +++ /dev/null @@ -1,65 +0,0 @@ -diff --git a/configure b/configure -index cbbaf77..f723154 100755 ---- a/configure -+++ b/configure -@@ -18836,60 +18836,6 @@ fi - fi - fi - --# Thread testing -- --# We have to run the thread test near the end so we have all our symbols --# defined. Cross compiling throws a warning. --# --if test "$enable_thread_safety" = yes; then --if test "$PORTNAME" != "win32" --then --{ $as_echo "$as_me:${as_lineno-$LINENO}: checking thread safety of required library functions" >&5 --$as_echo_n "checking thread safety of required library functions... " >&6; } -- --_CFLAGS="$CFLAGS" --_LIBS="$LIBS" --CFLAGS="$CFLAGS $PTHREAD_CFLAGS -DIN_CONFIGURE" --LIBS="$LIBS $PTHREAD_LIBS" --if test "$cross_compiling" = yes; then : -- { $as_echo "$as_me:${as_lineno-$LINENO}: result: maybe" >&5 --$as_echo "maybe" >&6; } -- { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --*** Skipping thread test program because of cross-compile build. --*** Run the program in src/test/thread on the target machine. --" >&5 --$as_echo "$as_me: WARNING: --*** Skipping thread test program because of cross-compile build. --*** Run the program in src/test/thread on the target machine. --" >&2;} --else -- cat confdefs.h - <<_ACEOF >conftest.$ac_ext --/* end confdefs.h. */ --#include "$srcdir/src/test/thread/thread_test.c" --_ACEOF --if ac_fn_c_try_run "$LINENO"; then : -- { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 --$as_echo "yes" >&6; } --else -- { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 --$as_echo "no" >&6; } -- as_fn_error $? "thread test program failed --This platform is not thread-safe. Check the file 'config.log' or compile --and run src/test/thread/thread_test for the exact reason. --Use --disable-thread-safety to disable thread safety." "$LINENO" 5 --fi --rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ -- conftest.$ac_objext conftest.beam conftest.$ac_ext --fi -- --CFLAGS="$_CFLAGS" --LIBS="$_LIBS" --else --{ $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: *** skipping thread test on Win32" >&5 --$as_echo "$as_me: WARNING: *** skipping thread test on Win32" >&2;} --fi --fi -- - # If compiler will take -Wl,--as-needed (or various platform-specific - # spellings thereof) then add that to LDFLAGS. This is much easier than - # trying to filter LIBS to the minimum for each executable. diff --git a/recipes/libpq/all/patches/13.6/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/13/002-mingw-build-static-libraries.patch similarity index 100% rename from recipes/libpq/all/patches/13.6/002-mingw-build-static-libraries.patch rename to recipes/libpq/all/patches/13/002-mingw-build-static-libraries.patch diff --git a/recipes/libpq/all/patches/14.2/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/14.2/002-mingw-build-static-libraries.patch deleted file mode 100644 index ce588507063738..00000000000000 --- a/recipes/libpq/all/patches/14.2/002-mingw-build-static-libraries.patch +++ /dev/null @@ -1,39 +0,0 @@ ---- a/src/Makefile.shlib -+++ b/src/Makefile.shlib -@@ -358,7 +358,10 @@ else - # Win32 case - - # See notes in src/backend/parser/Makefile about the following two rules --$(stlib): $(shlib) -+$(stlib): $(OBJS) | $(SHLIB_PREREQS) -+ rm -f $@ -+ $(LINK.static) $@ $^ -+ $(RANLIB) $@ - touch $@ - - # XXX A backend that loads a module linked with libgcc_s_dw2-1.dll will exit -@@ -371,12 +374,12 @@ $(stlib): $(shlib) - # Else we just use --export-all-symbols. - ifeq (,$(SHLIB_EXPORTS)) - $(shlib): $(OBJS) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=lib$(NAME).dll.a - else - DLL_DEFFILE = lib$(NAME)dll.def - - $(shlib): $(OBJS) $(DLL_DEFFILE) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=lib$(NAME).dll.a - - UC_NAME = $(shell echo $(NAME) | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') - -@@ -452,6 +455,9 @@ endif # not aix - ifneq (,$(findstring $(PORTNAME),win32 cygwin)) - $(INSTALL_SHLIB) $< '$(DESTDIR)$(bindir)/$(shlib)' - endif -+ifneq (,$(findstring $(PORTNAME),win32)) -+ $(INSTALL_SHLIB) $< '$(DESTDIR)$(libdir)/lib$(NAME).dll.a' -+endif - else # no soname - $(INSTALL_SHLIB) $< '$(DESTDIR)$(pkglibdir)/$(shlib)' - endif diff --git a/recipes/libpq/all/patches/14.5/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/14.5/002-mingw-build-static-libraries.patch deleted file mode 100644 index ce588507063738..00000000000000 --- a/recipes/libpq/all/patches/14.5/002-mingw-build-static-libraries.patch +++ /dev/null @@ -1,39 +0,0 @@ ---- a/src/Makefile.shlib -+++ b/src/Makefile.shlib -@@ -358,7 +358,10 @@ else - # Win32 case - - # See notes in src/backend/parser/Makefile about the following two rules --$(stlib): $(shlib) -+$(stlib): $(OBJS) | $(SHLIB_PREREQS) -+ rm -f $@ -+ $(LINK.static) $@ $^ -+ $(RANLIB) $@ - touch $@ - - # XXX A backend that loads a module linked with libgcc_s_dw2-1.dll will exit -@@ -371,12 +374,12 @@ $(stlib): $(shlib) - # Else we just use --export-all-symbols. - ifeq (,$(SHLIB_EXPORTS)) - $(shlib): $(OBJS) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=lib$(NAME).dll.a - else - DLL_DEFFILE = lib$(NAME)dll.def - - $(shlib): $(OBJS) $(DLL_DEFFILE) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=lib$(NAME).dll.a - - UC_NAME = $(shell echo $(NAME) | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') - -@@ -452,6 +455,9 @@ endif # not aix - ifneq (,$(findstring $(PORTNAME),win32 cygwin)) - $(INSTALL_SHLIB) $< '$(DESTDIR)$(bindir)/$(shlib)' - endif -+ifneq (,$(findstring $(PORTNAME),win32)) -+ $(INSTALL_SHLIB) $< '$(DESTDIR)$(libdir)/lib$(NAME).dll.a' -+endif - else # no soname - $(INSTALL_SHLIB) $< '$(DESTDIR)$(pkglibdir)/$(shlib)' - endif diff --git a/recipes/libpq/all/patches/14.7/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/14.7/002-mingw-build-static-libraries.patch deleted file mode 100644 index ce588507063738..00000000000000 --- a/recipes/libpq/all/patches/14.7/002-mingw-build-static-libraries.patch +++ /dev/null @@ -1,39 +0,0 @@ ---- a/src/Makefile.shlib -+++ b/src/Makefile.shlib -@@ -358,7 +358,10 @@ else - # Win32 case - - # See notes in src/backend/parser/Makefile about the following two rules --$(stlib): $(shlib) -+$(stlib): $(OBJS) | $(SHLIB_PREREQS) -+ rm -f $@ -+ $(LINK.static) $@ $^ -+ $(RANLIB) $@ - touch $@ - - # XXX A backend that loads a module linked with libgcc_s_dw2-1.dll will exit -@@ -371,12 +374,12 @@ $(stlib): $(shlib) - # Else we just use --export-all-symbols. - ifeq (,$(SHLIB_EXPORTS)) - $(shlib): $(OBJS) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--export-all-symbols -Wl,--out-implib=lib$(NAME).dll.a - else - DLL_DEFFILE = lib$(NAME)dll.def - - $(shlib): $(OBJS) $(DLL_DEFFILE) | $(SHLIB_PREREQS) -- $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=$(stlib) -+ $(CC) $(CFLAGS) -shared -static-libgcc -o $@ $(OBJS) $(DLL_DEFFILE) $(LDFLAGS) $(LDFLAGS_SL) $(SHLIB_LINK) $(LIBS) -Wl,--out-implib=lib$(NAME).dll.a - - UC_NAME = $(shell echo $(NAME) | tr 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ') - -@@ -452,6 +455,9 @@ endif # not aix - ifneq (,$(findstring $(PORTNAME),win32 cygwin)) - $(INSTALL_SHLIB) $< '$(DESTDIR)$(bindir)/$(shlib)' - endif -+ifneq (,$(findstring $(PORTNAME),win32)) -+ $(INSTALL_SHLIB) $< '$(DESTDIR)$(libdir)/lib$(NAME).dll.a' -+endif - else # no soname - $(INSTALL_SHLIB) $< '$(DESTDIR)$(pkglibdir)/$(shlib)' - endif diff --git a/recipes/libpq/all/patches/9.6.24/002-mingw-build-static-libraries.patch b/recipes/libpq/all/patches/9.6/002-mingw-build-static-libraries.patch similarity index 100% rename from recipes/libpq/all/patches/9.6.24/002-mingw-build-static-libraries.patch rename to recipes/libpq/all/patches/9.6/002-mingw-build-static-libraries.patch diff --git a/recipes/libpq/all/test_package/CMakeLists.txt b/recipes/libpq/all/test_package/CMakeLists.txt index db0dafd7c09848..b9f4d7ab61bce5 100644 --- a/recipes/libpq/all/test_package/CMakeLists.txt +++ b/recipes/libpq/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(PostgreSQL REQUIRED) diff --git a/recipes/libpq/all/test_v1_package/CMakeLists.txt b/recipes/libpq/all/test_v1_package/CMakeLists.txt index de3b75d9538de0..2f11d9b196ef70 100644 --- a/recipes/libpq/all/test_v1_package/CMakeLists.txt +++ b/recipes/libpq/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) diff --git a/recipes/libpq/config.yml b/recipes/libpq/config.yml index 5a83ac4481a63c..e010db029229d5 100644 --- a/recipes/libpq/config.yml +++ b/recipes/libpq/config.yml @@ -3,21 +3,15 @@ versions: folder: all "15.3": folder: all - "14.8": + "14.9": folder: all - "14.7": + "13.12": folder: all - "14.5": + "12.16": folder: all - "14.2": + "11.21": folder: all - "13.6": - folder: all - "12.10": - folder: all - "11.15": - folder: all - "10.20": + "10.23": folder: all "9.6.24": folder: all From cf1607144dfbc88d5802c4d007e66b985be0d791 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 29 Sep 2023 20:50:48 +0200 Subject: [PATCH 0832/1140] (#19984) Bump/pulseaudio/all * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * pulseaudio/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/pulseaudio/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/pulseaudio/all/conanfile.py b/recipes/pulseaudio/all/conanfile.py index f1b1de05bf9676..e50cb73ff538ad 100644 --- a/recipes/pulseaudio/all/conanfile.py +++ b/recipes/pulseaudio/all/conanfile.py @@ -59,12 +59,12 @@ def layout(self): def requirements(self): self.requires("libiconv/1.17") self.requires("libsndfile/1.2.2") - self.requires("libcap/2.68") + self.requires("libcap/2.69") self.requires("libtool/2.4.7") if self.options.with_alsa: - self.requires("libalsa/1.2.7.2") + self.requires("libalsa/1.2.10") if self.options.with_glib: - self.requires("glib/2.77.2") + self.requires("glib/2.78.0") if self.options.get_safe("with_fftw"): self.requires("fftw/3.3.10") if self.options.with_x11: @@ -90,7 +90,7 @@ def build_requirements(self): self.tool_requires("gettext/0.21") self.tool_requires("libtool/2.4.7") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 619835dcc32a7c01409c964238a581180e309b24 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 29 Sep 2023 21:31:08 +0200 Subject: [PATCH 0833/1140] (#19986) wayland/all: bump deps * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/wayland/all/conanfile.py | 4 ++-- recipes/wayland/all/test_package/conanfile.py | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/wayland/all/conanfile.py b/recipes/wayland/all/conanfile.py index 4deb10375518e7..fd8bace1e9cb70 100644 --- a/recipes/wayland/all/conanfile.py +++ b/recipes/wayland/all/conanfile.py @@ -58,9 +58,9 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} only supports Linux") def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if cross_building(self): self.tool_requires(str(self.ref)) diff --git a/recipes/wayland/all/test_package/conanfile.py b/recipes/wayland/all/test_package/conanfile.py index c201ad68aff345..e9a83534cede73 100644 --- a/recipes/wayland/all/test_package/conanfile.py +++ b/recipes/wayland/all/test_package/conanfile.py @@ -21,7 +21,7 @@ def requirements(self): def build_requirements(self): self.tool_requires(self.tested_reference_str) if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def layout(self): cmake_layout(self) From 821b8eba1977c7018fe59c54f69f6c2c42dff467 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 30 Sep 2023 05:32:58 +0900 Subject: [PATCH 0834/1140] (#19988) trantor: add version 1.5.14 --- recipes/trantor/all/conandata.yml | 7 +++++++ recipes/trantor/all/conanfile.py | 2 +- recipes/trantor/config.yml | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/recipes/trantor/all/conandata.yml b/recipes/trantor/all/conandata.yml index 2c3c3f7c60a560..efeba0b7ed4a11 100644 --- a/recipes/trantor/all/conandata.yml +++ b/recipes/trantor/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.14": + url: "https://github.com/an-tao/trantor/archive/v1.5.14.tar.gz" + sha256: "80775d65fd49dfb0eb85d70cd9c0f0cff38a7f46c90db918862c46e03ae63810" "1.5.13": url: "https://github.com/an-tao/trantor/archive/v1.5.13.tar.gz" sha256: "36f02302bff3ffa8d2b1bff29f451d7a11d215a43963fb95aa543b555de2f9bf" @@ -24,6 +27,10 @@ sources: url: "https://github.com/an-tao/trantor/archive/refs/tags/v1.5.5.tar.gz" sha256: "5a549c6efebe7ecba73a944cfba4a9713130704d4ccc82af534a2e108b9a0e71" patches: + "1.5.14": + - patch_file: "patches/1.5.12-0001-disable-werror.patch" + patch_description: "disable -Werror for gcc5" + patch_type: "portability" "1.5.13": - patch_file: "patches/1.5.12-0001-disable-werror.patch" patch_description: "disable -Werror for gcc5" diff --git a/recipes/trantor/all/conanfile.py b/recipes/trantor/all/conanfile.py index 8d8c3bbf7e46e1..6445f7c107ca06 100644 --- a/recipes/trantor/all/conanfile.py +++ b/recipes/trantor/all/conanfile.py @@ -38,7 +38,7 @@ def _min_cppstd(self): def _compilers_minimum_version(self): return { "gcc": "5", - "Visual Studio": "15.0", + "Visual Studio": "15", "msvc": "191", "clang": "5", "apple-clang": "10", diff --git a/recipes/trantor/config.yml b/recipes/trantor/config.yml index 51f47024c02e3c..e6a0e702be9d0b 100644 --- a/recipes/trantor/config.yml +++ b/recipes/trantor/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.14": + folder: "all" "1.5.13": folder: "all" "1.5.12": From cc0ffd6ca01b01bf8aad6b8eb2ad728b6ec30827 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 29 Sep 2023 23:30:03 +0200 Subject: [PATCH 0835/1140] (#19992) mpg123/all: bump deps * mpg123/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * mpg123/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * mpg123/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * mpg123/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/mpg123/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/mpg123/all/conanfile.py b/recipes/mpg123/all/conanfile.py index 5ff9754f83253b..7b5dfaff84832c 100644 --- a/recipes/mpg123/all/conanfile.py +++ b/recipes/mpg123/all/conanfile.py @@ -83,7 +83,7 @@ def layout(self): def requirements(self): if self.options.module == "libalsa": - self.requires("libalsa/1.2.7.2") + self.requires("libalsa/1.2.10") if self.options.module == "tinyalsa": self.requires("tinyalsa/2.0.0") @@ -96,7 +96,7 @@ def validate(self): def build_requirements(self): if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self.settings.arch in ["x86", "x86_64"]: self.tool_requires("yasm/1.3.0") if self._settings_build.os == "Windows": From c4cfd754b1289e87b3baec427f12e30a600d5d53 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 30 Sep 2023 00:32:22 +0200 Subject: [PATCH 0836/1140] (#19993) libsndfile/all: bump deps * libsndfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * libsndfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/libsndfile/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/libsndfile/all/conanfile.py b/recipes/libsndfile/all/conanfile.py index ef6e2406db7619..600abe6411b5e7 100644 --- a/recipes/libsndfile/all/conanfile.py +++ b/recipes/libsndfile/all/conanfile.py @@ -58,12 +58,12 @@ def layout(self): def requirements(self): if self.options.get_safe("with_alsa"): - self.requires("libalsa/1.2.7.2") + self.requires("libalsa/1.2.10") if self.options.with_external_libs: self.requires("ogg/1.3.5") self.requires("vorbis/1.3.7") self.requires("flac/1.4.2") - self.requires("opus/1.3.1") + self.requires("opus/1.4") if self.options.get_safe("with_mpeg", False): self.requires("mpg123/1.31.2") self.requires("libmp3lame/3.100") From a2b4f531e53ccd3b9039fafef4c702d3557aa889 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 02:54:46 +0300 Subject: [PATCH 0837/1140] (#19995) aws-c-common: add new versions, remove old versions * aws-c-common: add version 0.8.23 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * aws-c-common: add version 0.9.3 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * aws-c-common: remove old versions --------- Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/aws-c-common/all/conandata.yml | 48 ++++---------------------- recipes/aws-c-common/config.yml | 30 ++-------------- 2 files changed, 9 insertions(+), 69 deletions(-) diff --git a/recipes/aws-c-common/all/conandata.yml b/recipes/aws-c-common/all/conandata.yml index 6929bedbf2e128..92698304089d55 100644 --- a/recipes/aws-c-common/all/conandata.yml +++ b/recipes/aws-c-common/all/conandata.yml @@ -1,55 +1,19 @@ sources: + "0.9.3": + url: "https://github.com/awslabs/aws-c-common/archive/v0.9.3.tar.gz" + sha256: "389eaac7f64d7d5a91ca3decad6810429eb5a65bbba54798b9beffcb4d1d1ed6" "0.9.0": url: "https://github.com/awslabs/aws-c-common/archive/v0.9.0.tar.gz" sha256: "9b62ab1dcece3107810ea4f4511fe8e1e010a83cb0cb502b6ec685ce752a7b0c" - "0.8.2": - url: "https://github.com/awslabs/aws-c-common/archive/v0.8.2.tar.gz" - sha256: "36edc6e486c43bbb34059dde227e872c0d41ab54f0b3609d38f188cfbbc6d1f8" + "0.8.23": + url: "https://github.com/awslabs/aws-c-common/archive/v0.8.23.tar.gz" + sha256: "67455d8149c74b1db3e4dd68db47dc7372de02dd78fbc620f9c7f0270d9d6018" "0.7.5": url: "https://github.com/awslabs/aws-c-common/archive/v0.7.5.tar.gz" sha256: "e34fd3d3d32e3597f572205aaabbe995e162f4015e14c7328987b596bd25812c" - "0.7.4": - url: "https://github.com/awslabs/aws-c-common/archive/v0.7.4.tar.gz" - sha256: "e9462a141b5db30006704f537d19b92357a59be38d590272e6118976b0356ccd" - "0.7.3": - url: "https://github.com/awslabs/aws-c-common/archive/v0.7.3.tar.gz" - sha256: "e4b80d368668814d9b76989fd2e3cd0fcf0be160bbb8bfeedf1f652e27f9c08c" - "0.7.2": - url: "https://github.com/awslabs/aws-c-common/archive/v0.7.2.tar.gz" - sha256: "455aed7447ed58eb7d5d3e8c952ed59f77c71dfed4115883e900f36d95f06dab" - "0.7.1": - url: "https://github.com/awslabs/aws-c-common/archive/v0.7.1.tar.gz" - sha256: "75c444a337e446e82d4f71c127118981656234b25cbdfd5913b8de713354fb43" - "0.7.0": - url: "https://github.com/awslabs/aws-c-common/archive/v0.7.0.tar.gz" - sha256: "a4e94d2c1d045a27467c9dfae51382f851a5223c3a0ecc15a96d1dba94f85ad6" "0.6.20": url: "https://github.com/awslabs/aws-c-common/archive/v0.6.20.tar.gz" sha256: "6eb0b806c78b36a32eec9bcba8d2833e3973491a29d46fe3d11edc3f8d3e7f73" - "0.6.19": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.19.tar.gz" - sha256: "91cb2b809687be19fce8d6ca03ddc00c78723854ead30dcb58bdc4172cb1796c" - "0.6.17": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.17.tar.gz" - sha256: "441156ecfabb84e41601d7173a7f88267f099899f0ae6091c3b745d9e02211f6" - "0.6.15": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.15.tar.gz" - sha256: "eb3ead3fb7a1f09c046393f776a96a0f50ae5f38c70d462273084280383669f1" - "0.6.14": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.14.tar.gz" - sha256: "1691c9dad5a0d236c2a0e351cc972231b176947e454c61d1c4b3ea4ab42f32e7" - "0.6.11": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.11.tar.gz" - sha256: "86159bd1128eee2813f705c275d319e14d1b77017fab46f6ca5dafcc66edaea9" - "0.6.9": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.9.tar.gz" - sha256: "928a3e36f24d1ee46f9eec360ec5cebfe8b9b8994fe39d4fa74ff51aebb12717" - "0.6.8": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.8.tar.gz" - sha256: "2997e851ed690a614507a43f4c393f45a198614d94da1660ecdf9b5a729535fc" - "0.6.7": - url: "https://github.com/awslabs/aws-c-common/archive/v0.6.7.tar.gz" - sha256: "643b35c62f948367f484f3a436bc37b5799538f47b08aa72deb3818b8bcdc631" "0.4.25": url: "https://github.com/awslabs/aws-c-common/archive/v0.4.25.tar.gz" sha256: "f85a8f74e42bd983a4615654457f8037876bc6b8dbf890e368bb516cbc2e9844" diff --git a/recipes/aws-c-common/config.yml b/recipes/aws-c-common/config.yml index 472e641908fd07..e70a8039b9bc5a 100644 --- a/recipes/aws-c-common/config.yml +++ b/recipes/aws-c-common/config.yml @@ -1,37 +1,13 @@ versions: + "0.9.3": + folder: all "0.9.0": folder: all - "0.8.2": + "0.8.23": folder: all "0.7.5": folder: all - "0.7.4": - folder: all - "0.7.3": - folder: all - "0.7.2": - folder: all - "0.7.1": - folder: all - "0.7.0": - folder: all "0.6.20": folder: all - "0.6.19": - folder: all - "0.6.17": - folder: all - "0.6.15": - folder: all - "0.6.14": - folder: all - "0.6.11": - folder: all - "0.6.9": - folder: all - "0.6.8": - folder: all - "0.6.7": - folder: all "0.4.25": folder: all From b432a363190fd864352964a26ba4ab4bcb51d594 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 03:30:05 +0300 Subject: [PATCH 0838/1140] (#19997) cuda-api-wrappers: add version 0.7 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/cuda-api-wrappers/all/conandata.yml | 3 +++ recipes/cuda-api-wrappers/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cuda-api-wrappers/all/conandata.yml b/recipes/cuda-api-wrappers/all/conandata.yml index fa4742f5cc3204..5990b0d96ecd68 100644 --- a/recipes/cuda-api-wrappers/all/conandata.yml +++ b/recipes/cuda-api-wrappers/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.7": + url: "https://github.com/eyalroz/cuda-api-wrappers/archive/0.7b1.tar.gz" + sha256: "1ed5912d8f602ccd176865b824de17f462cb57142eb2a685d7cc034831e54a71" "0.6.3": url: "https://github.com/eyalroz/cuda-api-wrappers/archive/refs/tags/v0.6.3.tar.gz" sha256: "45d896136dbb4df6c75c36071899b9fe47df9a03629c95208c2d5bda979d109e" diff --git a/recipes/cuda-api-wrappers/config.yml b/recipes/cuda-api-wrappers/config.yml index a98729f2af8b08..b1edd3de7d7ae3 100644 --- a/recipes/cuda-api-wrappers/config.yml +++ b/recipes/cuda-api-wrappers/config.yml @@ -1,3 +1,5 @@ versions: + "0.7": + folder: all "0.6.3": folder: all From f69f237c5466f9d88cff153aefe114a5747c90d3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 30 Sep 2023 02:50:29 +0200 Subject: [PATCH 0839/1140] (#19999) pixman: bump meson --- recipes/pixman/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pixman/all/conanfile.py b/recipes/pixman/all/conanfile.py index a5d1aeafc9a5da..e14d1aef8b3a4c 100644 --- a/recipes/pixman/all/conanfile.py +++ b/recipes/pixman/all/conanfile.py @@ -54,7 +54,7 @@ def validate(self): raise ConanInvalidConfiguration("pixman can only be built as a static library on Windows") def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From bc5efe1efb6c5930ccc33bd0e114ef6943f7ab58 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 30 Sep 2023 03:30:17 +0200 Subject: [PATCH 0840/1140] (#20004) libpsl: bump icu, meson & pkgconf --- recipes/libpsl/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libpsl/all/conanfile.py b/recipes/libpsl/all/conanfile.py index ec026aac098e8e..0de3f9766ed38f 100644 --- a/recipes/libpsl/all/conanfile.py +++ b/recipes/libpsl/all/conanfile.py @@ -48,7 +48,7 @@ def layout(self): def requirements(self): if self.options.with_idna == "icu": - self.requires("icu/72.1") + self.requires("icu/73.2") elif self.options.with_idna == "libidn": self.requires("libidn/1.36") elif self.options.with_idna == "libidn2": @@ -57,9 +57,9 @@ def requirements(self): self.requires("libunistring/0.9.10") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 9a51b40ce89fb344707ca8ffcb9b58a4ae3edaf8 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 05:09:43 +0300 Subject: [PATCH 0841/1140] (#20005) vsg: add version 1.0.9 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/vsg/all/conandata.yml | 3 +++ recipes/vsg/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/vsg/all/conandata.yml b/recipes/vsg/all/conandata.yml index f79242254e9e4b..3b2abd6731e518 100644 --- a/recipes/vsg/all/conandata.yml +++ b/recipes/vsg/all/conandata.yml @@ -8,3 +8,6 @@ sources: "1.0.5": url: "https://github.com/vsg-dev/VulkanSceneGraph/archive/refs/tags/v1.0.5.tar.gz" sha256: "ff58260fcb88d19d92c40a70bc40ff06abb1a8805568eb76862a036d13ada75b" + "1.0.9": + url: "https://github.com/vsg-dev/VulkanSceneGraph/archive/v1.0.9.tar.gz" + sha256: "9a62be7facc13c391c33dc8356b147a3b86f531ea72a28f6b2c364777e761412" diff --git a/recipes/vsg/config.yml b/recipes/vsg/config.yml index 058c041064a224..9269a45607b90a 100644 --- a/recipes/vsg/config.yml +++ b/recipes/vsg/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.9": + folder: all "1.0.5": folder: all "1.0.3": From 4021bd012bbaa6ca37074ca54878a02117167519 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 05:55:23 +0300 Subject: [PATCH 0842/1140] (#20006) caf: add version 0.19.3 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/caf/all/conandata.yml | 3 +++ recipes/caf/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/caf/all/conandata.yml b/recipes/caf/all/conandata.yml index 260be0caef66de..396e0bc5ecfa64 100644 --- a/recipes/caf/all/conandata.yml +++ b/recipes/caf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.19.3": + url: "https://github.com/actor-framework/actor-framework/archive/0.19.3.tar.gz" + sha256: "97ca81bda2e8451505dbaf2aafddc99ffcee7af3db51ae9cbc5c11a3c46c921c" "0.19.2": url: "https://github.com/actor-framework/actor-framework/archive/0.19.2.tar.gz" sha256: "aa3fcc494424e0e20b177125458a6a6ed39c751a3d3d5193054e88bdf8a146d2" diff --git a/recipes/caf/config.yml b/recipes/caf/config.yml index 9d2f0ee39c4640..4e03d61da3e521 100644 --- a/recipes/caf/config.yml +++ b/recipes/caf/config.yml @@ -1,4 +1,6 @@ versions: + "0.19.3": + folder: all "0.19.2": folder: all "0.18.6": From a21c06e4b6d56cfc42d24e9131d8905caed8ecc8 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 06:34:11 +0300 Subject: [PATCH 0843/1140] (#20007) nvtx: add version 3.1.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/nvtx/all/conandata.yml | 3 +++ recipes/nvtx/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/nvtx/all/conandata.yml b/recipes/nvtx/all/conandata.yml index 7d5d894d503538..48340be192d8ea 100644 --- a/recipes/nvtx/all/conandata.yml +++ b/recipes/nvtx/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.1.0": + url: "https://github.com/NVIDIA/NVTX/archive/v3.1.0.tar.gz" + sha256: "dc4e4a227d04d3da46ad920dfee5f7599ac8d6b2ee1809c9067110fb1cc71ced" "3.0.1": url: "https://github.com/NVIDIA/NVTX/archive/refs/tags/v3.0.1.tar.gz" sha256: "bb8d1536aad708ec807bc675e12e5838c2f84481dec4005cd7a9bbd49e326ba1" diff --git a/recipes/nvtx/config.yml b/recipes/nvtx/config.yml index f1eca9cdf76de8..188be115336dd1 100644 --- a/recipes/nvtx/config.yml +++ b/recipes/nvtx/config.yml @@ -1,3 +1,5 @@ versions: + "3.1.0": + folder: all "3.0.1": folder: all From 2aa7d8b3541df2d705f865cc2059b1aad419f68c Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 30 Sep 2023 06:11:25 +0200 Subject: [PATCH 0844/1140] (#20011) libtiff/all: bump libwebp --- recipes/libtiff/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libtiff/all/conanfile.py b/recipes/libtiff/all/conanfile.py index 3393b9d3d4cd6f..c650a266c17ca9 100644 --- a/recipes/libtiff/all/conanfile.py +++ b/recipes/libtiff/all/conanfile.py @@ -79,7 +79,7 @@ def requirements(self): if self.options.zstd: self.requires("zstd/1.5.5") if self.options.webp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") def validate(self): if self.options.libdeflate and not self.options.zlib: From b71d402a919c1205c9140b333230e32ee89b1e1f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 08:09:55 +0300 Subject: [PATCH 0845/1140] (#20012) platform.exceptions: add version 0.5.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/platform.exceptions/all/conandata.yml | 13 ++++++++----- recipes/platform.exceptions/config.yml | 4 +++- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/recipes/platform.exceptions/all/conandata.yml b/recipes/platform.exceptions/all/conandata.yml index 9d13e79d6d9952..9459ce54f6fdc4 100644 --- a/recipes/platform.exceptions/all/conandata.yml +++ b/recipes/platform.exceptions/all/conandata.yml @@ -1,7 +1,10 @@ sources: - "0.2.0": - url: https://github.com/linksplatform/Exceptions/archive/refs/tags/0.4.0_0.2.0.zip - sha256: 9e4513da667e41f0bbe776123747ac63958972edb00eaee300c495ae3b39eb9b + "0.5.0": + url: "https://github.com/linksplatform/Exceptions/archive/csharp_0.5.0.tar.gz" + sha256: "5fbdd49adf7840431a581d0bfe61a5d247398a1fe622101b3985714d11d411f4" "0.3.0": - url: https://github.com/linksplatform/Exceptions/archive/refs/tags/cpp_0.3.0.zip - sha256: 08506f334098e8c9106ff357efd7f68b83a3c1f4dc03b6b97b6229b14737d0ce + url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/cpp_0.3.0.zip" + sha256: "08506f334098e8c9106ff357efd7f68b83a3c1f4dc03b6b97b6229b14737d0ce" + "0.2.0": + url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/0.4.0_0.2.0.zip" + sha256: "9e4513da667e41f0bbe776123747ac63958972edb00eaee300c495ae3b39eb9b" diff --git a/recipes/platform.exceptions/config.yml b/recipes/platform.exceptions/config.yml index 0906286bf12252..918726b6e05300 100644 --- a/recipes/platform.exceptions/config.yml +++ b/recipes/platform.exceptions/config.yml @@ -1,5 +1,7 @@ versions: - "0.2.0": + "0.5.0": folder: all "0.3.0": folder: all + "0.2.0": + folder: all From f4e7e286a06e5255e8c956a07eae5ce8f1227369 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 08:29:16 +0300 Subject: [PATCH 0846/1140] (#20013) platform.converters: add version 0.4.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/platform.converters/all/conandata.yml | 7 +++++-- recipes/platform.converters/config.yml | 2 ++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/recipes/platform.converters/all/conandata.yml b/recipes/platform.converters/all/conandata.yml index dbc2ae3eae6999..f7a43902b2ca7d 100644 --- a/recipes/platform.converters/all/conandata.yml +++ b/recipes/platform.converters/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.4.0": + url: "https://github.com/linksplatform/Converters/archive/csharp_0.4.0.tar.gz" + sha256: "dd55cff0c66fbb169d255d12e62c0ceba2e9d5c94921786871945c3a5c2d7357" "0.1.0": - url: https://github.com/linksplatform/Converters/archive/refs/tags/cpp_0.1.0.zip - sha256: a1a9e566b6628b1e09875f9ee93fb7fb600a8371d07e00a25c127e1609375d96 + url: "https://github.com/linksplatform/Converters/archive/refs/tags/cpp_0.1.0.zip" + sha256: "a1a9e566b6628b1e09875f9ee93fb7fb600a8371d07e00a25c127e1609375d96" diff --git a/recipes/platform.converters/config.yml b/recipes/platform.converters/config.yml index 6c11a439d0bc21..22f695c341d3f7 100644 --- a/recipes/platform.converters/config.yml +++ b/recipes/platform.converters/config.yml @@ -1,3 +1,5 @@ versions: + "0.4.0": + folder: all "0.1.0": folder: all From b39380054faab2592e02e9a4c9b1bd6de347dfbb Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 08:49:28 +0300 Subject: [PATCH 0847/1140] (#20016) proj: add version 9.3.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/proj/all/conandata.yml | 7 +++++++ recipes/proj/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/proj/all/conandata.yml b/recipes/proj/all/conandata.yml index 8f4cf560d8dc42..865b4bba90467a 100644 --- a/recipes/proj/all/conandata.yml +++ b/recipes/proj/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "9.3.0": + url: "https://github.com/OSGeo/PROJ/archive/9.3.0.tar.gz" + sha256: "f48c334eaf56c38d681bcfa37f188f422a562f45a66e6e646a79b4249641ecdb" "9.2.1": url: "https://github.com/OSGeo/PROJ/releases/download/9.2.1/proj-9.2.1.tar.gz" sha256: "15ebf4afa8744b9e6fccb5d571fc9f338dc3adcf99907d9e62d1af815d4971a1" @@ -24,6 +27,10 @@ sources: url: "https://github.com/OSGeo/PROJ/releases/download/6.3.1/proj-6.3.1.tar.gz" sha256: "6de0112778438dcae30fcc6942dee472ce31399b9e5a2b67e8642529868c86f8" patches: + "9.3.0": + - patch_file: "patches/0001-use-cmake-targets-9.2.1.patch" + patch_type: "conan" + patch_description: "Use cmake targets" "9.2.1": - patch_file: "patches/0001-use-cmake-targets-9.2.1.patch" patch_type: "conan" diff --git a/recipes/proj/config.yml b/recipes/proj/config.yml index 1eba8e77164d54..57e61ab70191e1 100644 --- a/recipes/proj/config.yml +++ b/recipes/proj/config.yml @@ -1,4 +1,6 @@ versions: + "9.3.0": + folder: "all" "9.2.1": folder: "all" "9.1.1": From a26a213f8175eb71450f2b08dde8fbb081c8c36e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 09:30:23 +0300 Subject: [PATCH 0848/1140] (#20018) stc: add version 4.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/stc/all/conandata.yml | 3 +++ recipes/stc/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/stc/all/conandata.yml b/recipes/stc/all/conandata.yml index a87f93d04cdefd..a7dd10bef0b552 100644 --- a/recipes/stc/all/conandata.yml +++ b/recipes/stc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.2": + url: "https://github.com/tylov/STC/archive/v4.2.tar.gz" + sha256: "f16c3185ba5693f0257e5b521f0b6b3c11041433a4abbbbc531370364eb75d0c" "4.1.1": url: "https://github.com/tylov/STC/archive/refs/tags/v4.1.1.tar.gz" sha256: "4386f7bc6480ba101f3e71b1adccfff8ccf586a31271d6ddc0f634d727d9f031" diff --git a/recipes/stc/config.yml b/recipes/stc/config.yml index bfb07935d0412b..3db9bf640436f7 100644 --- a/recipes/stc/config.yml +++ b/recipes/stc/config.yml @@ -1,4 +1,6 @@ versions: + "4.2": + folder: "all" "4.1.1": folder: "all" "3.9": From 7407669cfdefc926a7d8209510fb545a641731b5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 10:10:21 +0300 Subject: [PATCH 0849/1140] (#20019) librdkafka: add version 2.2.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/librdkafka/all/conandata.yml | 10 ++++++++++ recipes/librdkafka/config.yml | 2 ++ 2 files changed, 12 insertions(+) diff --git a/recipes/librdkafka/all/conandata.yml b/recipes/librdkafka/all/conandata.yml index 79827450beb2cd..81ba31cdfb277b 100644 --- a/recipes/librdkafka/all/conandata.yml +++ b/recipes/librdkafka/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.2.0": + url: "https://github.com/edenhill/librdkafka/archive/v2.2.0.tar.gz" + sha256: "af9a820cbecbc64115629471df7c7cecd40403b6c34bfdbb9223152677a47226" "2.0.2": url: "https://github.com/edenhill/librdkafka/archive/v2.0.2.tar.gz" sha256: "f321bcb1e015a34114c83cf1aa7b99ee260236aab096b85c003170c90a47ca9d" @@ -27,6 +30,13 @@ sources: url: "https://github.com/edenhill/librdkafka/archive/v1.5.3.tar.gz" sha256: "2105ca01fef5beca10c9f010bc50342b15d5ce6b73b2489b012e6d09a008b7bf" patches: + "2.2.0": + - patch_file: patches/0001-Change-library-names-1-9-1.patch + patch_description: "find_package conan packages" + patch_type: "conan" + - patch_file: patches/0002-Change-library-targets-and-result-variables-2-0-2.patch + patch_description: "refer conan package names" + patch_type: "conan" "2.0.2": - patch_file: patches/0001-Change-library-names-1-9-1.patch patch_description: "find_package conan packages" diff --git a/recipes/librdkafka/config.yml b/recipes/librdkafka/config.yml index 92b3b67d04bdf0..6e80eff9af8852 100644 --- a/recipes/librdkafka/config.yml +++ b/recipes/librdkafka/config.yml @@ -1,4 +1,6 @@ versions: + "2.2.0": + folder: all "2.0.2": folder: all "1.9.2": From 1c009c90c4eddaa24d233bdc71b55693b4b9baa1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 10:51:05 +0300 Subject: [PATCH 0850/1140] (#20021) outcome: add version 2.2.7 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/outcome/all/conandata.yml | 3 +++ recipes/outcome/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/outcome/all/conandata.yml b/recipes/outcome/all/conandata.yml index a2d2ce108afcdd..68135018bb9009 100644 --- a/recipes/outcome/all/conandata.yml +++ b/recipes/outcome/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.2.7": + url: "https://github.com/ned14/outcome/archive/v2.2.7.tar.gz" + sha256: "553fd03bb9684be19dfa251bfa0064e69e30a95b6b0ba9a62d68f8ec4e31662a" "2.2.4": url: "https://github.com/ned14/outcome/archive/v2.2.4.tar.gz" sha256: "29ad35c1980cf7f75294bb52df678c6a08817228e880fac8454cd6ac390fa1fc" diff --git a/recipes/outcome/config.yml b/recipes/outcome/config.yml index a37008481a1738..08abb1cf7e40b3 100644 --- a/recipes/outcome/config.yml +++ b/recipes/outcome/config.yml @@ -1,4 +1,6 @@ versions: + "2.2.7": + folder: all "2.2.4": folder: all "2.2.3": From b5067eac1a74ed57fc591543e6c933c48502ca73 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 11:11:13 +0300 Subject: [PATCH 0851/1140] (#20024) redboltz-mqtt_cpp: add version 13.2.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/redboltz-mqtt_cpp/all/conandata.yml | 3 +++ recipes/redboltz-mqtt_cpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/redboltz-mqtt_cpp/all/conandata.yml b/recipes/redboltz-mqtt_cpp/all/conandata.yml index ad87340ad9e356..edcba50235f7cd 100644 --- a/recipes/redboltz-mqtt_cpp/all/conandata.yml +++ b/recipes/redboltz-mqtt_cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "13.2.1": + url: "https://github.com/redboltz/mqtt_cpp/archive/v13.2.1.tar.gz" + sha256: "7607536cb7e0e4d32831ef068c48d3d62707df80ba35c5a3fdc31851e7876a9d" "13.0.0": url: "https://github.com/redboltz/mqtt_cpp/archive/refs/tags/v13.0.0.tar.gz" sha256: "5d06caa1218feb23d0a63892ced7b0edfd1f686002676175f6e384275a27a1e7" diff --git a/recipes/redboltz-mqtt_cpp/config.yml b/recipes/redboltz-mqtt_cpp/config.yml index ed9e26c6552eb1..3eb6ce30d67472 100644 --- a/recipes/redboltz-mqtt_cpp/config.yml +++ b/recipes/redboltz-mqtt_cpp/config.yml @@ -1,3 +1,5 @@ versions: + "13.2.1": + folder: all "13.0.0": folder: all From a6ca0b5fd7a494d813b3df61f0f8eb2c60b5aa77 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 11:30:10 +0300 Subject: [PATCH 0852/1140] (#20026) openddl-parser: add version 0.5.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/openddl-parser/all/conandata.yml | 3 +++ recipes/openddl-parser/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/openddl-parser/all/conandata.yml b/recipes/openddl-parser/all/conandata.yml index aff9aad9e373bf..367951b808907b 100644 --- a/recipes/openddl-parser/all/conandata.yml +++ b/recipes/openddl-parser/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.5.1": + url: "https://github.com/kimkulling/openddl-parser/archive/v0.5.1.tar.gz" + sha256: "511146377636f56a8a3bd6daace5ac2ed9672f4be28fc2c90597f4e88e069ffc" "0.5.0": url: "https://github.com/kimkulling/openddl-parser/archive/refs/tags/v0.5.0.tar.gz" sha256: "0ad1a95462932da247a21fc3bb4560c3d9b134e15464f6a518c9e01becc14b60" diff --git a/recipes/openddl-parser/config.yml b/recipes/openddl-parser/config.yml index c4cc95f34a3b67..c45ff0b2916ff5 100644 --- a/recipes/openddl-parser/config.yml +++ b/recipes/openddl-parser/config.yml @@ -1,4 +1,6 @@ versions: + "0.5.1": + folder: "all" "0.5.0": folder: "all" "cci.20211217": From 2a319b075b2f63925b951a22e4f97d329a0268c2 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 12:26:13 +0300 Subject: [PATCH 0853/1140] (#20028) mcap: add version 1.2.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/mcap/all/conandata.yml | 3 +++ recipes/mcap/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/mcap/all/conandata.yml b/recipes/mcap/all/conandata.yml index a1bc6133e68c96..4b98eb916b67c1 100644 --- a/recipes/mcap/all/conandata.yml +++ b/recipes/mcap/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.1": + url: "https://github.com/foxglove/mcap/archive/releases/cpp/v1.2.1.tar.gz" + sha256: "fdc0c351bbcf8883fec0047ff84fed74da88446859083beb6624a584e2cde669" 1.2.0: url: "https://github.com/foxglove/mcap/archive/refs/tags/releases/cpp/v1.2.0/main.tar.gz" sha256: "11a6badecac2b10e9687e912648a6e9679ef8731e4ab9570346ae9845ae64a65" diff --git a/recipes/mcap/config.yml b/recipes/mcap/config.yml index bfc72fea8d81a1..f50a75ba292e8a 100644 --- a/recipes/mcap/config.yml +++ b/recipes/mcap/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.1": + folder: all 1.2.0: folder: all 1.1.0: From 7b327db0902e5a44af6d99e7de85994a781d27ea Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 13:13:42 +0300 Subject: [PATCH 0854/1140] (#20029) seasocks: add version 1.4.6 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/seasocks/all/conandata.yml | 3 +++ recipes/seasocks/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/seasocks/all/conandata.yml b/recipes/seasocks/all/conandata.yml index 8ea105850a8bab..412d4f0b76fddf 100644 --- a/recipes/seasocks/all/conandata.yml +++ b/recipes/seasocks/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.4.6": + url: "https://github.com/mattgodbolt/seasocks/archive/v1.4.6.tar.gz" + sha256: "fc69636ce1205d338d4c02784333b04cd774fa368843fcf9f4fe6f8530a2cd67" "1.4.5": url: "https://github.com/mattgodbolt/seasocks/archive/v1.4.5.tar.gz" sha256: "82211959cf8aabc85b300358c5f68cf9c56dfdf4eaa09e548580fce908acfc1b" diff --git a/recipes/seasocks/config.yml b/recipes/seasocks/config.yml index bcda68af0d12d3..b2a6b234212ab4 100644 --- a/recipes/seasocks/config.yml +++ b/recipes/seasocks/config.yml @@ -1,4 +1,6 @@ versions: + "1.4.6": + folder: "all" "1.4.5": folder: "all" "1.4.4": From 5d9cd2987999318b299507b70dfd03021f18113c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 13:55:29 +0300 Subject: [PATCH 0855/1140] (#20033) easyloggingpp: add version 9.97.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/easyloggingpp/all/conandata.yml | 3 +++ recipes/easyloggingpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/easyloggingpp/all/conandata.yml b/recipes/easyloggingpp/all/conandata.yml index 5649e78f158ccf..83345fd6f0b12a 100644 --- a/recipes/easyloggingpp/all/conandata.yml +++ b/recipes/easyloggingpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "9.97.1": + url: "https://github.com/amrayn/easyloggingpp/archive/v9.97.1.tar.gz" + sha256: "ebe473e17b13f1d1f16d0009689576625796947a711e14aec29530f39560c7c2" "9.97.0": url: "https://github.com/amrayn/easyloggingpp/archive/v9.97.0.tar.gz" sha256: "9110638e21ef02428254af8688bf9e766483db8cc2624144aa3c59006907ce22" diff --git a/recipes/easyloggingpp/config.yml b/recipes/easyloggingpp/config.yml index 8f835ce7bab04d..b4a91abbf71818 100644 --- a/recipes/easyloggingpp/config.yml +++ b/recipes/easyloggingpp/config.yml @@ -1,3 +1,5 @@ versions: + "9.97.1": + folder: all "9.97.0": folder: all From 104a3f88a5426fe77a532d0f62e28ccb5a51dee0 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 14:30:30 +0300 Subject: [PATCH 0856/1140] (#20034) libipt: add version 2.0.6 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libipt/all/conandata.yml | 3 +++ recipes/libipt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libipt/all/conandata.yml b/recipes/libipt/all/conandata.yml index 91a36f41590f64..702bec04ce824d 100644 --- a/recipes/libipt/all/conandata.yml +++ b/recipes/libipt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.6": + url: "https://github.com/intel/libipt/archive/v2.0.6.tar.gz" + sha256: "631f4ebc81e12c0493288af3cc307b0de5b65f018d3e3839c87014b0d26acd75" "2.0.5": url: https://github.com/intel/libipt/archive/refs/tags/v2.0.5.tar.gz sha256: 95acf499fdf0a0f5ebd07587bb443c702b1fd79f7d869749824234388b9bff80 diff --git a/recipes/libipt/config.yml b/recipes/libipt/config.yml index 16ab573dd6bd38..c14d5aed738ae0 100644 --- a/recipes/libipt/config.yml +++ b/recipes/libipt/config.yml @@ -1,3 +1,5 @@ versions: + "2.0.6": + folder: all "2.0.5": folder: all From fd5967061d9604b3bc762c89d2a2a55c28a2338b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 15:11:41 +0300 Subject: [PATCH 0857/1140] (#20036) octomap: add version 1.9.8 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/octomap/all/conandata.yml | 7 +++++++ recipes/octomap/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/octomap/all/conandata.yml b/recipes/octomap/all/conandata.yml index badfa463524af4..315b1fcda454d6 100644 --- a/recipes/octomap/all/conandata.yml +++ b/recipes/octomap/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.9.8": + url: "https://github.com/OctoMap/octomap/archive/v1.9.8.tar.gz" + sha256: "417af6da4e855e9a83b93458aa98b01a2c88f880088baad2b59d323ce162586e" "1.9.7": url: "https://github.com/OctoMap/octomap/archive/v1.9.7.tar.gz" sha256: "3e9ac020686ceb4e17e161bffc5a0dafd9cccab33adeb9adee59a61c418ea1c1" @@ -12,6 +15,10 @@ sources: url: "https://github.com/OctoMap/octomap/archive/v1.9.3.tar.gz" sha256: "8488de97ed2c8f4757bfbaf3225e82a9e36783dce1f573b3bde1cf968aa89696" patches: + "1.9.8": + - patch_file: "patches/1.9.5-0001-targets-outputname-collision.patch" + patch_description: "CMake: build either shared or static, and avoid name collision" + patch_type: "conan" "1.9.7": - patch_file: "patches/1.9.5-0001-targets-outputname-collision.patch" patch_description: "CMake: build either shared or static, and avoid name collision" diff --git a/recipes/octomap/config.yml b/recipes/octomap/config.yml index bbf53f61e28d4d..7b6ae3353a6fd9 100644 --- a/recipes/octomap/config.yml +++ b/recipes/octomap/config.yml @@ -1,4 +1,6 @@ versions: + "1.9.8": + folder: all "1.9.7": folder: all "1.9.6": From b269efc9eb4687792a60c726fb72c15afe08b443 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 16:16:37 +0300 Subject: [PATCH 0858/1140] (#20039) zpp_throwing: add version 1.0.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/zpp_throwing/all/conandata.yml | 3 +++ recipes/zpp_throwing/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/zpp_throwing/all/conandata.yml b/recipes/zpp_throwing/all/conandata.yml index 063b5be845f319..118abd17e3a227 100644 --- a/recipes/zpp_throwing/all/conandata.yml +++ b/recipes/zpp_throwing/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.1": + url: "https://github.com/eyalz800/zpp_throwing/archive/v1.0.1.tar.gz" + sha256: "c15651ad36f9ddcb51e6244b0a78dbdebf7be8748b3e7ffe1c7339f0e41fd411" "1.0": url: "https://github.com/eyalz800/zpp_throwing/archive/refs/tags/v1.0.tar.gz" sha256: "e02ef0e028e436ed4382b14796550f48c1d2b5ae02910f10b5b9fe097981ea2f" diff --git a/recipes/zpp_throwing/config.yml b/recipes/zpp_throwing/config.yml index edab1ee152d366..7b06dd8bf61ea9 100644 --- a/recipes/zpp_throwing/config.yml +++ b/recipes/zpp_throwing/config.yml @@ -1,3 +1,5 @@ versions: + "1.0.1": + folder: all "1.0": folder: all From 605c9916c6150bc560a0f5a412e93c0dda49d0e9 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 16:36:54 +0300 Subject: [PATCH 0859/1140] (#20040) cyclonedds: add version 0.10.4 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/cyclonedds/all/conandata.yml | 7 +++++++ recipes/cyclonedds/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/cyclonedds/all/conandata.yml b/recipes/cyclonedds/all/conandata.yml index d51b6cdca669c5..8d9fa515082f8b 100644 --- a/recipes/cyclonedds/all/conandata.yml +++ b/recipes/cyclonedds/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.10.4": + url: "https://github.com/eclipse-cyclonedds/cyclonedds/archive/0.10.4.tar.gz" + sha256: "fe7bb5a4348e31656a935f72dec909a7d2b0fcf10840614fb552f08eb2da8484" "0.10.3": url: "https://github.com/eclipse-cyclonedds/cyclonedds/archive/refs/tags/0.10.3.tar.gz" sha256: "bc79696209febfe66d97e7af6b11e92f9db663caf608a922b6c201b1d6a5eb62" @@ -6,6 +9,10 @@ sources: url: "https://github.com/eclipse-cyclonedds/cyclonedds/archive/refs/tags/0.10.2.tar.gz" sha256: "bc84e137e0c8a055b8cd97fbeafec94e36de1b0c2e88800896a82384fd867ae5" patches: + "0.10.4": + - patch_file: "patches/0.10.2-0001-fix-find-iceoryx.patch" + patch_description: "Fix cmake find for iceoryx package" + patch_type: "conan" "0.10.3": - patch_file: "patches/0.10.2-0001-fix-find-iceoryx.patch" patch_description: "Fix cmake find for iceoryx package" diff --git a/recipes/cyclonedds/config.yml b/recipes/cyclonedds/config.yml index 6fdde61015259e..b770b060712653 100644 --- a/recipes/cyclonedds/config.yml +++ b/recipes/cyclonedds/config.yml @@ -1,4 +1,6 @@ versions: + "0.10.4": + folder: all "0.10.3": folder: all "0.10.2": From 639682bd38a6e5407f8c621ef70abb7a28c0518e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 17:30:35 +0300 Subject: [PATCH 0860/1140] (#20045) libfreenect: add version 0.7.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libfreenect/all/conandata.yml | 5 +++++ recipes/libfreenect/config.yml | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/libfreenect/all/conandata.yml b/recipes/libfreenect/all/conandata.yml index d95c75077fd157..5f576feee3083f 100644 --- a/recipes/libfreenect/all/conandata.yml +++ b/recipes/libfreenect/all/conandata.yml @@ -1,7 +1,12 @@ sources: + "0.7.0": + url: "https://github.com/OpenKinect/libfreenect/archive/v0.7.0.tar.gz" + sha256: "adbfc6e7ce72f77cccb3341807a1e2cc6fe2ee62e1bc4d70a6c9b05fac83fe8f" "0.6.2": url: "https://github.com/OpenKinect/libfreenect/archive/refs/tags/v0.6.2.tar.gz" sha256: "e135f5e60ae290bf1aa403556211f0a62856a9e34f12f12400ec593620a36bfa" patches: + "0.7.0": + - patch_file: "patches/0.6.2-fix-cmake.patch" "0.6.2": - patch_file: "patches/0.6.2-fix-cmake.patch" diff --git a/recipes/libfreenect/config.yml b/recipes/libfreenect/config.yml index a09c617182ab2d..d4f601d9832b33 100644 --- a/recipes/libfreenect/config.yml +++ b/recipes/libfreenect/config.yml @@ -1,3 +1,5 @@ versions: + "0.7.0": + folder: all "0.6.2": folder: all From bc765051fb7c4c31d3d40851ca5a71b72d3c3b6f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 18:42:38 +0300 Subject: [PATCH 0861/1140] (#20046) hffix: add version 1.3.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/hffix/all/conandata.yml | 3 +++ recipes/hffix/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/hffix/all/conandata.yml b/recipes/hffix/all/conandata.yml index 63e048eedc7871..a5fdd1b12f317b 100644 --- a/recipes/hffix/all/conandata.yml +++ b/recipes/hffix/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.3.0": + url: "https://github.com/jamesdbrock/hffix/archive/v1.3.0.tar.gz" + sha256: "db3584c9daa5cfb76a096e02d945355294558a78d0128b5c2e82b8849fa26d77" "1.1.1": url: "https://github.com/jamesdbrock/hffix/archive/refs/tags/v1.1.1.tar.gz" sha256: "25dcaee8ded3590dd04225bd98909c9d78c8e39c26fb3c9880ec001a35464c07" diff --git a/recipes/hffix/config.yml b/recipes/hffix/config.yml index 60d31991f5141a..4d32e3eeef7e4e 100644 --- a/recipes/hffix/config.yml +++ b/recipes/hffix/config.yml @@ -1,3 +1,5 @@ versions: + "1.3.0": + folder: all "1.1.1": folder: all From 17ef90e04177b0c59f5f0135f07c97f89ebc32d1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 19:12:42 +0300 Subject: [PATCH 0862/1140] (#20048) tinyexr: add version 1.0.7 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/tinyexr/all/conandata.yml | 3 +++ recipes/tinyexr/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/tinyexr/all/conandata.yml b/recipes/tinyexr/all/conandata.yml index 2b4deeb06840bb..e57fb348a5c615 100644 --- a/recipes/tinyexr/all/conandata.yml +++ b/recipes/tinyexr/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.7": + url: "https://github.com/syoyo/tinyexr/archive/v1.0.7.tar.gz" + sha256: "1ffcc4ce85edef4af955497417445c2a7d3565ad9f314cd69f33075a37a48359" "1.0.6": url: "https://github.com/syoyo/tinyexr/archive/v1.0.6.tar.gz" sha256: "807a5665a7da8dc5ba4dd2c0f69079d87f37a147399680a54e3b38f86486aa67" diff --git a/recipes/tinyexr/config.yml b/recipes/tinyexr/config.yml index b08dcb504fac7a..675ce3be793968 100644 --- a/recipes/tinyexr/config.yml +++ b/recipes/tinyexr/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.7": + folder: all "1.0.6": folder: all "1.0.1": From 594d79804d8c6cbf71dc1e92020d72193ebe1673 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 30 Sep 2023 20:33:52 +0300 Subject: [PATCH 0863/1140] (#20049) godot_headers: add version 3.5.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/godot_headers/all/conandata.yml | 3 +++ recipes/godot_headers/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/godot_headers/all/conandata.yml b/recipes/godot_headers/all/conandata.yml index 8764611b2ac9a5..de60664696e4bf 100644 --- a/recipes/godot_headers/all/conandata.yml +++ b/recipes/godot_headers/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.5.2": + url: "https://github.com/godotengine/godot-headers/archive/godot-3.5.2-stable.tar.gz" + sha256: "42e97953d3f193db01cccd856dff0430a6737d47b8496a70e7df34387d870a6e" "3.5.1": url: "https://github.com/godotengine/godot-headers/archive/godot-3.5.1-stable.tar.gz" sha256: "1c38268031425a4881c0d6d41926a0f1bf5847f05dc24c29332609e318276b6b" diff --git a/recipes/godot_headers/config.yml b/recipes/godot_headers/config.yml index 3ded438e58f33b..07764b9a8e270f 100644 --- a/recipes/godot_headers/config.yml +++ b/recipes/godot_headers/config.yml @@ -1,4 +1,6 @@ versions: + "3.5.2": + folder: all "3.5.1": folder: all "3.4.4": From 6a06a362132d065c59494aa34ee26e475f52d2ec Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 02:47:41 +0900 Subject: [PATCH 0864/1140] (#20051) simdjson: add version 3.3.0, remove older versions --- recipes/simdjson/all/conandata.yml | 21 +++------------------ recipes/simdjson/all/conanfile.py | 20 +++----------------- recipes/simdjson/config.yml | 14 ++------------ 3 files changed, 8 insertions(+), 47 deletions(-) diff --git a/recipes/simdjson/all/conandata.yml b/recipes/simdjson/all/conandata.yml index c81b28e0ad2e38..7fb086ae208174 100644 --- a/recipes/simdjson/all/conandata.yml +++ b/recipes/simdjson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.3.0": + url: "https://github.com/simdjson/simdjson/archive/v3.3.0.tar.gz" + sha256: "a8c9feff2f19c3ff281d42f0b6b4b18f02236513b99229756fa9a1b14787a58a" "3.2.3": url: "https://github.com/simdjson/simdjson/archive/v3.2.3.tar.gz" sha256: "ab72701b8560c4f93a5de525657b3bf34094f99a1e63bd9db3195d1bcb90aa09" @@ -14,27 +17,9 @@ sources: "3.1.8": url: "https://github.com/simdjson/simdjson/archive/v3.1.8.tar.gz" sha256: "99e7eeb0a0038e0213da68f099e6a8b67bcaeea1586385ec5f752bea85d902d8" - "3.1.7": - url: "https://github.com/simdjson/simdjson/archive/v3.1.7.tar.gz" - sha256: "c65f5184fba321c7b9e97f6c881af9b607457bdd60fac0467010e099121540e2" - "3.1.5": - url: "https://github.com/simdjson/simdjson/archive/v3.1.5.tar.gz" - sha256: "5b916be17343324426fc467a4041a30151e481700d60790acfd89716ecc37076" - "3.1.1": - url: "https://github.com/simdjson/simdjson/archive/v3.1.1.tar.gz" - sha256: "4fcb1c9b1944e2eb8a4a4a22c979e2827165216f859e94d93c846c1261e0e432" - "3.1.0": - url: "https://github.com/simdjson/simdjson/archive/refs/tags/3.1.0.tar.gz" - sha256: "14d17ba7139d27c1e1bf01e765f5c26e84cc9e9be6a316c977638e01c7de85fa" "3.0.1": url: "https://github.com/simdjson/simdjson/archive/v3.0.1.tar.gz" sha256: "156b1bc5eb0561b2bd166b46d191fd3d95a3e709cc63761477d3b7aec2b6e9ed" "2.2.3": url: "https://github.com/simdjson/simdjson/archive/v2.2.3.tar.gz" sha256: "4c62f2d82edec3dbc63650c10453dc471de9f1be689eb5b4bde89efed89db5d8" - "1.1.0": - url: "https://github.com/simdjson/simdjson/archive/v1.1.0.tar.gz" - sha256: "9effcb21fe48e4bcc9b96031e60c3911c58aa656ad8c78212d269c0db9e0133e" - "0.9.7": - url: "https://github.com/simdjson/simdjson/archive/v0.9.7.tar.gz" - sha256: "a21279ae4cf0049234a822c5c3550f99ec1707d3cda12156d331dcc8cd411ba0" diff --git a/recipes/simdjson/all/conanfile.py b/recipes/simdjson/all/conanfile.py index b0c6d0fa54bf1d..7b42a92cdbbc87 100644 --- a/recipes/simdjson/all/conanfile.py +++ b/recipes/simdjson/all/conanfile.py @@ -72,8 +72,7 @@ def loose_lt_semver(v1, v2): f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not fully support." ) - if Version(self.version) >= "2.0.0" and \ - self.settings.compiler == "gcc" and \ + if self.settings.compiler == "gcc" and \ Version(self.settings.compiler.version).major == "9": if self.settings.compiler.get_safe("libcxx") == "libstdc++11": raise ConanInvalidConfiguration(f"{self.ref} doesn't support GCC 9 with libstdc++11.") @@ -86,24 +85,11 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["SIMDJSON_ENABLE_THREADS"] = self.options.threads - if Version(self.version) < "1.0.0": - tc.variables["SIMDJSON_BUILD_STATIC"] = not self.options.shared - tc.variables["SIMDJSON_SANITIZE"] = False - tc.variables["SIMDJSON_JUST_LIBRARY"] = True - else: - tc.variables["SIMDJSON_DEVELOPER_MODE"] = False + tc.variables["SIMDJSON_DEVELOPER_MODE"] = False tc.generate() def _patch_sources(self): - if Version(self.version) < "1.0.0": - simd_flags_file = os.path.join(self.source_folder, "cmake", "simdjson-flags.cmake") - # Those flags are not set in >=1.0.0 since we disable SIMDJSON_DEVELOPER_MODE - replace_in_file(self, simd_flags_file, "target_compile_options(simdjson-internal-flags INTERFACE -fPIC)", "") - replace_in_file(self, simd_flags_file, "-Werror", "") - replace_in_file(self, simd_flags_file, "/WX", "") - # Relocatable shared lib on macOS - replace_in_file(self, simd_flags_file, "set(CMAKE_MACOSX_RPATH OFF)", "") - else: + if Version(self.version) < "3.3.0": developer_options = os.path.join(self.source_folder, "cmake", "developer-options.cmake") # Relocatable shared lib on macOS replace_in_file(self, developer_options, "set(CMAKE_MACOSX_RPATH OFF)", "") diff --git a/recipes/simdjson/config.yml b/recipes/simdjson/config.yml index 78febe4d556f02..6e192862adaada 100644 --- a/recipes/simdjson/config.yml +++ b/recipes/simdjson/config.yml @@ -1,4 +1,6 @@ versions: + "3.3.0": + folder: all "3.2.3": folder: all "3.2.2": @@ -9,19 +11,7 @@ versions: folder: all "3.1.8": folder: all - "3.1.7": - folder: all - "3.1.5": - folder: all - "3.1.1": - folder: all - "3.1.0": - folder: all "3.0.1": folder: all "2.2.3": folder: all - "1.1.0": - folder: all - "0.9.7": - folder: all From 7d01d7154a8a5ce2e31ae4317a4315f98a66f29a Mon Sep 17 00:00:00 2001 From: Sneder89 <45610045+Sneder89@users.noreply.github.com> Date: Sat, 30 Sep 2023 19:59:40 +0200 Subject: [PATCH 0865/1140] (#20053) Add cppcheck 2.12.1 * add 2.12.1 * Update conandata.yml * Update conandata.yml * Update conandata.yml --- recipes/cppcheck/all/conandata.yml | 3 +++ recipes/cppcheck/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cppcheck/all/conandata.yml b/recipes/cppcheck/all/conandata.yml index 43f1aa2fd39bee..309e9e9115ce02 100644 --- a/recipes/cppcheck/all/conandata.yml +++ b/recipes/cppcheck/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.12.1": + url: "https://github.com/danmar/cppcheck/archive/2.12.1.tar.gz" + sha256: "2a3d4ba1179419612183ab3d6aed6d3b18be75e98cd6f138ea8e2020905dced2" "2.12": url: "https://github.com/danmar/cppcheck/archive/2.12.0.tar.gz" sha256: "7d67776118aee9a4f0214f993a4baa4a168b2dbb10c14b6ec5baf2ca147565b8" diff --git a/recipes/cppcheck/config.yml b/recipes/cppcheck/config.yml index c685c098418079..0fb8b3e88183bc 100644 --- a/recipes/cppcheck/config.yml +++ b/recipes/cppcheck/config.yml @@ -1,4 +1,6 @@ versions: + "2.12.1": + folder: all "2.12": folder: all "2.11.1": From 278178210e7f8cd3909230bfbb78b5dc02d0a573 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 30 Sep 2023 20:35:08 +0200 Subject: [PATCH 0866/1140] (#20054) date: use version range for libcurl --- recipes/date/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/date/all/conanfile.py b/recipes/date/all/conanfile.py index 16a2a092edd68d..94529453674c10 100644 --- a/recipes/date/all/conanfile.py +++ b/recipes/date/all/conanfile.py @@ -53,7 +53,7 @@ def layout(self): def requirements(self): if not self.options.header_only and not self.options.use_system_tz_db: - self.requires("libcurl/8.2.1") + self.requires("libcurl/[>=7.78 <9]") def package_id(self): if self.info.options.header_only: From 50eada88503bdd5297eccdc42920cc5612459db6 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 04:30:20 +0900 Subject: [PATCH 0867/1140] (#20086) rapidcsv: add version 8.80 --- recipes/rapidcsv/all/conandata.yml | 3 +++ recipes/rapidcsv/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/rapidcsv/all/conandata.yml b/recipes/rapidcsv/all/conandata.yml index 7a2083f7a43d32..22f73545deb36a 100644 --- a/recipes/rapidcsv/all/conandata.yml +++ b/recipes/rapidcsv/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.80": + url: "https://github.com/d99kris/rapidcsv/archive/refs/tags/v8.80.tar.gz" + sha256: "4c9e01cb2554cc76acac61532ef33b59e5b1f822160d2eb7efee2c128ea7f4c5" "8.77": url: "https://github.com/d99kris/rapidcsv/archive/refs/tags/v8.77.tar.gz" sha256: "2513c05e1a39799edd93787e86bdd83462bee06150b40942879af955288fa495" diff --git a/recipes/rapidcsv/config.yml b/recipes/rapidcsv/config.yml index d18c0697363e95..643c892898926b 100644 --- a/recipes/rapidcsv/config.yml +++ b/recipes/rapidcsv/config.yml @@ -1,4 +1,6 @@ versions: + "8.80": + folder: "all" "8.77": folder: "all" "8.75": From 0250b41cd0c57c4254a44a70f7f572bf33efeb82 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 04:49:30 +0900 Subject: [PATCH 0868/1140] (#20087) unordered_dense: add version 4.1.2 --- recipes/unordered_dense/all/conandata.yml | 3 +++ recipes/unordered_dense/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/unordered_dense/all/conandata.yml b/recipes/unordered_dense/all/conandata.yml index 9666412e076d67..cb46afb843f82f 100644 --- a/recipes/unordered_dense/all/conandata.yml +++ b/recipes/unordered_dense/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.1.2": + url: "https://github.com/martinus/unordered_dense/archive/v4.1.2.tar.gz" + sha256: "300410dbcd32800f83b2113dfecbdfe8cd256caa4cfeb117d646021d6e3209ae" "4.1.0": url: "https://github.com/martinus/unordered_dense/archive/v4.1.0.tar.gz" sha256: "0f594cb3b08fc657db3843139000005b6827e5c69d00f5c8d74c1239bd21746f" diff --git a/recipes/unordered_dense/config.yml b/recipes/unordered_dense/config.yml index 11719a7c946232..ff0267b8985262 100644 --- a/recipes/unordered_dense/config.yml +++ b/recipes/unordered_dense/config.yml @@ -1,4 +1,6 @@ versions: + "4.1.2": + folder: all "4.1.0": folder: all "4.0.4": From 148149aad68f25f92309b969fa722647231b7f41 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 05:09:16 +0900 Subject: [PATCH 0869/1140] (#20096) choc: add recipe --- recipes/choc/all/conandata.yml | 4 ++ recipes/choc/all/conanfile.py | 49 +++++++++++++++++++ recipes/choc/all/test_package/CMakeLists.txt | 8 +++ recipes/choc/all/test_package/conanfile.py | 26 ++++++++++ .../choc/all/test_package/test_package.cpp | 9 ++++ recipes/choc/config.yml | 3 ++ 6 files changed, 99 insertions(+) create mode 100644 recipes/choc/all/conandata.yml create mode 100644 recipes/choc/all/conanfile.py create mode 100644 recipes/choc/all/test_package/CMakeLists.txt create mode 100644 recipes/choc/all/test_package/conanfile.py create mode 100644 recipes/choc/all/test_package/test_package.cpp create mode 100644 recipes/choc/config.yml diff --git a/recipes/choc/all/conandata.yml b/recipes/choc/all/conandata.yml new file mode 100644 index 00000000000000..c9e73e3a7173c0 --- /dev/null +++ b/recipes/choc/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "cci.20230918": + url: "https://github.com/Tracktion/choc/archive/8572719d3b9085ccc88893cdaf8c2c703fa55adb.tar.gz" + sha256: "f98e4bc8e0be19b416a4c01a2673280a63dec45e444175cca85f06bd29748ac4" diff --git a/recipes/choc/all/conanfile.py b/recipes/choc/all/conanfile.py new file mode 100644 index 00000000000000..c7f6cc492b72bc --- /dev/null +++ b/recipes/choc/all/conanfile.py @@ -0,0 +1,49 @@ +from conan import ConanFile +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +import os + +required_conan_version = ">=1.52.0" + +class ChocConan(ConanFile): + name = "choc" + description = "A collection of header only classes, permissively licensed, to provide basic useful tasks with the bare-minimum of dependencies." + license = "ISC" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Tracktion/choc/" + topics = ("audio", "json", "containers", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + return 11 + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + copy(self, pattern="LICENSE*", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.h", + dst=os.path.join(self.package_folder, "include", "choc"), + src=self.source_folder, + excludes=("tests"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/choc/all/test_package/CMakeLists.txt b/recipes/choc/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..3d6e4b5e02fcd7 --- /dev/null +++ b/recipes/choc/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(choc REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE choc::choc) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/choc/all/test_package/conanfile.py b/recipes/choc/all/test_package/conanfile.py new file mode 100644 index 00000000000000..e845ae751a3017 --- /dev/null +++ b/recipes/choc/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/choc/all/test_package/test_package.cpp b/recipes/choc/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..e7b235a639ba22 --- /dev/null +++ b/recipes/choc/all/test_package/test_package.cpp @@ -0,0 +1,9 @@ +#include + +#include "choc/platform/choc_Platform.h" + +int main(void) { + std::cout << CHOC_OPERATING_SYSTEM_NAME << '\n'; + + return EXIT_SUCCESS; +} diff --git a/recipes/choc/config.yml b/recipes/choc/config.yml new file mode 100644 index 00000000000000..55bc2cddc1b4a2 --- /dev/null +++ b/recipes/choc/config.yml @@ -0,0 +1,3 @@ +versions: + "cci.20230918": + folder: all From aeb11538c6bc8d62e4acce10be3cb034506922f0 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 30 Sep 2023 22:30:12 +0200 Subject: [PATCH 0870/1140] (#20100) yaml linter: remove warning about base_path base_path is necessary in some cases (eg qt) where upstream patches apply to only a sub-directory of the sources. This happens when the sources are an aggregation of several repositories. the presence of base_path is an indirect consequence of explicitly setting the `destination` argument of the `get` function, so a better diagnostic would be to detect these. --- linter/conandata_yaml_linter.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/linter/conandata_yaml_linter.py b/linter/conandata_yaml_linter.py index 9e7133803906ea..51d27b850beec7 100644 --- a/linter/conandata_yaml_linter.py +++ b/linter/conandata_yaml_linter.py @@ -92,17 +92,6 @@ def main(): " reviewing and consumers to evaluate patches" ) - # v2 migrations suggestion - if "base_path" in parsed["patches"][version][i]: - base_path = parsed["patches"][version][i]["base_path"] - print( - f"::notice file={args.path},line={base_path.start_line},endline={base_path.end_line}," - f"title=conandata.yml v2 migration suggestion" - "::'base_path' should not be required once a recipe has been upgraded to take advantage of" - " layouts (see https://docs.conan.io/en/latest/reference/conanfile/tools/layout.html) and" - " the new helper (see https://docs.conan.io/en/latest/reference/conanfile/tools/files/patches.html#conan-tools-files-apply-conandata-patches)" - ) - def pretty_print_yaml_validate_error(args, error): snippet = error.context_mark.get_snippet().replace("\n", "%0A") From 1401abdc79a19985cb53c74c5eacbe018cb076e4 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 05:49:38 +0900 Subject: [PATCH 0871/1140] (#20168) etl: add version 20.38.2 * etl: add version 20.38.2 * update 20.38.3 --- recipes/etl/all/conandata.yml | 3 +++ recipes/etl/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/etl/all/conandata.yml b/recipes/etl/all/conandata.yml index aaf305dbf4ff24..9a2f4ce536daa7 100644 --- a/recipes/etl/all/conandata.yml +++ b/recipes/etl/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "20.38.3": + url: "https://github.com/ETLCPP/etl/archive/20.38.3.tar.gz" + sha256: "7d2f384dfa9a50c8e066b716524016d2b62e753b0b75fed09a2b7e2c260759d2" "20.38.0": url: "https://github.com/ETLCPP/etl/archive/20.38.0.tar.gz" sha256: "7e29ce81a2a2d5826286502a2ad5bde1f4b591d2c9e0ef7ccc335e75445223cd" diff --git a/recipes/etl/config.yml b/recipes/etl/config.yml index f57d0b4090ca85..4bf96a5a206434 100644 --- a/recipes/etl/config.yml +++ b/recipes/etl/config.yml @@ -1,4 +1,6 @@ versions: + "20.38.3": + folder: all "20.38.0": folder: all "20.37.3": From 091c55fe14456c39659bdcab60d82484871b3c64 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 06:10:54 +0900 Subject: [PATCH 0872/1140] (#20188) roaring: add version 2.0.2, remove older versions, add with_avx512 option for >= 1.1.0 --- recipes/roaring/all/conandata.yml | 30 ++----------------- recipes/roaring/all/conanfile.py | 16 ++++++++-- .../roaring/all/test_package/CMakeLists.txt | 3 -- .../roaring/all/test_package/test_package.cpp | 2 -- recipes/roaring/config.yml | 20 ++----------- 5 files changed, 19 insertions(+), 52 deletions(-) diff --git a/recipes/roaring/all/conandata.yml b/recipes/roaring/all/conandata.yml index e26f0a417c73ce..f16d216d33bdd1 100644 --- a/recipes/roaring/all/conandata.yml +++ b/recipes/roaring/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.2": + url: "https://github.com/RoaringBitmap/CRoaring/archive/v2.0.2.tar.gz" + sha256: "92636a931f8a7bf36ce5a96d3039db128afd0e075f5aa7936fa1685dd2bbc75b" "1.3.0": url: "https://github.com/RoaringBitmap/CRoaring/archive/v1.3.0.tar.gz" sha256: "c4fccf6a8cfa6f15f47d0e6f6b202940c2305e3078eb745d25fe9e2739ae5278" @@ -17,36 +20,9 @@ sources: "0.9.9": url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.9.9.tar.gz" sha256: "3083bcbc37e43403111c482ddf317a710972256c23bc83abc8925803a02bdf60" - "0.9.8": - url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.9.8.tar.gz" - sha256: "d83ea18ded541a49f792951a6e71cd20136171ca0a4c15c77ec5cd5b83ca8e63" - "0.9.6": - url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.9.6.tar.gz" - sha256: "6d410750eb4ce70db2fa3dc25b7bc33fd4a91a85ef7dff595200d0acef99b1ee" - "0.9.3": - url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.9.3.tar.gz" - sha256: "b7534adebf50a554e86b81a2b39459c9921c504e9a876abe00bd741d0a4bc85d" - "0.9.0": - url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.9.0.tar.gz" - sha256: "52c1f56e1f84ffb9ff6cb90fd1d23cfe04926f696ae57e796d0b056fff572693" "0.8.1": url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.8.1.tar.gz" sha256: "5359f2a051f10e42cea5edc3cb3650fd272e9125e6a0538901cf30619939d4f8" - "0.8.0": - url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.8.0.tar.gz" - sha256: "cd6c4770baccfea385c0c6891a8a80133ba26093209740ca0a3eea348aff1a20" "0.7.3": url: "https://github.com/RoaringBitmap/CRoaring/archive/v0.7.3.tar.gz" sha256: "e3f8115ba44ef0e1eb7b982dc3c3233f08f5f95ec1260169c2ad0ca50e56b656" - "0.6.0": - url: "https://github.com/RoaringBitmap/CRoaring/archive/refs/tags/v0.6.0.tar.gz" - sha256: "b8e2499ca9ac6ba0d18dbbcde4bae3752acf81f08ea6309ea2a88d27972dffcf" - "0.5.0": - url: "https://github.com/RoaringBitmap/CRoaring/archive/refs/tags/v0.5.0.tar.gz" - sha256: "edab1b1a464e5a361ff622dc833170b2f33729c161aee4c2e53a324ac62ef78f" - "0.4.0": - url: "https://github.com/RoaringBitmap/CRoaring/archive/refs/tags/v0.4.0.tar.gz" - sha256: "0faf6ac893694d5c283a729373af74f813989ef0257781636ac4c397b48c1219" - "0.3.4": - url: "https://github.com/RoaringBitmap/CRoaring/archive/refs/tags/v0.3.4.tar.gz" - sha256: "ddc5899823c46707d7dbf4e4c117a811b0428bdcb84978d9e65ceaefe6f59595" diff --git a/recipes/roaring/all/conanfile.py b/recipes/roaring/all/conanfile.py index 485a7146b02ba0..f0d51742149de0 100644 --- a/recipes/roaring/all/conanfile.py +++ b/recipes/roaring/all/conanfile.py @@ -22,6 +22,7 @@ class RoaringConan(ConanFile): "shared": [True, False], "fPIC": [True, False], "with_avx": [True, False], + "with_avx512": [True, False], "with_neon": [True, False], "native_optimization": [True, False], } @@ -29,15 +30,23 @@ class RoaringConan(ConanFile): "shared": False, "fPIC": True, "with_avx": True, + "with_avx512": True, "with_neon": True, "native_optimization": False, } + @property + def _min_cppstd(self): + return 11 + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC if self.settings.arch not in ("x86", "x86_64"): del self.options.with_avx + del self.options.with_avx512 + elif Version(self.version) < "1.1.0": + del self.options.with_avx512 if not str(self.settings.arch).startswith("arm"): del self.options.with_neon @@ -50,7 +59,7 @@ def layout(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, "11") + check_min_cppstd(self, self._min_cppstd) if self.settings.compiler == "apple-clang" and Version(self.settings.compiler.version) < "11": raise ConanInvalidConfiguration( f"{self.ref} requires at least apple-clang 11 to support runtime dispatching.", @@ -62,6 +71,8 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["ROARING_DISABLE_AVX"] = not self.options.get_safe("with_avx", False) + if "with_avx512" in self.options: + tc.variables["ROARING_DISABLE_AVX512"] = not self.options.with_avx512 tc.variables["ROARING_DISABLE_NEON"] = not self.options.get_safe("with_neon", False) tc.variables["ROARING_DISABLE_NATIVE"] = not self.options.native_optimization tc.variables["ROARING_BUILD_STATIC"] = not self.options.shared @@ -71,7 +82,8 @@ def generate(self): tc.generate() def build(self): - replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "set(CMAKE_MACOSX_RPATH OFF)", "") + if Version(self.version) < "2.0.0": + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "set(CMAKE_MACOSX_RPATH OFF)", "") cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/roaring/all/test_package/CMakeLists.txt b/recipes/roaring/all/test_package/CMakeLists.txt index 60d328135f9263..6e9e7fadde2653 100644 --- a/recipes/roaring/all/test_package/CMakeLists.txt +++ b/recipes/roaring/all/test_package/CMakeLists.txt @@ -6,6 +6,3 @@ find_package(roaring REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE roaring::roaring) target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) -if(roaring_VERSION VERSION_LESS "0.3.0") - target_compile_definitions(${PROJECT_NAME} PRIVATE "ROARING_NO_NAMESPACE") -endif() diff --git a/recipes/roaring/all/test_package/test_package.cpp b/recipes/roaring/all/test_package/test_package.cpp index 456ab7f7990a4e..18169725770ed6 100644 --- a/recipes/roaring/all/test_package/test_package.cpp +++ b/recipes/roaring/all/test_package/test_package.cpp @@ -5,9 +5,7 @@ #include "roaring/roaring.hh" #include "roaring/roaring.h" -#ifndef ROARING_NO_NAMESPACE using namespace roaring; -#endif void test_example_cpp(bool copy_on_write) { // create a new empty bitmap diff --git a/recipes/roaring/config.yml b/recipes/roaring/config.yml index 4dee57cf2ee127..3518f9cac57d3d 100644 --- a/recipes/roaring/config.yml +++ b/recipes/roaring/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.2": + folder: all "1.3.0": folder: all "1.1.5": @@ -11,25 +13,7 @@ versions: folder: all "0.9.9": folder: all - "0.9.8": - folder: all - "0.9.6": - folder: all - "0.9.3": - folder: all - "0.9.0": - folder: all "0.8.1": folder: all - "0.8.0": - folder: all "0.7.3": folder: all - "0.6.0": - folder: all - "0.5.0": - folder: all - "0.4.0": - folder: all - "0.3.4": - folder: all From 9268f2b69395b9ca54f248a2ae4dec48b0462798 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 1 Oct 2023 00:10:43 +0200 Subject: [PATCH 0873/1140] (#20205) meson: add version 1.2.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/meson/all/conandata.yml | 3 +++ recipes/meson/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/meson/all/conandata.yml b/recipes/meson/all/conandata.yml index 17f050a5732927..d58e97ba5b9522 100644 --- a/recipes/meson/all/conandata.yml +++ b/recipes/meson/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.2.2": + url: "https://github.com/mesonbuild/meson/releases/download/1.2.2/meson-1.2.2.tar.gz" + sha256: "4a0f04de331fbc7af3b802a844fc8838f4ccd1ded1e792ba4f8f2faf8c5fe4d6" "1.2.1": url: "https://github.com/mesonbuild/meson/releases/download/1.2.1/meson-1.2.1.tar.gz" sha256: "b1db3a153087549497ee52b1c938d2134e0338214fe14f7efd16fecd57b639f5" diff --git a/recipes/meson/config.yml b/recipes/meson/config.yml index 785517ff377e80..cde056a588debc 100644 --- a/recipes/meson/config.yml +++ b/recipes/meson/config.yml @@ -1,4 +1,6 @@ versions: + "1.2.2": + folder: all "1.2.1": folder: all "1.2.0": From 2a830a6d040295953b6e58f07b389943bcc70316 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 1 Oct 2023 01:29:55 +0300 Subject: [PATCH 0874/1140] (#20041) fribidi: add version 1.0.13 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/fribidi/all/conandata.yml | 3 +++ recipes/fribidi/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/fribidi/all/conandata.yml b/recipes/fribidi/all/conandata.yml index 08937af14f7283..281ca46617df09 100644 --- a/recipes/fribidi/all/conandata.yml +++ b/recipes/fribidi/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.13": + url: "https://github.com/fribidi/fribidi/archive/v1.0.13.tar.gz" + sha256: "f24e8e381bcf76533ae56bd776196f3a0369ec28e9c0fdb6edd163277e008314" "1.0.12": url: "https://github.com/fribidi/fribidi/releases/download/v1.0.12/fribidi-1.0.12.tar.xz" sha256: "0cd233f97fc8c67bb3ac27ce8440def5d3ffacf516765b91c2cc654498293495" diff --git a/recipes/fribidi/config.yml b/recipes/fribidi/config.yml index 1a912a9e71c6ea..88a69bbd500167 100644 --- a/recipes/fribidi/config.yml +++ b/recipes/fribidi/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.13": + folder: all "1.0.12": folder: all "1.0.10": From 77383910c43a9755d338956e4c581842d859c9ca Mon Sep 17 00:00:00 2001 From: Alec Edgington <54802828+cqc-alec@users.noreply.github.com> Date: Sun, 1 Oct 2023 00:08:51 +0100 Subject: [PATCH 0875/1140] (#20206) Add symengine 0.11.1 * Update boost dependency. * Add symengine 0.11.1. * Add 0.11.1 in config. --- recipes/symengine/all/conandata.yml | 3 +++ recipes/symengine/all/conanfile.py | 2 +- recipes/symengine/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/symengine/all/conandata.yml b/recipes/symengine/all/conandata.yml index d0b808ba0adde3..c2da1e1b162ec9 100644 --- a/recipes/symengine/all/conandata.yml +++ b/recipes/symengine/all/conandata.yml @@ -8,3 +8,6 @@ sources: "0.10.1": url: "https://github.com/symengine/symengine/releases/download/v0.10.1/symengine-0.10.1.tar.gz" sha256: "9c007c99e9633f5549a55fa7a66ebcbcf9e04092eb55f7bb781c22b9cf0570c4" + "0.11.1": + url: "https://github.com/symengine/symengine/releases/download/v0.11.1/symengine-0.11.1.tar.gz" + sha256: "217b39955dc19f920c6f54c057fdc89e8e155ddee8f0e3c3cacc67b3e3850b64" diff --git a/recipes/symengine/all/conanfile.py b/recipes/symengine/all/conanfile.py index cfb736044d218e..ec084a7552d079 100644 --- a/recipes/symengine/all/conanfile.py +++ b/recipes/symengine/all/conanfile.py @@ -36,7 +36,7 @@ class SymengineConan(ConanFile): def requirements(self): if self.options.integer_class == "boostmp": - self.requires("boost/1.81.0") + self.requires("boost/1.83.0") else: self.requires("gmp/6.2.1", transitive_headers=True, transitive_libs=True) diff --git a/recipes/symengine/config.yml b/recipes/symengine/config.yml index b95eb1527125e7..32a90ea4753f74 100644 --- a/recipes/symengine/config.yml +++ b/recipes/symengine/config.yml @@ -5,3 +5,5 @@ versions: folder: all "0.10.1": folder: all + "0.11.1": + folder: all From 0cbe1da2ab087d1088167a01bcb884d93f3d88a3 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Sun, 1 Oct 2023 02:19:55 +0300 Subject: [PATCH 0876/1140] (#20207) md4qt: bump version. --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 7275b589730d9f..d726da5cad811b 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.0.18": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.18.tar.gz" + sha256: "4fe70a63eb78cdf0355f6a6b292c40c8cc8ed4a62bcbec17afefa713b19c28b1" "2.0.16": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.16.tar.gz" sha256: "9da7cd02883c2f4d4a2371cda4c195ebc02f57bb673ef948b88a256f3db55724" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index e6e6297a347208..948892a125b470 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.18": + folder: all "2.0.16": folder: all "2.0.15": From 6c3056aab0ed415e8ec0ed29033722a55d8b1b96 Mon Sep 17 00:00:00 2001 From: Sylwester Dawida Date: Sun, 1 Oct 2023 01:51:26 +0200 Subject: [PATCH 0877/1140] (#20208) add 7bitconf 1.1.0 version --- recipes/7bitconf/all/conandata.yml | 3 +++ recipes/7bitconf/all/conanfile.py | 3 +-- recipes/7bitconf/config.yml | 2 ++ 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/recipes/7bitconf/all/conandata.yml b/recipes/7bitconf/all/conandata.yml index 62dda78f205157..71f022ca93c84b 100644 --- a/recipes/7bitconf/all/conandata.yml +++ b/recipes/7bitconf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.0": + url: "https://github.com/7bitCoder/7bitConf/archive/refs/tags/v1.1.0.tar.gz" + sha256: "07e5bff366d66c276032021c9a9ca5cdb1d8f097b29c032d07ee6ae1a10885a2" "1.0.0": url: "https://github.com/7bitCoder/7bitConf/archive/refs/tags/v1.0.0.tar.gz" sha256: "48a02d331f4281c8ff691d55c54abe744228637e9ad3af500daf526f4c77696d" diff --git a/recipes/7bitconf/all/conanfile.py b/recipes/7bitconf/all/conanfile.py index 50d4e6434d0f0d..4865b328bad13d 100644 --- a/recipes/7bitconf/all/conanfile.py +++ b/recipes/7bitconf/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("taocpp-json/1.0.0-beta.13", transitive_headers=True) + self.requires("taocpp-json/1.0.0-beta.14", transitive_headers=True) def package_id(self): if self.info.options.header_only: @@ -137,4 +137,3 @@ def package_info(self): if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs.append("m") - diff --git a/recipes/7bitconf/config.yml b/recipes/7bitconf/config.yml index 40341aa3db6cd3..73c245662b08d6 100644 --- a/recipes/7bitconf/config.yml +++ b/recipes/7bitconf/config.yml @@ -1,3 +1,5 @@ versions: + "1.1.0": + folder: all "1.0.0": folder: all From 51587601f8464d2270fa06ab17599d97c708e3f7 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 09:31:03 +0900 Subject: [PATCH 0878/1140] (#20209) glaze: add version 1.5.1 --- recipes/glaze/all/conandata.yml | 3 +++ recipes/glaze/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index 2840b2eed5cbb1..d4df74aaa8ab0f 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.1": + url: "https://github.com/stephenberry/glaze/archive/v1.5.1.tar.gz" + sha256: "b119b0375d13ab34ebc156e1c12eacc65e7f4c8b0cfcf6ae93e8fe18744d1ad5" "1.5.0": url: "https://github.com/stephenberry/glaze/archive/v1.5.0.tar.gz" sha256: "9ab1cc5faa3a1a46b478c884207e6c364e4b6ae9c09f96cbf9f2ef620b3bb3b5" diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index dfc0e2b2fc07ab..bac143c8ee8f36 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.1": + folder: all "1.5.0": folder: all "1.4.1": From d7a14031ef0144172d9d717c917282d014f022ed Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 09:52:39 +0900 Subject: [PATCH 0879/1140] (#20210) clickhouse-cpp: add version 2.5.0 --- recipes/clickhouse-cpp/all/conandata.yml | 3 +++ recipes/clickhouse-cpp/all/conanfile.py | 3 +++ recipes/clickhouse-cpp/config.yml | 2 ++ 3 files changed, 8 insertions(+) diff --git a/recipes/clickhouse-cpp/all/conandata.yml b/recipes/clickhouse-cpp/all/conandata.yml index 67cb91f1f1a6cf..21db8c747eb056 100644 --- a/recipes/clickhouse-cpp/all/conandata.yml +++ b/recipes/clickhouse-cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.5.0": + url: "https://github.com/ClickHouse/clickhouse-cpp/archive/refs/tags/v2.5.0.tar.gz" + sha256: "7eead6beb47a64be9b1f12f2435f0fb6304e8363823ed72178c76faf0d835801" "2.4.0": url: "https://github.com/ClickHouse/clickhouse-cpp/archive/refs/tags/v2.4.0.tar.gz" sha256: "336a1d0b4c4d6bd67bd272afab3bdac51695f8b0e93dd6c85d4d774d6c7df8ad" diff --git a/recipes/clickhouse-cpp/all/conanfile.py b/recipes/clickhouse-cpp/all/conanfile.py index df83d233feb8a1..4f321b7e267a75 100644 --- a/recipes/clickhouse-cpp/all/conanfile.py +++ b/recipes/clickhouse-cpp/all/conanfile.py @@ -85,6 +85,9 @@ def generate(self): tc.cache_variables["WITH_SYSTEM_ABSEIL"] = True tc.cache_variables["WITH_SYSTEM_LZ4"] = True tc.cache_variables["WITH_SYSTEM_CITYHASH"] = True + # TODO: enable DEBUG_DEPENDENCIES on >= 2.5.0 + if Version(self.version) >= "2.5.0": + tc.cache_variables["DEBUG_DEPENDENCIES"] = False tc.generate() cd = CMakeDeps(self) diff --git a/recipes/clickhouse-cpp/config.yml b/recipes/clickhouse-cpp/config.yml index e1d4aed9fe78fa..ea52eed8663189 100644 --- a/recipes/clickhouse-cpp/config.yml +++ b/recipes/clickhouse-cpp/config.yml @@ -1,3 +1,5 @@ versions: + "2.5.0": + folder: all "2.4.0": folder: all From b57879089e84d29768550ee7cce5fcf38ae1eccb Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 1 Oct 2023 03:32:35 +0200 Subject: [PATCH 0880/1140] (#20228) dlib/all: bump deps --- recipes/dlib/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/dlib/all/conanfile.py b/recipes/dlib/all/conanfile.py index fc668dbc311da2..dd3241419e6d17 100644 --- a/recipes/dlib/all/conanfile.py +++ b/recipes/dlib/all/conanfile.py @@ -76,9 +76,9 @@ def requirements(self): if self.options.with_png: self.requires("libpng/1.6.40") if self.options.get_safe("with_webp"): - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") if self.options.with_sqlite3: - self.requires("sqlite3/3.42.0") + self.requires("sqlite3/3.43.1") if self.options.with_openblas: self.requires("openblas/0.3.20") From 21a486f4cb5f325511784ad940f5b18ac6649dcc Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 1 Oct 2023 04:15:38 +0200 Subject: [PATCH 0881/1140] (#19935) glib/all: bump deps * glib/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * use range for zlib --- recipes/glib/all/conanfile.py | 8 ++++---- recipes/glib/all/test_package/conanfile.py | 2 +- recipes/glib/all/test_v1_package/conanfile.py | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/recipes/glib/all/conanfile.py b/recipes/glib/all/conanfile.py index 95fb7a1a6aec3d..a90b8bbde49a84 100644 --- a/recipes/glib/all/conanfile.py +++ b/recipes/glib/all/conanfile.py @@ -65,7 +65,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") self.requires("libffi/3.4.4") if Version(self.version) >= "2.73.2": self.requires("pcre2/10.42") @@ -74,7 +74,7 @@ def requirements(self): if self.options.get_safe("with_elf"): self.requires("libelf/0.8.13") if self.options.get_safe("with_mount"): - self.requires("libmount/2.36.2") + self.requires("libmount/2.39") if self.options.get_safe("with_selinux"): self.requires("libselinux/3.3") if self.settings.os != "Linux": @@ -85,9 +85,9 @@ def requirements(self): self.requires("libiconv/1.17") def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/glib/all/test_package/conanfile.py b/recipes/glib/all/test_package/conanfile.py index 2f5458641d6f7d..168cdc2e86991b 100644 --- a/recipes/glib/all/test_package/conanfile.py +++ b/recipes/glib/all/test_package/conanfile.py @@ -18,7 +18,7 @@ def requirements(self): def build_requirements(self): if self.settings.os != "Windows" and not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def generate(self): tc = CMakeToolchain(self) diff --git a/recipes/glib/all/test_v1_package/conanfile.py b/recipes/glib/all/test_v1_package/conanfile.py index ed236807fcf7e8..32471187016745 100644 --- a/recipes/glib/all/test_v1_package/conanfile.py +++ b/recipes/glib/all/test_v1_package/conanfile.py @@ -8,7 +8,7 @@ class TestPackageConan(ConanFile): def build_requirements(self): if self.settings.os != "Windows": - self.build_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def build(self): if self.settings.os != "Windows": From 1fc45dd744151824c262501e4257bc26f987d3d7 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 1 Oct 2023 05:36:20 +0200 Subject: [PATCH 0882/1140] (#20227) freeimage/all: bump deps --- recipes/freeimage/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/freeimage/all/conanfile.py b/recipes/freeimage/all/conanfile.py index 8ea9581a8d7f16..7b598ff9ef76dc 100644 --- a/recipes/freeimage/all/conanfile.py +++ b/recipes/freeimage/all/conanfile.py @@ -71,7 +71,7 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": self.requires("mozjpeg/4.1.1") if self.options.with_jpeg2000: @@ -79,7 +79,7 @@ def requirements(self): if self.options.with_png: self.requires("libpng/1.6.40") if self.options.with_webp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") if self.options.with_tiff or self.options.with_openexr: # can't upgrade to openexr/3.x.x because plugin tiff requires openexr/2.x.x header files self.requires("openexr/2.5.7") @@ -89,7 +89,7 @@ def requirements(self): if self.options.with_jxr: self.requires("jxrlib/cci.20170615") if self.options.with_tiff: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") def validate(self): if self.settings.compiler.get_safe("cppstd"): From 59852df9d4f477be6a29f5784744c21678d9b148 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 1 Oct 2023 06:32:07 +0200 Subject: [PATCH 0883/1140] (#20229) sail/all: bump deps --- recipes/sail/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/sail/all/conanfile.py b/recipes/sail/all/conanfile.py index 31e7177ae090ee..b4491bf3957587 100644 --- a/recipes/sail/all/conanfile.py +++ b/recipes/sail/all/conanfile.py @@ -58,15 +58,15 @@ def requirements(self): if self.options.with_jpeg2000: self.requires("jasper/4.0.0") if self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") if self.options.with_png: self.requires("libpng/1.6.40") if self.options.with_tiff: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") if self.options.with_webp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") def layout(self): cmake_layout(self, src_folder="src") From db9a2262a0364887fb569738ce9e5486077cd677 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 1 Oct 2023 07:12:37 +0200 Subject: [PATCH 0884/1140] (#20230) leptonica/all: bump deps --- recipes/leptonica/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/leptonica/all/conanfile.py b/recipes/leptonica/all/conanfile.py index 2603c7965bfb49..e749f2b2e4eb16 100644 --- a/recipes/leptonica/all/conanfile.py +++ b/recipes/leptonica/all/conanfile.py @@ -78,16 +78,16 @@ def requirements(self): if self.options.with_png: self.requires("libpng/1.6.40") if self.options.with_tiff: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") if self.options.with_openjpeg: self.requires("openjpeg/2.5.0") if self.options.with_webp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") def build_requirements(self): if self.options.with_webp or self.options.with_openjpeg: if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 0c4a3ccac4e8c7f9dbc3470acea52ffeb898bf19 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 15:53:39 +0900 Subject: [PATCH 0885/1140] (#19930) libsystemd: add version 253.10, update dependencies * libsystemd: add version 253.10, update dependencies * fix version number --- recipes/libsystemd/all/conandata.yml | 10 ++++++++++ recipes/libsystemd/all/conanfile.py | 8 ++++---- recipes/libsystemd/config.yml | 2 ++ 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/recipes/libsystemd/all/conandata.yml b/recipes/libsystemd/all/conandata.yml index d4431fac17cc4a..6908923204fe68 100644 --- a/recipes/libsystemd/all/conandata.yml +++ b/recipes/libsystemd/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "253.10": + url: "https://github.com/systemd/systemd-stable/archive/v253.10.tar.gz" + sha256: "7c869513b2ad015568e8e35304942f84378b0c59972cb44de5ac905b8eea08d4" "253.6": url: "https://github.com/systemd/systemd-stable/archive/v253.6.tar.gz" sha256: "a0aebcfaa2e001a4d846691631d1722c4cfa1a175e4ea62db6edca0ea3cf1e3e" @@ -24,6 +27,13 @@ sources: url: "https://github.com/systemd/systemd-stable/archive/v246.16.tar.gz" sha256: "b69f9940d65870f090269a28f1047a633d4b80d0001e091d53a031dd40a822d2" patches: + "253.10": + - patch_file: "patches/253.3/0001-missing_syscalls.py-Replace-unicode-with-ascii.patch" + patch_description: "allow to use meson.build with older versions of Python by replacing utf8 message to ascii message in the helper script" + patch_type: "conan" + - patch_file: "patches/251.15/0001-Remove-dependency-from-coreutils.patch" + patch_description: "allow to build in environments without 'realpath --relative-to' by replacing it with conan-specific build variable" + patch_type: "conan" "253.6": - patch_file: "patches/253.3/0001-missing_syscalls.py-Replace-unicode-with-ascii.patch" patch_description: "allow to use meson.build with older versions of Python by replacing utf8 message to ascii message in the helper script" diff --git a/recipes/libsystemd/all/conanfile.py b/recipes/libsystemd/all/conanfile.py index 0836b21234ebc0..7267a019ded534 100644 --- a/recipes/libsystemd/all/conanfile.py +++ b/recipes/libsystemd/all/conanfile.py @@ -52,7 +52,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("libcap/2.68") + self.requires("libcap/2.69") self.requires("libmount/2.39") if Version(self.version) >= "253.6": self.requires("libxcrypt/4.4.35") @@ -61,7 +61,7 @@ def requirements(self): if self.options.with_lz4: self.requires("lz4/1.9.4") if self.options.with_xz: - self.requires("xz_utils/5.4.2") + self.requires("xz_utils/5.4.4") if self.options.with_zstd: self.requires("zstd/1.5.5") @@ -70,11 +70,11 @@ def validate(self): raise ConanInvalidConfiguration("Only Linux supported") def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.1") self.tool_requires("m4/1.4.19") self.tool_requires("gperf/3.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/libsystemd/config.yml b/recipes/libsystemd/config.yml index f5844863606911..e30829e3e34741 100644 --- a/recipes/libsystemd/config.yml +++ b/recipes/libsystemd/config.yml @@ -1,4 +1,6 @@ versions: + "253.10": + folder: all "253.6": folder: all "253.3": From ed4879397c792a136ea3a3b6817595f143668441 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 1 Oct 2023 10:12:43 +0200 Subject: [PATCH 0886/1140] (#20231) platform.converters: improve compiler versions checks for msvc and cleanup a little bit --- recipes/platform.converters/all/conanfile.py | 25 ++++++++++---------- 1 file changed, 12 insertions(+), 13 deletions(-) diff --git a/recipes/platform.converters/all/conanfile.py b/recipes/platform.converters/all/conanfile.py index 2979e31430f9ba..898832d2cd9d42 100644 --- a/recipes/platform.converters/all/conanfile.py +++ b/recipes/platform.converters/all/conanfile.py @@ -7,12 +7,15 @@ from conan.tools.layout import basic_layout from conan.tools.scm import Version -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.50.0" class PlatformConvertersConan(ConanFile): name = "platform.converters" - description = "platform.converters is one of the libraries of the LinksPlatform modular framework, to provide conversions between different types" + description = ( + "platform.converters is one of the libraries of the LinksPlatform " + "modular framework, to provide conversions between different types" + ) license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/linksplatform/Converters" @@ -23,7 +26,7 @@ class PlatformConvertersConan(ConanFile): no_copy_source = True @property - def _minimum_cpp_standard(self): + def _min_cppstd(self): return 20 @property @@ -31,6 +34,7 @@ def _compilers_minimum_version(self): return { "gcc": "10", "Visual Studio": "16", + "msvc": "192", "clang": "14", "apple-clang": "14", } @@ -42,20 +46,15 @@ def package_id(self): self.info.clear() def validate(self): - minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) - - if not minimum_version: - self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) - elif Version(self.settings.compiler.version) < minimum_version: + minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler)) + if minimum_version and Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration( - f"{self.name}/{self.version} requires c++{self._minimum_cpp_standard}, " - f"which is not supported by {self.settings.compiler} {self.settings.compiler.version}." + f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support." ) - if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 6a162afec9514230c34bf52fc315ca29f02675d0 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 1 Oct 2023 11:15:27 +0200 Subject: [PATCH 0887/1140] (#20236) cmake/binary: add version 3.27.6 & 3.26.5, remove older versions --- recipes/cmake/binary/conandata.yml | 79 ++++++++++++------------------ recipes/cmake/config.yml | 8 ++- 2 files changed, 33 insertions(+), 54 deletions(-) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index 3eb4a53d2fff43..e31c9995f80312 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.6": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.6-linux-aarch64.tar.gz" + sha256: "811e5040ad7f3fb4924a875373d2a1a174a01400233a81a638a989157438a5e3" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.6-linux-x86_64.tar.gz" + sha256: "26373a283daa8490d772dc8a179450cd6d391cb2a9db8d4242fe09e361efc42e" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.6-macos10.10-universal.tar.gz" + sha256: "3977258c8d30f03f6506fdb12dac9b8570db7d5e54f541285ee540de433a9cff" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.6-windows-arm64.zip" + sha256: "980b7e532d77bfb4e5814c76403242c503019f1c0699440220cf2d527c8ff350" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.6-windows-x86_64.zip" + sha256: "f013a0cca091aa953f9a60a99292ec7a20ae3f9ceb05cb5c08ebe164097c526f" "3.27.5": Linux: armv8: @@ -37,63 +56,25 @@ sources: x86_64: url: "https://cmake.org/files/v3.27/cmake-3.27.4-windows-x86_64.zip" sha256: "e5e060756444d0b2070328a8821c1ceb62bd6d267aae61bfff06f96c7ec943a6" - "3.27.1": - Linux: - armv8: - url: "https://cmake.org/files/v3.27/cmake-3.27.1-linux-aarch64.tar.gz" - sha256: "812e32b569bcfb61f5ededdec244c4fddcd18d2c352a902ef88ed7d02005b2bd" - x86_64: - url: "https://cmake.org/files/v3.27/cmake-3.27.1-linux-x86_64.tar.gz" - sha256: "9fef63e1cf87cab1153f9433045df2e43c336e462518b0f5e52d2cc91d762cff" - Macos: - universal: - url: "https://cmake.org/files/v3.27/cmake-3.27.1-macos10.10-universal.tar.gz" - sha256: "3f9b1b6c29369d2b4e71991420966599a378b01f84e6420d5e881946a04debed" - Windows: - armv8: - url: "https://cmake.org/files/v3.27/cmake-3.27.1-windows-arm64.zip" - sha256: "588576bd73f20a851de053571a3ccb9bfe28446b5952ea62918dd273da608183" - x86_64: - url: "https://cmake.org/files/v3.27/cmake-3.27.1-windows-x86_64.zip" - sha256: "664fe1655999f0b693d1e64ddb430191c727ab0a03dc1da7278f291172e1e04e" - "3.27.0": - Linux: - armv8: - url: "https://cmake.org/files/v3.27/cmake-3.27.0-linux-aarch64.tar.gz" - sha256: "97c2f8cf9e063a7acf9f15ed472d87c511bf5cb62d3e42b9c90524fb0c2e4748" - x86_64: - url: "https://cmake.org/files/v3.27/cmake-3.27.0-linux-x86_64.tar.gz" - sha256: "89c7e74d29f442e4734954310e09dd12d13636991f2d90d0ed1bececb8bf9b9c" - Macos: - universal: - url: "https://cmake.org/files/v3.27/cmake-3.27.0-macos10.10-universal.tar.gz" - sha256: "dd9a7a8d5bd7d20b694eda8ff9c31147a5e1faa3bca1099836cfa0f81f8d5809" - Windows: - armv8: - url: "https://cmake.org/files/v3.27/cmake-3.27.0-windows-arm64.zip" - sha256: "9345cbbb25cb5e8f3c68db067151a013c628783edbfc6fcf622ae58900aa8ad3" - x86_64: - url: "https://cmake.org/files/v3.27/cmake-3.27.0-windows-x86_64.zip" - sha256: "fc5f901ef4d438eafbe35b24c608d5de11e517f157b3b7ab8ebbaa7c3c0171d2" - "3.26.4": + "3.26.5": Linux: armv8: - url: "https://cmake.org/files/v3.26/cmake-3.26.4-linux-aarch64.tar.gz" - sha256: "1c9843c92f40bee1a16baa12871693d3e190c9a222259a89e406d4d9aae6cf74" + url: "https://cmake.org/files/v3.26/cmake-3.26.5-linux-aarch64.tar.gz" + sha256: "737b990dcbc71f060b75193b2ddd5cf9d18c199e7a94c7169c80cf9314fe714a" x86_64: - url: "https://cmake.org/files/v3.26/cmake-3.26.4-linux-x86_64.tar.gz" - sha256: "ba1e0dcc710e2f92be6263f9617510b3660fa9dc409ad2fb8190299563f952a0" + url: "https://cmake.org/files/v3.26/cmake-3.26.5-linux-x86_64.tar.gz" + sha256: "130941ae3ffe4a9ee3395514787115a273a8d1ce15cb971494bb45f7e58bb3c3" Macos: universal: - url: "https://cmake.org/files/v3.26/cmake-3.26.4-macos10.10-universal.tar.gz" - sha256: "f30362daae58788ada07f9f0fe2b49a53dde4262e2d8fe73640045d9d6055183" + url: "https://cmake.org/files/v3.26/cmake-3.26.5-macos10.10-universal.tar.gz" + sha256: "30ff04703b5973414decde82860045afdf88e6da381aca6aeb2d625b05f53f2d" Windows: armv8: - url: "https://cmake.org/files/v3.26/cmake-3.26.4-windows-arm64.zip" - sha256: "6a9b28f318e766e40ac032b7fd2064fa9e026ff329f0ea175cbc8b15af51c45c" + url: "https://cmake.org/files/v3.26/cmake-3.26.5-windows-arm64.zip" + sha256: "1d5dd0e8a316290944e3c84bd6950df7ff650c5edde311af8903e88cb6cbc0ae" x86_64: - url: "https://cmake.org/files/v3.26/cmake-3.26.4-windows-x86_64.zip" - sha256: "62c35427104a4f8205226f72708d71334bd36a72cf72c60d0e3a766d71dcc78a" + url: "https://cmake.org/files/v3.26/cmake-3.26.5-windows-x86_64.zip" + sha256: "b95d6d8113593e001ae64df615358ea47185ad52a79d0c420332e052bd30c283" "3.25.3": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 179f7ccf1c5b2c..88d76a326d17c4 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -1,13 +1,11 @@ versions: + "3.27.6": + folder: "binary" "3.27.5": folder: "binary" "3.27.4": folder: "binary" - "3.27.1": - folder: "binary" - "3.27.0": - folder: "binary" - "3.26.4": + "3.26.5": folder: "binary" "3.25.3": folder: "binary" From 379b49d35add03d226631e75830379ac2130e058 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 18:54:56 +0900 Subject: [PATCH 0888/1140] (#20237) libzippp: add version 7.0-1.10.1 * libzippp: add version 7.0-1.10.1 * fix version number --- recipes/libzippp/all/conandata.yml | 3 +++ recipes/libzippp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libzippp/all/conandata.yml b/recipes/libzippp/all/conandata.yml index 90151532c90b56..20f731c93139a0 100644 --- a/recipes/libzippp/all/conandata.yml +++ b/recipes/libzippp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "7.0-1.10.1": + url: "https://github.com/ctabin/libzippp/archive/libzippp-v7.0-1.10.1.tar.gz" + sha256: "67d6808406b4fc255016ede52c7b5105e2d0e43899a3331de9ed86da5dea07a1" "6.1-1.9.2": url: "https://github.com/ctabin/libzippp/archive/libzippp-v6.1-1.9.2.tar.gz" sha256: "3796f174780f23938749da493cf4cbc4c55f84a568ec395f2c256dfe10129305" diff --git a/recipes/libzippp/config.yml b/recipes/libzippp/config.yml index f715620c8ae878..ce3931e22d5f51 100644 --- a/recipes/libzippp/config.yml +++ b/recipes/libzippp/config.yml @@ -1,4 +1,6 @@ versions: + "7.0-1.10.1": + folder: all "6.1-1.9.2": folder: all "6.0-1.9.2": From ed8251da06a8d082227745ac0d30b0930adccd0d Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 1 Oct 2023 12:59:32 +0200 Subject: [PATCH 0889/1140] (#19692) harfbuzz: add version 8.2.1 * harfbuzz: add version 8.2.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * 8.2.1 --------- Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/harfbuzz/all/conandata.yml | 3 +++ recipes/harfbuzz/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/harfbuzz/all/conandata.yml b/recipes/harfbuzz/all/conandata.yml index d165dd235addde..779ff0fde3b71c 100644 --- a/recipes/harfbuzz/all/conandata.yml +++ b/recipes/harfbuzz/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.2.1": + url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.2.1/harfbuzz-8.2.1.tar.xz" + sha256: "0fec78f98c9c8faf228957a201c8846f809452c20f8445eb092a1ba6f22dbea5" "8.1.1": url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.1.1/harfbuzz-8.1.1.tar.xz" sha256: "0305ad702e11906a5fc0c1ba11c270b7f64a8f5390d676aacfd71db129d6565f" diff --git a/recipes/harfbuzz/config.yml b/recipes/harfbuzz/config.yml index 502391a71084d7..bff626c84bf864 100644 --- a/recipes/harfbuzz/config.yml +++ b/recipes/harfbuzz/config.yml @@ -1,4 +1,6 @@ versions: + "8.2.1": + folder: all "8.1.1": folder: all "8.0.1": From 4fad619d446d82ca5f8e96397c4a19ea28e1844b Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Sun, 1 Oct 2023 14:04:18 +0200 Subject: [PATCH 0890/1140] (#20238) [highs] bump version to 1.6.0 --- recipes/highs/all/conandata.yml | 3 +++ recipes/highs/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/highs/all/conandata.yml b/recipes/highs/all/conandata.yml index 373553d2ba8bb5..c88418f873ba76 100644 --- a/recipes/highs/all/conandata.yml +++ b/recipes/highs/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.6.0": + url: "https://github.com/ERGO-Code/HiGHS/archive/refs/tags/v1.6.0.tar.gz" + sha256: "71962981566477c72c51b8b722c5df053d857b05b4f0e6869f455f657b3aa193" "1.5.3": url: "https://github.com/ERGO-Code/HiGHS/archive/refs/tags/v1.5.3.tar.gz" sha256: "ce1a7d2f008e60cc69ab06f8b16831bd0fcd5f6002d3bbebae9d7a3513a1d01d" diff --git a/recipes/highs/config.yml b/recipes/highs/config.yml index 03874f3b487549..ba8bd2230d031d 100644 --- a/recipes/highs/config.yml +++ b/recipes/highs/config.yml @@ -1,4 +1,6 @@ versions: + "1.6.0": + folder: all "1.5.3": folder: all "1.4.2": From 5196dec872f824be2b977551985e982de456555a Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 1 Oct 2023 22:50:03 +0900 Subject: [PATCH 0891/1140] (#20240) cpp-httplib: add version 0.14.1 * cpp-httplib: add version 0.14.1 * add version to config.yml --- recipes/cpp-httplib/all/conandata.yml | 3 +++ recipes/cpp-httplib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cpp-httplib/all/conandata.yml b/recipes/cpp-httplib/all/conandata.yml index cf312a0b54c1d0..89e0040b5d9cb5 100644 --- a/recipes/cpp-httplib/all/conandata.yml +++ b/recipes/cpp-httplib/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.14.1": + url: "https://github.com/yhirose/cpp-httplib/archive/v0.14.1.tar.gz" + sha256: "2d4fb5544da643e5d0a82585555d8b7502b4137eb321a4abbb075e21d2f00e96" "0.14.0": url: "https://github.com/yhirose/cpp-httplib/archive/v0.14.0.tar.gz" sha256: "3a92248ef8cf2c32ad07f910b8e3052ff2427022b2adb871cf326fb620d2438e" diff --git a/recipes/cpp-httplib/config.yml b/recipes/cpp-httplib/config.yml index 3a4d3cd3226a9c..44182a765684d0 100644 --- a/recipes/cpp-httplib/config.yml +++ b/recipes/cpp-httplib/config.yml @@ -1,4 +1,6 @@ versions: + "0.14.1": + folder: all "0.14.0": folder: all "0.13.3": From eb5ed3bc1d01a734918005b9df97ac795460220a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 1 Oct 2023 19:18:52 +0300 Subject: [PATCH 0892/1140] (#20031) libsvm: add version 332 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libsvm/all/conandata.yml | 3 +++ recipes/libsvm/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libsvm/all/conandata.yml b/recipes/libsvm/all/conandata.yml index 5712311441eb33..4ce3fd15b7dbaa 100644 --- a/recipes/libsvm/all/conandata.yml +++ b/recipes/libsvm/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "332": + url: "https://github.com/cjlin1/libsvm/archive/v332.tar.gz" + sha256: "e1d7d316112d199ebd69c9695f79226d236b86e2c8d88e70cfe35fd383954ed8" "330": url: "https://github.com/cjlin1/libsvm/archive/v330.tar.gz" sha256: "e4fe41308c87cc210aec73e4f5f0fb4da14234d90e7a131763fbad3788ca2d80" diff --git a/recipes/libsvm/config.yml b/recipes/libsvm/config.yml index 026fbb9e303568..c1b9e6f3043949 100644 --- a/recipes/libsvm/config.yml +++ b/recipes/libsvm/config.yml @@ -1,4 +1,6 @@ versions: + "332": + folder: all "330": folder: all "325": From ac3227cc025973eaf679a7f7cea84758638e3261 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sun, 1 Oct 2023 20:48:46 +0200 Subject: [PATCH 0893/1140] (#19417) glib/all: bump libgettext * glib/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glib/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glib/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * glib/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * print meson log in case of failure * fix libintl discovery * remove outdated versions * fix 2.75.3 patch * remove more outdated versions * fixup conandata.yml * fixup pcre2 component * remove unused import * revert unrelated changes * Update conanfile.py --- recipes/glib/all/conandata.yml | 40 ++++----------- recipes/glib/all/conanfile.py | 31 ++---------- .../0001-2.73.3-clang-static-assert.patch | 33 ------------- .../patches/libintl-discovery-2.75.3.patch | 49 +++++++++++++++++++ .../glib/all/patches/libintl-discovery.patch | 49 +++++++++++++++++++ recipes/glib/config.yml | 18 ------- 6 files changed, 112 insertions(+), 108 deletions(-) delete mode 100644 recipes/glib/all/patches/0001-2.73.3-clang-static-assert.patch create mode 100644 recipes/glib/all/patches/libintl-discovery-2.75.3.patch create mode 100644 recipes/glib/all/patches/libintl-discovery.patch diff --git a/recipes/glib/all/conandata.yml b/recipes/glib/all/conandata.yml index b749d7ac74580a..2288ee67fc7c68 100644 --- a/recipes/glib/all/conandata.yml +++ b/recipes/glib/all/conandata.yml @@ -17,39 +17,17 @@ sources: "2.76.3": url: "https://download.gnome.org/sources/glib/2.76/glib-2.76.3.tar.xz" sha256: "c0be444e403d7c3184d1f394f89f0b644710b5e9331b54fa4e8b5037813ad32a" - "2.76.2": - url: "https://download.gnome.org/sources/glib/2.76/glib-2.76.2.tar.xz" - sha256: "24f3847857b1d8674cdb0389a36edec0f13c666cd3ce727ecd340eb9da8aca9e" - "2.76.1": - url: "https://download.gnome.org/sources/glib/2.76/glib-2.76.1.tar.xz" - sha256: "43dc0f6a126958f5b454136c4398eab420249c16171a769784486e25f2fda19f" - "2.76.0": - url: "https://download.gnome.org/sources/glib/2.76/glib-2.76.0.tar.xz" - sha256: "525bb703b807142e1aee5ccf222c344e8064b21c0c45677ef594e587874c6797" "2.75.3": url: "https://download.gnome.org/sources/glib/2.75/glib-2.75.3.tar.xz" sha256: "7c517d0aff456c35a039bce8a8df7a08ce95a8285b09d1849f8865f633f7f871" - "2.75.2": - url: "https://download.gnome.org/sources/glib/2.75/glib-2.75.2.tar.xz" - sha256: "360d6fb75202c0eb0d07f0ab812b19b526f1c05ccc0a8ed7e5d2c988616d343a" - "2.75.1": - url: "https://download.gnome.org/sources/glib/2.75/glib-2.75.1.tar.xz" - sha256: "96fd22355a542cca96c31082f2d09b72cb5a3454b6ea60c1be17c987a18a6b93" - "2.75.0": - url: "https://download.gnome.org/sources/glib/2.75/glib-2.75.0.tar.xz" - sha256: "6dde8e55cc4a2c83d96797120b08bcffb5f645b2e212164ae22d63c40e0e6360" - "2.74.1": - url: "https://download.gnome.org/sources/glib/2.74/glib-2.74.1.tar.xz" - sha256: "0ab981618d1db47845e56417b0d7c123f81a3427b2b9c93f5a46ff5bbb964964" - "2.73.3": - url: "https://download.gnome.org/sources/glib/2.73/glib-2.73.3.tar.xz" - sha256: "df1a2b841667d6b48b2ef6969ebda4328243829f6e45866726f806f90f64eead" - "2.72.4": - url: "https://download.gnome.org/sources/glib/2.72/glib-2.72.4.tar.xz" - sha256: "8848aba518ba2f4217d144307a1d6cb9afcc92b54e5c13ac1f8c4d4608e96f0e" patches: - "2.73.3": - - patch_file: "patches/0001-2.73.3-clang-static-assert.patch" + "2.76.3": + - patch_file: "patches/libintl-discovery.patch" + patch_type: bugfix + patch_description: fix libintl discovery + patch_source: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/3352 + "2.75.3": + - patch_file: "patches/libintl-discovery-2.75.3.patch" patch_type: bugfix - patch_description: fix for clang compilation - patch_source: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/2898 + patch_description: fix libintl discovery + patch_source: https://gitlab.gnome.org/GNOME/glib/-/merge_requests/3352 diff --git a/recipes/glib/all/conanfile.py b/recipes/glib/all/conanfile.py index a90b8bbde49a84..fa5bd0a44e4c3f 100644 --- a/recipes/glib/all/conanfile.py +++ b/recipes/glib/all/conanfile.py @@ -6,7 +6,6 @@ from conan.tools.layout import basic_layout from conan.tools.meson import Meson, MesonToolchain from conan.tools.microsoft import is_msvc -from conan.tools.scm import Version import os import shutil @@ -67,10 +66,7 @@ def layout(self): def requirements(self): self.requires("zlib/[>=1.2.11 <2]") self.requires("libffi/3.4.4") - if Version(self.version) >= "2.73.2": - self.requires("pcre2/10.42") - else: - self.requires("pcre/8.45") + self.requires("pcre2/10.42") if self.options.get_safe("with_elf"): self.requires("libelf/0.8.13") if self.options.get_safe("with_mount"): @@ -79,7 +75,7 @@ def requirements(self): self.requires("libselinux/3.3") if self.settings.os != "Linux": # for Linux, gettext is provided by libc - self.requires("libgettext/0.21", transitive_headers=True, transitive_libs=True) + self.requires("libgettext/0.22", transitive_headers=True, transitive_libs=True) if is_apple_os(self): self.requires("libiconv/1.17") @@ -99,8 +95,6 @@ def generate(self): tc.generate() tc = MesonToolchain(self) - if is_apple_os(self) and Version(self.version) < "2.75.1": - tc.project_options["iconv"] = "external" # https://gitlab.gnome.org/GNOME/glib/issues/1557 tc.project_options["selinux"] = "enabled" if self.options.get_safe("with_selinux") else "disabled" tc.project_options["libmount"] = "enabled" if self.options.get_safe("with_mount") else "disabled" if self.settings.os == "FreeBSD": @@ -116,20 +110,11 @@ def _patch_sources(self): "subdir('fuzzing')", "#subdir('fuzzing')", ) # https://gitlab.gnome.org/GNOME/glib/-/issues/2152 - if Version(self.version) < "2.73.2": - for filename in [ - os.path.join(self.source_folder, "meson.build"), - os.path.join(self.source_folder, "glib", "meson.build"), - os.path.join(self.source_folder, "gobject", "meson.build"), - os.path.join(self.source_folder, "gio", "meson.build"), - ]: - replace_in_file(self, filename, "subdir('tests')", "#subdir('tests')") if self.settings.os != "Linux": # allow to find gettext replace_in_file(self, os.path.join(self.source_folder, "meson.build"), - "libintl = cc.find_library('intl', required : false" if Version(self.version) < "2.73.1" \ - else "libintl = dependency('intl', required: false", + "libintl = dependency('intl', required: false", "libintl = dependency('libgettext', method : 'pkg-config', required : false", ) @@ -152,10 +137,7 @@ def build(self): meson.build() def package(self): - if Version(self.version) < "2.73.0": - copy(self, pattern="COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) - else: - copy(self, pattern="LGPL-2.1-or-later.txt", dst=os.path.join(self.package_folder, "licenses"), src=os.path.join(self.source_folder, "LICENSES")) + copy(self, pattern="LGPL-2.1-or-later.txt", dst=os.path.join(self.package_folder, "licenses"), src=os.path.join(self.source_folder, "LICENSES")) meson = Meson(self) meson.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) @@ -234,10 +216,7 @@ def package_info(self): if is_apple_os(self): self.cpp_info.components["glib-2.0"].requires.append("libiconv::libiconv") - if Version(self.version) >= "2.73.2": - self.cpp_info.components["glib-2.0"].requires.append("pcre2::pcre2") - else: - self.cpp_info.components["glib-2.0"].requires.append("pcre::pcre") + self.cpp_info.components["glib-2.0"].requires.append("pcre2::pcre2") if self.settings.os == "Linux": self.cpp_info.components["gio-2.0"].system_libs.append("resolv") diff --git a/recipes/glib/all/patches/0001-2.73.3-clang-static-assert.patch b/recipes/glib/all/patches/0001-2.73.3-clang-static-assert.patch deleted file mode 100644 index c46f5e071d71cd..00000000000000 --- a/recipes/glib/all/patches/0001-2.73.3-clang-static-assert.patch +++ /dev/null @@ -1,33 +0,0 @@ -diff --git a/gio/gio-launch-desktop.c b/gio/gio-launch-desktop.c -index 29bf9d5d4..47717b987 100644 ---- a/gio/gio-launch-desktop.c -+++ b/gio/gio-launch-desktop.c -@@ -39,7 +39,6 @@ - - #if defined(__linux__) && !defined(__BIONIC__) - #include --#include - #include - #include - #include -@@ -48,6 +47,9 @@ - #include - - #include "gjournal-private.h" -+#define GLIB_COMPILATION -+#include "gmacros.h" /* For G_STATIC_ASSERT define */ -+#undef GLIB_COMPILATION - - /* - * write_all: -@@ -119,8 +121,8 @@ journal_stream_fd (const char *identifier, - /* Arbitrary large size for the sending buffer, from systemd */ - int large_buffer_size = 8 * 1024 * 1024; - -- static_assert (LOG_EMERG == 0, "Linux ABI defines LOG_EMERG"); -- static_assert (LOG_DEBUG == 7, "Linux ABI defines LOG_DEBUG"); -+ G_STATIC_ASSERT (LOG_EMERG == 0 && sizeof "Linux ABI defines LOG_EMERG"); -+ G_STATIC_ASSERT (LOG_DEBUG == 7 && sizeof "Linux ABI defines LOG_DEBUG"); - - fd = socket (AF_UNIX, SOCK_STREAM | SOCK_CLOEXEC, 0); - diff --git a/recipes/glib/all/patches/libintl-discovery-2.75.3.patch b/recipes/glib/all/patches/libintl-discovery-2.75.3.patch new file mode 100644 index 00000000000000..0df94096d06153 --- /dev/null +++ b/recipes/glib/all/patches/libintl-discovery-2.75.3.patch @@ -0,0 +1,49 @@ +From 32249a22fc39319651e7c23442d37ec837f05764 Mon Sep 17 00:00:00 2001 +From: Nirbheek Chauhan +Date: Thu, 8 Sep 2022 02:36:33 +0530 +Subject: [PATCH] meson: Fix detection of a system-provided proxy-libintl + +proxy-libintl defines ngettext() as a define in the header that points +to the actual symbol in the library which is g_libintl_ngettext(). +Same with bind_textdomain_codeset(). +--- + meson.build | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +diff --git a/meson.build b/meson.build +index 0cbc9689f5..de0bee5a39 100644 +--- a/meson.build ++++ b/meson.build +@@ -2088,6 +2088,7 @@ libz_dep = dependency('zlib') + # FIXME: glib-gettext.m4 has much more checks to detect broken/uncompatible + # implementations. This could be extended if issues are found in some platforms. + libintl_deps = [] ++libintl_prefix = '#include ' + libintl = dependency('intl', required: false, allow_fallback: false) + if libintl.found() + # libintl supports different threading APIs, which may not +@@ -2099,11 +2100,11 @@ if libintl.found() + # + # Meson's builtin dependency lookup as of 0.60.0 doesn't check for + # pthread, so we do this manually here. +- if cc.has_function('ngettext', dependencies : libintl) ++ if cc.has_function('ngettext', dependencies : libintl, prefix: libintl_prefix) + libintl_deps += [libintl] + else + libintl_pthread = cc.find_library('pthread', required : false) +- if libintl_pthread.found() and cc.has_function('ngettext', dependencies : [libintl, libintl_pthread]) ++ if libintl_pthread.found() and cc.has_function('ngettext', dependencies : [libintl, libintl_pthread], prefix: libintl_prefix) + libintl_deps += [libintl, libintl_pthread] + else + libintl = disabler() +@@ -2112,7 +2113,7 @@ if libintl.found() + endif + + if libintl.found() +- have_bind_textdomain_codeset = cc.has_function('bind_textdomain_codeset', dependencies: libintl_deps) ++ have_bind_textdomain_codeset = cc.has_function('bind_textdomain_codeset', dependencies: libintl_deps, prefix: libintl_prefix) + else + libintl = dependency('intl', allow_fallback: true) + assert(libintl.type_name() == 'internal') +-- +GitLab diff --git a/recipes/glib/all/patches/libintl-discovery.patch b/recipes/glib/all/patches/libintl-discovery.patch new file mode 100644 index 00000000000000..17083da96cd176 --- /dev/null +++ b/recipes/glib/all/patches/libintl-discovery.patch @@ -0,0 +1,49 @@ +From 32249a22fc39319651e7c23442d37ec837f05764 Mon Sep 17 00:00:00 2001 +From: Nirbheek Chauhan +Date: Thu, 8 Sep 2022 02:36:33 +0530 +Subject: [PATCH] meson: Fix detection of a system-provided proxy-libintl + +proxy-libintl defines ngettext() as a define in the header that points +to the actual symbol in the library which is g_libintl_ngettext(). +Same with bind_textdomain_codeset(). +--- + meson.build | 7 ++++--- + 1 file changed, 4 insertions(+), 3 deletions(-) + +diff --git a/meson.build b/meson.build +index 0cbc9689f5..de0bee5a39 100644 +--- a/meson.build ++++ b/meson.build +@@ -2089,6 +2089,7 @@ libz_dep = dependency('zlib') + # FIXME: glib-gettext.m4 has much more checks to detect broken/uncompatible + # implementations. This could be extended if issues are found in some platforms. + libintl_deps = [] ++libintl_prefix = '#include ' + libintl = dependency('intl', required: false, allow_fallback: false) + if libintl.found() + # libintl supports different threading APIs, which may not +@@ -2100,11 +2101,11 @@ if libintl.found() + # + # Meson's builtin dependency lookup as of 0.60.0 doesn't check for + # pthread, so we do this manually here. +- if cc.has_function('ngettext', dependencies : libintl) ++ if cc.has_function('ngettext', dependencies : libintl, prefix: libintl_prefix) + libintl_deps += [libintl] + else + libintl_pthread = cc.find_library('pthread', required : false) +- if libintl_pthread.found() and cc.has_function('ngettext', dependencies : [libintl, libintl_pthread]) ++ if libintl_pthread.found() and cc.has_function('ngettext', dependencies : [libintl, libintl_pthread], prefix: libintl_prefix) + libintl_deps += [libintl, libintl_pthread] + else + libintl = disabler() +@@ -2113,7 +2114,7 @@ if libintl.found() + endif + + if libintl.found() +- have_bind_textdomain_codeset = cc.has_function('bind_textdomain_codeset', dependencies: libintl_deps) ++ have_bind_textdomain_codeset = cc.has_function('bind_textdomain_codeset', dependencies: libintl_deps, prefix: libintl_prefix) + else + libintl = dependency('intl', allow_fallback: true) + assert(libintl.type_name() == 'internal') +-- +GitLab diff --git a/recipes/glib/config.yml b/recipes/glib/config.yml index 87471ca63de5f7..da0b056644c24d 100644 --- a/recipes/glib/config.yml +++ b/recipes/glib/config.yml @@ -11,23 +11,5 @@ versions: folder: all "2.76.3": folder: all - "2.76.2": - folder: all - "2.76.1": - folder: all - "2.76.0": - folder: all "2.75.3": folder: all - "2.75.2": - folder: all - "2.75.1": - folder: all - "2.75.0": - folder: all - "2.74.1": - folder: all - "2.73.3": - folder: all - "2.72.4": - folder: all From 4c9dfb022609353fe68d7be552bce26df82fc411 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 2 Oct 2023 00:09:37 +0300 Subject: [PATCH 0894/1140] (#20037) winflexbison: add v2.5.25 --- recipes/winflexbison/all/conandata.yml | 5 + .../patches/0001-2.5.25-mingw-support.patch | 177 ++++++++++++++++++ recipes/winflexbison/config.yml | 2 + 3 files changed, 184 insertions(+) create mode 100644 recipes/winflexbison/all/patches/0001-2.5.25-mingw-support.patch diff --git a/recipes/winflexbison/all/conandata.yml b/recipes/winflexbison/all/conandata.yml index c1a75693f1653c..44c1f53fdafb9d 100644 --- a/recipes/winflexbison/all/conandata.yml +++ b/recipes/winflexbison/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.5.25": + url: "https://github.com/lexxmark/winflexbison/archive/v2.5.25.tar.gz" + sha256: "8e1b71e037b524ba3f576babb0cf59182061df1f19cd86112f085a882560f60b" "2.5.24": url: "https://github.com/lexxmark/winflexbison/archive/v2.5.24.tar.gz" sha256: "a49d6e310636e3487e1e066e411d908cfeae2d5b5fde1f3cf74fe1d6d4301062" @@ -6,6 +9,8 @@ sources: url: "https://github.com/lexxmark/winflexbison/archive/v2.5.22.tar.gz" sha256: "697c2c4af3308625605b75498bd63a9a294660f8e43a4c35452cf4334fa4a530" patches: + "2.5.25": + - patch_file: "patches/0001-2.5.25-mingw-support.patch" "2.5.24": - patch_file: "patches/0001-2.5.24-mingw-support.patch" "2.5.22": diff --git a/recipes/winflexbison/all/patches/0001-2.5.25-mingw-support.patch b/recipes/winflexbison/all/patches/0001-2.5.25-mingw-support.patch new file mode 100644 index 00000000000000..54af813f752634 --- /dev/null +++ b/recipes/winflexbison/all/patches/0001-2.5.25-mingw-support.patch @@ -0,0 +1,177 @@ +--- bison/src/config.h ++++ bison/src/config.h +@@ -1,1 +1,2 @@ ++#pragma once + #define PACKAGE_BUGREPORT "https://github.com/lexxmark/winflexbison/issues" +--- bison/src/conflicts.c ++++ bison/src/conflicts.c +@@ -30,7 +30,7 @@ + #include "getargs.h" + #include "gram.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "print-xml.h" + #include "reader.h" + #include "state.h" +--- bison/src/lalr.c ++++ bison/src/lalr.c +@@ -33,7 +33,7 @@ + #include "getargs.h" + #include "gram.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "muscle-tab.h" + #include "nullable.h" + #include "reader.h" +--- bison/src/LR0.c ++++ bison/src/LR0.c +@@ -32,7 +32,7 @@ + #include "getargs.h" + #include "gram.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "reader.h" + #include "reduce.h" + #include "state.h" +--- bison/src/main.c ++++ bison/src/main.c +@@ -45,7 +45,7 @@ + #include "gram.h" + #include "ielr.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "muscle-tab.h" + #include "nullable.h" + #include "output.h" +--- bison/src/print.c ++++ bison/src/print.c +@@ -35,7 +35,7 @@ + #include "getargs.h" + #include "gram.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "muscle-tab.h" + #include "reader.h" + #include "reduce.h" +--- bison/src/print-graph.c ++++ bison/src/print-graph.c +@@ -31,7 +31,7 @@ + #include "gram.h" + #include "graphviz.h" + #include "lalr.h" +-#include "lr0.h" ++#include "LR0.h" + #include "reader.h" + #include "state.h" + #include "symtab.h" +--- bison/src/print-xml.c ++++ bison/src/print-xml.c +@@ -37,1 +37,1 @@ +-#include "lr0.h" ++#include "LR0.h" +--- CMakeLists.txt ++++ CMakeLists.txt +@@ -2,23 +2,23 @@ + + project (winflexbison) + +-if(NOT MSVC) +- message( FATAL_ERROR "Visual Studio Build supported only" ) ++if(MSVC) ++ add_definitions(-D_CRT_SECURE_NO_WARNINGS) + endif() + +-add_definitions(-D_CRT_SECURE_NO_WARNINGS) ++ + + if(CMAKE_BUILD_TYPE STREQUAL "Debug") + add_definitions(-D_DEBUG) + endif() + + # next line needed for compile in C (nor CPP) mode (ucrt headers bug) + add_definitions(-Dinline=__inline) + # next line needed for VS2017 only + add_definitions(-Drestrict=__restrict) + +-set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /W3 /MD /Od /Zi /EHsc") +-set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /W3 /GL /Od /Oi /Gy /Zi /EHsc") ++#set(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /W3 /MD /Od /Zi /EHsc") ++#set(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /W3 /GL /Od /Oi /Gy /Zi /EHsc") + + # Define Release by default. + if(NOT CMAKE_BUILD_TYPE) +--- common/CMakeLists.txt ++++ common/CMakeLists.txt +@@ -4,6 +4,12 @@ + + project(${PROJECT_NAME} C) + ++include(CheckSymbolExists) ++check_symbol_exists(nanouptime "sys/time.h" HAVE_NANOUPTIME) ++check_symbol_exists(clock_gettime "time.h" HAVE_CLOCK_GETTIME) ++check_symbol_exists(microuptime "sys/time.h" HAVE_MICROUPTIME) ++check_symbol_exists(timespec_get "time.h" HAVE_TIMESPEC_GET) ++ + # Definition of Macros + add_definitions(-D_LIB) + +@@ -31,3 +37,9 @@ + add_library(${PROJECT_NAME} STATIC + ${SOURCE_FILES} + ) ++target_compile_definitions(${PROJECT_NAME} PRIVATE ++ $<$:HAVE_NANOUPTIME=1> ++ $<$:HAVE_CLOCK_GETTIME=1> ++ $<$:HAVE_MICROUPTIME=1> ++ $<$:HAVE_TIMESPEC_GET=1> ++) +--- common/m4/lib/clean-temp.h ++++ common/m4/lib/clean-temp.h +@@ -137,3 +137,3 @@ +- +-typedef int mode_t; +- ++#if defined _MSC_VER ++typedef int mode_t; ++#endif +--- common/misc/gethrxtime.c ++++ common/misc/gethrxtime.c +@@ -27,6 +27,6 @@ +-//#include + #include "timespec.h" +- ++#if HAVE_CLOCK_GETTIME ++#include ++#endif + /* Get the current time, as a count of the number of nanoseconds since + an arbitrary epoch (e.g., the system boot time). Prefer a +- high-resolution clock that is not subject to resetting or +@@ -49,8 +49,8 @@ + if (clock_gettime (CLOCK_MONOTONIC, &ts) == 0) + return xtime_make (ts.tv_sec, ts.tv_nsec); + } +-# endif +- ++# ++# else + # if HAVE_MICROUPTIME + { + struct timeval tv; +@@ -69,6 +69,6 @@ + } + # endif + # endif ++# endif + } +- + #endif +--- flex/CMakeLists.txt ++++ flex/CMakeLists.txt +@@ -25,1 +25,1 @@ +-target_link_libraries(${PROJECT_NAME} winflexbison_common kernel32.lib user32.lib) ++target_link_libraries(${PROJECT_NAME} winflexbison_common kernel32 user32) diff --git a/recipes/winflexbison/config.yml b/recipes/winflexbison/config.yml index 480280b1fb8e8b..4ae41b917c9169 100644 --- a/recipes/winflexbison/config.yml +++ b/recipes/winflexbison/config.yml @@ -1,4 +1,6 @@ versions: + "2.5.25": + folder: all "2.5.24": folder: all "2.5.22": From d8304db68b2edb9f635eb687940b4a4040c57344 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 00:40:12 +0200 Subject: [PATCH 0895/1140] (#20174) cassandra-cpp-driver: add package_type + bump boost + better way to package relocatable shared lib on macOS * better way to package relocatable shared libs on macOS * add package_type * bump boost * no self.info in validate() --- recipes/cassandra-cpp-driver/all/conanfile.py | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/recipes/cassandra-cpp-driver/all/conanfile.py b/recipes/cassandra-cpp-driver/all/conanfile.py index 91a6e9ffd905ae..5cfe8683bd139a 100644 --- a/recipes/cassandra-cpp-driver/all/conanfile.py +++ b/recipes/cassandra-cpp-driver/all/conanfile.py @@ -3,7 +3,6 @@ from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, replace_in_file, rm from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.build import check_min_cppstd -from conan.tools.apple import fix_apple_shared_install_name import os required_conan_version = ">=1.53.0" @@ -14,7 +13,8 @@ class CassandraCppDriverConan(ConanFile): license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://docs.datastax.com/en/developer/cpp-driver/" - topics = ("cassandra", "cpp-driver", "database",) + topics = ("cassandra", "cpp-driver", "database") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -70,10 +70,10 @@ def requirements(self): self.requires("zlib/[>=1.2.11 <2]") if self.options.use_atomic == "boost": - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def validate(self): - if self.info.settings.compiler.cppstd: + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) if self.options.use_atomic == "boost": @@ -123,6 +123,8 @@ def generate(self): if self.settings.os == "Linux": tc.variables["CASS_USE_TIMERFD"] = self.options.use_timerfd + # Relocatable shared lib on Macos + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" tc.generate() deps = CMakeDeps(self) @@ -147,7 +149,6 @@ def package(self): copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) cmake = CMake(self) cmake.install() - fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["cassandra" if self.options.shared else "cassandra_static"] From 37939ce2e965ee654b2af81df987f8172a7544f4 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 01:52:52 +0200 Subject: [PATCH 0896/1140] (#20175) ldns: relocatable shared lib on macOS + add package_type + version range for openssl * relocatable shared lib on macOS * add package_type * cleanup * version range for openssl --- recipes/ldns/all/conanfile.py | 17 +++++------------ 1 file changed, 5 insertions(+), 12 deletions(-) diff --git a/recipes/ldns/all/conanfile.py b/recipes/ldns/all/conanfile.py index b6e94e58b15d80..531318c15033cd 100644 --- a/recipes/ldns/all/conanfile.py +++ b/recipes/ldns/all/conanfile.py @@ -1,9 +1,9 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.apple import XCRun +from conan.tools.apple import fix_apple_shared_install_name, XCRun from conan.tools.build import cross_building from conan.tools.env import VirtualRunEnv -from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm +from conan.tools.files import copy, get, rm from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain from conan.tools.layout import basic_layout import os @@ -18,7 +18,7 @@ class LdnsConan(ConanFile): homepage = "https://www.nlnetlabs.nl/projects/ldns" description = "LDNS is a DNS library that facilitates DNS tool programming" topics = ("dns") - + package_type = "library" settings = "os", "compiler", "build_type", "arch" options = { "shared": [True, False], @@ -29,13 +29,6 @@ class LdnsConan(ConanFile): "fPIC": True, } - @property - def _settings_build(self): - return getattr(self, "settings_build", self.settings) - - def export_sources(self): - export_conandata_patches(self) - def config_options(self): if self.settings.os == "Windows": self.options.rm_safe("fPIC") @@ -50,7 +43,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1.1 <4]") def validate(self): if self.settings.os == "Windows": @@ -100,7 +93,6 @@ def generate(self): tc.generate() def build(self): - apply_conandata_patches(self) autotools = Autotools(self) autotools.configure() autotools.make() @@ -111,6 +103,7 @@ def package(self): autotools.install(target=target) rm(self, "*.la", os.path.join(self.package_folder, "lib")) copy(self, pattern="LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["ldns"] From 0ee5ff7ea298dee3ca2f7f941422f0c2b25711e3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 02:39:15 +0200 Subject: [PATCH 0897/1140] (#20000) serd: bump meson * bump meson * bump meson --- recipes/serd/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/serd/all/conanfile.py b/recipes/serd/all/conanfile.py index 038ad977840b24..b5008dc8cfa011 100644 --- a/recipes/serd/all/conanfile.py +++ b/recipes/serd/all/conanfile.py @@ -43,7 +43,7 @@ def layout(self): basic_layout(self, src_folder="src") def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.2") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 46643e6b89e46ecdc18dc1faf20e3a4971e6ae38 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 03:31:33 +0200 Subject: [PATCH 0898/1140] (#20176) xlsxio: relocatable shared libs on macOS + cleanup recipe a little bit * relocatable shared lib on macOS * remove useless VirtualBuildEnv * fix set_property - no cmake_find_mode both, there is no Find module file upstream, only a CMake config file - no explicit global pc file, there is none upstream, only pc files per component --- recipes/xlsxio/all/conanfile.py | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/recipes/xlsxio/all/conanfile.py b/recipes/xlsxio/all/conanfile.py index b5d3c01dc87ce2..7724a07d644647 100644 --- a/recipes/xlsxio/all/conanfile.py +++ b/recipes/xlsxio/all/conanfile.py @@ -1,7 +1,6 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout, CMakeDeps -from conan.tools.env import VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir from conan.tools.scm import Version import os @@ -74,9 +73,6 @@ def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): - tc = VirtualBuildEnv(self) - tc.generate() - tc = CMakeToolchain(self) tc.variables["BUILD_STATIC"] = not self.options.shared tc.variables["BUILD_SHARED"] = self.options.shared @@ -84,6 +80,8 @@ def generate(self): if Version(self.version) >= "0.2.34": tc.variables["WITH_MINIZIP_NG"] = self.options.with_minizip_ng tc.variables["WITH_WIDE"] = self.options.with_wide + # Relocatable shared lib on Macos + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" tc.generate() tc = CMakeDeps(self) @@ -108,10 +106,7 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "share")) def package_info(self): - self.cpp_info.set_property("cmake_find_mode", "both") self.cpp_info.set_property("cmake_file_name", "xlsxio") - self.cpp_info.set_property("cmake_module_file_name", "xlsxio") - self.cpp_info.set_property("pkg_config_name", "xlsxio") ziplib = "minizip::minizip" if self.options.with_libzip: @@ -122,7 +117,6 @@ def package_info(self): xlsxio_macro = "BUILD_XLSXIO_SHARED" if self.options.shared else "BUILD_XLSXIO_STATIC" self.cpp_info.components["xlsxio_read"].set_property("cmake_target_name", "xlsxio::xlsxio_read") - self.cpp_info.components["xlsxio_read"].set_property("cmake_module_target_name", "xlsxio::xlsxio_read") self.cpp_info.components["xlsxio_read"].set_property("pkg_config_name", "libxlsxio_read") self.cpp_info.components["xlsxio_read"].libs = ["xlsxio_read"] self.cpp_info.components["xlsxio_read"].requires = ["expat::expat", ziplib] @@ -131,7 +125,6 @@ def package_info(self): self.cpp_info.components["xlsxio_read"].defines.append(xlsxio_macro) self.cpp_info.components["xlsxio_write"].set_property("cmake_target_name", "xlsxio::xlsxio_write") - self.cpp_info.components["xlsxio_write"].set_property("cmake_module_target_name", "xlsxio::xlsxio_write") self.cpp_info.components["xlsxio_write"].set_property("pkg_config_name", "libxlsxio_write") self.cpp_info.components["xlsxio_write"].libs = ["xlsxio_write"] self.cpp_info.components["xlsxio_write"].requires = ["expat::expat", ziplib] @@ -141,7 +134,6 @@ def package_info(self): if self.options.with_wide: self.cpp_info.components["xlsxio_readw"].set_property("cmake_target_name", "xlsxio::xlsxio_readw") - self.cpp_info.components["xlsxio_readw"].set_property("cmake_module_target_name", "xlsxio::xlsxio_readw") self.cpp_info.components["xlsxio_readw"].set_property("pkg_config_name", "libxlsxio_readw") self.cpp_info.components["xlsxio_readw"].libs = ["xlsxio_readw"] self.cpp_info.components["xlsxio_readw"].requires = ["expat::expat", ziplib] From aadbe7b9cde83a4f79896a9a87fe3a58491eabe0 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 04:30:07 +0200 Subject: [PATCH 0899/1140] (#20178) shapelib: relocatable shared lib on macOS + add package_type * relocatable shared lib on macOS * add package_type --- recipes/shapelib/all/conandata.yml | 3 +++ recipes/shapelib/all/conanfile.py | 4 ++-- .../all/patches/0003-relocatable-shared-macos.patch | 10 ++++++++++ 3 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 recipes/shapelib/all/patches/0003-relocatable-shared-macos.patch diff --git a/recipes/shapelib/all/conandata.yml b/recipes/shapelib/all/conandata.yml index 5dde0cb6bfee12..16ed675c6719f7 100644 --- a/recipes/shapelib/all/conandata.yml +++ b/recipes/shapelib/all/conandata.yml @@ -12,3 +12,6 @@ patches: patch_description: "Use the standard BUILD_TESTING variable to control building tests" patch_source: "https://github.com/OSGeo/shapelib/pull/46" patch_type: "portability" + - patch_file: "patches/0003-relocatable-shared-macos.patch" + patch_description: "Relocatable shared lib on macOS" + patch_type: "conan" diff --git a/recipes/shapelib/all/conanfile.py b/recipes/shapelib/all/conanfile.py index 19059022ab189c..e9396ff670b11d 100644 --- a/recipes/shapelib/all/conanfile.py +++ b/recipes/shapelib/all/conanfile.py @@ -4,7 +4,7 @@ from conan.tools.cmake import CMake, cmake_layout, CMakeToolchain from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.54.0" class ShapelibConan(ConanFile): @@ -14,6 +14,7 @@ class ShapelibConan(ConanFile): topics = ("osgeo", "shapefile", "esri", "geospatial") homepage = "https://github.com/OSGeo/shapelib" url = "https://github.com/conan-io/conan-center-index" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -45,7 +46,6 @@ def source(self): def generate(self): tc = CMakeToolchain(self) - tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" tc.variables["BUILD_TESTING"] = False tc.variables["USE_RPATH"] = False tc.generate() diff --git a/recipes/shapelib/all/patches/0003-relocatable-shared-macos.patch b/recipes/shapelib/all/patches/0003-relocatable-shared-macos.patch new file mode 100644 index 00000000000000..5994e77d745e17 --- /dev/null +++ b/recipes/shapelib/all/patches/0003-relocatable-shared-macos.patch @@ -0,0 +1,10 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -117,7 +117,6 @@ set_target_properties(shp + PROPERTIES + SOVERSION ${shp_SOVERSION} + VERSION ${shp_VERSION} +- INSTALL_NAME_DIR "${CMAKE_INSTALL_LIBDIR}" + ) + + if(USE_RPATH) From a3d954d334f698a8662e1d68c8186be88e7f9f15 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Mon, 2 Oct 2023 05:11:47 +0200 Subject: [PATCH 0900/1140] (#20179) streamvbyte: relocatable shared lib for macOS * relocatable shared lib on macOS * add patch_source for install layout fix --- recipes/streamvbyte/all/conandata.yml | 7 ++++++- .../patches/1.0.0-0002-relocatable-shared-macos.patch | 9 +++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) create mode 100644 recipes/streamvbyte/all/patches/1.0.0-0002-relocatable-shared-macos.patch diff --git a/recipes/streamvbyte/all/conandata.yml b/recipes/streamvbyte/all/conandata.yml index a5dd541a0c7806..6ecc44a0710521 100644 --- a/recipes/streamvbyte/all/conandata.yml +++ b/recipes/streamvbyte/all/conandata.yml @@ -6,4 +6,9 @@ patches: "1.0.0": - patch_file: "patches/1.0.0-0001-fix-cmake.patch" patch_description: "fix install destination" - patch_type: "conan" + patch_source: "https://github.com/lemire/streamvbyte/pull/67" + patch_type: "portability" + - patch_file: "patches/1.0.0-0002-relocatable-shared-macos.patch" + patch_description: "Relocatable shared lib for macOS" + patch_source: "https://github.com/lemire/streamvbyte/pull/66" + patch_type: "portability" diff --git a/recipes/streamvbyte/all/patches/1.0.0-0002-relocatable-shared-macos.patch b/recipes/streamvbyte/all/patches/1.0.0-0002-relocatable-shared-macos.patch new file mode 100644 index 00000000000000..5d52b1fe170f0a --- /dev/null +++ b/recipes/streamvbyte/all/patches/1.0.0-0002-relocatable-shared-macos.patch @@ -0,0 +1,9 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -1,6 +1,4 @@ + cmake_minimum_required(VERSION 3.3) +- +-set(CMAKE_MACOSX_RPATH OFF) + project(STREAMVBYTE VERSION "1.0.0") + + set(STREAMVBYTE_LIB_VERSION "1.0.0" CACHE STRING "streamvbyte library version") From 9327dbb23e09d78e1064f4865693455d1e879ac7 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 2 Oct 2023 12:50:36 +0900 Subject: [PATCH 0901/1140] (#20246) clickhouse-cpp: add version 2.5.1 --- recipes/clickhouse-cpp/all/conandata.yml | 3 +++ recipes/clickhouse-cpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/clickhouse-cpp/all/conandata.yml b/recipes/clickhouse-cpp/all/conandata.yml index 21db8c747eb056..16d1b5fbe21b5c 100644 --- a/recipes/clickhouse-cpp/all/conandata.yml +++ b/recipes/clickhouse-cpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.5.1": + url: "https://github.com/ClickHouse/clickhouse-cpp/archive/refs/tags/v2.5.1.tar.gz" + sha256: "8942fc702eca1f656e59c680c7e464205bffea038b62c1a0ad1f794ee01e7266" "2.5.0": url: "https://github.com/ClickHouse/clickhouse-cpp/archive/refs/tags/v2.5.0.tar.gz" sha256: "7eead6beb47a64be9b1f12f2435f0fb6304e8363823ed72178c76faf0d835801" diff --git a/recipes/clickhouse-cpp/config.yml b/recipes/clickhouse-cpp/config.yml index ea52eed8663189..b99c6305af1052 100644 --- a/recipes/clickhouse-cpp/config.yml +++ b/recipes/clickhouse-cpp/config.yml @@ -1,4 +1,6 @@ versions: + "2.5.1": + folder: all "2.5.0": folder: all "2.4.0": From 21a447d5c930e7351d93e2991dfaea4e326d1d0f Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Mon, 2 Oct 2023 06:30:48 +0200 Subject: [PATCH 0902/1140] (#20249) xkbcommon: silence console log --- recipes/xkbcommon/all/conanfile.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/xkbcommon/all/conanfile.py b/recipes/xkbcommon/all/conanfile.py index 926843dcf8b92f..d6a9ac9f0458dc 100644 --- a/recipes/xkbcommon/all/conanfile.py +++ b/recipes/xkbcommon/all/conanfile.py @@ -171,9 +171,7 @@ def package_info(self): self.cpp_info.components["xkbcli-interactive-wayland"].requires.append("wayland-protocols::wayland-protocols") if Version(self.version) >= "1.0.0": - bindir = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bindir}") - self.env_info.PATH.append(bindir) + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) # unofficial, but required to avoid side effects (libxkbcommon component # "steals" the default global pkg_config name) From 4d9a5d9bd9b9d3fd69aca329d535f44eb95ee02d Mon Sep 17 00:00:00 2001 From: nerix Date: Mon, 2 Oct 2023 08:02:00 +0200 Subject: [PATCH 0903/1140] (#19820) libavif: Add version 1.0.1 Co-authored-by: Carlos Zoido --- recipes/libavif/all/conandata.yml | 7 ++++ ...001-disable-developer-only-codepaths.patch | 34 +++++++++++++++++++ recipes/libavif/config.yml | 2 ++ 3 files changed, 43 insertions(+) create mode 100644 recipes/libavif/all/patches/1.0.1-0001-disable-developer-only-codepaths.patch diff --git a/recipes/libavif/all/conandata.yml b/recipes/libavif/all/conandata.yml index 1889bd2ede18fd..853cd880f3a209 100644 --- a/recipes/libavif/all/conandata.yml +++ b/recipes/libavif/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.1": + url: "https://github.com/AOMediaCodec/libavif/archive/refs/tags/v1.0.1.tar.gz" + sha256: "398fe7039ce35db80fe7da8d116035924f2c02ea4a4aa9f4903df6699287599c" "0.11.1": url: "https://github.com/AOMediaCodec/libavif/archive/refs/tags/v0.11.1.tar.gz" sha256: "0eb49965562a0e5e5de58389650d434cff32af84c34185b6c9b7b2fccae06d4e" @@ -6,6 +9,10 @@ sources: url: "https://github.com/AOMediaCodec/libavif/archive/refs/tags/v0.9.3.tar.gz" sha256: "bcd9a1f57f982a9615eb7e2faf87236dc88eb1d0c886f3471c7440ead605060d" patches: + "1.0.1": + - patch_file: patches/1.0.1-0001-disable-developer-only-codepaths.patch + patch_description: "disable compiler options for develop" + patch_type: "portability" "0.11.1": - patch_file: patches/0.11.1-0001-disable-developer-only-codepaths.patch patch_description: "disable compiler options for develop" diff --git a/recipes/libavif/all/patches/1.0.1-0001-disable-developer-only-codepaths.patch b/recipes/libavif/all/patches/1.0.1-0001-disable-developer-only-codepaths.patch new file mode 100644 index 00000000000000..9bedacfdc3b86e --- /dev/null +++ b/recipes/libavif/all/patches/1.0.1-0001-disable-developer-only-codepaths.patch @@ -0,0 +1,34 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 1f0cde1..4ad03b6 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -70,11 +70,13 @@ if(AVIF_LOCAL_LIBGAV1) + enable_language(CXX) + endif() + ++if(0) + if(APPLE) + set(XCRUN xcrun) + else() + set(XCRUN) + endif() ++endif() + + if(BUILD_SHARED_LIBS) + set(AVIF_LIBRARY_PREFIX "${CMAKE_SHARED_LIBRARY_PREFIX}") +@@ -209,6 +211,7 @@ else(libsharpyuv_FOUND) + endif(libsharpyuv_FOUND) + # --------------------------------------------------------------------------------------- + ++if(0) + # Enable all warnings + include(CheckCCompilerFlag) + if(CMAKE_C_COMPILER_ID MATCHES "Clang") +@@ -257,6 +260,7 @@ if(AVIF_ENABLE_COVERAGE) + message(WARNING "libavif: Ignoring request for coverage (AVIF_ENABLE_COVERAGE); only clang is currently supported.") + endif() + endif() ++endif() + + if(AVIF_ENABLE_EXPERIMENTAL_YCGCO_R) + add_compile_definitions(AVIF_ENABLE_EXPERIMENTAL_YCGCO_R) diff --git a/recipes/libavif/config.yml b/recipes/libavif/config.yml index f3e6d6038f1fa1..5cf9b4e379877b 100644 --- a/recipes/libavif/config.yml +++ b/recipes/libavif/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.1": + folder: all "0.11.1": folder: all "0.9.3": From 5ad9c550939540336006109a12d7b65473e3037f Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 2 Oct 2023 15:50:09 +0900 Subject: [PATCH 0904/1140] (#19952) libnpy: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libnpy: add recipe * Set cppstd compat to 11 --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libnpy/all/conandata.yml | 4 ++ recipes/libnpy/all/conanfile.py | 68 +++++++++++++++++++ .../libnpy/all/test_package/CMakeLists.txt | 8 +++ recipes/libnpy/all/test_package/conanfile.py | 26 +++++++ .../libnpy/all/test_package/test_package.cpp | 15 ++++ recipes/libnpy/config.yml | 3 + 6 files changed, 124 insertions(+) create mode 100644 recipes/libnpy/all/conandata.yml create mode 100644 recipes/libnpy/all/conanfile.py create mode 100644 recipes/libnpy/all/test_package/CMakeLists.txt create mode 100644 recipes/libnpy/all/test_package/conanfile.py create mode 100644 recipes/libnpy/all/test_package/test_package.cpp create mode 100644 recipes/libnpy/config.yml diff --git a/recipes/libnpy/all/conandata.yml b/recipes/libnpy/all/conandata.yml new file mode 100644 index 00000000000000..f7c435c55da391 --- /dev/null +++ b/recipes/libnpy/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.0.1": + url: "https://github.com/llohse/libnpy/archive/refs/tags/v1.0.1.tar.gz" + sha256: "43452a4db1e8c1df606c64376ea1e32789124051d7640e7e4e8518ab4f0fba44" diff --git a/recipes/libnpy/all/conanfile.py b/recipes/libnpy/all/conanfile.py new file mode 100644 index 00000000000000..1a453076924de6 --- /dev/null +++ b/recipes/libnpy/all/conanfile.py @@ -0,0 +1,68 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.scm import Version +import os + +required_conan_version = ">=1.52.0" + +class LibNPYConan(ConanFile): + name = "libnpy" + description = "C++ library for reading and writing of numpy's .npy files" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/llohse/libnpy" + topics = ("python", "numpy", "npy", "header-only") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + @property + def _min_cppstd(self): + # Author didn't explicitly make it C++11 compatible, but turns out it is, + # maybe this changes in a future version but for now it's set to C++11 + # See https://github.com/llohse/libnpy/issues/35#issuecomment-1727327678 + return 11 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "6", + "clang": "5", + "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", + } + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("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) + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="*.hpp", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "include"), + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/libnpy/all/test_package/CMakeLists.txt b/recipes/libnpy/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..d8ff7a7d074355 --- /dev/null +++ b/recipes/libnpy/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(libnpy REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE libnpy::libnpy) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/libnpy/all/test_package/conanfile.py b/recipes/libnpy/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/libnpy/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libnpy/all/test_package/test_package.cpp b/recipes/libnpy/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..896ab340a0523a --- /dev/null +++ b/recipes/libnpy/all/test_package/test_package.cpp @@ -0,0 +1,15 @@ +#include "npy.hpp" +#include +#include + +int main() { + const std::vector data{1, 2, 3, 4, 5, 6}; + + npy::npy_data d; + d.data = data; + d.shape = {2, 3}; + d.fortran_order = false; + + const std::string path{"out.npy"}; + npy::write_npy(path, d); +} diff --git a/recipes/libnpy/config.yml b/recipes/libnpy/config.yml new file mode 100644 index 00000000000000..715e55357a17be --- /dev/null +++ b/recipes/libnpy/config.yml @@ -0,0 +1,3 @@ +versions: + "1.0.1": + folder: all From af7969499bf4a3454f982026af8b15263c2ec984 Mon Sep 17 00:00:00 2001 From: Tobias Hermann Date: Mon, 2 Oct 2023 10:05:46 +0200 Subject: [PATCH 0905/1140] (#19953) Add frugally-deep version 0.15.24-p0 * Add frugally-deep version 0.15.21-p0 * Add frugally-deep version 0.15.22-p0 * Add frugally-deep version 0.15.23-p0 * Add frugally-deep version 0.15.24-p0 --- recipes/frugally-deep/all/conandata.yml | 3 +++ recipes/frugally-deep/all/conanfile.py | 2 +- recipes/frugally-deep/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/frugally-deep/all/conandata.yml b/recipes/frugally-deep/all/conandata.yml index 5db89f0f8f389c..51c5e56abaac5b 100644 --- a/recipes/frugally-deep/all/conandata.yml +++ b/recipes/frugally-deep/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.15.24-p0": + url: "https://github.com/Dobiasd/frugally-deep/archive/v0.15.24-p0.tar.gz" + sha256: "118b0219a3f17c6d5a3535874acb145ee2079fd309e1fb83884facc684810baf" "0.15.19-p0": url: "https://github.com/Dobiasd/frugally-deep/archive/v0.15.19-p0.tar.gz" sha256: "acaba428ae19ef8d57a53b3767373cd96770c190dd57909e52d2759be89ac942" diff --git a/recipes/frugally-deep/all/conanfile.py b/recipes/frugally-deep/all/conanfile.py index 4b479f8d56a41d..45f4704b4ab53f 100644 --- a/recipes/frugally-deep/all/conanfile.py +++ b/recipes/frugally-deep/all/conanfile.py @@ -39,7 +39,7 @@ def layout(self): def requirements(self): self.requires("eigen/3.4.0") - self.requires("functionalplus/0.2.18-p0") + self.requires("functionalplus/0.2.20-p0") self.requires("nlohmann_json/3.11.2") def package_id(self): diff --git a/recipes/frugally-deep/config.yml b/recipes/frugally-deep/config.yml index 5b45f706132677..fa67726d0442a0 100644 --- a/recipes/frugally-deep/config.yml +++ b/recipes/frugally-deep/config.yml @@ -1,4 +1,6 @@ versions: + "0.15.24-p0": + folder: all "0.15.19-p0": folder: all "0.15.18-p0": From a2690ec3b781f9bb2ef533a590d0eee1a3331ed5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 2 Oct 2023 11:54:12 +0300 Subject: [PATCH 0906/1140] (#20043) nv-codec-headers: add version 12.0.16.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/nv-codec-headers/all/conandata.yml | 3 +++ recipes/nv-codec-headers/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/nv-codec-headers/all/conandata.yml b/recipes/nv-codec-headers/all/conandata.yml index 708ee808ccc1d0..df731f0997f31a 100644 --- a/recipes/nv-codec-headers/all/conandata.yml +++ b/recipes/nv-codec-headers/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "12.0.16.0": + url: "https://github.com/FFmpeg/nv-codec-headers/archive/n12.0.16.0.tar.gz" + sha256: "2a1533b65f55f9da52956faf0627ed3b74868ac0c7f269990edd21369113b48f" "11.1.5.1": url: "https://github.com/FFmpeg/nv-codec-headers/archive/n11.1.5.1.tar.gz" sha256: "d095fbd56aa93772471a323be0ebe65504a0f43f06c76a30b6d25da77b06ae9c" diff --git a/recipes/nv-codec-headers/config.yml b/recipes/nv-codec-headers/config.yml index 993edd5a104227..018eb4087b8928 100644 --- a/recipes/nv-codec-headers/config.yml +++ b/recipes/nv-codec-headers/config.yml @@ -1,4 +1,6 @@ versions: + "12.0.16.0": + folder: all "11.1.5.1": folder: all "9.1.23.2": From 37062914278fcce731c4f5b9352bc006f331eb05 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Mon, 2 Oct 2023 12:54:09 +0200 Subject: [PATCH 0907/1140] (#20216) Bump cpprestsdk's zlib requirement to [>=1.2.11 <2] range --- recipes/cpprestsdk/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cpprestsdk/all/conanfile.py b/recipes/cpprestsdk/all/conanfile.py index 0383ff59b8cacf..c75c41fcad7c4f 100644 --- a/recipes/cpprestsdk/all/conanfile.py +++ b/recipes/cpprestsdk/all/conanfile.py @@ -60,7 +60,7 @@ def requirements(self): self.requires("boost/1.83.0") self.requires("openssl/[>=1.1 <4]") if self.options.with_compression: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_websockets: self.requires("websocketpp/0.8.2") From 9f01d3de1cd598d06844516180b15d5cedef5790 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Mon, 2 Oct 2023 19:27:39 +0200 Subject: [PATCH 0908/1140] (#20220) Bump drogon's zlib requirement to [>=1.2.11 <2] range --- recipes/drogon/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index 1cde167ffc5cc2..827f0fd96949d1 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -113,7 +113,7 @@ def requirements(self): self.requires("trantor/1.5.13", transitive_headers=True, transitive_libs=True) self.requires("jsoncpp/1.9.5", transitive_headers=True, transitive_libs=True) self.requires("openssl/[>=1.1 <4]") - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.settings.os == "Linux": self.requires("util-linux-libuuid/2.39") if self.options.with_profile: From a15866a61db999c9e581b5c81fe397f0d39a0bbc Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Tue, 3 Oct 2023 12:20:31 +0200 Subject: [PATCH 0909/1140] (#20262) [bot] Update authorized users list (2023-10-02) --- .c3i/authorized_users.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index cc585bf78c5cf3..5ec8bdc0fdecce 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1233,3 +1233,7 @@ authorized_users: - mrjoel - Nerixyz - irieger +- Slashcash +- CJaccarino +- gagoi +- tux3 From 8d824872fdd2468ea0a58264da5ade0b856213d4 Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Tue, 3 Oct 2023 12:29:41 +0200 Subject: [PATCH 0910/1140] (#19218) Add Yoga * Add yoga/2.0.0 * Cleanup conanfile * cannot be build as shared lib * Enforce shared=False * Drop option for shared * Drop unused CMakeDeps Co-authored-by: Uilian Ries * Drop unused import --------- Co-authored-by: Uilian Ries --- recipes/yoga/all/conandata.yml | 9 +++ recipes/yoga/all/conanfile.py | 80 +++++++++++++++++++ .../yoga/all/patches/0001-delete-tests.patch | 12 +++ recipes/yoga/all/test_package/CMakeLists.txt | 9 +++ recipes/yoga/all/test_package/conanfile.py | 27 +++++++ .../yoga/all/test_package/test_package.cpp | 20 +++++ recipes/yoga/config.yml | 3 + 7 files changed, 160 insertions(+) create mode 100644 recipes/yoga/all/conandata.yml create mode 100644 recipes/yoga/all/conanfile.py create mode 100644 recipes/yoga/all/patches/0001-delete-tests.patch create mode 100644 recipes/yoga/all/test_package/CMakeLists.txt create mode 100644 recipes/yoga/all/test_package/conanfile.py create mode 100644 recipes/yoga/all/test_package/test_package.cpp create mode 100644 recipes/yoga/config.yml diff --git a/recipes/yoga/all/conandata.yml b/recipes/yoga/all/conandata.yml new file mode 100644 index 00000000000000..94212fbd08096d --- /dev/null +++ b/recipes/yoga/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "2.0.0": + url: "https://github.com/facebook/yoga/archive/refs/tags/v2.0.0.tar.gz" + sha256: "29eaf05191dd857f76b6db97c77cce66db3c0067c88bd5e052909386ea66b8c5" +patches: + "2.0.0": + - patch_file: "patches/0001-delete-tests.patch" + patch_description: "Delete test targets from cmake" + patch_type: "conan" diff --git a/recipes/yoga/all/conanfile.py b/recipes/yoga/all/conanfile.py new file mode 100644 index 00000000000000..e8249b9860f592 --- /dev/null +++ b/recipes/yoga/all/conanfile.py @@ -0,0 +1,80 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.build import check_min_cppstd +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +import os + + +class YogaConan(ConanFile): + name = "yoga" + description = "cross-platform layout engine which implements Flexbox" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://yogalayout.com/" + topics = ("layout engine", "flexbox") + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + options = { + "fPIC": [True, False], + } + default_options = { + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 14 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "5", + "clang": "3.4", + "apple-clang": "10", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 191) + if not is_msvc(self): + 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) + + def generate(self): + apply_conandata_patches(self) + tc = CMakeToolchain(self) + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build(target="yogacore") + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + self.cpp_info.libs = ["yogacore"] diff --git a/recipes/yoga/all/patches/0001-delete-tests.patch b/recipes/yoga/all/patches/0001-delete-tests.patch new file mode 100644 index 00000000000000..d3a76211634cab --- /dev/null +++ b/recipes/yoga/all/patches/0001-delete-tests.patch @@ -0,0 +1,12 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index f4ce73cc..9f414127 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -10,7 +10,6 @@ set(CMAKE_VERBOSE_MAKEFILE on) + include(${CMAKE_CURRENT_SOURCE_DIR}/cmake/project-defaults.cmake) + + add_subdirectory(yoga) +-add_subdirectory(tests) + + # cmake install config + include(GNUInstallDirs) diff --git a/recipes/yoga/all/test_package/CMakeLists.txt b/recipes/yoga/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..4c709290f183be --- /dev/null +++ b/recipes/yoga/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.15) + +project(test_package CXX) + +find_package(yoga REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE yoga::yoga) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/yoga/all/test_package/conanfile.py b/recipes/yoga/all/test_package/conanfile.py new file mode 100644 index 00000000000000..02eb5ce439fb40 --- /dev/null +++ b/recipes/yoga/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +# It will become the standard on Conan 2.x +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/yoga/all/test_package/test_package.cpp b/recipes/yoga/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..ce6ef4ea1d25ed --- /dev/null +++ b/recipes/yoga/all/test_package/test_package.cpp @@ -0,0 +1,20 @@ +#include +#include + +int main(void) { + const YGNodeRef root = YGNodeNew(); + YGNodeStyleSetAlignItems(root, YGAlignFlexStart); + YGNodeStyleSetWidth(root, 100); + YGNodeStyleSetHeight(root, 100); + + const YGNodeRef root_child0 = YGNodeNew(); + YGNodeStyleSetWidth(root_child0, 50); + YGNodeStyleSetAspectRatio(root_child0, 1); + YGNodeInsertChild(root, root_child0, 0); + + YGNodeCalculateLayout(root, YGUndefined, YGUndefined, YGDirectionLTR); + + YGNodeFreeRecursive(root); + + return EXIT_SUCCESS; +} diff --git a/recipes/yoga/config.yml b/recipes/yoga/config.yml new file mode 100644 index 00000000000000..d77ad03cbf5108 --- /dev/null +++ b/recipes/yoga/config.yml @@ -0,0 +1,3 @@ +versions: + "2.0.0": + folder: all From 668048789b5c4b7b834f2c3d31da444ef4c4b340 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 3 Oct 2023 12:51:26 +0200 Subject: [PATCH 0911/1140] (#20181) alembic 1.8.5: relocatable shared lib on macOS + disable warnings as errors * disable warnings as errors * relocatable shared libs on macOS --- recipes/alembic/all/conanfile.py | 3 ++ .../all/patches/1.8.5-0001-fix-cmake.patch | 40 ++++++++++++++++--- 2 files changed, 38 insertions(+), 5 deletions(-) diff --git a/recipes/alembic/all/conanfile.py b/recipes/alembic/all/conanfile.py index 96e5f773727fd8..a05a7f705ff406 100644 --- a/recipes/alembic/all/conanfile.py +++ b/recipes/alembic/all/conanfile.py @@ -2,6 +2,7 @@ from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +from conan.tools.scm import Version import os required_conan_version = ">=1.53.0" @@ -70,6 +71,8 @@ def generate(self): tc.variables["ALEMBIC_USING_IMATH_3"] = False tc.variables["ALEMBIC_ILMBASE_FOUND"] = 1 tc.variables["ALEMBIC_ILMBASE_LIBS"] = "OpenEXR::OpenEXR" + if Version(self.version) >= "1.8.4": + tc.variables["ALEMBIC_DEBUG_WARNINGS_AS_ERRORS"] = False tc.generate() deps = CMakeDeps(self) deps.generate() diff --git a/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch b/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch index 3ebad2885a6413..c048ccd304a2e2 100644 --- a/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch +++ b/recipes/alembic/all/patches/1.8.5-0001-fix-cmake.patch @@ -1,6 +1,26 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -100,9 +100,6 @@ SET(DARWIN FALSE) + IF ("${CMAKE_SYSTEM_NAME}" MATCHES "Darwin") + SET(DARWIN TRUE) + # suppress rpath warning +- IF (POLICY CMP0042) +- CMAKE_POLICY(SET CMP0042 OLD) +- ENDIF() + ENDIF() + + SET(LINUX FALSE) +@@ -212,7 +209,6 @@ INCLUDE("./cmake/AlembicIlmBase.cmake") + + # HDF5 + IF (USE_HDF5) +- FIND_PACKAGE(ZLIB REQUIRED) + SET(ALEMBIC_WITH_HDF5 "1") + INCLUDE("./cmake/AlembicHDF5.cmake") + SET(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DH5_USE_18_API") --- a/lib/Alembic/CMakeLists.txt +++ b/lib/Alembic/CMakeLists.txt -@@ -68,7 +68,6 @@ IF (ALEMBIC_SHARED_LIBS) +@@ -68,28 +68,26 @@ IF (ALEMBIC_SHARED_LIBS) if (ALEMBIC_USING_IMATH_3) if (APPLE OR UNIX) @@ -8,7 +28,20 @@ endif () endif () ENDIF() -@@ -87,9 +87,9 @@ TARGET_LINK_LIBRARIES(Alembic + + + TARGET_LINK_LIBRARIES(Alembic +- LINK_PUBLIC ++ PUBLIC + ${ALEMBIC_ILMBASE_LIBS} + ${CMAKE_THREAD_LIBS_INIT} + ${EXTERNAL_MATH_LIBS} +- LINK_PRIVATE ++ PRIVATE + ${HDF5_LIBRARIES} +- ${ZLIB_LIBRARY} + ) + SET( ALEMBIC_LIB_INSTALL_DIR lib CACHE STRING "Where to install the Alembic libs") INSTALL(TARGETS Alembic EXPORT AlembicTargets @@ -21,6 +54,3 @@ #-****************************************************************************** # PACKAGE EXPORTS --- -2.41.0 - From 5d8800386dc399dfd2f01cd599d4a88ff0dc9801 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Tue, 3 Oct 2023 13:49:24 +0200 Subject: [PATCH 0912/1140] (#20239) dcmtk: conan v2 support & remove old versions * conan v2 support * cleanup * simplify "cmake required" variables injection for openssl * fix windows * small change * deprecate builtin_dictionary & external_dictionary in favor of default_dict & use_dcmdictpath options * fix env var condition * also fix check_cxx tests for libiconv * typo * fix cmake targets --- recipes/dcmtk/all/CMakeLists.txt | 7 - recipes/dcmtk/all/conandata.yml | 22 +- recipes/dcmtk/all/conanfile.py | 325 ++++++++++-------- .../0001-cmake-use-conan-packages.patch | 253 -------------- .../0002-cmake-use-conan-packages.patch | 225 ------------ ....6.7-0001-cmake-robust-deps-handling.patch | 162 +++++++++ ....6.7-0002-cmake-check-openssl-symbol.patch | 89 +++++ .../all/patches/cmake-patching-3-6-7.patch | 216 ------------ recipes/dcmtk/all/test_package/CMakeLists.txt | 11 +- recipes/dcmtk/all/test_package/conanfile.py | 19 +- .../dcmtk/all/test_v1_package/CMakeLists.txt | 8 + .../dcmtk/all/test_v1_package/conanfile.py | 17 + recipes/dcmtk/config.yml | 4 - 13 files changed, 476 insertions(+), 882 deletions(-) delete mode 100644 recipes/dcmtk/all/CMakeLists.txt delete mode 100644 recipes/dcmtk/all/patches/0001-cmake-use-conan-packages.patch delete mode 100644 recipes/dcmtk/all/patches/0002-cmake-use-conan-packages.patch create mode 100644 recipes/dcmtk/all/patches/3.6.7-0001-cmake-robust-deps-handling.patch create mode 100644 recipes/dcmtk/all/patches/3.6.7-0002-cmake-check-openssl-symbol.patch delete mode 100644 recipes/dcmtk/all/patches/cmake-patching-3-6-7.patch create mode 100644 recipes/dcmtk/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/dcmtk/all/test_v1_package/conanfile.py diff --git a/recipes/dcmtk/all/CMakeLists.txt b/recipes/dcmtk/all/CMakeLists.txt deleted file mode 100644 index 56b7606e716f95..00000000000000 --- a/recipes/dcmtk/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.0) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/dcmtk/all/conandata.yml b/recipes/dcmtk/all/conandata.yml index 7e3e0a0cc6e011..7ae433b2e0c081 100644 --- a/recipes/dcmtk/all/conandata.yml +++ b/recipes/dcmtk/all/conandata.yml @@ -2,25 +2,11 @@ sources: "3.6.7": url: "https://dicom.offis.de/download/dcmtk/dcmtk367/dcmtk-3.6.7.tar.gz" sha256: "7c58298e3e8d60232ee6fc8408cfadd14463cc11a3c4ca4c59af5988c7e9710a" - "3.6.6": - url: "https://dicom.offis.de/download/dcmtk/dcmtk366/dcmtk-3.6.6.tar.gz" - sha256: "6859c62b290ee55677093cccfd6029c04186d91cf99c7642ae43627387f3458e" - "3.6.5": - url: "https://dicom.offis.de/download/dcmtk/dcmtk365/dcmtk-3.6.5.tar.gz" - sha256: "a05178665f21896dbb0974106dba1ad144975414abd760b4cf8f5cc979f9beb9" patches: "3.6.7": - - patch_file: "patches/cmake-patching-3-6-7.patch" - base_path: "source_subfolder" + - patch_file: "patches/3.6.7-0001-cmake-robust-deps-handling.patch" + patch_description: "CMake: robust discovery with find_package() and use imported targets" patch_type: conan - patch_description: "Don't ignore dependencies that can't be found; patch some variable names" - "3.6.6": - - patch_file: "patches/0002-cmake-use-conan-packages.patch" - base_path: "source_subfolder" + - patch_file: "patches/3.6.7-0002-cmake-check-openssl-symbol.patch" + patch_description: "CMake: fix OpenSSL compatibility checks" patch_type: conan - patch_description: "Don't ignore dependencies that can't be found; patch some variable names" - "3.6.5": - - patch_file: "patches/0001-cmake-use-conan-packages.patch" - base_path: "source_subfolder" - patch_type: conan - patch_description: "Don't ignore dependencies that can't be found; patch some variable names" diff --git a/recipes/dcmtk/all/conanfile.py b/recipes/dcmtk/all/conanfile.py index 286fb28a07048c..c91c7cb9ec81d6 100644 --- a/recipes/dcmtk/all/conanfile.py +++ b/recipes/dcmtk/all/conanfile.py @@ -1,15 +1,14 @@ -from conans import CMake +import os +import textwrap + from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import cross_building -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, rmdir, save -from conan.tools.microsoft import is_msvc, msvc_runtime_flag -from conan.tools.scm import Version -import functools -import os -import textwrap +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rmdir, save +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.54.0" class DCMTKConan(ConanFile): @@ -19,7 +18,7 @@ class DCMTKConan(ConanFile): homepage = "https://dicom.offis.de/dcmtk" license = "BSD-3-Clause" topics = ("dicom", "image") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -33,9 +32,11 @@ class DCMTKConan(ConanFile): "with_libpng": [True, False], "with_libtiff": [True, False], "with_tcpwrappers": [True, False], - "builtin_dictionary": [None, True, False], + "default_dict": ["builtin", "external", "none"], + "builtin_dictionary": [None, True, False, "deprecated"], + "use_dcmdictpath": [True, False], "builtin_private_tags": [True, False], - "external_dictionary": [None, True, False], + "external_dictionary": [None, True, False, "deprecated"], "wide_io": [True, False], "enable_stl": [True, False], } @@ -51,58 +52,67 @@ class DCMTKConan(ConanFile): "with_libpng": True, "with_libtiff": True, "with_tcpwrappers": False, - "builtin_dictionary": None, + "default_dict": "external", + "builtin_dictionary": "deprecated", + "use_dcmdictpath": True, "builtin_private_tags": False, - "external_dictionary": None, + "external_dictionary": "deprecated", "wide_io": False, "enable_stl": True, } - generators = "cmake", "cmake_find_package" - - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - def export_sources(self): - self.copy("CMakeLists.txt") export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": self.options.rm_safe("fPIC") self.options.rm_safe("with_tcpwrappers") + self.options.default_dict = "builtin" def configure(self): if self.options.shared: self.options.rm_safe("fPIC") + # Deprecated options + if self.options.builtin_dictionary != "deprecated": + self.output.warning("builtin_dictionary option is deprecated. Use default_dict option instead.") + if self.options.builtin_dictionary: + self.options.default_dict = "builtin" + elif self.options.builtin_dictionary == False: + self.options.default_dict = "external" + if self.options.external_dictionary != "deprecated": + self.output.warning("external_dictionary option is deprecated. Use use_dcmdictpath option instead.") + if self.options.external_dictionary: + self.options.use_dcmdictpath = True + elif self.options.external_dictionary == False: + self.options.use_dcmdictpath = False + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.options.charset_conversion == "libiconv": self.requires("libiconv/1.17") elif self.options.charset_conversion == "icu": - self.requires("icu/72.1") + self.requires("icu/73.2") if self.options.with_libxml2: - self.requires("libxml2/2.10.3") + self.requires("libxml2/2.11.4") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_openssl: - if self.settings.os == "Windows": - # FIXME: CMake configuration fails to detect Openssl 1.1 on Windows. - self.requires("openssl/1.0.2u") - else: - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1 <4]") if self.options.with_libpng: - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") if self.options.with_libtiff: - self.requires("libtiff/4.4.0") + self.requires("libtiff/4.6.0") if self.options.get_safe("with_tcpwrappers"): self.requires("tcp-wrappers/7.6") + def package_id(self): + # Deprecated options don't contribute to package id + del self.info.options.builtin_dictionary + del self.info.options.external_dictionary + def validate(self): if hasattr(self, "settings_build") and cross_building(self) and \ self.settings.os == "Macos" and self.settings.arch == "armv8": @@ -110,90 +120,122 @@ def validate(self): raise ConanInvalidConfiguration("Cross building to Macos M1 is not supported (yet)") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + def generate(self): + tc = CMakeToolchain(self) # DICOM Data Dictionaries are required - cmake.definitions["CMAKE_INSTALL_DATADIR"] = self._dcm_datadictionary_path - - cmake.definitions["BUILD_APPS"] = self.options.with_applications - cmake.definitions["DCMTK_WITH_ICONV"] = self.options.charset_conversion == "libiconv" - if self.options.charset_conversion == "libiconv": - cmake.definitions["WITH_LIBICONVINC"] = self.deps_cpp_info["libiconv"].rootpath - cmake.definitions["DCMTK_WITH_ICU"] = self.options.charset_conversion == "icu" - cmake.definitions["DCMTK_WITH_OPENJPEG"] = False - cmake.definitions["DCMTK_WITH_OPENSSL"] = self.options.with_openssl - if self.options.with_openssl: - cmake.definitions["WITH_OPENSSLINC"] = self.deps_cpp_info["openssl"].rootpath - cmake.definitions["DCMTK_WITH_PNG"] = self.options.with_libpng - if self.options.with_libpng: - cmake.definitions["WITH_LIBPNGINC"] = self.deps_cpp_info["libpng"].rootpath - cmake.definitions["DCMTK_WITH_SNDFILE"] = False - cmake.definitions["DCMTK_WITH_THREADS"] = self.options.with_multithreading - cmake.definitions["DCMTK_WITH_TIFF"] = self.options.with_libtiff - if self.options.with_libtiff: - cmake.definitions["WITH_LIBTIFFINC"] = self.deps_cpp_info["libtiff"].rootpath + tc.variables["CMAKE_INSTALL_DATADIR"] = self._dcm_datadictionary_path.replace("\\", "/") + tc.cache_variables["DCMTK_USE_FIND_PACKAGE"] = True + tc.variables["BUILD_APPS"] = self.options.with_applications + tc.variables["DCMTK_WITH_TIFF"] = self.options.with_libtiff + tc.variables["DCMTK_WITH_PNG"] = self.options.with_libpng + tc.variables["DCMTK_WITH_XML"] = self.options.with_libxml2 + tc.variables["DCMTK_WITH_ZLIB"] = self.options.with_zlib + tc.variables["DCMTK_WITH_OPENSSL"] = self.options.with_openssl + tc.variables["DCMTK_WITH_SNDFILE"] = False # not used at all, do not try to add an option for this one + tc.variables["DCMTK_WITH_ICONV"] = self.options.charset_conversion == "libiconv" + tc.variables["DCMTK_WITH_ICU"] = self.options.charset_conversion == "icu" if self.settings.os != "Windows": - cmake.definitions["DCMTK_WITH_WRAP"] = self.options.with_tcpwrappers - cmake.definitions["DCMTK_WITH_XML"] = self.options.with_libxml2 - if self.options.with_libxml2: - cmake.definitions["WITH_LIBXMLINC"] = self.deps_cpp_info["libxml2"].rootpath - cmake.definitions["WITH_LIBXML_SHARED"] = self.options["libxml2"].shared - cmake.definitions["DCMTK_WITH_ZLIB"] = self.options.with_zlib - if self.options.with_zlib: - cmake.definitions["WITH_ZLIBINC"] = self.deps_cpp_info["zlib"].rootpath - - if self.options.enable_stl: - cmake.definitions["DCMTK_ENABLE_STL"] = "ON" - else: - cmake.definitions["DCMTK_ENABLE_STL"] = "OFF" - cmake.definitions["DCMTK_ENABLE_CXX11"] = True - - cmake.definitions["DCMTK_ENABLE_MANPAGE"] = False - cmake.definitions["DCMTK_WITH_DOXYGEN"] = False - - cmake.definitions["DCMTK_ENABLE_PRIVATE_TAGS"] = self.options.builtin_private_tags - if self.options.external_dictionary is not None: - if Version(self.version) < "3.6.7": - cmake.definitions["DCMTK_ENABLE_EXTERNAL_DICTIONARY"] = self.options.external_dictionary - else: - cmake.definitions["DCMTK_DEFAULT_DICT"] = self.options.external_dictionary - if self.options.builtin_dictionary is not None: - cmake.definitions["DCMTK_ENABLE_BUILTIN_DICTIONARY"] = self.options.builtin_dictionary - cmake.definitions["DCMTK_WIDE_CHAR_FILE_IO_FUNCTIONS"] = self.options.wide_io - cmake.definitions["DCMTK_WIDE_CHAR_MAIN_FUNCTION"] = self.options.wide_io - + tc.variables["DCMTK_WITH_WRAP"] = self.options.with_tcpwrappers + tc.variables["DCMTK_WITH_OPENJPEG"] = False # not used at all, do not try to add an option for this one + tc.variables["DCMTK_ENABLE_PRIVATE_TAGS"] = self.options.builtin_private_tags + tc.variables["DCMTK_WITH_THREADS"] = self.options.with_multithreading + tc.variables["DCMTK_WITH_DOXYGEN"] = False + tc.variables["DCMTK_WIDE_CHAR_FILE_IO_FUNCTIONS"] = self.options.wide_io + tc.variables["DCMTK_WIDE_CHAR_MAIN_FUNCTION"] = self.options.wide_io + tc.variables["DCMTK_ENABLE_STL"] = self.options.enable_stl + tc.variables["DCMTK_ENABLE_CXX11"] = True + tc.variables["DCMTK_ENABLE_MANPAGE"] = False + tc.cache_variables["DCMTK_DEFAULT_DICT"] = self.options.default_dict + tc.variables["DCMTK_USE_DCMDICTPATH"] = self.options.use_dcmdictpath if self.settings.os == "Windows": - cmake.definitions["DCMTK_OVERWRITE_WIN32_COMPILER_FLAGS"] = False - + tc.variables["DCMTK_OVERWRITE_WIN32_COMPILER_FLAGS"] = False if is_msvc(self): - cmake.definitions["DCMTK_ICONV_FLAGS_ANALYZED"] = True - cmake.definitions["DCMTK_COMPILE_WIN32_MULTITHREADED_DLL"] = "MD" in msvc_runtime_flag(self) + tc.variables["DCMTK_ICONV_FLAGS_ANALYZED"] = True + tc.variables["DCMTK_COMPILE_WIN32_MULTITHREADED_DLL"] = not is_msvc_static_runtime(self) + tc.generate() + + deps = CMakeDeps(self) + deps.generate() + + def _collect_cmake_required(self, dependency): + dep = self.dependencies.host[dependency] + dep_cpp_info = dep.cpp_info.aggregated_components() + dep_includes = [p.replace("\\", "/") for p in dep_cpp_info.includedirs] + dep_defs = [d for d in dep_cpp_info.defines] + libdirs_flag = "/LIBPATH:" if is_msvc(self) else "-L" + dep_libdirs = ["{}{}".format(libdirs_flag, p.replace("\\", "/")) for p in dep_cpp_info.libdirs] + dep_libs = [l for l in dep_cpp_info.libs] + dep_system_libs = [s for s in dep_cpp_info.system_libs] + dep_frameworks = [f"-framework {f}" for f in dep_cpp_info.frameworks] + for _, trans_dependency in dep.dependencies.items(): + if trans_dependency.context != "host": + continue + trans_dep_cpp_info = trans_dependency.cpp_info.aggregated_components() + dep_includes.extend([p.replace("\\", "/") for p in trans_dep_cpp_info.includedirs]) + dep_defs.extend([d for d in trans_dep_cpp_info.defines]) + dep_libdirs.extend(["{}{}".format(libdirs_flag, p.replace("\\", "/")) for p in trans_dep_cpp_info.libdirs]) + dep_libs.extend([l for l in trans_dep_cpp_info.libs]) + dep_system_libs.extend([s for s in trans_dep_cpp_info.system_libs]) + dep_frameworks.extend([f"-framework {f}" for f in trans_dep_cpp_info.frameworks]) - cmake.configure(build_folder=self._build_subfolder) - return cmake + return { + "includes": ";".join(dep_includes), + "definitions": ";".join(dep_defs), + "link_options": ";".join(dep_libdirs + dep_frameworks), + "libraries": ";".join(dep_libs + dep_system_libs), + } - def build(self): + def _patch_sources(self): apply_conandata_patches(self) - cmake = self._configure_cmake() + + # Workaround for CMakeDeps bug with check_* like functions. + # See https://github.com/conan-io/conan/issues/12012 & https://github.com/conan-io/conan/issues/12180 + if self.options.with_openssl: + cmake_required = self._collect_cmake_required("openssl") + replace_in_file( + self, + os.path.join(self.source_folder, "CMake", "dcmtkPrepare.cmake"), + "set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${OPENSSL_LIBS} ${THREAD_LIBS})", + textwrap.dedent(f"""\ + list(APPEND CMAKE_REQUIRED_INCLUDES "{cmake_required['includes']}") + list(APPEND CMAKE_REQUIRED_DEFINITIONS "{cmake_required['definitions']}") + list(APPEND CMAKE_REQUIRED_LINK_OPTIONS "{cmake_required['link_options']}") + list(APPEND CMAKE_REQUIRED_LIBRARIES "{cmake_required['libraries']}") + """), + ) + + if self.options.charset_conversion == "libiconv": + cmake_required = self._collect_cmake_required("libiconv") + replace_in_file( + self, + os.path.join(self.source_folder, "CMake", "3rdparty.cmake"), + "set(CMAKE_REQUIRED_LIBRARIES ${LIBICONV_LIBS})", + textwrap.dedent(f"""\ + list(APPEND CMAKE_REQUIRED_DEFINITIONS "{cmake_required['definitions']}") + list(APPEND CMAKE_REQUIRED_LINK_OPTIONS "{cmake_required['link_options']}") + list(APPEND CMAKE_REQUIRED_LIBRARIES "{cmake_required['libraries']}") + """), + ) + + def build(self): + self._patch_sources() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="COPYRIGHT", dst="licenses", src=self._source_subfolder) - - cmake = self._configure_cmake() + copy(self, "COPYRIGHT", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - rmdir(self, os.path.join(self.package_folder, "cmake")) rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "etc")) rmdir(self, os.path.join(self.package_folder, "share")) + # TODO: to remove once support of cmake_find_package* dropped self._create_cmake_module_alias_targets( os.path.join(self.package_folder, self._module_file_rel_path), {target: f"DCMTK::{target}" for target in self._dcmtk_components} @@ -202,21 +244,17 @@ def package(self): def _create_cmake_module_alias_targets(self, module_file, targets): content = "" for alias, aliased in targets.items(): - content += textwrap.dedent("""\ + content += textwrap.dedent(f"""\ if(TARGET {aliased} AND NOT TARGET {alias}) add_library({alias} INTERFACE IMPORTED) set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) endif() - """.format(alias=alias, aliased=aliased)) + """) save(self, module_file, content) - @property - def _module_subfolder(self): - return os.path.join("lib", "cmake") - @property def _module_file_rel_path(self): - return os.path.join(self._module_subfolder, "conan-official-{self.name}-targets.cmake") + return os.path.join("lib", "cmake", f"conan-official-{self.name}-targets.cmake") @property def _dcmtk_components(self): @@ -243,8 +281,6 @@ def tcpwrappers(): def xml2(): return ["libxml2::libxml2"] if self.options.with_libxml2 else [] - charls = "dcmtkcharls" if Version("3.6.6") <= self.version else "charls" - return { "ofstd" : charset_conversion(), "oflog" : ["ofstd"], @@ -256,8 +292,8 @@ def xml2(): "ijg8" : [], "ijg12" : [], "ijg16" : [], - "dcmjpls" : ["ofstd", "oflog", "dcmdata", "dcmimgle", "dcmimage", charls], - charls : ["ofstd", "oflog"], + "dcmjpls" : ["ofstd", "oflog", "dcmdata", "dcmimgle", "dcmimage", "dcmtkcharls"], + "dcmtkcharls": ["ofstd", "oflog"], "dcmtls" : ["ofstd", "dcmdata", "dcmnet"] + openssl(), "dcmnet" : ["ofstd", "oflog", "dcmdata"] + tcpwrappers(), "dcmsr" : ["ofstd", "oflog", "dcmdata", "dcmimgle", "dcmimage"] + xml2(), @@ -282,41 +318,38 @@ def package_info(self): self.cpp_info.set_property("cmake_find_mode", "both") self.cpp_info.set_property("cmake_file_name", "DCMTK") - self.cpp_info.names["cmake_find_package"] = "DCMTK" - self.cpp_info.names["cmake_find_package_multi"] = "DCMTK" + for target_lib, requires in self._dcmtk_components.items(): + self.cpp_info.components[target_lib].set_property("cmake_target_name", f"DCMTK::{target_lib}") + # Before 3.6.7, targets were not namespaced, therefore they are also exposed for conveniency + self.cpp_info.components[target_lib].set_property("cmake_target_aliases", [target_lib]) + + self.cpp_info.components[target_lib].libs = [target_lib] + self.cpp_info.components[target_lib].includedirs.append(os.path.join("include", "dcmtk")) + self.cpp_info.components[target_lib].requires = requires - def register_components(components): - for target_lib, requires in components.items(): - self.cpp_info.components[target_lib].set_property("cmake_target_name", target_lib) - self.cpp_info.components[target_lib].libs = [target_lib] - self.cpp_info.components[target_lib].includedirs.append(os.path.join("include", "dcmtk")) - self.cpp_info.components[target_lib].requires = requires - - # TODO: to remove in conan v2 once cmake_find_package* generators removed - self.cpp_info.components[target_lib].names["cmake_find_package"] = target_lib - self.cpp_info.components[target_lib].names["cmake_find_package_multi"] = target_lib - self.cpp_info.components[target_lib].builddirs.append(self._module_subfolder) - self.cpp_info.components[target_lib].build_modules["cmake_find_package"] = [self._module_file_rel_path] - self.cpp_info.components[target_lib].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - - if self.settings.os == "Windows": - self.cpp_info.components["ofstd"].system_libs.extend([ - "iphlpapi", "ws2_32", "netapi32", "wsock32" - ]) - elif self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["ofstd"].system_libs.append("m") - if self.options.with_multithreading: - self.cpp_info.components["ofstd"].system_libs.append("pthread") - - register_components(self._dcmtk_components) - - dcmdictpath = os.path.join(self._dcm_datadictionary_path, "dcmtk", "dicom.dic") - self.output.info(f"Settings DCMDICTPATH environment variable: {dcmdictpath}") - self.runenv_info.define_path("DCMDICTPATH", dcmdictpath) - self.env_info.DCMDICTPATH = dcmdictpath # remove in conan v2? + # TODO: to remove in conan v2 once cmake_find_package* generators removed + self.cpp_info.components[target_lib].build_modules["cmake_find_package"] = [self._module_file_rel_path] + self.cpp_info.components[target_lib].build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] + if self.settings.os == "Windows": + self.cpp_info.components["ofstd"].system_libs.extend([ + "iphlpapi", "ws2_32", "netapi32", "wsock32" + ]) + elif self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["ofstd"].system_libs.append("m") + if self.options.with_multithreading: + self.cpp_info.components["ofstd"].system_libs.append("pthread") + + if self.options.default_dict == "external": + dcmdictpath = os.path.join(self._dcm_datadictionary_path, "dcmtk", "dicom.dic") + self.runenv_info.define_path("DCMDICTPATH", dcmdictpath) + if self.options.with_applications: + self.buildenv_info.define_path("DCMDICTPATH", dcmdictpath) + + # TODO: to remove in conan v2 + self.cpp_info.names["cmake_find_package"] = "DCMTK" + self.cpp_info.names["cmake_find_package_multi"] = "DCMTK" + if self.options.default_dict == "external": + self.env_info.DCMDICTPATH = dcmdictpath if self.options.with_applications: - self.buildenv_info.define_path("DCMDICTPATH", dcmdictpath) - bin_path = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bin_path}") - self.env_info.PATH.append(bin_path) + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) diff --git a/recipes/dcmtk/all/patches/0001-cmake-use-conan-packages.patch b/recipes/dcmtk/all/patches/0001-cmake-use-conan-packages.patch deleted file mode 100644 index 0e7d266d097c2d..00000000000000 --- a/recipes/dcmtk/all/patches/0001-cmake-use-conan-packages.patch +++ /dev/null @@ -1,253 +0,0 @@ ---- a/CMake/3rdparty.cmake -+++ b/CMake/3rdparty.cmake -@@ -40,13 +40,15 @@ if(WIN32 AND NOT MINGW) - # libxml support: configure compiler - if(DCMTK_WITH_XML) - if(WITH_LIBXMLINC) -- set(LIBXML_INCDIR "${WITH_LIBXMLINC}/include") -- set(LIBXML_LIBDIR "${WITH_LIBXMLINC}/lib") -- set(LIBXML_LIBS debug "${LIBXML_LIBDIR}/libxml2_d.lib" optimized "${LIBXML_LIBDIR}/libxml2_o.lib" debug "${LIBXML_LIBDIR}/iconv_d.lib" optimized "${LIBXML_LIBDIR}/iconv_o.lib") -+ set(LIBXML_INCDIR ${CONAN_INCLUDE_DIRS_LIBXML2} ${CONAN_INCLUDE_DIRS_ICONV}) -+ link_directories(${WITH_LIBXMLINC}/lib) -+ set(LIBXML_LIBS ${CONAN_LIBS_LIBXML2}) - message(STATUS "Info: DCMTK XML support will be enabled") - set(WITH_LIBXML 1) -+ if(NOT WITH_LIBXML_SHARED) - # this hides some warnings that are emitted when linking against libxmlXXX.lib instead of linking the DLL directly - add_definitions("-DLIBXML_STATIC") -+ endif() - else() # turn off library if library path not set - message(STATUS "Warning: XML support will be disabled because libxml2 directory is not specified. Correct path and re-enable DCMTK_WITH_XML.") - set(DCMTK_WITH_XML OFF CACHE BOOL "" FORCE) -@@ -58,8 +60,8 @@ if(WIN32 AND NOT MINGW) - if(DCMTK_WITH_PNG) - if(WITH_LIBPNGINC) - set(LIBPNG_INCDIR "${WITH_LIBPNGINC}/include") -- set(LIBPNG_LIBDIR "${WITH_LIBPNGINC}/lib") -- set(LIBPNG_LIBS debug "${LIBPNG_LIBDIR}/libpng_d.lib" optimized "${LIBPNG_LIBDIR}/libpng_o.lib") -+ link_directories(${WITH_LIBPNGINC}/lib) -+ set(LIBPNG_LIBS CONAN_PKG::libpng) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - else() # turn off library if library path not set -@@ -73,8 +75,8 @@ if(WIN32 AND NOT MINGW) - if(DCMTK_WITH_TIFF) - if(WITH_LIBTIFFINC) - set(LIBTIFF_INCDIR "${WITH_LIBTIFFINC}/include") -- set(LIBTIFF_LIBDIR "${WITH_LIBTIFFINC}/lib") -- set(LIBTIFF_LIBS debug "${LIBTIFF_LIBDIR}/libtiff_d.lib" optimized "${LIBTIFF_LIBDIR}/libtiff_o.lib") -+ link_directories(${WITH_LIBTIFFINC}/lib) -+ set(LIBTIFF_LIBS CONAN_PKG::libtiff) - message(STATUS "Info: DCMTK TIFF support will be enabled") - set(WITH_LIBTIFF 1) - else() # turn off library if library path not set -@@ -90,9 +92,9 @@ if(WIN32 AND NOT MINGW) - include(CheckCXXSourceCompiles) - set(OPENSSL_BINDIR "${WITH_OPENSSLINC}/bin") - set(OPENSSL_INCDIR "${WITH_OPENSSLINC}/include") -- set(OPENSSL_LIBDIR "${WITH_OPENSSLINC}/lib") -+ link_directories(${WITH_OPENSSLINC}/lib) - # starting with OpenSSL 1.1.0, the Windows crypt32 library is needed for a static link of OpenSSL. -- set(OPENSSL_LIBS "crypt32" debug "${OPENSSL_LIBDIR}/dcmtkssl_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkssl_o.lib" debug "${OPENSSL_LIBDIR}/dcmtkcrypto_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkcrypto_o.lib") -+ set(OPENSSL_LIBS ${CONAN_LIBS_OPENSSL}) - set(TEMP_INCLUDES "${CMAKE_REQUIRED_INCLUDES}") - list(APPEND CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCDIR}") - CHECK_CXX_SOURCE_COMPILES("extern \"C\" {\n#include \n}\nint main(){\n#if OPENSSL_VERSION_NUMBER < 0x10001000L\n#error OpenSSL too old\n#endif\n}\n" OPENSSL_VERSION_CHECK) -@@ -116,8 +118,8 @@ if(WIN32 AND NOT MINGW) - if(DCMTK_WITH_ZLIB) - if(WITH_ZLIBINC) - set(ZLIB_INCDIR "${WITH_ZLIBINC}/include") -- set(ZLIB_LIBDIR "${WITH_ZLIBINC}/lib") -- set(ZLIB_LIBS debug "${ZLIB_LIBDIR}/zlib_d.lib" optimized "${ZLIB_LIBDIR}/zlib_o.lib") -+ link_directories(${WITH_ZLIBINC}/lib) -+ set(ZLIB_LIBS CONAN_PKG::zlib) - message(STATUS "Info: DCMTK ZLIB support will be enabled") - set(WITH_ZLIB 1) - else() # turn off library if library path not set -@@ -131,8 +133,8 @@ if(WIN32 AND NOT MINGW) - if(DCMTK_WITH_SNDFILE) - if(WITH_SNDFILEINC) - set(SNDFILE_INCDIR "${WITH_SNDFILEINC}/include") -- set(SNDFILE_LIBDIR "${WITH_SNDFILEINC}/lib") -- set(SNDFILE_LIBS debug "${SNDFILE_LIBDIR}/libsndfile_d.lib" optimized "${SNDFILE_LIBDIR}/libsndfile_o.lib") -+ link_directories(${WITH_SNDFILEINC}/lib) -+ set(SNDFILE_LIBS CONAN_PKG::libsndfile) - message(STATUS "Info: DCMTK SNDFILE support will be enabled") - set(WITH_SNDFILE 1) - else() # turn off library if library path not set -@@ -146,8 +148,8 @@ if(WIN32 AND NOT MINGW) - if(DCMTK_WITH_ICONV) - if(WITH_LIBICONVINC) - set(LIBICONV_INCDIR "${WITH_LIBICONVINC}/include") -- set(LIBICONV_LIBDIR "${WITH_LIBICONVINC}/lib") -- set(LIBICONV_LIBS debug "${LIBICONV_LIBDIR}/libiconv_d.lib" optimized "${LIBICONV_LIBDIR}/libiconv_o.lib") -+ link_directories(${WITH_LIBICONVINC}/lib) -+ set(LIBICONV_LIBS CONAN_PKG::libiconv) - message(STATUS "Info: DCMTK ICONV support will be enabled") - set(WITH_LIBICONV 1) - else() # turn off library if library path not set -@@ -170,7 +172,7 @@ if(WIN32 AND NOT MINGW) - else() - set(OPENJPEG_INCDIR "${WITH_OPENJPEGINC1}") - set(OPENJPEG_LIBDIR "${WITH_OPENJPEGINC}/lib") -- set(OPENJPEG_LIBS debug "${OPENJPEG_LIBDIR}/openjp2_d.lib" optimized "${OPENJPEG_LIBDIR}/openjp2_o.lib") -+ set(OPENJPEG_LIBS CONAN_PKG::openjpeg) - message(STATUS "Info: DCMTK OpenJPEG support will be enabled") - set(WITH_OPENJPEG 1) - endif() -@@ -185,7 +187,7 @@ else(WIN32 AND NOT MINGW) - - # Find TIFF - if(DCMTK_WITH_TIFF) -- find_package(TIFF QUIET) -+ find_package(TIFF REQUIRED) - # turn off library if it could not be found - if(NOT TIFF_FOUND) - message(STATUS "Warning: TIFF support will be disabled because libtiff was not found.") -@@ -194,21 +196,21 @@ else(WIN32 AND NOT MINGW) - else() - set(WITH_LIBTIFF 1) - # libtiff can be compiled with libjpeg support; if available, add libjpeg to library and include path -- find_package(JPEG QUIET) -+ find_package(JPEG REQUIRED) - if(NOT JPEG_FOUND) - message(STATUS "Info: DCMTK TIFF support will be enabled (but without JPEG)") -- include_directories(${TIFF_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS}) - else() - message(STATUS "Info: DCMTK TIFF support will be enabled") -- include_directories(${TIFF_INCLUDE_DIR} ${JPEG_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS} ${JPEG_INCLUDE_DIRS}) - endif() -- set(LIBTIFF_LIBS ${TIFF_LIBRARY} ${JPEG_LIBRARY}) -+ set(LIBTIFF_LIBS ${TIFF_LIBRARIES} ${JPEG_LIBRARIES}) - endif() - endif() - - # Find PNG - if(DCMTK_WITH_PNG) -- find_package(PNG QUIET) -+ find_package(PNG REQUIRED) - if(NOT PNG_FOUND) - set(DCMTK_WITH_PNG OFF CACHE BOOL "" FORCE) - message(STATUS "Warning: PNG support will be disabled because libpng was not found.") -@@ -217,13 +219,13 @@ else(WIN32 AND NOT MINGW) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - include_directories(${PNG_INCLUDE_DIR}) -- set(LIBPNG_LIBS ${PNG_LIBRARY}) -+ set(LIBPNG_LIBS ${PNG_LIBRARIES}) - endif() - endif() - - # Find OpenSSL - if(DCMTK_WITH_OPENSSL) -- find_package(OpenSSL QUIET) -+ find_package(OpenSSL REQUIRED) - if(NOT OPENSSL_FOUND) - message(STATUS "Warning: OPENSSL support will be disabled because openssl was not found.") - set(WITH_OPENSSL "") -@@ -254,7 +256,7 @@ else(WIN32 AND NOT MINGW) - - # Find libXML2 - if(DCMTK_WITH_XML) -- find_package(LibXml2 QUIET) -+ find_package(LibXml2 REQUIRED) - if(NOT LIBXML2_FOUND) - message(STATUS "Warning: XML support will be disabled because libxml2 was not found.") - set(WITH_LIBXML "") -@@ -269,7 +271,7 @@ else(WIN32 AND NOT MINGW) - - # Find zlib - if(DCMTK_WITH_ZLIB) -- find_package(ZLIB QUIET) -+ find_package(ZLIB REQUIRED) - if(NOT ZLIB_FOUND) - message(STATUS "Warning: ZLIB support will be disabled because zlib was not found.") - set(WITH_ZLIB "") -@@ -284,7 +286,7 @@ else(WIN32 AND NOT MINGW) - - # Find libsndfile - if(DCMTK_WITH_SNDFILE) -- find_package(Sndfile QUIET) -+ find_package(Sndfile REQUIRED) - if(NOT SNDFILE_LIBS) - message(STATUS "Warning: SNDFILE support will be disabled because libsndfile was not found.") - set(WITH_SNDFILE "") -@@ -292,16 +294,16 @@ else(WIN32 AND NOT MINGW) - else() - message(STATUS "Info: DCMTK SNDFILE support will be enabled") - set(WITH_SNDFILE 1) -- include_directories(${SNDFILE_INCLUDE_DIRS}) -- set(SNDFILE_LIBS ${SNDFILE_LIBRARIES}) -+ include_directories(${Sndfile_INCLUDE_DIRS}) -+ set(SNDFILE_LIBS ${Sndfile_LIBRARIES}) - endif() - endif() - - # Find libiconv - if(DCMTK_WITH_ICONV) -- find_package(Iconv QUIET) -- find_package(Charset QUIET) -- if(ICONV_FOUND) -+ find_package(Iconv REQUIRED) -+ #find_package(Charset REQUIRED) #FIXME?? -+ if(Iconv_FOUND) - if(NOT Iconv_IS_BUILT_IN) - set(LIBICONV_FOUND ${ICONV_FOUND}) - else() -@@ -322,14 +324,14 @@ else(WIN32 AND NOT MINGW) - set(WITH_LIBICONV 1) - set(LIBICONV_INCDIR ${LIBICONV_INCLUDE_DIRS} ${Iconv_INCLUDE_DIRS} ${ICONV_INCLUDE_DIR} ${LIBCHARSET_INCLUDE_DIRS}) - set(LIBICONV_LIBDIR ${LIBICONV_LIBDIR}) -- set(LIBICONV_LIBS ${LIBICONV_LIBRARIES} ${Iconv_LIBRARIES} ${ICONV_LIBRARIES} ${LIBCHARSET_LIBRARY}) -+ set(LIBICONV_LIBS Iconv::Iconv) - include_directories(${LIBICONV_INCDIR}) - endif() - endif() - - # Find libwrap - if(DCMTK_WITH_WRAP) -- find_package(Wrap QUIET) -+ find_package(Wrap REQUIRED) - if(NOT WRAP_FOUND) - message(STATUS "Warning: WRAP support will be disabled because libwrap was not found.") - set(WITH_TCPWRAPPER "") -@@ -344,7 +346,7 @@ else(WIN32 AND NOT MINGW) - - # Find OpenJPEG - if(DCMTK_WITH_OPENJPEG) -- find_package(OpenJPEG QUIET) -+ find_package(OpenJPEG REQUIRED) - if(NOT OPENJPEG_FOUND) - message(STATUS "Warning: OpenJPEG support will be disabled because the OpenJPEG library was not found.") - set(WITH_OPENJPEG "") -@@ -352,8 +354,8 @@ else(WIN32 AND NOT MINGW) - else() - message(STATUS "Info: DCMTK OpenJPEG support will be enabled") - set(WITH_OPENJPEG 1) -- include_directories(${OPENJPEG_INCLUDE_DIRS}) -- set(OPENJPEG_LIBS ${OPENJPEG_LIBRARIES}) -+ include_directories(${OpenJPEG_INCLUDE_DIRS}) -+ set(OPENJPEG_LIBS ${OpenJPEG_LIBRARIES}) - endif() - endif() - -@@ -371,7 +373,7 @@ if(NOT DEFINED DCMTK_WITH_STDLIBC_ICONV) - endif() - - if(DCMTK_WITH_ICU) -- find_package(ICU COMPONENTS uc data QUIET) -+ find_package(ICU COMPONENTS uc data REQUIRED) - if(NOT ICU_FOUND) - message(STATUS "Warning: ICU support will be disabled because the ICU were not found.") - set(DCMTK_WITH_ICU OFF CACHE BOOL "" FORCE) -@@ -387,7 +389,7 @@ endif() - - # Find doxygen - if(DCMTK_WITH_DOXYGEN) -- find_package(Doxygen QUIET) # will set variable DOXYGEN_EXECUTABLE -+ find_package(Doxygen REQUIRED) # will set variable DOXYGEN_EXECUTABLE - if(NOT DOXYGEN_FOUND) - message(STATUS "Warning: DOXYGEN support will be disabled because doxygen was not found.") - set(DCMTK_WITH_DOXYGEN OFF CACHE BOOL "" FORCE) diff --git a/recipes/dcmtk/all/patches/0002-cmake-use-conan-packages.patch b/recipes/dcmtk/all/patches/0002-cmake-use-conan-packages.patch deleted file mode 100644 index d566a50607ec76..00000000000000 --- a/recipes/dcmtk/all/patches/0002-cmake-use-conan-packages.patch +++ /dev/null @@ -1,225 +0,0 @@ ---- CMake/3rdparty.cmake -+++ CMake/3rdparty.cmake -@@ -21,7 +21,7 @@ mark_as_advanced(DCMTK_USE_FIND_PACKAGE) - if(DCMTK_USE_FIND_PACKAGE) - # Find TIFF - if(DCMTK_WITH_TIFF) -- find_package(TIFF QUIET) -+ find_package(TIFF REQUIRED) - # turn off library if it could not be found - if(NOT TIFF_FOUND) - message(STATUS "Warning: TIFF support will be disabled because libtiff was not found.") -@@ -30,21 +30,21 @@ if(DCMTK_USE_FIND_PACKAGE) - else() - set(WITH_LIBTIFF 1) - # libtiff can be compiled with libjpeg support; if available, add libjpeg to library and include path -- find_package(JPEG QUIET) -+ find_package(JPEG REQUIRED) - if(NOT JPEG_FOUND) - message(STATUS "Info: DCMTK TIFF support will be enabled (but without JPEG)") -- include_directories(${TIFF_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS}) - else() - message(STATUS "Info: DCMTK TIFF support will be enabled") -- include_directories(${TIFF_INCLUDE_DIR} ${JPEG_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS} ${JPEG_INCLUDE_DIRS}) - endif() -- set(LIBTIFF_LIBS ${TIFF_LIBRARY} ${JPEG_LIBRARY}) -+ set(LIBTIFF_LIBS ${TIFF_LIBRARIES} ${JPEG_LIBRARIES}) - endif() - endif() - - # Find PNG - if(DCMTK_WITH_PNG) -- find_package(PNG QUIET) -+ find_package(PNG REQUIRED) - if(NOT PNG_FOUND) - set(DCMTK_WITH_PNG OFF CACHE BOOL "" FORCE) - message(STATUS "Warning: PNG support will be disabled because libpng was not found.") -@@ -53,13 +53,13 @@ if(DCMTK_USE_FIND_PACKAGE) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - include_directories(${PNG_INCLUDE_DIR}) -- set(LIBPNG_LIBS ${PNG_LIBRARY}) -+ set(LIBPNG_LIBS ${PNG_LIBRARIES}) - endif() - endif() - - # Find OpenSSL - if(DCMTK_WITH_OPENSSL) -- find_package(OpenSSL QUIET) -+ find_package(OpenSSL REQUIRED) - if(NOT OPENSSL_FOUND) - message(STATUS "Warning: OPENSSL support will be disabled because openssl was not found.") - set(WITH_OPENSSL "") -@@ -90,7 +90,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find libXML2 - if(DCMTK_WITH_XML) -- find_package(LibXml2 QUIET) -+ find_package(LibXml2 REQUIRED) - if(NOT LIBXML2_FOUND) - message(STATUS "Warning: XML support will be disabled because libxml2 was not found.") - set(WITH_LIBXML "") -@@ -105,7 +105,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find zlib - if(DCMTK_WITH_ZLIB) -- find_package(ZLIB QUIET) -+ find_package(ZLIB REQUIRED) - if(NOT ZLIB_FOUND) - message(STATUS "Warning: ZLIB support will be disabled because zlib was not found.") - set(WITH_ZLIB "") -@@ -120,7 +120,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find libsndfile - if(DCMTK_WITH_SNDFILE) -- find_package(Sndfile QUIET) -+ find_package(Sndfile REQUIRED) - if(NOT SNDFILE_LIBS) - message(STATUS "Warning: SNDFILE support will be disabled because libsndfile was not found.") - set(WITH_SNDFILE "") -@@ -128,16 +128,16 @@ if(DCMTK_USE_FIND_PACKAGE) - else() - message(STATUS "Info: DCMTK SNDFILE support will be enabled") - set(WITH_SNDFILE 1) -- include_directories(${SNDFILE_INCLUDE_DIRS}) -- set(SNDFILE_LIBS ${SNDFILE_LIBRARIES}) -+ include_directories(${Sndfile_INCLUDE_DIRS}) -+ set(SNDFILE_LIBS ${Sndfile_LIBRARIES}) - endif() - endif() - - # Find libiconv - if(DCMTK_WITH_ICONV) -- find_package(Iconv QUIET) -- find_package(Charset QUIET) -- if(ICONV_FOUND) -+ find_package(Iconv REQUIRED) -+ #find_package(Charset QUIET) #FIXME?? -+ if(Iconv_FOUND) - if(NOT Iconv_IS_BUILT_IN) - set(LIBICONV_FOUND ${ICONV_FOUND}) - else() -@@ -158,7 +158,7 @@ if(DCMTK_USE_FIND_PACKAGE) - set(WITH_LIBICONV 1) - set(LIBICONV_INCDIR ${LIBICONV_INCLUDE_DIRS} ${Iconv_INCLUDE_DIRS} ${ICONV_INCLUDE_DIR} ${LIBCHARSET_INCLUDE_DIRS}) - set(LIBICONV_LIBDIR ${LIBICONV_LIBDIR}) -- set(LIBICONV_LIBS ${LIBICONV_LIBRARIES} ${Iconv_LIBRARIES} ${ICONV_LIBRARIES} ${LIBCHARSET_LIBRARY}) -+ set(LIBICONV_LIBS Iconv::Iconv) - include_directories(${LIBICONV_INCDIR}) - endif() - endif() -@@ -234,13 +234,15 @@ else() - # libxml support: configure compiler - if(DCMTK_WITH_XML) - if(WITH_LIBXMLINC) -- set(LIBXML_INCDIR "${WITH_LIBXMLINC}/include") -- set(LIBXML_LIBDIR "${WITH_LIBXMLINC}/lib") -- set(LIBXML_LIBS debug "${LIBXML_LIBDIR}/libxml2_d.lib" optimized "${LIBXML_LIBDIR}/libxml2_o.lib" debug "${LIBXML_LIBDIR}/iconv_d.lib" optimized "${LIBXML_LIBDIR}/iconv_o.lib") -+ set(LIBXML_INCDIR ${CONAN_INCLUDE_DIRS_LIBXML2} ${CONAN_INCLUDE_DIRS_ICONV}) -+ link_directories(${WITH_LIBXMLINC}/lib) -+ set(LIBXML_LIBS ${CONAN_LIBS_LIBXML2}) - message(STATUS "Info: DCMTK XML support will be enabled") - set(WITH_LIBXML 1) -+ if(NOT WITH_LIBXML_SHARED) - # this hides some warnings that are emitted when linking against libxmlXXX.lib instead of linking the DLL directly - add_definitions("-DLIBXML_STATIC") -+ endif() - else() # turn off library if library path not set - message(STATUS "Warning: XML support will be disabled because libxml2 directory is not specified. Correct path and re-enable DCMTK_WITH_XML.") - set(DCMTK_WITH_XML OFF CACHE BOOL "" FORCE) -@@ -252,8 +254,8 @@ else() - if(DCMTK_WITH_PNG) - if(WITH_LIBPNGINC) - set(LIBPNG_INCDIR "${WITH_LIBPNGINC}/include") -- set(LIBPNG_LIBDIR "${WITH_LIBPNGINC}/lib") -- set(LIBPNG_LIBS debug "${LIBPNG_LIBDIR}/libpng_d.lib" optimized "${LIBPNG_LIBDIR}/libpng_o.lib") -+ link_directories(${WITH_LIBPNGINC}/lib) -+ set(LIBPNG_LIBS CONAN_PKG::libpng) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - else() # turn off library if library path not set -@@ -267,8 +269,8 @@ else() - if(DCMTK_WITH_TIFF) - if(WITH_LIBTIFFINC) - set(LIBTIFF_INCDIR "${WITH_LIBTIFFINC}/include") -- set(LIBTIFF_LIBDIR "${WITH_LIBTIFFINC}/lib") -- set(LIBTIFF_LIBS debug "${LIBTIFF_LIBDIR}/libtiff_d.lib" optimized "${LIBTIFF_LIBDIR}/libtiff_o.lib") -+ link_directories(${WITH_LIBTIFFINC}/lib) -+ set(LIBTIFF_LIBS CONAN_PKG::libtiff) - message(STATUS "Info: DCMTK TIFF support will be enabled") - set(WITH_LIBTIFF 1) - else() # turn off library if library path not set -@@ -284,9 +286,9 @@ else() - include(CheckCXXSourceCompiles) - set(OPENSSL_BINDIR "${WITH_OPENSSLINC}/bin") - set(OPENSSL_INCDIR "${WITH_OPENSSLINC}/include") -- set(OPENSSL_LIBDIR "${WITH_OPENSSLINC}/lib") -+ link_directories(${WITH_OPENSSLINC}/lib) - # starting with OpenSSL 1.1.0, the Windows crypt32 library is needed for a static link of OpenSSL. -- set(OPENSSL_LIBS "crypt32" debug "${OPENSSL_LIBDIR}/dcmtkssl_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkssl_o.lib" debug "${OPENSSL_LIBDIR}/dcmtkcrypto_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkcrypto_o.lib") -+ set(OPENSSL_LIBS ${CONAN_LIBS_OPENSSL}) - set(TEMP_INCLUDES "${CMAKE_REQUIRED_INCLUDES}") - list(APPEND CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCDIR}") - CHECK_CXX_SOURCE_COMPILES("extern \"C\" {\n#include \n}\nint main(){\n#if OPENSSL_VERSION_NUMBER < 0x10001000L\n#error OpenSSL too old\n#endif\n}\n" OPENSSL_VERSION_CHECK) -@@ -310,8 +312,8 @@ else() - if(DCMTK_WITH_ZLIB) - if(WITH_ZLIBINC) - set(ZLIB_INCDIR "${WITH_ZLIBINC}/include") -- set(ZLIB_LIBDIR "${WITH_ZLIBINC}/lib") -- set(ZLIB_LIBS debug "${ZLIB_LIBDIR}/zlib_d.lib" optimized "${ZLIB_LIBDIR}/zlib_o.lib") -+ link_directories(${WITH_ZLIBINC}/lib) -+ set(ZLIB_LIBS CONAN_PKG::zlib) - message(STATUS "Info: DCMTK ZLIB support will be enabled") - set(WITH_ZLIB 1) - else() # turn off library if library path not set -@@ -325,8 +327,8 @@ else() - if(DCMTK_WITH_SNDFILE) - if(WITH_SNDFILEINC) - set(SNDFILE_INCDIR "${WITH_SNDFILEINC}/include") -- set(SNDFILE_LIBDIR "${WITH_SNDFILEINC}/lib") -- set(SNDFILE_LIBS debug "${SNDFILE_LIBDIR}/libsndfile_d.lib" optimized "${SNDFILE_LIBDIR}/libsndfile_o.lib") -+ link_directories(${WITH_SNDFILEINC}/lib) -+ set(SNDFILE_LIBS CONAN_PKG::libsndfile) - message(STATUS "Info: DCMTK SNDFILE support will be enabled") - set(WITH_SNDFILE 1) - else() # turn off library if library path not set -@@ -340,8 +342,8 @@ else() - if(DCMTK_WITH_ICONV) - if(WITH_LIBICONVINC) - set(LIBICONV_INCDIR "${WITH_LIBICONVINC}/include") -- set(LIBICONV_LIBDIR "${WITH_LIBICONVINC}/lib") -- set(LIBICONV_LIBS debug "${LIBICONV_LIBDIR}/libiconv_d.lib" optimized "${LIBICONV_LIBDIR}/libiconv_o.lib") -+ link_directories(${WITH_LIBICONVINC}/lib) -+ set(LIBICONV_LIBS CONAN_PKG::libiconv) - message(STATUS "Info: DCMTK ICONV support will be enabled") - set(WITH_LIBICONV 1) - else() # turn off library if library path not set -@@ -364,7 +366,7 @@ else() - else() - set(OPENJPEG_INCDIR "${WITH_OPENJPEGINC1}") - set(OPENJPEG_LIBDIR "${WITH_OPENJPEGINC}/lib") -- set(OPENJPEG_LIBS debug "${OPENJPEG_LIBDIR}/openjp2_d.lib" optimized "${OPENJPEG_LIBDIR}/openjp2_o.lib") -+ set(OPENJPEG_LIBS CONAN_PKG::openjpeg) - message(STATUS "Info: DCMTK OpenJPEG support will be enabled") - set(WITH_OPENJPEG 1) - endif() -@@ -388,7 +390,7 @@ if(NOT DEFINED DCMTK_WITH_STDLIBC_ICONV) - endif() - - if(DCMTK_WITH_ICU) -- find_package(ICU COMPONENTS uc data QUIET) -+ find_package(ICU COMPONENTS uc data REQUIRED) - if(NOT ICU_FOUND) - message(STATUS "Warning: ICU support will be disabled because the ICU were not found.") - set(DCMTK_WITH_ICU OFF CACHE BOOL "" FORCE) -@@ -404,7 +406,7 @@ endif() - - # Find doxygen - if(DCMTK_WITH_DOXYGEN) -- find_package(Doxygen QUIET) # will set variable DOXYGEN_EXECUTABLE -+ find_package(Doxygen REQUIRED) # will set variable DOXYGEN_EXECUTABLE - if(NOT DOXYGEN_FOUND) - message(STATUS "Warning: DOXYGEN support will be disabled because doxygen was not found.") - set(DCMTK_WITH_DOXYGEN OFF CACHE BOOL "" FORCE) diff --git a/recipes/dcmtk/all/patches/3.6.7-0001-cmake-robust-deps-handling.patch b/recipes/dcmtk/all/patches/3.6.7-0001-cmake-robust-deps-handling.patch new file mode 100644 index 00000000000000..264a486b31bc69 --- /dev/null +++ b/recipes/dcmtk/all/patches/3.6.7-0001-cmake-robust-deps-handling.patch @@ -0,0 +1,162 @@ +--- a/CMake/3rdparty.cmake ++++ b/CMake/3rdparty.cmake +@@ -21,7 +21,7 @@ mark_as_advanced(DCMTK_USE_FIND_PACKAGE) + if(DCMTK_USE_FIND_PACKAGE) + # Find TIFF + if(DCMTK_WITH_TIFF) +- find_package(TIFF QUIET) ++ find_package(TIFF REQUIRED) + # turn off library if it could not be found + if(NOT TIFF_FOUND) + message(STATUS "Warning: TIFF support will be disabled because libtiff was not found.") +@@ -30,21 +30,13 @@ if(DCMTK_USE_FIND_PACKAGE) + else() + set(WITH_LIBTIFF 1) + # libtiff can be compiled with libjpeg support; if available, add libjpeg to library and include path +- find_package(JPEG QUIET) +- if(NOT JPEG_FOUND) +- message(STATUS "Info: DCMTK TIFF support will be enabled (but without JPEG)") +- include_directories(${TIFF_INCLUDE_DIR}) +- else() +- message(STATUS "Info: DCMTK TIFF support will be enabled") +- include_directories(${TIFF_INCLUDE_DIR} ${JPEG_INCLUDE_DIR}) +- endif() +- set(LIBTIFF_LIBS ${TIFF_LIBRARY} ${TIFF_EXTRA_LIBS_STATIC} ${JPEG_LIBRARY}) ++ set(LIBTIFF_LIBS TIFF::TIFF) + endif() + endif() + + # Find PNG + if(DCMTK_WITH_PNG) +- find_package(PNG QUIET) ++ find_package(PNG REQUIRED) + if(NOT PNG_FOUND) + set(DCMTK_WITH_PNG OFF CACHE BOOL "" FORCE) + message(STATUS "Warning: PNG support will be disabled because libpng was not found.") +@@ -53,33 +45,23 @@ if(DCMTK_USE_FIND_PACKAGE) + message(STATUS "Info: DCMTK PNG support will be enabled") + set(WITH_LIBPNG 1) + include_directories(${PNG_INCLUDE_DIR}) +- set(LIBPNG_LIBS ${PNG_LIBRARY}) ++ set(LIBPNG_LIBS PNG::PNG) + endif() + endif() + + # Find OpenSSL + if(DCMTK_WITH_OPENSSL) +- find_package(OpenSSL QUIET) ++ find_package(OpenSSL REQUIRED) + if(NOT OPENSSL_FOUND) + message(STATUS "Warning: OPENSSL support will be disabled because openssl was not found.") + set(WITH_OPENSSL "") + set(DCMTK_WITH_OPENSSL OFF CACHE BOOL "" FORCE) + else() +- include(CheckLibraryExists) +- include(CheckCXXSourceCompiles) +- set(TEMP_INCLUDES "${CMAKE_REQUIRED_INCLUDES}") +- list(APPEND CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCLUDE_DIR}") +- CHECK_CXX_SOURCE_COMPILES("extern \"C\" {\n#include \n}\nint main(){\n#if OPENSSL_VERSION_NUMBER < 0x10001000L\n#error OpenSSL too old\n#endif\n}\n" OPENSSL_VERSION_CHECK) +- set(CMAKE_REQUIRED_INCLUDES "${TEMP_INCLUDES}") +- if(OPENSSL_VERSION_CHECK) ++ if(1) + message(STATUS "Info: DCMTK OPENSSL support will be enabled") + set(WITH_OPENSSL 1) + include_directories(${OPENSSL_INCLUDE_DIR}) +- set(OPENSSL_LIBS ${OPENSSL_LIBRARIES} ${OPENSSL_EXTRA_LIBS_STATIC}) +- CHECK_LIBRARY_EXISTS(dl dlopen "" HAVE_LIBDL) +- if(HAVE_LIBDL) +- set(OPENSSL_LIBS ${OPENSSL_LIBS} dl) +- endif() ++ set(OPENSSL_LIBS OpenSSL::SSL OpenSSL::Crypto) + else() + message(STATUS "Info: DCMTK OPENSSL support will be disabled: DCMTK requires OpenSSL version 1.0.1 or newer") + set(DCMTK_WITH_OPENSSL OFF CACHE BOOL "" FORCE) +@@ -90,7 +72,7 @@ if(DCMTK_USE_FIND_PACKAGE) + + # Find libXML2 + if(DCMTK_WITH_XML) +- find_package(LibXml2 QUIET) ++ find_package(LibXml2 REQUIRED MODULE) + if(NOT LIBXML2_FOUND) + message(STATUS "Warning: XML support will be disabled because libxml2 was not found.") + set(WITH_LIBXML "") +@@ -99,13 +81,13 @@ if(DCMTK_USE_FIND_PACKAGE) + message(STATUS "Info: DCMTK XML support will be enabled") + set(WITH_LIBXML 1) + include_directories(${LIBXML2_INCLUDE_DIR}) +- set(LIBXML_LIBS ${LIBXML2_LIBRARIES} ${LIBXML2_EXTRA_LIBS_STATIC}) ++ set(LIBXML_LIBS LibXml2::LibXml2) + endif() + endif() + + # Find zlib + if(DCMTK_WITH_ZLIB) +- find_package(ZLIB QUIET) ++ find_package(ZLIB REQUIRED) + if(NOT ZLIB_FOUND) + message(STATUS "Warning: ZLIB support will be disabled because zlib was not found.") + set(WITH_ZLIB "") +@@ -114,7 +96,7 @@ if(DCMTK_USE_FIND_PACKAGE) + message(STATUS "Info: DCMTK ZLIB support will be enabled") + set(WITH_ZLIB 1) + include_directories(${ZLIB_INCLUDE_DIRS}) +- set(ZLIB_LIBS ${ZLIB_LIBRARIES}) ++ set(ZLIB_LIBS ZLIB::ZLIB) + endif() + endif() + +@@ -135,11 +117,10 @@ if(DCMTK_USE_FIND_PACKAGE) + + # Find libiconv + if(DCMTK_WITH_ICONV) +- find_package(Iconv QUIET) +- find_package(LIBCHARSET QUIET) +- if(ICONV_FOUND) ++ find_package(Iconv REQUIRED) ++ if(Iconv_FOUND) + if(NOT Iconv_IS_BUILT_IN) +- set(LIBICONV_FOUND ${ICONV_FOUND}) ++ set(LIBICONV_FOUND ${Iconv_FOUND}) + else() + message(STATUS "Info: found builtin ICONV support inside the C standard library.") + set(DCMTK_WITH_STDLIBC_ICONV ON CACHE BOOL "" FORCE) +@@ -149,7 +130,7 @@ if(DCMTK_USE_FIND_PACKAGE) + set(LIBICONV_SECOND_ARGUMENT_CONST ${ICONV_SECOND_ARGUMENT_IS_CONST} CACHE INTERNAL "${HELPSTRING}") + endif() + endif() +- if(NOT LIBICONV_FOUND OR NOT LIBCHARSET_FOUND) ++ if(NOT LIBICONV_FOUND) + message(STATUS "Warning: ICONV support will be disabled because libiconv was not found. Correct LIBICONV_LIBDIR and LIBICONV_INCLUDE_DIR and re-enable DCMTK_WITH_ICONV.") + set(DCMTK_WITH_ICONV OFF CACHE BOOL "" FORCE) + set(WITH_LIBICONV "") +@@ -157,24 +138,24 @@ if(DCMTK_USE_FIND_PACKAGE) + message(STATUS "Info: DCMTK ICONV support will be enabled") + set(WITH_LIBICONV 1) + set(LIBICONV_INCDIR ${LIBICONV_INCLUDE_DIRS} ${Iconv_INCLUDE_DIRS} ${ICONV_INCLUDE_DIR} ${LIBCHARSET_INCLUDE_DIRS}) +- set(LIBICONV_LIBDIR ${LIBICONV_LIBDIR}) +- set(LIBICONV_LIBS ${LIBICONV_LIBRARIES} ${Iconv_LIBRARIES} ${ICONV_LIBRARIES} ${LIBCHARSET_LIBRARY}) ++ set(LIBICONV_LIBDIR ${Iconv_LIB_DIRS}) ++ set(LIBICONV_LIBS Iconv::Iconv) + include_directories(${LIBICONV_INCDIR}) + endif() + endif() + + # Find libwrap + if(DCMTK_WITH_WRAP) +- find_package(WRAP QUIET) +- if(NOT WRAP_FOUND) ++ find_package(tcp-wrappers REQUIRED CONFIG) ++ if(NOT tcp-wrappers_FOUND) + message(STATUS "Warning: WRAP support will be disabled because libwrap was not found.") + set(WITH_TCPWRAPPER "") + set(DCMTK_WITH_WRAP OFF CACHE BOOL "" FORCE) + else() + message(STATUS "Info: DCMTK WRAP support will be enabled") + set(WITH_TCPWRAPPER 1) +- include_directories(${WRAP_INCLUDE_DIRS}) +- set(WRAP_LIBS ${WRAP_LIBRARIES} ${WRAP_EXTRA_LIBS_STATIC}) ++ include_directories(${tcp-wrappers_INCLUDE_DIRS}) ++ set(WRAP_LIBS tcp-wrappers::tcp-wrappers) + endif() + endif() + diff --git a/recipes/dcmtk/all/patches/3.6.7-0002-cmake-check-openssl-symbol.patch b/recipes/dcmtk/all/patches/3.6.7-0002-cmake-check-openssl-symbol.patch new file mode 100644 index 00000000000000..a3f1d5ac2c44be --- /dev/null +++ b/recipes/dcmtk/all/patches/3.6.7-0002-cmake-check-openssl-symbol.patch @@ -0,0 +1,89 @@ +--- a/CMake/dcmtkPrepare.cmake ++++ b/CMake/dcmtkPrepare.cmake +@@ -668,48 +668,50 @@ if(DCMTK_WITH_OPENSSL) + CHECK_INCLUDE_FILE_CXX("openssl/provider.h" HAVE_OPENSSL_PROVIDER_H) + + # test presence of functions, constants and macros needed for the dcmtls module +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_get0_param" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET0_PARAM) +- CHECK_FUNCTIONWITHHEADER_EXISTS("RAND_egd" "openssl/rand.h" HAVE_OPENSSL_PROTOTYPE_RAND_EGD) +- CHECK_FUNCTIONWITHHEADER_EXISTS("DH_bits" "openssl/dh.h" HAVE_OPENSSL_PROTOTYPE_DH_BITS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("EVP_PKEY_RSA_PSS" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_RSA_PSS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("EVP_PKEY_base_id" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_BASE_ID) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_get_cert_store" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET_CERT_STORE) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_get_ciphers" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET_CIPHERS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set0_tmp_dh_pkey" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET0_TMP_DH_PKEY) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set1_curves(0,0,0)" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET1_CURVES) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set1_sigalgs" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET1_SIGALGS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set_ecdh_auto(0,0)" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_ECDH_AUTO) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set_max_proto_version(0,0)" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_MAX_PROTO_VERSION) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_CTX_set_security_level" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_SECURITY_LEVEL) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_ERROR_WANT_ASYNC" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_ASYNC) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_ERROR_WANT_ASYNC_JOB" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_ASYNC_JOB) +- CHECK_FUNCTIONWITHHEADER_EXISTS("SSL_ERROR_WANT_CLIENT_HELLO_CB" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_CLIENT_HELLO_CB) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TLS1_TXT_ECDHE_RSA_WITH_CHACHA20_POLY1305" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_TLS1_TXT_ECDHE_RSA_WITH_CHACHA20_POLY1305) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TLS_method" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_TLS_METHOD) +- CHECK_FUNCTIONWITHHEADER_EXISTS("X509_STORE_get0_param" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_STORE_GET0_PARAM) +- CHECK_FUNCTIONWITHHEADER_EXISTS("X509_get_signature_nid" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET_SIGNATURE_NID) ++ include(CheckSymbolExists) ++ include(CheckCSourceCompiles) ++ check_symbol_exists("SSL_CTX_get0_param" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET0_PARAM) ++ check_symbol_exists("RAND_egd" "openssl/rand.h" HAVE_OPENSSL_PROTOTYPE_RAND_EGD) ++ check_symbol_exists("DH_bits" "openssl/dh.h" HAVE_OPENSSL_PROTOTYPE_DH_BITS) ++ check_symbol_exists("EVP_PKEY_RSA_PSS" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_RSA_PSS) ++ check_symbol_exists("EVP_PKEY_base_id" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_BASE_ID) ++ check_symbol_exists("SSL_CTX_get_cert_store" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET_CERT_STORE) ++ check_symbol_exists("SSL_CTX_get_ciphers" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_GET_CIPHERS) ++ check_symbol_exists("SSL_CTX_set0_tmp_dh_pkey" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET0_TMP_DH_PKEY) ++ check_c_source_compiles("#include \nint main() {SSL_CTX_set1_curves(0,0,0); return 0;}" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET1_CURVES) ++ check_symbol_exists("SSL_CTX_set1_sigalgs" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET1_SIGALGS) ++ check_c_source_compiles("#include \nint main() {SSL_CTX_set_ecdh_auto(0,0); return 0;}" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_ECDH_AUTO) ++ check_c_source_compiles("#include \nint main() {SSL_CTX_set_max_proto_version(0,0); return 0;}" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_MAX_PROTO_VERSION) ++ check_symbol_exists("SSL_CTX_set_security_level" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_CTX_SET_SECURITY_LEVEL) ++ check_symbol_exists("SSL_ERROR_WANT_ASYNC" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_ASYNC) ++ check_symbol_exists("SSL_ERROR_WANT_ASYNC_JOB" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_ASYNC_JOB) ++ check_symbol_exists("SSL_ERROR_WANT_CLIENT_HELLO_CB" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_SSL_ERROR_WANT_CLIENT_HELLO_CB) ++ check_symbol_exists("TLS1_TXT_ECDHE_RSA_WITH_CHACHA20_POLY1305" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_TLS1_TXT_ECDHE_RSA_WITH_CHACHA20_POLY1305) ++ check_symbol_exists("TLS_method" "openssl/ssl.h" HAVE_OPENSSL_PROTOTYPE_TLS_METHOD) ++ check_symbol_exists("X509_STORE_get0_param" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_STORE_GET0_PARAM) ++ check_symbol_exists("X509_get_signature_nid" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET_SIGNATURE_NID) + + # test presence of functions, constants and macros needed for the dcmsign module +- CHECK_FUNCTIONWITHHEADER_EXISTS("ASN1_STRING_get0_data" "openssl/asn1.h" HAVE_OPENSSL_PROTOTYPE_ASN1_STRING_GET0_DATA) +- CHECK_FUNCTIONWITHHEADER_EXISTS("EVP_PKEY_get0_EC_KEY" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_GET0_EC_KEY) +- CHECK_FUNCTIONWITHHEADER_EXISTS("EVP_PKEY_get_group_name" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_GET_GROUP_NAME) +- CHECK_FUNCTIONWITHHEADER_EXISTS("EVP_PKEY_id" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_ID) +- CHECK_FUNCTIONWITHHEADER_EXISTS("OSSL_PROVIDER_load" "openssl/provider.h" HAVE_OPENSSL_PROTOTYPE_OSSL_PROVIDER_LOAD) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_STATUS_INFO_get0_failure_info" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_FAILURE_INFO) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_STATUS_INFO_get0_status" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_STATUS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_STATUS_INFO_get0_text" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_TEXT) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_VERIFY_CTS_set_certs(0,0)" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTS_SET_CERTS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_VERIFY_CTX_set_data" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_DATA) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_VERIFY_CTX_set_flags" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_FLAGS) +- CHECK_FUNCTIONWITHHEADER_EXISTS("TS_VERIFY_CTX_set_store" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_STORE) +- CHECK_FUNCTIONWITHHEADER_EXISTS("X509_get0_notAfter" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET0_NOTAFTER) +- CHECK_FUNCTIONWITHHEADER_EXISTS("X509_get0_notBefore" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET0_NOTBEFORE) ++ check_symbol_exists("ASN1_STRING_get0_data" "openssl/asn1.h" HAVE_OPENSSL_PROTOTYPE_ASN1_STRING_GET0_DATA) ++ check_symbol_exists("EVP_PKEY_get0_EC_KEY" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_GET0_EC_KEY) ++ check_symbol_exists("EVP_PKEY_get_group_name" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_GET_GROUP_NAME) ++ check_symbol_exists("EVP_PKEY_id" "openssl/evp.h" HAVE_OPENSSL_PROTOTYPE_EVP_PKEY_ID) ++ check_symbol_exists("OSSL_PROVIDER_load" "openssl/provider.h" HAVE_OPENSSL_PROTOTYPE_OSSL_PROVIDER_LOAD) ++ check_symbol_exists("TS_STATUS_INFO_get0_failure_info" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_FAILURE_INFO) ++ check_symbol_exists("TS_STATUS_INFO_get0_status" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_STATUS) ++ check_symbol_exists("TS_STATUS_INFO_get0_text" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_STATUS_INFO_GET0_TEXT) ++ check_c_source_compiles("#include \nint main() {TS_VERIFY_CTS_set_certs(0,0); return 0;}" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTS_SET_CERTS) ++ check_symbol_exists("TS_VERIFY_CTX_set_data" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_DATA) ++ check_symbol_exists("TS_VERIFY_CTX_set_flags" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_FLAGS) ++ check_symbol_exists("TS_VERIFY_CTX_set_store" "openssl/ts.h" HAVE_OPENSSL_PROTOTYPE_TS_VERIFY_CTX_SET_STORE) ++ check_symbol_exists("X509_get0_notAfter" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET0_NOTAFTER) ++ check_symbol_exists("X509_get0_notBefore" "openssl/x509.h" HAVE_OPENSSL_PROTOTYPE_X509_GET0_NOTBEFORE) + + # check if type EVP_MD_CTX is defined as typedef for "struct evp_md_ctx_st" (new) or "struct env_md_ctx_st" (old) +- CHECK_FUNCTIONWITHHEADER_EXISTS("struct evp_md_ctx_st *a; EVP_MD_CTX *b=a" "openssl/evp.h" HAVE_OPENSSL_DECLARATION_NEW_EVP_MD_CTX) ++ check_c_source_compiles("#include \nint main() {struct evp_md_ctx_st *a; EVP_MD_CTX *b=a; return 0;}" HAVE_OPENSSL_DECLARATION_NEW_EVP_MD_CTX) + + # check if the first parameter passed to X509_ALGOR_get0() should be "const ASN1_OBJECT **" (new) or "ASN1_OBJECT **" (old) +- CHECK_FUNCTIONWITHHEADER_EXISTS("const ASN1_OBJECT *a; X509_ALGOR_get0(&a,0,0,0)" "openssl/x509.h" HAVE_OPENSSL_X509_ALGOR_GET0_CONST_PARAM) ++ check_c_source_compiles("#include \nint main() {const ASN1_OBJECT *a; X509_ALGOR_get0(&a,0,0,0); return 0;}" HAVE_OPENSSL_X509_ALGOR_GET0_CONST_PARAM) + + # restore previous value of CMAKE_REQUIRED_LIBRARIES + set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES_TEMP}) diff --git a/recipes/dcmtk/all/patches/cmake-patching-3-6-7.patch b/recipes/dcmtk/all/patches/cmake-patching-3-6-7.patch deleted file mode 100644 index b10d0378042ba8..00000000000000 --- a/recipes/dcmtk/all/patches/cmake-patching-3-6-7.patch +++ /dev/null @@ -1,216 +0,0 @@ ---- CMake/3rdparty.cmake -+++ CMake/3rdparty.cmake -@@ -21,7 +21,7 @@ mark_as_advanced(DCMTK_USE_FIND_PACKAGE) - if(DCMTK_USE_FIND_PACKAGE) - # Find TIFF - if(DCMTK_WITH_TIFF) -- find_package(TIFF QUIET) -+ find_package(TIFF REQUIRED) - # turn off library if it could not be found - if(NOT TIFF_FOUND) - message(STATUS "Warning: TIFF support will be disabled because libtiff was not found.") -@@ -30,21 +30,21 @@ if(DCMTK_USE_FIND_PACKAGE) - else() - set(WITH_LIBTIFF 1) - # libtiff can be compiled with libjpeg support; if available, add libjpeg to library and include path -- find_package(JPEG QUIET) -+ find_package(JPEG REQUIRED) - if(NOT JPEG_FOUND) - message(STATUS "Info: DCMTK TIFF support will be enabled (but without JPEG)") -- include_directories(${TIFF_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS}) - else() - message(STATUS "Info: DCMTK TIFF support will be enabled") -- include_directories(${TIFF_INCLUDE_DIR} ${JPEG_INCLUDE_DIR}) -+ include_directories(${TIFF_INCLUDE_DIRS} ${JPEG_INCLUDE_DIRS}) - endif() -- set(LIBTIFF_LIBS ${TIFF_LIBRARY} ${TIFF_EXTRA_LIBS_STATIC} ${JPEG_LIBRARY}) -+ set(LIBTIFF_LIBS ${TIFF_LIBRARIES} ${JPEG_LIBRARIES}) - endif() - endif() - - # Find PNG - if(DCMTK_WITH_PNG) -- find_package(PNG QUIET) -+ find_package(PNG REQUIRED) - if(NOT PNG_FOUND) - set(DCMTK_WITH_PNG OFF CACHE BOOL "" FORCE) - message(STATUS "Warning: PNG support will be disabled because libpng was not found.") -@@ -53,13 +53,13 @@ if(DCMTK_USE_FIND_PACKAGE) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - include_directories(${PNG_INCLUDE_DIR}) -- set(LIBPNG_LIBS ${PNG_LIBRARY}) -+ set(LIBPNG_LIBS ${PNG_LIBRARIES}) - endif() - endif() - - # Find OpenSSL - if(DCMTK_WITH_OPENSSL) -- find_package(OpenSSL QUIET) -+ find_package(OpenSSL REQUIRED) - if(NOT OPENSSL_FOUND) - message(STATUS "Warning: OPENSSL support will be disabled because openssl was not found.") - set(WITH_OPENSSL "") -@@ -90,7 +90,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find libXML2 - if(DCMTK_WITH_XML) -- find_package(LibXml2 QUIET) -+ find_package(LibXml2 REQUIRED) - if(NOT LIBXML2_FOUND) - message(STATUS "Warning: XML support will be disabled because libxml2 was not found.") - set(WITH_LIBXML "") -@@ -105,7 +105,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find zlib - if(DCMTK_WITH_ZLIB) -- find_package(ZLIB QUIET) -+ find_package(ZLIB REQUIRED) - if(NOT ZLIB_FOUND) - message(STATUS "Warning: ZLIB support will be disabled because zlib was not found.") - set(WITH_ZLIB "") -@@ -120,7 +120,7 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find libsndfile - if(DCMTK_WITH_SNDFILE) -- find_package(SNDFILE QUIET) -+ find_package(SNDFILE REQUIRED) - if(NOT SNDFILE_LIBS) - message(STATUS "Warning: SNDFILE support will be disabled because libsndfile was not found.") - set(WITH_SNDFILE "") -@@ -135,9 +135,9 @@ if(DCMTK_USE_FIND_PACKAGE) - - # Find libiconv - if(DCMTK_WITH_ICONV) -- find_package(Iconv QUIET) -- find_package(LIBCHARSET QUIET) -- if(ICONV_FOUND) -+ find_package(Iconv REQUIRED) -+ find_package(LIBCHARSET REQUIRED) -+ if(Iconv_FOUND) - if(NOT Iconv_IS_BUILT_IN) - set(LIBICONV_FOUND ${ICONV_FOUND}) - else() -@@ -158,7 +158,7 @@ if(DCMTK_USE_FIND_PACKAGE) - set(WITH_LIBICONV 1) - set(LIBICONV_INCDIR ${LIBICONV_INCLUDE_DIRS} ${Iconv_INCLUDE_DIRS} ${ICONV_INCLUDE_DIR} ${LIBCHARSET_INCLUDE_DIRS}) - set(LIBICONV_LIBDIR ${LIBICONV_LIBDIR}) -- set(LIBICONV_LIBS ${LIBICONV_LIBRARIES} ${Iconv_LIBRARIES} ${ICONV_LIBRARIES} ${LIBCHARSET_LIBRARY}) -+ set(LIBICONV_LIBS Iconv::Iconv) - include_directories(${LIBICONV_INCDIR}) - endif() - endif() -@@ -241,13 +241,15 @@ else() - # libxml support: configure compiler - if(DCMTK_WITH_XML) - if(WITH_LIBXMLINC) -- set(LIBXML_INCDIR "${WITH_LIBXMLINC}/include") -- set(LIBXML_LIBDIR "${WITH_LIBXMLINC}/lib") -- set(LIBXML_LIBS debug "${LIBXML_LIBDIR}/libxml2_d.lib" optimized "${LIBXML_LIBDIR}/libxml2_o.lib" debug "${LIBXML_LIBDIR}/iconv_d.lib" optimized "${LIBXML_LIBDIR}/iconv_o.lib") -+ set(LIBXML_INCDIR ${CONAN_INCLUDE_DIRS_LIBXML2} ${CONAN_INCLUDE_DIRS_ICONV}) -+ link_directories(${WITH_LIBXMLINC}/lib) -+ set(LIBXML_LIBS ${CONAN_LIBS_LIBXML2}) - message(STATUS "Info: DCMTK XML support will be enabled") - set(WITH_LIBXML 1) -+ if(NOT WITH_LIBXML_SHARED) - # this hides some warnings that are emitted when linking against libxmlXXX.lib instead of linking the DLL directly - add_definitions("-DLIBXML_STATIC") -+ endif() - else() # turn off library if library path not set - message(STATUS "Warning: XML support will be disabled because libxml2 directory is not specified. Correct path and re-enable DCMTK_WITH_XML.") - set(DCMTK_WITH_XML OFF CACHE BOOL "" FORCE) -@@ -259,8 +261,8 @@ else() - if(DCMTK_WITH_PNG) - if(WITH_LIBPNGINC) - set(LIBPNG_INCDIR "${WITH_LIBPNGINC}/include") -- set(LIBPNG_LIBDIR "${WITH_LIBPNGINC}/lib") -- set(LIBPNG_LIBS debug "${LIBPNG_LIBDIR}/libpng_d.lib" optimized "${LIBPNG_LIBDIR}/libpng_o.lib") -+ link_directories(${WITH_LIBPNGINC}/lib) -+ set(LIBPNG_LIBS CONAN_PKG::libpng) - message(STATUS "Info: DCMTK PNG support will be enabled") - set(WITH_LIBPNG 1) - else() # turn off library if library path not set -@@ -274,8 +276,8 @@ else() - if(DCMTK_WITH_TIFF) - if(WITH_LIBTIFFINC) - set(LIBTIFF_INCDIR "${WITH_LIBTIFFINC}/include") -- set(LIBTIFF_LIBDIR "${WITH_LIBTIFFINC}/lib") -- set(LIBTIFF_LIBS debug "${LIBTIFF_LIBDIR}/libtiff_d.lib" optimized "${LIBTIFF_LIBDIR}/libtiff_o.lib") -+ link_directories(${WITH_LIBTIFFINC}/lib) -+ set(LIBTIFF_LIBS CONAN_PKG::libtiff) - message(STATUS "Info: DCMTK TIFF support will be enabled") - set(WITH_LIBTIFF 1) - else() # turn off library if library path not set -@@ -291,9 +293,9 @@ else() - include(CheckCXXSourceCompiles) - set(OPENSSL_BINDIR "${WITH_OPENSSLINC}/bin") - set(OPENSSL_INCDIR "${WITH_OPENSSLINC}/include") -- set(OPENSSL_LIBDIR "${WITH_OPENSSLINC}/lib") -+ link_directories(${WITH_OPENSSLINC}/lib) - # starting with OpenSSL 1.1.0, the Windows crypt32 library is needed for a static link of OpenSSL. -- set(OPENSSL_LIBS "crypt32" debug "${OPENSSL_LIBDIR}/dcmtkssl_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkssl_o.lib" debug "${OPENSSL_LIBDIR}/dcmtkcrypto_d.lib" optimized "${OPENSSL_LIBDIR}/dcmtkcrypto_o.lib") -+ set(OPENSSL_LIBS ${CONAN_LIBS_OPENSSL}) - set(TEMP_INCLUDES "${CMAKE_REQUIRED_INCLUDES}") - list(APPEND CMAKE_REQUIRED_INCLUDES "${OPENSSL_INCDIR}") - CHECK_CXX_SOURCE_COMPILES("extern \"C\" {\n#include \n}\nint main(){\n#if OPENSSL_VERSION_NUMBER < 0x10001000L\n#error OpenSSL too old\n#endif\n}\n" OPENSSL_VERSION_CHECK) -@@ -317,8 +319,8 @@ else() - if(DCMTK_WITH_ZLIB) - if(WITH_ZLIBINC) - set(ZLIB_INCDIR "${WITH_ZLIBINC}/include") -- set(ZLIB_LIBDIR "${WITH_ZLIBINC}/lib") -- set(ZLIB_LIBS debug "${ZLIB_LIBDIR}/zlib_d.lib" optimized "${ZLIB_LIBDIR}/zlib_o.lib") -+ link_directories(${WITH_ZLIBINC}/lib) -+ set(ZLIB_LIBS CONAN_PKG::zlib) - message(STATUS "Info: DCMTK ZLIB support will be enabled") - set(WITH_ZLIB 1) - else() # turn off library if library path not set -@@ -332,8 +334,8 @@ else() - if(DCMTK_WITH_SNDFILE) - if(WITH_SNDFILEINC) - set(SNDFILE_INCDIR "${WITH_SNDFILEINC}/include") -- set(SNDFILE_LIBDIR "${WITH_SNDFILEINC}/lib") -- set(SNDFILE_LIBS debug "${SNDFILE_LIBDIR}/libsndfile_d.lib" optimized "${SNDFILE_LIBDIR}/libsndfile_o.lib") -+ link_directories(${WITH_SNDFILEINC}/lib) -+ set(SNDFILE_LIBS CONAN_PKG::libsndfile) - message(STATUS "Info: DCMTK SNDFILE support will be enabled") - set(WITH_SNDFILE 1) - else() # turn off library if library path not set -@@ -347,8 +349,8 @@ else() - if(DCMTK_WITH_ICONV) - if(WITH_LIBICONVINC) - set(LIBICONV_INCDIR "${WITH_LIBICONVINC}/include") -- set(LIBICONV_LIBDIR "${WITH_LIBICONVINC}/lib") -- set(LIBICONV_LIBS debug "${LIBICONV_LIBDIR}/libiconv_d.lib" optimized "${LIBICONV_LIBDIR}/libiconv_o.lib") -+ link_directories(${WITH_LIBICONVINC}/lib) -+ set(LIBICONV_LIBS CONAN_PKG::libiconv) - message(STATUS "Info: DCMTK ICONV support will be enabled") - set(WITH_LIBICONV 1) - else() # turn off library if library path not set -@@ -371,7 +373,7 @@ else() - else() - set(OPENJPEG_INCDIR "${WITH_OPENJPEGINC1}") - set(OPENJPEG_LIBDIR "${WITH_OPENJPEGINC}/lib") -- set(OPENJPEG_LIBS debug "${OPENJPEG_LIBDIR}/openjp2_d.lib" optimized "${OPENJPEG_LIBDIR}/openjp2_o.lib") -+ set(OPENJPEG_LIBS CONAN_PKG::openjpeg) - message(STATUS "Info: DCMTK OpenJPEG support will be enabled") - set(WITH_OPENJPEG 1) - endif() -@@ -395,7 +397,7 @@ if(NOT DEFINED DCMTK_WITH_STDLIBC_ICONV) - endif() - - if(DCMTK_WITH_ICU) -- find_package(ICU COMPONENTS uc data QUIET) -+ find_package(ICU COMPONENTS uc data REQUIRED) - if(NOT ICU_FOUND) - message(STATUS "Warning: ICU support will be disabled because the ICU were not found.") - set(DCMTK_WITH_ICU OFF CACHE BOOL "" FORCE) -@@ -411,7 +413,7 @@ endif() - - # Find doxygen - if(DCMTK_WITH_DOXYGEN) -- find_package(Doxygen QUIET) # will set variable DOXYGEN_EXECUTABLE -+ find_package(Doxygen REQUIRED) # will set variable DOXYGEN_EXECUTABLE - if(NOT DOXYGEN_FOUND) - message(STATUS "Warning: DOXYGEN support will be disabled because doxygen was not found.") - set(DCMTK_WITH_DOXYGEN OFF CACHE BOOL "" FORCE) diff --git a/recipes/dcmtk/all/test_package/CMakeLists.txt b/recipes/dcmtk/all/test_package/CMakeLists.txt index b3dafcdddcb7d1..4e506092ed288f 100644 --- a/recipes/dcmtk/all/test_package/CMakeLists.txt +++ b/recipes/dcmtk/all/test_package/CMakeLists.txt @@ -1,11 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) find_package(DCMTK REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} dcmdata) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) +target_link_libraries(${PROJECT_NAME} PRIVATE DCMTK::dcmdata) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/dcmtk/all/test_package/conanfile.py b/recipes/dcmtk/all/test_package/conanfile.py index c5fa77486cfa53..0a6bc68712d901 100644 --- a/recipes/dcmtk/all/test_package/conanfile.py +++ b/recipes/dcmtk/all/test_package/conanfile.py @@ -1,12 +1,19 @@ -from conans import CMake from conan import ConanFile -from conan.tools.build import cross_building +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) def build(self): cmake = CMake(self) @@ -14,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/dcmtk/all/test_v1_package/CMakeLists.txt b/recipes/dcmtk/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..be00a8c7f57c71 --- /dev/null +++ b/recipes/dcmtk/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/dcmtk/all/test_v1_package/conanfile.py b/recipes/dcmtk/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/dcmtk/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/dcmtk/config.yml b/recipes/dcmtk/config.yml index 81e7bce3c7d995..8e28175b233706 100644 --- a/recipes/dcmtk/config.yml +++ b/recipes/dcmtk/config.yml @@ -1,7 +1,3 @@ versions: "3.6.7": folder: "all" - "3.6.6": - folder: "all" - "3.6.5": - folder: "all" From a3083f9152020f9a76cc856742a21dad972ca50f Mon Sep 17 00:00:00 2001 From: Daniel Date: Tue, 3 Oct 2023 15:59:01 +0200 Subject: [PATCH 0913/1140] (#20294) [config] Remove old profile configurations --- .c3i/config_v1.yml | 36 ------------------------------------ .c3i/config_v2.yml | 15 --------------- 2 files changed, 51 deletions(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index bc6adc07ba3705..7f7dc6d5833da2 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -67,17 +67,6 @@ tasks: # Profile configurations to build packages configurations: - - id: linux-gcc - epochs: [0] - hrname: "Linux, GCC" - content: - - os: [ "Linux" ] - arch: [ "x86_64" ] - compiler: - - "gcc": - compiler.libcxx: [ "libstdc++11" ] - compiler.version: [ "5", "7", "9", "10" ] - build_type: [ "Release", "Debug" ] - id: linux-gcc epochs: [20211221, 20220120, 20230606] hrname: "Linux, GCC" @@ -100,17 +89,6 @@ configurations: compiler.libcxx: ["libstdc++", "libc++"] compiler.version: ["12", "13"] build_type: ["Release", "Debug"] - - id: macos-clang - epochs: [0, 20211221] - hrname: "macOS, Clang" - content: - - os: [ "Macos" ] - arch: [ "x86_64" ] - compiler: - - "apple-clang": - compiler.version: [ "11.0", "12.0" ] - compiler.libcxx: [ "libc++" ] - build_type: [ "Release", "Debug" ] - id: macos-clang epochs: [20220120, 20230606] hrname: "macOS, Clang" @@ -122,20 +100,6 @@ configurations: compiler.version: [ "13.0" ] compiler.libcxx: [ "libc++" ] build_type: [ "Release", "Debug" ] - - id: macos-m1-clang - epochs: [0, 20211221] - hrname: "macOS, Clang (M1/arm64)" - build_profile: - os: "Macos" - arch: "x86_64" - content: - - os: [ "Macos" ] - arch: [ "armv8" ] - compiler: - - "apple-clang": - compiler.version: [ "12.0" ] - compiler.libcxx: [ "libc++" ] - build_type: [ "Release", "Debug" ] - id: macos-m1-clang epochs: [20220120, 20230606] hrname: "macOS, Clang (M1/arm64)" diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index 6ce21e93668a5c..26bfec81b6d30c 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -103,21 +103,6 @@ configurations: compiler.version: ["13" ] compiler.libcxx: [ "libc++" ] build_type: [ "Release"] - - id: windows-msvc - epochs: [0, 20211221, 20220120, 20220628] - hrname: "Windows, MSVC" - build_profile: - os: "Windows" - content: - - os: [ "Windows" ] - arch: [ "x86_64" ] - compiler: - - "msvc": - compiler.version: [ "192" ] - build_type: - - "Release": - compiler.runtime: ["dynamic"] - compiler.runtime_type: [ "Release" ] - id: windows-msvc epochs: [20230606] hrname: "Windows, MSVC" From 2bf24d37bf325f3cdc65ccdd7ad26a56df47de74 Mon Sep 17 00:00:00 2001 From: Chris Mc Date: Tue, 3 Oct 2023 08:14:03 -0700 Subject: [PATCH 0914/1140] (#19998) Move prince-chrismc back to a community reviewer * Update my reviewers title I no longer work for JFrog * Update alert-community.yml --- .c3i/reviewers.yml | 2 +- .github/workflows/alert-community.yml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.c3i/reviewers.yml b/.c3i/reviewers.yml index 6c7ecd5befbc8f..8f6463b4a33c6a 100644 --- a/.c3i/reviewers.yml +++ b/.c3i/reviewers.yml @@ -37,7 +37,7 @@ reviewers: type: "community" request_reviews: false - user: "prince-chrismc" - type: "team" + type: "community" request_reviews: false - user: "Croydon" type: "community" diff --git a/.github/workflows/alert-community.yml b/.github/workflows/alert-community.yml index 2df6d8d62a6c1d..17c21b9aa39f55 100644 --- a/.github/workflows/alert-community.yml +++ b/.github/workflows/alert-community.yml @@ -24,12 +24,12 @@ jobs: - uses: ./.github/actions/alert-community with: files: ".github/*/*" - reviewers: "@ericLemanissier @prince-chrismc @Croydon" + reviewers: "@ericLemanissier @Croydon" - uses: ./.github/actions/alert-community with: files: "linter/*/*" - reviewers: "@ericLemanissier @prince-chrismc @Croydon" + reviewers: "@ericLemanissier @Croydon" - uses: ./.github/actions/alert-community with: From 7483e5be48215583c829f9bf34173759aa4093bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 3 Oct 2023 18:23:50 +0200 Subject: [PATCH 0915/1140] (#19981) nas: Fix license * Sketch NAS fix * Fix licensing field --- recipes/nas/all/conanfile.py | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/recipes/nas/all/conanfile.py b/recipes/nas/all/conanfile.py index a6ece9857a5b29..5a3dcf12eeb770 100644 --- a/recipes/nas/all/conanfile.py +++ b/recipes/nas/all/conanfile.py @@ -3,7 +3,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.layout import basic_layout from conan.tools.env import VirtualBuildEnv -from conan.tools.files import chdir, get, download, export_conandata_patches, apply_conandata_patches, rm, copy +from conan.tools.files import chdir, get, export_conandata_patches, apply_conandata_patches, rm, copy, load, save from conan.tools.gnu import AutotoolsToolchain, Autotools, AutotoolsDeps import os @@ -17,7 +17,7 @@ class NasRecipe(ConanFile): topics = ("audio", "sound") url = "https://github.com/conan-io/conan-center-index" homepage = "https://www.radscan.com/nas.html" - license = "Unlicense" + license = "DocumentRef-wave.h:LicenseRef-MIT-advertising" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -61,8 +61,6 @@ def build_requirements(self): def source(self): get(self, **self.conan_data["sources"][self.version][0], strip_root=True) - # This library does not come with a License file by itself, package it from an external source - download(self, filename="LICENSE", **self.conan_data["sources"][self.version][1]) @property def _user_info_build(self): @@ -107,8 +105,16 @@ def build(self): # j1 avoids some errors while trying to run this target autotools.make(target="World", args=["-j1"] + self._imake_make_args) + def _extract_license(self): + header = "Copyright 1995" + footer = "Translation: You can do whatever you want with this software!" + nas_audio = load(self, os.path.join(self.source_folder, "README")) + begin = nas_audio.find(header) + end = nas_audio.find(footer, begin) + return nas_audio[begin:end] + def package(self): - copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), self._extract_license()) tmp_install = os.path.join(self.build_folder, "prefix") self.output.warning(tmp_install) From 5e4dd8adfb44fd4293f8b3a52efe4ce5c7a4658a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 3 Oct 2023 22:00:42 +0300 Subject: [PATCH 0916/1140] (#18638) libxshmfence: migrate to Conan v2 * libxshmfence: migrate to Conan v2 * libxshmfence: bump deps --- recipes/libxshmfence/all/conanfile.py | 119 +++++++++--------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 19 ++- .../all/test_package/test_package.c | 5 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 100 insertions(+), 75 deletions(-) create mode 100644 recipes/libxshmfence/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libxshmfence/all/test_v1_package/conanfile.py diff --git a/recipes/libxshmfence/all/conanfile.py b/recipes/libxshmfence/all/conanfile.py index abd496668a102b..c2a5a359ad39aa 100644 --- a/recipes/libxshmfence/all/conanfile.py +++ b/recipes/libxshmfence/all/conanfile.py @@ -1,20 +1,28 @@ +import os + from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, rm, rmdir -from conans import tools, AutoToolsBuildEnvironment -import contextlib -import os +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.build import cross_building +from conan.tools.env import Environment, VirtualBuildEnv, VirtualRunEnv +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain, PkgConfigDeps +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc, unix_path required_conan_version = ">=1.53.0" + class LibxshmfenceConan(ConanFile): name = "libxshmfence" + description = "Shared memory 'SyncFence' synchronization primitive" license = "X11" - homepage = "https://gitlab.freedesktop.org/xorg/lib/libxshmfence" url = "https://github.com/conan-io/conan-center-index" - description = "Shared memory 'SyncFence' synchronization primitive" + homepage = "https://gitlab.freedesktop.org/xorg/lib/libxshmfence" topics = ("shared", "memory", "syncfence", "synchronization", "interprocess") - settings = "os", "compiler", "build_type", "arch" + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -24,22 +32,10 @@ class LibxshmfenceConan(ConanFile): "fPIC": True, } - generators = "pkg_config" - - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) - @property - def _user_info_build(self): - return getattr(self, "user_info_build", self.deps_user_info) - def export_sources(self): export_conandata_patches(self) @@ -53,64 +49,63 @@ def configure(self): # for plain C projects only self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") - + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("xorg-proto/2022.2", transitive_headers=True) + def validate(self): if self.settings.os == "Windows": raise ConanInvalidConfiguration("Windows is not supported by libxshmfence recipe. Contributions are welcome") def build_requirements(self): - self.build_requires("automake/1.16.5") - self.build_requires("pkgconf/1.9.3") - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): - self.build_requires("msys2/cci.latest") - - def requirements(self): - self.requires("xorg-proto/2022.2") + self.tool_requires("automake/1.16.5") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/1.9.5") + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - @contextlib.contextmanager - def _build_context(self): - if self.settings.compiler == "Visual Studio": - with tools.vcvars(self): - env = { - "CC": "{} cl -nologo".format(self._user_info_build["automake"].compile).replace("\\", "/"), - } - with tools.environment_append(env): - yield - else: - yield - - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self, win_bash=self._settings_build.os == "Windows") - self._autotools.libs = [] - yes_no = lambda v: "yes" if v else "no" - configure_args = [ - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-static={}".format(yes_no(not self.options.shared)), - ] - self._autotools.configure(args=configure_args, configure_dir=self._source_subfolder) - return self._autotools + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + env = VirtualBuildEnv(self) + env.generate() + if not cross_building(self): + env = VirtualRunEnv(self) + env.generate(scope="build") + tc = AutotoolsToolchain(self) + tc.generate() + tc = PkgConfigDeps(self) + tc.generate() + + if is_msvc(self): + env = Environment() + automake_conf = self.dependencies.build["automake"].conf_info + compile_wrapper = unix_path(self, automake_conf.get("user.automake:compile-wrapper", check_type=str)) + env.define("CC", f"{compile_wrapper} cl -nologo") + env.vars(self).save_script("conanbuild_msvc") def build(self): apply_conandata_patches(self) - with self._build_context(): - autotools = self._configure_autotools() - autotools.make() + autotools = Autotools(self) + autotools.configure() + autotools.make() def package(self): - self.copy("COPYING", src=self._source_subfolder, dst="licenses") - with self._build_context(): - autotools = self._configure_autotools() - autotools.install() + copy(self, "COPYING", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) + autotools = Autotools(self) + autotools.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rm(self, "*.la", os.path.join(self.package_folder, "lib")) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["xshmfence"] - self.cpp_info.names["pkg_config"] = "xshmfence" self.cpp_info.set_property("pkg_config_name", "xshmfence") diff --git a/recipes/libxshmfence/all/test_package/CMakeLists.txt b/recipes/libxshmfence/all/test_package/CMakeLists.txt index b08d77d4e43289..c48db83ea92319 100644 --- a/recipes/libxshmfence/all/test_package/CMakeLists.txt +++ b/recipes/libxshmfence/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(libxshmfence REQUIRED) +find_package(libxshmfence REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} libxshmfence::libxshmfence) diff --git a/recipes/libxshmfence/all/test_package/conanfile.py b/recipes/libxshmfence/all/test_package/conanfile.py index 19e6a0c06e3d81..ef5d7042163ecc 100644 --- a/recipes/libxshmfence/all/test_package/conanfile.py +++ b/recipes/libxshmfence/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libxshmfence/all/test_package/test_package.c b/recipes/libxshmfence/all/test_package/test_package.c index 2dc0779250663e..6b5dd2b42332cd 100644 --- a/recipes/libxshmfence/all/test_package/test_package.c +++ b/recipes/libxshmfence/all/test_package/test_package.c @@ -1,15 +1,14 @@ #include "X11/xshmfence.h" int main() { - int fd; - struct xshmfence *x; + int fd; + struct xshmfence *x; fd = xshmfence_alloc_shm(); if (fd < 0) { return 1; } - x = xshmfence_map_shm(fd); if (!x) { return 1; diff --git a/recipes/libxshmfence/all/test_v1_package/CMakeLists.txt b/recipes/libxshmfence/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libxshmfence/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libxshmfence/all/test_v1_package/conanfile.py b/recipes/libxshmfence/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/libxshmfence/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 2b8416a0784e241806d7bdf89ada42c9acd7bfa4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 3 Oct 2023 23:07:17 +0300 Subject: [PATCH 0917/1140] (#18755) playrho: migrate to Conan v2 * playrho: migrate to Conan v2 * playrho: move DLLs from lib to bin * playrho: restore VirtualRunEnv in test_package --- recipes/playrho/all/CMakeLists.txt | 9 -- recipes/playrho/all/conandata.yml | 1 - recipes/playrho/all/conanfile.py | 95 +++++++++++-------- .../playrho/all/test_package/CMakeLists.txt | 5 +- recipes/playrho/all/test_package/conanfile.py | 22 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../playrho/all/test_v1_package/conanfile.py | 18 ++++ 7 files changed, 96 insertions(+), 62 deletions(-) delete mode 100644 recipes/playrho/all/CMakeLists.txt create mode 100644 recipes/playrho/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/playrho/all/test_v1_package/conanfile.py diff --git a/recipes/playrho/all/CMakeLists.txt b/recipes/playrho/all/CMakeLists.txt deleted file mode 100644 index 7d5ba25565b0ab..00000000000000 --- a/recipes/playrho/all/CMakeLists.txt +++ /dev/null @@ -1,9 +0,0 @@ -cmake_minimum_required(VERSION 3.4) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) - -set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) - -add_subdirectory(source_subfolder) diff --git a/recipes/playrho/all/conandata.yml b/recipes/playrho/all/conandata.yml index 03bf919319da86..9c08727b484840 100644 --- a/recipes/playrho/all/conandata.yml +++ b/recipes/playrho/all/conandata.yml @@ -6,4 +6,3 @@ sources: patches: "1.1.0": - patch_file: "patches/1.1.0-0001-fix-target-name.patch" - base_path: "source_subfolder" diff --git a/recipes/playrho/all/conanfile.py b/recipes/playrho/all/conanfile.py index 9aab4b29f12b39..b2457aa21b0743 100644 --- a/recipes/playrho/all/conanfile.py +++ b/recipes/playrho/all/conanfile.py @@ -1,9 +1,14 @@ -from conans import ConanFile, CMake, tools -from conans.tools import ConanInvalidConfiguration import os -import functools -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, rename +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" + class PlayrhoConan(ConanFile): name = "playrho" @@ -12,25 +17,30 @@ class PlayrhoConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/louis-langholtz/PlayRho/" topics = ("physics-engine", "collision-detection", "box2d") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], - "fPIC": [True, False], + "fPIC": [True, False], } default_options = { "shared": False, "fPIC": True, } - generators = "cmake" @property - def _source_subfolder(self): - return "source_subfolder" + def _compilers_minimum_versions(self): + return { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "msvc": "192", + "Visual Studio": "16", + } def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -38,54 +48,57 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - @property - def _compilers_minimum_versions(self): - return { - "gcc": "8", - "Visual Studio": "16", - "clang": "7", - "apple-clang": "12", - } + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) + check_min_cppstd(self, 17) compilers_minimum_version = self._compilers_minimum_versions minimum_version = compilers_minimum_version.get(str(self.settings.compiler), False) if minimum_version: - if tools.Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{} requires C++17, which your compiler does not support.".format(self.name)) + if Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.name} requires C++17, which your compiler does not support." + ) else: - self.output.warn("{} requires C++17. Your compiler is unknown. Assuming it supports C++17.".format(self.name)) + self.output.warning( + f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17." + ) def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["PLAYRHO_BUILD_SHARED"] = self.options.shared - cmake.definitions["PLAYRHO_BUILD_STATIC"] = not self.options.shared - cmake.definitions["PLAYRHO_INSTALL"] = True - cmake.configure() - return cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True + tc.variables["PLAYRHO_BUILD_SHARED"] = self.options.shared + tc.variables["PLAYRHO_BUILD_STATIC"] = not self.options.shared + tc.variables["PLAYRHO_INSTALL"] = True + tc.generate() + + tc = CMakeDeps(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE.txt", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE.txt", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) - tools.rmdir(os.path.join(self.package_folder, "lib", "PlayRho")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "PlayRho")) + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.libs = ["PlayRho"] diff --git a/recipes/playrho/all/test_package/CMakeLists.txt b/recipes/playrho/all/test_package/CMakeLists.txt index cf755d3555681b..6486eec9801471 100644 --- a/recipes/playrho/all/test_package/CMakeLists.txt +++ b/recipes/playrho/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(PlayRho REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/playrho/all/test_package/conanfile.py b/recipes/playrho/all/test_package/conanfile.py index 61ac8b93182903..ef5d7042163ecc 100644 --- a/recipes/playrho/all/test_package/conanfile.py +++ b/recipes/playrho/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -from conan.tools.build import cross_building -class PlayrhoTestConan(ConanFile): +class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/playrho/all/test_v1_package/CMakeLists.txt b/recipes/playrho/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/playrho/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/playrho/all/test_v1_package/conanfile.py b/recipes/playrho/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..61ac8b93182903 --- /dev/null +++ b/recipes/playrho/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools +from conan.tools.build import cross_building + +class PlayrhoTestConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 4e36c9f08ddf4c6a6070e5f2d00cf3961247ca9b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Tue, 3 Oct 2023 23:32:47 +0300 Subject: [PATCH 0918/1140] (#18890) libdrm: migrate to Conan v2 * libdrm: migrate to Conan v2 * libdrm: restore VirtualRunEnv in test_package * libdrm: bump deps * libdrm: add pthread dependency * libdrm: bump deps * libdrm: add pkgconf dependency --- recipes/libdrm/all/conanfile.py | 127 +++++++++--------- .../libdrm/all/test_package/CMakeLists.txt | 9 +- recipes/libdrm/all/test_package/conanfile.py | 22 ++- .../libdrm/all/test_v1_package/CMakeLists.txt | 8 ++ .../libdrm/all/test_v1_package/conanfile.py | 18 +++ 5 files changed, 108 insertions(+), 76 deletions(-) create mode 100644 recipes/libdrm/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libdrm/all/test_v1_package/conanfile.py diff --git a/recipes/libdrm/all/conanfile.py b/recipes/libdrm/all/conanfile.py index aad89cccd5bf6d..4947d9528c7e3e 100644 --- a/recipes/libdrm/all/conanfile.py +++ b/recipes/libdrm/all/conanfile.py @@ -4,19 +4,24 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.files import get, load, mkdir, rmdir, save +from conan.tools.gnu import PkgConfigDeps +from conan.tools.layout import basic_layout +from conan.tools.meson import MesonToolchain, Meson from conan.tools.scm import Version -from conans import Meson + +required_conan_version = ">=1.53.0" class LibdrmConan(ConanFile): name = "libdrm" - description = "User space library for accessing the Direct Rendering Manager, on operating systems that support the ioctl interface" - topics = ("libdrm", "graphics") + description = ("User space library for accessing the Direct Rendering Manager, " + "on operating systems that support the ioctl interface") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://gitlab.freedesktop.org/mesa/drm" - license = "MIT" - generators = "PkgConfigDeps" + topics = ("graphics",) + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -35,7 +40,7 @@ class LibdrmConan(ConanFile): "etnaviv": [True, False], "valgrind": [True, False], "freedreno-kgsl": [True, False], - "udev": [True, False] + "udev": [True, False], } default_options = { "shared": False, @@ -54,100 +59,93 @@ class LibdrmConan(ConanFile): "etnaviv": False, "valgrind": False, "freedreno-kgsl": False, - "udev": False + "udev": False, } - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" - - def build_requirements(self): - self.build_requires("meson/0.64.1") - def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC if Version(self.version) >= "2.4.111": del self.options.libkms def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + basic_layout(self, src_folder="src") def requirements(self): if self.options.intel: - self.requires("libpciaccess/0.16") - if self.settings.os == "Linux": - self.requires("linux-headers-generic/5.14.9") + self.requires("libpciaccess/0.17") + if self.settings.os in ["Linux", "FreeBSD"]: + self.requires("linux-headers-generic/5.15.128") def validate(self): if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration("libdrm supports only Linux or FreeBSD") + def build_requirements(self): + self.tool_requires("meson/1.2.2") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/2.0.3") + def source(self): - get(self, **self.conan_data["sources"][self.version], - strip_root=True, destination=self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_meson(self): - meson = Meson(self) + def generate(self): + tc = PkgConfigDeps(self) + tc.generate() + + tc = MesonToolchain(self) + tc.project_options["cairo-tests"] = "disabled" if Version(self.version) >= "2.4.113" else "false" + tc.project_options["install-test-programs"] = "false" - defs={ - "cairo-tests" : "disabled" if Version(self.version) >= "2.4.113" else "false", - "install-test-programs": "false" - } if Version(self.version) < "2.4.111": - defs["libkms"] = "true" if self.options.libkms else "false" - - defs["freedreno-kgsl"] = "true" if getattr(self.options, "freedreno-kgsl") else "false" - defs["udev"] = "true" if self.options.udev else "false" - - for o in ["intel", "radeon", "amdgpu","nouveau", "vmwgfx", "omap", "exynos", - "freedreno", "tegra", "vc4", "etnaviv", "valgrind"]: + tc.project_options["libkms"] = "true" if self.options.libkms else "false" + + tc.project_options["freedreno-kgsl"] = "true" if getattr(self.options, "freedreno-kgsl") else "false" + tc.project_options["udev"] = "true" if self.options.udev else "false" + + for o in ["intel", "radeon", "amdgpu", "nouveau", "vmwgfx", "omap", + "exynos", "freedreno", "tegra", "vc4", "etnaviv", "valgrind"]: if Version(self.version) >= "2.4.113": - defs[o] = "enabled" if getattr(self.options, o) else "disabled" + tc.project_options[o] = "enabled" if getattr(self.options, o) else "disabled" else: - defs[o] = "true" if getattr(self.options, o) else "false" + tc.project_options[o] = "true" if getattr(self.options, o) else "false" - defs["datadir"] = os.path.join(self.package_folder, "res") - defs["mandir"] = os.path.join(self.package_folder, "res", "man") - - meson.configure( - defs = defs, - source_folder=self._source_subfolder, - build_folder=self._build_subfolder) - return meson + tc.project_options["datadir"] = os.path.join(self.package_folder, "res") + tc.project_options["mandir"] = os.path.join(self.package_folder, "res", "man") + tc.generate() def build(self): - meson = self._configure_meson() + meson = Meson(self) + meson.configure() meson.build() def package(self): - meson = self._configure_meson() + meson = Meson(self) meson.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) mkdir(self, os.path.join(self.package_folder, "licenses")) # Extract the License/s from the header to a file - tmp = load(self, os.path.join(self._source_subfolder, "include", "drm", "drm.h")) - license_contents = re.search("\*\/.*(\/\*(\*(?!\/)|[^*])*\*\/)", tmp, re.DOTALL)[1] + tmp = load(self, os.path.join(self.source_folder, "include", "drm", "drm.h")) + license_contents = re.search(r"\*/.*(/\*(\*(?!/)|[^*])*\*/)", tmp, re.DOTALL)[1] save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), license_contents) def package_info(self): self.cpp_info.components["libdrm_libdrm"].libs = ["drm"] - self.cpp_info.components["libdrm_libdrm"].includedirs.append(os.path.join('include', 'libdrm')) + self.cpp_info.components["libdrm_libdrm"].includedirs.append(os.path.join("include", "libdrm")) self.cpp_info.components["libdrm_libdrm"].set_property("pkg_config_name", "libdrm") - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.components["libdrm_libdrm"].requires = ["linux-headers-generic::linux-headers-generic"] if Version(self.version) < "2.4.111": if self.options.libkms: self.cpp_info.components["libdrm_libkms"].libs = ["kms"] - self.cpp_info.components["libdrm_libkms"].includedirs.append(os.path.join('include', 'libkms')) + self.cpp_info.components["libdrm_libkms"].includedirs.append(os.path.join("include", "libkms")) self.cpp_info.components["libdrm_libkms"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_libkms"].set_property("pkg_config_name", "libkms") @@ -157,32 +155,33 @@ def package_info(self): if self.options.freedreno: self.cpp_info.components["libdrm_freedreno"].libs = ["drm_freedreno"] - self.cpp_info.components["libdrm_freedreno"].includedirs.append(os.path.join('include', 'libdrm')) - self.cpp_info.components["libdrm_freedreno"].includedirs.append(os.path.join('include', 'freedreno')) + self.cpp_info.components["libdrm_freedreno"].includedirs.append(os.path.join("include", "libdrm")) + self.cpp_info.components["libdrm_freedreno"].includedirs.append(os.path.join("include", "freedreno")) self.cpp_info.components["libdrm_freedreno"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_freedreno"].set_property("pkg_config_name", "libdrm_freedreno") if self.options.amdgpu: self.cpp_info.components["libdrm_amdgpu"].libs = ["drm_amdgpu"] - self.cpp_info.components["libdrm_amdgpu"].includedirs.append(os.path.join('include', 'libdrm')) + self.cpp_info.components["libdrm_amdgpu"].includedirs.append(os.path.join("include", "libdrm")) self.cpp_info.components["libdrm_amdgpu"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_amdgpu"].set_property("pkg_config_name", "libdrm_amdgpu") if self.options.nouveau: self.cpp_info.components["libdrm_nouveau"].libs = ["drm_nouveau"] - self.cpp_info.components["libdrm_nouveau"].includedirs.append(os.path.join('include', 'libdrm')) + self.cpp_info.components["libdrm_nouveau"].includedirs.append(os.path.join("include", "libdrm")) self.cpp_info.components["libdrm_nouveau"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_nouveau"].set_property("pkg_config_name", "libdrm_nouveau") + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["libdrm_nouveau"].system_libs = ["pthread"] if self.options.intel: self.cpp_info.components["libdrm_intel"].libs = ["drm_intel"] - self.cpp_info.components["libdrm_intel"].includedirs.append(os.path.join('include', 'libdrm')) + self.cpp_info.components["libdrm_intel"].includedirs.append(os.path.join("include", "libdrm")) self.cpp_info.components["libdrm_intel"].requires = ["libdrm_libdrm", "libpciaccess::libpciaccess"] self.cpp_info.components["libdrm_intel"].set_property("pkg_config_name", "libdrm_intel") if self.options.radeon: self.cpp_info.components["libdrm_radeon"].libs = ["drm_radeon"] - self.cpp_info.components["libdrm_radeon"].includedirs.append(os.path.join('include', 'libdrm')) + self.cpp_info.components["libdrm_radeon"].includedirs.append(os.path.join("include", "libdrm")) self.cpp_info.components["libdrm_radeon"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_radeon"].set_property("pkg_config_name", "libdrm_radeon") - diff --git a/recipes/libdrm/all/test_package/CMakeLists.txt b/recipes/libdrm/all/test_package/CMakeLists.txt index afa24763570742..0561a690e26c10 100644 --- a/recipes/libdrm/all/test_package/CMakeLists.txt +++ b/recipes/libdrm/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libdrm REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE libdrm::libdrm) diff --git a/recipes/libdrm/all/test_package/conanfile.py b/recipes/libdrm/all/test_package/conanfile.py index 8e9e5fdc7aa40a..ef5d7042163ecc 100644 --- a/recipes/libdrm/all/test_package/conanfile.py +++ b/recipes/libdrm/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,7 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) - + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libdrm/all/test_v1_package/CMakeLists.txt b/recipes/libdrm/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libdrm/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libdrm/all/test_v1_package/conanfile.py b/recipes/libdrm/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..994065a7574452 --- /dev/null +++ b/recipes/libdrm/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) + From 4a70918e81eadb664095d9e92dd3262587179dc4 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 01:02:23 +0300 Subject: [PATCH 0919/1140] (#19231) libselinux: add v3.5, fix license info MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libselinux: bump deps * libselinux: bump pkgconf dep * libselinux: set correct licenses * libselinux: add v3.5 * libselinux: restore old versions for now to correct their licenses * libselinux: restore 0001-fix-fno-common-3.0.patch * libselinux: avoid building both .a and .so * libselinux: correct license tag Co-authored-by: Jordan Williams --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Jordan Williams --- recipes/libselinux/all/conandata.yml | 5 ++ recipes/libselinux/all/conanfile.py | 62 +++++++++++-------- .../all/test_package/CMakeLists.txt | 2 +- .../all/test_v1_package/CMakeLists.txt | 2 +- recipes/libselinux/config.yml | 2 + 5 files changed, 45 insertions(+), 28 deletions(-) diff --git a/recipes/libselinux/all/conandata.yml b/recipes/libselinux/all/conandata.yml index bc06101ad2d727..3db74c02a2ca7b 100644 --- a/recipes/libselinux/all/conandata.yml +++ b/recipes/libselinux/all/conandata.yml @@ -1,4 +1,9 @@ sources: + "3.5": + - url: "https://github.com/SELinuxProject/selinux/releases/download/3.5/libselinux-3.5.tar.gz" + sha256: "9a3a3705ac13a2ccca2de6d652b6356fead10f36fb33115c185c5ccdf29eec19" + - url: "https://github.com/SELinuxProject/selinux/releases/download/3.5/libsepol-3.5.tar.gz" + sha256: "78fdaf69924db780bac78546e43d9c44074bad798c2c415d0b9bb96d065ee8a2" "3.3": - url: "https://github.com/SELinuxProject/selinux/releases/download/3.3/libselinux-3.3.tar.gz" sha256: "acfdee27633d2496508c28727c3d41d3748076f66d42fccde2e6b9f3463a7057" diff --git a/recipes/libselinux/all/conanfile.py b/recipes/libselinux/all/conanfile.py index b2c0ccb43ccfa9..eb1d902d82d02d 100644 --- a/recipes/libselinux/all/conanfile.py +++ b/recipes/libselinux/all/conanfile.py @@ -1,11 +1,12 @@ +import os + from conan import ConanFile +from conan.errors import ConanInvalidConfiguration from conan.tools.env import VirtualBuildEnv -from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get +from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get, rename, replace_in_file, save from conan.tools.gnu import Autotools, AutotoolsToolchain, PkgConfigDeps from conan.tools.layout import basic_layout from conan.tools.scm import Version -from conan.errors import ConanInvalidConfiguration -import os required_conan_version = ">=1.53.0" @@ -20,7 +21,14 @@ class LibSELinuxConan(ConanFile): topics = ("linux", "selinux", "security", "security-enhanced") url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/SELinuxProject/selinux" - license = "Unlicense" + license = ( + # https://github.com/SELinuxProject/selinux/blob/main/libselinux/LICENSE + # For the libselinux component: public domain with a limited liability clause + "LicenseRef-LICENSE-libselinux", + # https://github.com/SELinuxProject/selinux/blob/main/libsepol/LICENSE + # For the libsepol component: LGPL-2.1 + "LGPL-2.1-or-later", + ) package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -48,7 +56,7 @@ def requirements(self): self.requires("pcre2/10.42") def validate(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration(f"{self.ref} only supports Linux") def build_requirements(self): @@ -60,22 +68,6 @@ def source(self): for download in self.conan_data["sources"][self.version]: get(self, **download) - @property - def _sepol_soversion(self): - return "2" if Version(self.version) >= "3.2" else "1" - - @property - def _selinux_soversion(self): - return "1" - - @property - def _sepol_library_target(self): - return f"libsepol.so.{self._sepol_soversion}" if self.options.shared else "libsepol.a" - - @property - def _selinux_library_target(self): - return f"libselinux.so.{self._selinux_soversion}" if self.options.shared else "libselinux.a" - @property def _sepol_source_folder(self): return os.path.join(self.source_folder, f"libsepol-{self.version}") @@ -100,13 +92,31 @@ def generate(self): def build(self): apply_conandata_patches(self) autotools = Autotools(self) - with chdir(self, os.path.join(self._sepol_source_folder, "src")): - autotools.make(self._sepol_library_target) - with chdir(self, os.path.join(self._selinux_source_folder)): - autotools.make() + for subdir in [self._sepol_source_folder, self._selinux_source_folder]: + with chdir(self, subdir): + # Build only .a or .so, not both + replace_in_file(self, os.path.join("src", "Makefile"), + "all: $(LIBA) $(LIBSO) $(LIBPC)", + "all: $(LIBSO)" if self.options.shared else "all: $(LIBA)") + # Skip utils dir by truncating its Makefile + save(self, os.path.join("utils", "Makefile"), "all:\n") + autotools.make() + + def _copy_licenses(self): + copy(self, "LICENSE", self._selinux_source_folder, os.path.join(self.package_folder, "licenses")) + rename(self, os.path.join(self.package_folder, "licenses", "LICENSE"), + os.path.join(self.package_folder, "licenses", "LICENSE-libselinux")) + if Version(self.version) >= "3.5": + copy(self, "LICENSE", self._sepol_source_folder, os.path.join(self.package_folder, "licenses")) + rename(self, os.path.join(self.package_folder, "licenses", "LICENSE"), + os.path.join(self.package_folder, "licenses", "LICENSE-libsepol")) + else: + copy(self, "COPYING", self._sepol_source_folder, os.path.join(self.package_folder, "licenses")) + rename(self, os.path.join(self.package_folder, "licenses", "COPYING"), + os.path.join(self.package_folder, "licenses", "LICENSE-libsepol")) def package(self): - copy(self, "LICENSE", self._selinux_source_folder, os.path.join(self.package_folder, "licenses")) + self._copy_licenses() for library in [self._sepol_source_folder, self._selinux_source_folder]: copy(self, "*.h", os.path.join(library, "include"), os.path.join(self.package_folder, "include")) if self.options.shared: diff --git a/recipes/libselinux/all/test_package/CMakeLists.txt b/recipes/libselinux/all/test_package/CMakeLists.txt index 7a316858398f3f..a2c8fc569bb2f2 100644 --- a/recipes/libselinux/all/test_package/CMakeLists.txt +++ b/recipes/libselinux/all/test_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) find_package(libselinux REQUIRED CONFIG) diff --git a/recipes/libselinux/all/test_v1_package/CMakeLists.txt b/recipes/libselinux/all/test_v1_package/CMakeLists.txt index 925ecbe19e448d..91630d79f4abb3 100644 --- a/recipes/libselinux/all/test_v1_package/CMakeLists.txt +++ b/recipes/libselinux/all/test_v1_package/CMakeLists.txt @@ -1,4 +1,4 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package) include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) diff --git a/recipes/libselinux/config.yml b/recipes/libselinux/config.yml index 3fc66eb377b843..761b7522ae137c 100644 --- a/recipes/libselinux/config.yml +++ b/recipes/libselinux/config.yml @@ -1,4 +1,6 @@ versions: + "3.5": + folder: all "3.3": folder: all "3.2": From 8533a3cefe559afc8172b0b70d1bfbc71750ff4f Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 4 Oct 2023 07:15:17 +0900 Subject: [PATCH 0920/1140] (#19709) wasmtime-cpp: update wasmtime/12.0.1 * wasmtime-cpp: update wasmtime/12.0.1 * update wasmtime-12.0.2 --- recipes/wasmtime-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/wasmtime-cpp/all/conanfile.py b/recipes/wasmtime-cpp/all/conanfile.py index 3b547f8d8dbced..9970e18861d775 100644 --- a/recipes/wasmtime-cpp/all/conanfile.py +++ b/recipes/wasmtime-cpp/all/conanfile.py @@ -43,7 +43,7 @@ def requirements(self): "0.39.0": "0.39.1", "1.0.0": "1.0.1", "6.0.0": "6.0.1", - "9.0.0": "9.0.1", + "9.0.0": "12.0.2", } self.requires(f"wasmtime/{version_map.get(version, version)}") From 94d2d66da119e30455e65a0c0f964d06bcc811db Mon Sep 17 00:00:00 2001 From: Pavel Kisliak Date: Wed, 4 Oct 2023 02:34:08 +0300 Subject: [PATCH 0921/1140] (#19775) [BitSerializer] Add new version 0.65, migrate repository to GitHub --- recipes/bitserializer/all/conandata.yml | 15 +++++++++------ recipes/bitserializer/all/conanfile.py | 2 +- recipes/bitserializer/config.yml | 2 ++ 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/recipes/bitserializer/all/conandata.yml b/recipes/bitserializer/all/conandata.yml index 9b5b2264c84bba..1571f9c56284c3 100644 --- a/recipes/bitserializer/all/conandata.yml +++ b/recipes/bitserializer/all/conandata.yml @@ -1,10 +1,13 @@ sources: + "0.65": + url: "https://github.com/PavelKisliak/BitSerializer/archive/v0.65.tar.gz" + sha256: "b4d90f13dd424faebe3ee57ee0cb86ff304e893990afd259c6a29d1f8533b2ef" "0.50": - url: "https://bitbucket.com/Pavel_Kisliak/BitSerializer/get/0.50.tar.gz" - sha256: "dc000b6516db60337d5dd56fb1b60e29ce700bd2e6f4e609ca548b84d1f1dcee" + url: "https://github.com/PavelKisliak/BitSerializer/archive/0.50.tar.gz" + sha256: "0ba9d57f1546b9c9245a97ced0ed05ec9fb969e0542093da3a8bf9dcfe7f7a6d" "0.44": - url: "https://bitbucket.com/Pavel_Kisliak/BitSerializer/get/0.44.tar.gz" - sha256: "39ee0b038c9f38a012f96913c9738a68514d2e923431fbd83ddf3f454e02bc6c" + url: "https://github.com/PavelKisliak/BitSerializer/archive/0.44.tar.gz" + sha256: "ab0f74914d8120ee5e7a8ed10b0e9d83ed8135cd9e3356b5d0dcefc1cc88e47f" "0.10": - url: "https://bitbucket.com/Pavel_Kisliak/BitSerializer/get/0.10.tar.gz" - sha256: "d5ae211aead17acb91d9fb7df7e72a30202f39412159dd0b46fe0e5046b29f94" + url: "https://github.com/PavelKisliak/BitSerializer/archive/0.10.tar.gz" + sha256: "e9b898e453c66742a3c9d762c3e9f64f478fdb79680792b8725f953342fcc348" diff --git a/recipes/bitserializer/all/conanfile.py b/recipes/bitserializer/all/conanfile.py index e4f6815698c022..5acbd3659a4cb2 100644 --- a/recipes/bitserializer/all/conanfile.py +++ b/recipes/bitserializer/all/conanfile.py @@ -126,7 +126,7 @@ def generate(self): deps.generate() def _patch_sources(self): - if Version(self.version) >= "0.50": + if Version(self.version) >= "0.50" and self.options.with_rapidyaml: # Remove 'ryml' subdirectory from #include replace_in_file( self, os.path.join(self.source_folder, "include", "bitserializer", "rapidyaml_archive.h"), diff --git a/recipes/bitserializer/config.yml b/recipes/bitserializer/config.yml index 31b18058643087..7319ee088f9060 100644 --- a/recipes/bitserializer/config.yml +++ b/recipes/bitserializer/config.yml @@ -1,4 +1,6 @@ versions: + "0.65": + folder: "all" "0.50": folder: "all" "0.44": From c4dc7705c622fa3721cfeb9e9ebd4790989c376a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 4 Oct 2023 02:12:47 +0200 Subject: [PATCH 0922/1140] (#19938) apr-util: bump dependencies and use version range for openssl * bump dependencies and use version range for openssl * fix libdirs in APRUTIL_LDFLAGS env var --- recipes/apr-util/all/conanfile.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/recipes/apr-util/all/conanfile.py b/recipes/apr-util/all/conanfile.py index 86dd0a9fc160cd..cdc91defc9dca4 100644 --- a/recipes/apr-util/all/conanfile.py +++ b/recipes/apr-util/all/conanfile.py @@ -76,7 +76,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("apr/1.7.0", transitive_headers=True) + self.requires("apr/1.7.4", transitive_headers=True) if self.settings.os != "Windows": #cmake build doesn't allow injection of iconv yet # https://github.com/conan-io/conan-center-index/pull/16142#issuecomment-1494282164 @@ -84,15 +84,15 @@ def requirements(self): # are pulling it in - discovered in https://github.com/conan-io/conan-center-index/pull/16266 self.requires("libiconv/1.17", transitive_libs=True) if self.options.with_openssl: - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1.1 <4]") if self.options.with_mysql: - self.requires("libmysqlclient/8.0.31") + self.requires("libmysqlclient/8.1.0") if self.options.with_sqlite3: - self.requires("sqlite3/3.41.1") + self.requires("sqlite3/3.43.1") if self.options.with_expat: self.requires("expat/2.5.0") if self.options.with_postgresql: - self.requires("libpq/14.5") + self.requires("libpq/15.4") def validate(self): if not self.options.with_expat: @@ -210,7 +210,7 @@ def package_info(self): self.runenv_info.define_path("APR_UTIL_ROOT", self.package_folder) deps = [dep for dep in reversed(self.dependencies.host.topological_sort.values())] - libdirs = [p for dep in deps for p in dep.cpp_info.aggregated_components().includedirs] + libdirs = [p for dep in deps for p in dep.cpp_info.aggregated_components().libdirs] aprutil_ldflags = " ".join([f"-L{p}" for p in libdirs]) self.runenv_info.define("APRUTIL_LDFLAGS", aprutil_ldflags) From 70af853087f1488e823505718a163907e9b28a4e Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 4 Oct 2023 09:51:38 +0900 Subject: [PATCH 0923/1140] (#20078) libcoro: add version 0.9 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libcoro: add version 0.9 * make openssl transitive_headers * link math lib * Update recipes/libcoro/all/conandata.yml --------- Co-authored-by: Rubén Rincón Blanco --- recipes/libcoro/all/conandata.yml | 14 +++++++++++ recipes/libcoro/all/conanfile.py | 23 +++++++++++++++++-- .../patches/0.9-0001-allow-shared-lib.patch | 13 +++++++++++ .../patches/0.9-0002-disable-git-config.patch | 21 +++++++++++++++++ .../patches/0.9-0003-include-exception.patch | 15 ++++++++++++ recipes/libcoro/config.yml | 2 ++ 6 files changed, 86 insertions(+), 2 deletions(-) create mode 100644 recipes/libcoro/all/patches/0.9-0001-allow-shared-lib.patch create mode 100644 recipes/libcoro/all/patches/0.9-0002-disable-git-config.patch create mode 100644 recipes/libcoro/all/patches/0.9-0003-include-exception.patch diff --git a/recipes/libcoro/all/conandata.yml b/recipes/libcoro/all/conandata.yml index 61258b10a8ddf9..08d79c6bc3667c 100644 --- a/recipes/libcoro/all/conandata.yml +++ b/recipes/libcoro/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.9": + url: "https://github.com/jbaldwin/libcoro/archive/refs/tags/v0.9.tar.gz" + sha256: "680479582023f019bfa58b17bbcd30aa2ef1a8ba2c09d4ea9b296dbc77e93f1f" "0.8": url: "https://github.com/jbaldwin/libcoro/archive/refs/tags/v0.8.tar.gz" sha256: "09d8de39c9233d79c0dd1379c6826c636f63667f21001b66eb9b2080f6b270ad" @@ -6,6 +9,17 @@ sources: url: "https://github.com/jbaldwin/libcoro/archive/refs/tags/v0.7.tar.gz" sha256: "ce1f3f1c4fa21b53d1cd195a29bd5a2313e53aa35637b402db04207d02316e51" patches: + "0.9": + - patch_file: "patches/0.9-0001-allow-shared-lib.patch" + patch_type: "conan" + patch_description: "Allow to build the library as a shared library" + - patch_file: "patches/0.9-0002-disable-git-config.patch" + patch_type: "conan" + patch_description: "Comment out invocation of git config command" + - patch_file: "patches/0.9-0003-include-exception.patch" + patch_type: "backport" + patch_source: "https://github.com/jbaldwin/libcoro/pull/169" + patch_description: "include std headers" "0.8": - patch_file: "patches/0.8-0001-allow-shared-lib.patch" patch_type: "conan" diff --git a/recipes/libcoro/all/conanfile.py b/recipes/libcoro/all/conanfile.py index ea05c701592dce..1117b3d012d2ad 100644 --- a/recipes/libcoro/all/conanfile.py +++ b/recipes/libcoro/all/conanfile.py @@ -22,11 +22,15 @@ class LibcoroConan(ConanFile): "shared": [True, False], "fPIC": [True, False], "with_networking": [True, False], + "with_ssl": [True, False], + "with_threading": [True, False], } default_options = { "shared": False, "fPIC": True, "with_networking": True, + "with_ssl": True, + "with_threading": True, } @property @@ -47,6 +51,9 @@ def config_options(self): del self.options.fPIC if Version(self.version) < "0.8": del self.options.with_networking + if Version(self.version) < "0.9": + del self.options.with_ssl + del self.options.with_threading def configure(self): if self.options.shared: @@ -56,7 +63,8 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("openssl/[>=1.1 <4]", transitive_headers=True) + if "with_ssl" not in self.options or self.options.with_ssl: + self.requires("openssl/[>=1.1 <4]", transitive_headers=True) self.requires("c-ares/1.19.1", transitive_headers=True) self.requires("tl-expected/1.1.0", transitive_headers=True) @@ -84,6 +92,9 @@ def generate(self): if Version(self.version) >= "0.8": tc.variables["LIBCORO_EXTERNAL_DEPENDENCIES"] = True tc.variables["LIBCORO_FEATURE_NETWORKING"] = self.options.with_networking + if Version(self.version) >= "0.9": + tc.variables["LIBCORO_FEATURE_THREADING"] = self.options.with_threading + tc.variables["LIBCORO_FEATURE_SSL"] = self.options.with_ssl tc.generate() deps = CMakeDeps(self) deps.generate() @@ -108,4 +119,12 @@ def package_info(self): else: self.cpp_info.libs = ["libcoro"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["pthread"] + self.cpp_info.system_libs = ["pthread", "m"] + + if Version(self.version) >= "0.9": + if self.options.with_networking: + self.cpp_info.defines.append("LIBCORO_FEATURE_NETWORKING") + if self.options.with_ssl: + self.cpp_info.defines.append("LIBCORO_FEATURE_SSL") + if self.options.with_threading: + self.cpp_info.defines.append("LIBCORO_FEATURE_THREADING") diff --git a/recipes/libcoro/all/patches/0.9-0001-allow-shared-lib.patch b/recipes/libcoro/all/patches/0.9-0001-allow-shared-lib.patch new file mode 100644 index 00000000000000..4838c6103aa0fa --- /dev/null +++ b/recipes/libcoro/all/patches/0.9-0001-allow-shared-lib.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index ef0eea4..4c342e3 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -110,7 +110,7 @@ if(LIBCORO_FEATURE_NETWORKING) + endif() + endif() + +-add_library(${PROJECT_NAME} STATIC ${LIBCORO_SOURCE_FILES}) ++add_library(${PROJECT_NAME} ${LIBCORO_SOURCE_FILES}) + set_target_properties(${PROJECT_NAME} PROPERTIES LINKER_LANGUAGE CXX PREFIX "") + target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_20) + target_include_directories(${PROJECT_NAME} PUBLIC inc) diff --git a/recipes/libcoro/all/patches/0.9-0002-disable-git-config.patch b/recipes/libcoro/all/patches/0.9-0002-disable-git-config.patch new file mode 100644 index 00000000000000..b169455e6e1bae --- /dev/null +++ b/recipes/libcoro/all/patches/0.9-0002-disable-git-config.patch @@ -0,0 +1,21 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index ef0eea4..4c342e3 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -12,11 +12,11 @@ if (NOT "$ENV{version}" STREQUAL "") + endif() + + # Set the githooks directory to auto format and update the readme. +-message("${PROJECT_NAME} ${CMAKE_CURRENT_SOURCE_DIR} -> git config --local core.hooksPath .githooks") +-execute_process( +- COMMAND git config --local core.hooksPath .githooks +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} +-) ++#message("${PROJECT_NAME} ${CMAKE_CURRENT_SOURCE_DIR} -> git config --local core.hooksPath .githooks") ++#execute_process( ++# COMMAND git config --local core.hooksPath .githooks ++# WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR} ++#) + + option(LIBCORO_EXTERNAL_DEPENDENCIES "Use Cmake find_package to resolve dependencies instead of embedded libraries, Default=OFF." OFF) + option(LIBCORO_BUILD_TESTS "Build the tests, Default=ON." ON) diff --git a/recipes/libcoro/all/patches/0.9-0003-include-exception.patch b/recipes/libcoro/all/patches/0.9-0003-include-exception.patch new file mode 100644 index 00000000000000..eac4b8bc794e63 --- /dev/null +++ b/recipes/libcoro/all/patches/0.9-0003-include-exception.patch @@ -0,0 +1,15 @@ +diff --git a/inc/coro/generator.hpp b/inc/coro/generator.hpp +index ede42d0..b103fb8 100644 +--- a/inc/coro/generator.hpp ++++ b/inc/coro/generator.hpp +@@ -1,8 +1,8 @@ + #pragma once +- + #include + #include +- ++#include ++#include + namespace coro + { + template diff --git a/recipes/libcoro/config.yml b/recipes/libcoro/config.yml index a836136a326319..77538762e21e74 100644 --- a/recipes/libcoro/config.yml +++ b/recipes/libcoro/config.yml @@ -1,4 +1,6 @@ versions: + "0.9": + folder: all "0.8": folder: all "0.7": From fd23fdc5ac28fbf0b9c317213686e829c4d3a827 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 4 Oct 2023 10:12:24 +0900 Subject: [PATCH 0924/1140] (#20241) ada: add version 2.6.10 --- recipes/ada/all/conandata.yml | 3 +++ recipes/ada/all/conanfile.py | 3 ++- recipes/ada/config.yml | 2 ++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index 0d566dbc80ea82..509473568c35a1 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.6.10": + url: "https://github.com/ada-url/ada/archive/v2.6.10.tar.gz" + sha256: "a43e1ea0bcdd7585edf538afffe1fc3303b936752e18bac545fa11729de088bc" "2.6.7": url: "https://github.com/ada-url/ada/archive/v2.6.7.tar.gz" sha256: "882a0aa6e19174b60b2fa00ee75d35a31ecd5158fb97d0e4e719ba21bb07acb9" diff --git a/recipes/ada/all/conanfile.py b/recipes/ada/all/conanfile.py index 4954905b8f7dee..68040e85196714 100644 --- a/recipes/ada/all/conanfile.py +++ b/recipes/ada/all/conanfile.py @@ -82,7 +82,8 @@ def generate(self): def _patch_sources(self): # solve APPLE RELOCATABLE SHARED LIBS (KB-H077) - replace_in_file(self, os.path.join(self.source_folder, "cmake", "ada-flags.cmake"), "set(CMAKE_MACOSX_RPATH OFF)", "") + if Version(self.version) < "2.6.10": + replace_in_file(self, os.path.join(self.source_folder, "cmake", "ada-flags.cmake"), "set(CMAKE_MACOSX_RPATH OFF)", "") def build(self): self._patch_sources() diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index 2c76fe7baba056..417e43596e1945 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.6.10": + folder: all "2.6.7": folder: all "2.6.4": From 2ba7c25627152a93c078b43eb033e367f24c0bbb Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 4 Oct 2023 04:07:38 +0200 Subject: [PATCH 0925/1140] (#20242) onnx: respect protobuf lite option --- recipes/onnx/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/onnx/all/conanfile.py b/recipes/onnx/all/conanfile.py index 7d2738dc5a86a0..3f4e49bfd6bc57 100644 --- a/recipes/onnx/all/conanfile.py +++ b/recipes/onnx/all/conanfile.py @@ -84,7 +84,7 @@ def generate(self): tc.variables["ONNX_WERROR"] = False tc.variables["ONNX_COVERAGE"] = False tc.variables["ONNX_BUILD_TESTS"] = False - tc.variables["ONNX_USE_LITE_PROTO"] = False + tc.variables["ONNX_USE_LITE_PROTO"] = self.dependencies.host["protobuf"].options.lite tc.variables["ONNX_ML"] = True if Version(self.version) < "1.13.0": tc.variables["ONNXIFI_ENABLE_EXT"] = False From 8e944c28d9bec052af563b1fd2ddc9248503f209 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 4 Oct 2023 04:53:08 +0200 Subject: [PATCH 0926/1140] (#20243) qpdf/all: bump deps --- recipes/qpdf/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/qpdf/all/conanfile.py b/recipes/qpdf/all/conanfile.py index 2ec6c272a6287d..e97cf90bc30a7b 100644 --- a/recipes/qpdf/all/conanfile.py +++ b/recipes/qpdf/all/conanfile.py @@ -68,9 +68,9 @@ def requirements(self): if self.options.with_jpeg == "libjpeg": self.requires("libjpeg/9e") elif self.options.with_jpeg == "libjpeg-turbo": - self.requires("libjpeg-turbo/2.1.5") + self.requires("libjpeg-turbo/3.0.0") elif self.options.with_jpeg == "mozjpeg": - self.requires("mozjpeg/4.1.1") + self.requires("mozjpeg/4.1.3") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -88,7 +88,7 @@ def validate(self): def build_requirements(self): self.tool_requires("cmake/[>=3.16 <4]") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 4d3089e36467cf508cb5e995c00f97695db26b48 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 4 Oct 2023 05:32:29 +0200 Subject: [PATCH 0927/1140] (#20244) libgd/all: bump deps --- recipes/libgd/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libgd/all/conanfile.py b/recipes/libgd/all/conanfile.py index 965fc900c6e3b3..5776782b6abbcd 100644 --- a/recipes/libgd/all/conanfile.py +++ b/recipes/libgd/all/conanfile.py @@ -53,15 +53,15 @@ def layout(self): def requirements(self): self.requires("zlib/[>=1.2.11 <2]") if self.options.with_png: - self.requires("libpng/1.6.39") + self.requires("libpng/1.6.40") if is_msvc(self): self.requires("getopt-for-visual-studio/20200201") if self.options.with_jpeg: self.requires("libjpeg/9e") if self.options.with_tiff: - self.requires("libtiff/4.4.0") + self.requires("libtiff/4.6.0") if self.options.with_freetype: - self.requires("freetype/2.12.1") + self.requires("freetype/2.13.0") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 21d7cc349962dfb67c5e6de39128f24f9fcb4ace Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 4 Oct 2023 13:11:33 +0900 Subject: [PATCH 0928/1140] (#20251) pugixml: add version 1.14 --- recipes/pugixml/all/conandata.yml | 3 +++ recipes/pugixml/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/pugixml/all/conandata.yml b/recipes/pugixml/all/conandata.yml index 0e56e7f953dbc0..cfdd629e0abb24 100644 --- a/recipes/pugixml/all/conandata.yml +++ b/recipes/pugixml/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.14": + url: "https://github.com/zeux/pugixml/releases/download/v1.14/pugixml-1.14.tar.gz" + sha256: "2f10e276870c64b1db6809050a75e11a897a8d7456c4be5c6b2e35a11168a015" "1.13": url: "https://github.com/zeux/pugixml/releases/download/v1.13/pugixml-1.13.tar.gz" sha256: "40c0b3914ec131485640fa57e55bf1136446026b41db91c1bef678186a12abbe" diff --git a/recipes/pugixml/config.yml b/recipes/pugixml/config.yml index 191cc957e0c3b6..384412d36091f9 100644 --- a/recipes/pugixml/config.yml +++ b/recipes/pugixml/config.yml @@ -1,4 +1,6 @@ versions: + "1.14": + folder: "all" "1.13": folder: "all" "1.12.1": From b21f628d8e7521ff50710e4e7a6f0dfddc0ddb2f Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 4 Oct 2023 06:50:53 +0200 Subject: [PATCH 0929/1140] (#20252) fontconfig/meson: bump deps * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * fontconfig/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/fontconfig/meson/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/fontconfig/meson/conanfile.py b/recipes/fontconfig/meson/conanfile.py index 4ae32ba159e757..ab15f87fd44866 100644 --- a/recipes/fontconfig/meson/conanfile.py +++ b/recipes/fontconfig/meson/conanfile.py @@ -56,9 +56,9 @@ def requirements(self): def build_requirements(self): self.tool_requires("gperf/3.1") - self.tool_requires("meson/1.2.1") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/2.0.2") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 36dcdcdf16db8073b1eaa9713c4f13532083872e Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 4 Oct 2023 07:38:42 +0200 Subject: [PATCH 0930/1140] (#20180) brotli: relocatable shared libs on macOS for 1.1.0 --- recipes/brotli/all/conanfile.py | 5 +++-- recipes/brotli/all/patches/1.1.0-target-props.patch | 10 ++++------ 2 files changed, 7 insertions(+), 8 deletions(-) diff --git a/recipes/brotli/all/conanfile.py b/recipes/brotli/all/conanfile.py index 7e93d9903056df..47e559afcc649d 100644 --- a/recipes/brotli/all/conanfile.py +++ b/recipes/brotli/all/conanfile.py @@ -78,8 +78,9 @@ def generate(self): tc.preprocessor_definitions["BROTLI_DEBUG"] = 1 if self.options.enable_log: tc.preprocessor_definitions["BROTLI_ENABLE_LOG"] = 1 - # To install relocatable shared libs on Macos - tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" + if Version(self.version) < "1.1.0": + # To install relocatable shared libs on Macos + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" tc.generate() def build(self): diff --git a/recipes/brotli/all/patches/1.1.0-target-props.patch b/recipes/brotli/all/patches/1.1.0-target-props.patch index df1e483759f2e6..0c9b697569cec8 100644 --- a/recipes/brotli/all/patches/1.1.0-target-props.patch +++ b/recipes/brotli/all/patches/1.1.0-target-props.patch @@ -1,15 +1,13 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 61378cd..4de317b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -112,7 +112,6 @@ elseif(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD") - add_definitions(-DOS_FREEBSD) +@@ -113,7 +113,6 @@ elseif(${CMAKE_SYSTEM_NAME} MATCHES "FreeBSD") elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") add_definitions(-DOS_MACOSX) -- set(CMAKE_MACOS_RPATH TRUE) - set(CMAKE_INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib") + set(CMAKE_MACOS_RPATH TRUE) +- set(CMAKE_INSTALL_NAME_DIR "${CMAKE_INSTALL_PREFIX}/lib") endif() + if(BROTLI_EMSCRIPTEN) @@ -171,14 +170,10 @@ endif() # Build the brotli executable add_executable(brotli c/tools/brotli.c) From b2225b761cbf8f172c51d304ae4abf8c93dfce55 Mon Sep 17 00:00:00 2001 From: Roberto Rossini <71787608+robomics@users.noreply.github.com> Date: Wed, 4 Oct 2023 08:53:27 +0200 Subject: [PATCH 0931/1140] (#20295) hictk: add v0.0.3 and bump deps --- recipes/hictk/all/conandata.yml | 3 +++ recipes/hictk/all/conanfile.py | 6 +++++- recipes/hictk/config.yml | 2 ++ 3 files changed, 10 insertions(+), 1 deletion(-) diff --git a/recipes/hictk/all/conandata.yml b/recipes/hictk/all/conandata.yml index accdbdc6e5b48e..0a77d0b0f3599a 100644 --- a/recipes/hictk/all/conandata.yml +++ b/recipes/hictk/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.0.3": + url: "https://github.com/paulsengroup/hictk/archive/refs/tags/v0.0.3.tar.gz" + sha256: "f49657b9ef80ef9fa07f125a0b6f056923235c9ea77e19cee312b004384ea39e" "0.0.2": url: "https://github.com/paulsengroup/hictk/archive/refs/tags/v0.0.2.tar.gz" sha256: "7716711ecb33247d8f79f6768ebbdcf55e51e9b6f962245747b33d0967431427" diff --git a/recipes/hictk/all/conanfile.py b/recipes/hictk/all/conanfile.py index 8f5dc0a67cf84f..a654990739eee2 100644 --- a/recipes/hictk/all/conanfile.py +++ b/recipes/hictk/all/conanfile.py @@ -39,15 +39,19 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): + self.requires("bshoshany-thread-pool/3.5.0", transitive_headers=True) self.requires("fast_float/5.2.0", transitive_headers=True) if self.options.with_eigen: self.requires("eigen/3.4.0", transitive_headers=True) - self.requires("fmt/10.1.0", transitive_headers=True) + self.requires("fmt/10.1.1", transitive_headers=True) self.requires("hdf5/1.14.1", transitive_headers=True) self.requires("highfive/2.7.1", transitive_headers=True) self.requires("libdeflate/1.18", transitive_headers=True) self.requires("parallel-hashmap/1.3.11", transitive_headers=True) + self.requires("span-lite/0.10.3", transitive_headers=True) self.requires("spdlog/1.12.0", transitive_headers=True) + self.requires("xxhash/0.8.2", transitive_headers=True) + self.requires("zstd/1.5.5", transitive_headers=True) def package_id(self): self.info.clear() diff --git a/recipes/hictk/config.yml b/recipes/hictk/config.yml index 05473f80b31308..ff35624c14df59 100644 --- a/recipes/hictk/config.yml +++ b/recipes/hictk/config.yml @@ -1,4 +1,6 @@ versions: + "0.0.3": + folder: all "0.0.2": folder: all "0.0.1": From fc68f16d9c17db21db108f6dc16d61e2436d2047 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 4 Oct 2023 09:46:25 +0200 Subject: [PATCH 0932/1140] (#20177) pupnp: relocatable shared libs on macOS Co-authored-by: Uilian Ries --- recipes/pupnp/all/conanfile.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/recipes/pupnp/all/conanfile.py b/recipes/pupnp/all/conanfile.py index ec9c1261d9bacf..eda427ac46bf0c 100644 --- a/recipes/pupnp/all/conanfile.py +++ b/recipes/pupnp/all/conanfile.py @@ -2,6 +2,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name from conan.tools.env import VirtualBuildEnv from conan.tools.files import copy, get, rm, rmdir from conan.tools.gnu import Autotools, AutotoolsToolchain @@ -114,6 +115,7 @@ def package(self): autotools.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rm(self, "*.la", self.package_folder, recursive=True) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.set_property("pkg_config_name", "libupnp") From ac5617a60d588a35178104c09f30801379fd200b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 11:42:45 +0300 Subject: [PATCH 0933/1140] (#18253) kitten: migrate to Conan v2 * kitten: migrate to Conan v2 * kitten: restore test_v1_package * kitten: restore VirtualRunEnv in test_package --- recipes/kitten/all/CMakeLists.txt | 7 -- recipes/kitten/all/conanfile.py | 77 +++++++++---------- .../kitten/all/test_package/CMakeLists.txt | 5 +- recipes/kitten/all/test_package/conanfile.py | 19 +++-- .../kitten/all/test_package/test_package.cpp | 9 ++- .../kitten/all/test_v1_package/CMakeLists.txt | 8 ++ .../kitten/all/test_v1_package/conanfile.py | 17 ++++ 7 files changed, 82 insertions(+), 60 deletions(-) delete mode 100644 recipes/kitten/all/CMakeLists.txt create mode 100644 recipes/kitten/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/kitten/all/test_v1_package/conanfile.py diff --git a/recipes/kitten/all/CMakeLists.txt b/recipes/kitten/all/CMakeLists.txt deleted file mode 100644 index d17aaff199b4a6..00000000000000 --- a/recipes/kitten/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.8.11) -project(cmake_wrapper) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/kitten/all/conanfile.py b/recipes/kitten/all/conanfile.py index 7db05a55fbcac1..04b20a94ca5f99 100644 --- a/recipes/kitten/all/conanfile.py +++ b/recipes/kitten/all/conanfile.py @@ -1,28 +1,30 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class KittenConan(ConanFile): name = "kitten" description = "A small C++ library inspired by Category Theory focused on functional composition." - homepage = "https://github.com/rvarago/kitten" - url = "https://github.com/conan-io/conan-center-index" license = "MIT" - topics = ("category-theory", "composition", "monadic-interface", "declarative-programming") + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/rvarago/kitten" + topics = ("category-theory", "composition", "monadic-interface", "declarative-programming", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - no_copy_source = True - exports_sources = "CMakeLists.txt" - generators = "cmake" - _cmake = None @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 17 @property def _minimum_compilers_version(self): @@ -33,50 +35,46 @@ def _minimum_compilers_version(self): "apple-clang": "10", } + def layout(self): + cmake_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 17) - - def loose_lt_semver(v1, v2): - lv1 = [int(v) for v in v1.split(".")] - lv2 = [int(v) for v in v2.split(".")] - min_length = min(len(lv1), len(lv2)) - return lv1[:min_length] < lv2[:min_length] + check_min_cppstd(self, self._min_cppstd) min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) - if min_version and loose_lt_semver(str(self.settings.compiler.version), min_version): - raise ConanInvalidConfiguration( - "{} requires C++17, which your compiler does not support.".format(self.name) - ) - - def package_id(self): - self.info.header_only() + if min_version and Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration(f"{self.name} requires C++{self._min_cppstd}, which your compiler does not support.") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["BUILD_TESTS"] = False - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["BUILD_TESTS"] = False + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "lib", "cmake")) + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "kitten") self.cpp_info.set_property("cmake_target_name", "rvarago::kitten") + self.cpp_info.components["libkitten"].set_property("cmake_target_name", "rvarago::kitten") # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "kitten" @@ -85,4 +83,3 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "rvarago" self.cpp_info.components["libkitten"].names["cmake_find_package"] = "kitten" self.cpp_info.components["libkitten"].names["cmake_find_package_multi"] = "kitten" - self.cpp_info.components["libkitten"].set_property("cmake_target_name", "rvarago::kitten") diff --git a/recipes/kitten/all/test_package/CMakeLists.txt b/recipes/kitten/all/test_package/CMakeLists.txt index 60b5b3b426db6b..8f30ef6f011383 100644 --- a/recipes/kitten/all/test_package/CMakeLists.txt +++ b/recipes/kitten/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(kitten REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/kitten/all/test_package/conanfile.py b/recipes/kitten/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/kitten/all/test_package/conanfile.py +++ b/recipes/kitten/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/kitten/all/test_package/test_package.cpp b/recipes/kitten/all/test_package/test_package.cpp index 8ddfae2423dd72..50559e2a32b1d0 100644 --- a/recipes/kitten/all/test_package/test_package.cpp +++ b/recipes/kitten/all/test_package/test_package.cpp @@ -1,14 +1,15 @@ +#include "kitten/instances/optional.h" +#include "kitten/kitten.h" + #include #include -#include "kitten/kitten.h" -#include "kitten/instances/optional.h" - using namespace rvarago::kitten; int main() { auto constexpr maybe_an_approximate_answer = std::optional{41}; - auto constexpr exact_answer = (maybe_an_approximate_answer | [](auto const& el) { return el + 1; }).value(); + auto constexpr exact_answer = + (maybe_an_approximate_answer | [](auto const& el) { return el + 1; }).value(); static_assert(42 == exact_answer); std::cout << "rvarago::kitten works! The exact answer is: " << exact_answer << '\n'; return 0; diff --git a/recipes/kitten/all/test_v1_package/CMakeLists.txt b/recipes/kitten/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/kitten/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/kitten/all/test_v1_package/conanfile.py b/recipes/kitten/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/kitten/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 64a40904e0460ce8ff6cf1f9b64fe640bc400ceb Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 11:49:55 +0300 Subject: [PATCH 0934/1140] (#18356) so5extra: migrate to Conan v2 * so5extra: migrate to Conan v2 * so5extra: restore test_v1_package * so5extra: restore VirtualRunEnv in test_package * so5extra: bump deps --- recipes/so5extra/all/conanfile.py | 83 +++++++++++-------- .../so5extra/all/test_package/CMakeLists.txt | 5 +- .../so5extra/all/test_package/conanfile.py | 19 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../so5extra/all/test_v1_package/conanfile.py | 17 ++++ 5 files changed, 89 insertions(+), 43 deletions(-) create mode 100644 recipes/so5extra/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/so5extra/all/test_v1_package/conanfile.py diff --git a/recipes/so5extra/all/conanfile.py b/recipes/so5extra/all/conanfile.py index 080aef93955585..57a11fc2bf146f 100644 --- a/recipes/so5extra/all/conanfile.py +++ b/recipes/so5extra/all/conanfile.py @@ -1,63 +1,80 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class So5extraConan(ConanFile): name = "so5extra" + description = "A collection of various SObjectizer's extensions." license = "BSD-3-Clause" - homepage = "https://github.com/Stiffstream/so5extra" url = "https://github.com/conan-io/conan-center-index" - description = "A collection of various SObjectizer's extensions." - topics = ("concurrency", "actor-framework", "actors", "agents", "sobjectizer") + homepage = "https://github.com/Stiffstream/so5extra" + topics = ("concurrency", "actor-framework", "actors", "agents", "sobjectizer", "header-only") + + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" + def _min_cppstd(self): + return 17 - def requirements(self): - self.requires("sobjectizer/5.7.4") - - def validate(self): - minimal_cpp_standard = "17" - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, minimal_cpp_standard) - minimal_version = { + @property + def _compilers_minimum_version(self): + return { "gcc": "7", "clang": "6", "apple-clang": "10", - "Visual Studio": "15" + "Visual Studio": "15", } - compiler = str(self.settings.compiler) - if compiler not in minimal_version: - self.output.warn( - "%s recipe lacks information about the %s compiler standard version support" % (self.name, compiler)) - self.output.warn( - "%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) - return - version = tools.Version(self.settings.compiler.version) - if version < minimal_version[compiler]: - raise ConanInvalidConfiguration("%s requires a compiler that supports at least C++%s" % (self.name, minimal_cpp_standard)) + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("sobjectizer/5.8.0") def package_id(self): - self.info.header_only() + self.info.clear() + + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + compiler = str(self.settings.compiler) + if compiler not in self._compilers_minimum_version: + self.output.warning(f"{self.name} recipe lacks information about the {compiler} compiler standard version support") + self.output.warning(f"{self.name} requires a compiler that supports at least C++{self._min_cppstd}") + return + version = Version(self.settings.compiler.version) + if version < self._compilers_minimum_version[compiler]: + raise ConanInvalidConfiguration(f"{self.name} requires a compiler that supports at least C++{self._min_cppstd}") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy("*.hpp", dst="include/so_5_extra", src=os.path.join(self._source_subfolder, "dev", "so_5_extra")) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "*.hpp", + dst=os.path.join(self.package_folder, "include/so_5_extra"), + src=os.path.join(self.source_folder, "dev", "so_5_extra")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_file_name", "so5extra") self.cpp_info.set_property("cmake_target_name", "sobjectizer::so5extra") + self.cpp_info.components["so_5_extra"].set_property("cmake_target_name", "sobjectizer::so5extra") + self.cpp_info.components["so_5_extra"].requires = ["sobjectizer::sobjectizer"] # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "so5extra" @@ -66,5 +83,3 @@ def package_info(self): self.cpp_info.names["cmake_find_package_multi"] = "sobjectizer" self.cpp_info.components["so_5_extra"].names["cmake_find_package"] = "so5extra" self.cpp_info.components["so_5_extra"].names["cmake_find_package_multi"] = "so5extra" - self.cpp_info.components["so_5_extra"].set_property("cmake_target_name", "sobjectizer::so5extra") - self.cpp_info.components["so_5_extra"].requires = ["sobjectizer::sobjectizer"] diff --git a/recipes/so5extra/all/test_package/CMakeLists.txt b/recipes/so5extra/all/test_package/CMakeLists.txt index 933e0f59b04bde..6797a4d254c0ad 100644 --- a/recipes/so5extra/all/test_package/CMakeLists.txt +++ b/recipes/so5extra/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.8) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(so5extra REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/so5extra/all/test_package/conanfile.py b/recipes/so5extra/all/test_package/conanfile.py index 38f4483872d47f..ef5d7042163ecc 100644 --- a/recipes/so5extra/all/test_package/conanfile.py +++ b/recipes/so5extra/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/so5extra/all/test_v1_package/CMakeLists.txt b/recipes/so5extra/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/so5extra/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/so5extra/all/test_v1_package/conanfile.py b/recipes/so5extra/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..38f4483872d47f --- /dev/null +++ b/recipes/so5extra/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 437cf83dd36bf972f9289f192a2d1125af32ff47 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 13:28:36 +0300 Subject: [PATCH 0935/1140] (#18360) libxpm: migrate to Conan v2 * libxpm: migrate to Conan v2 * libxpm: restore test_v1_package * libxpm: not a header-only library * libxpm: remove duplicate source file * libxpm: fix windows/ export * libxpm: add VirtualRunEnv --- recipes/libxpm/all/CMakeLists.txt | 3 - recipes/libxpm/all/conanfile.py | 73 +++++++++++-------- .../libxpm/all/test_package/CMakeLists.txt | 5 +- recipes/libxpm/all/test_package/conanfile.py | 20 +++-- .../libxpm/all/test_package/test_package.c | 6 +- .../libxpm/all/test_v1_package/CMakeLists.txt | 8 ++ .../libxpm/all/test_v1_package/conanfile.py | 18 +++++ 7 files changed, 86 insertions(+), 47 deletions(-) create mode 100644 recipes/libxpm/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libxpm/all/test_v1_package/conanfile.py diff --git a/recipes/libxpm/all/CMakeLists.txt b/recipes/libxpm/all/CMakeLists.txt index 77475adeda3d99..681dd5c613eecc 100644 --- a/recipes/libxpm/all/CMakeLists.txt +++ b/recipes/libxpm/all/CMakeLists.txt @@ -2,9 +2,6 @@ cmake_minimum_required(VERSION 3.1) project(libXpm VERSION "${CONAN_libXpm_VERSION}" LANGUAGES C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS) - # ---- X11 dependency ---- if(NOT WIN32) diff --git a/recipes/libxpm/all/conanfile.py b/recipes/libxpm/all/conanfile.py index 63d51162a71f71..0312deadc10a94 100644 --- a/recipes/libxpm/all/conanfile.py +++ b/recipes/libxpm/all/conanfile.py @@ -1,19 +1,22 @@ -import functools import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class LibXpmConan(ConanFile): name = "libxpm" description = "X Pixmap (XPM) image file format library" + license = "MIT-open-group" url = "https://github.com/conan-io/conan-center-index" homepage = "https://gitlab.freedesktop.org/xorg/lib/libxpm" - topics = "xpm" - license = "MIT-open-group" + topics = ("xpm",) + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -23,18 +26,15 @@ class LibXpmConan(ConanFile): "shared": False, "fPIC": True, } - generators = "cmake" - exports_sources = "CMakeLists.txt", "windows/*" no_copy_source = True - def validate(self): - if self.settings.os not in ("Windows", "Linux", "FreeBSD"): - raise ConanInvalidConfiguration( - "libXpm is supported only on Windows, Linux and FreeBSD" - ) - - def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True) + def export_sources(self): + copy(self, "CMakeLists.txt", + src=self.recipe_folder, + dst=os.path.join(self.export_sources_folder, "src")) + copy(self, "*", + src=os.path.join(self.recipe_folder, "windows"), + dst=os.path.join(self.export_sources_folder, "src", "windows")) def config_options(self): if self.settings.os == "Windows": @@ -42,28 +42,43 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): if self.settings.os != "Windows": self.requires("xorg/system") - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.definitions["CONAN_libXpm_VERSION"] = self.version - cmake.configure() - return cmake + def validate(self): + if self.settings.os not in ("Windows", "Linux", "FreeBSD"): + raise ConanInvalidConfiguration("libXpm is supported only on Windows, Linux and FreeBSD") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["CONAN_libXpm_VERSION"] = self.version + tc.generate() def build(self): - self._configure_cmake().build() + cmake = CMake(self) + cmake.configure() + cmake.build() def package(self): - self.copy("COPYING", "licenses") - self.copy("COPYRIGHT", "licenses") - self._configure_cmake().install() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "COPYRIGHT", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) + cmake.install() def package_info(self): self.cpp_info.libs = ["Xpm"] diff --git a/recipes/libxpm/all/test_package/CMakeLists.txt b/recipes/libxpm/all/test_package/CMakeLists.txt index 0ea6d5bc37b287..1f28dfc6ff7536 100644 --- a/recipes/libxpm/all/test_package/CMakeLists.txt +++ b/recipes/libxpm/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS) - find_package(libxpm REQUIRED CONFIG) add_executable(test_package test_package.c) diff --git a/recipes/libxpm/all/test_package/conanfile.py b/recipes/libxpm/all/test_package/conanfile.py index a8c92dea633357..ef5d7042163ecc 100644 --- a/recipes/libxpm/all/test_package/conanfile.py +++ b/recipes/libxpm/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools - class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libxpm/all/test_package/test_package.c b/recipes/libxpm/all/test_package/test_package.c index ed1efad8c383c9..925df166533ce4 100644 --- a/recipes/libxpm/all/test_package/test_package.c +++ b/recipes/libxpm/all/test_package/test_package.c @@ -1,12 +1,8 @@ #include #include -int main(int argc, char const* argv[]) +int main() { - (void)argc; - (void)argv; - XpmFree(NULL); - return 0; } diff --git a/recipes/libxpm/all/test_v1_package/CMakeLists.txt b/recipes/libxpm/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libxpm/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libxpm/all/test_v1_package/conanfile.py b/recipes/libxpm/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..a8c92dea633357 --- /dev/null +++ b/recipes/libxpm/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 763cfb61f1410a87df581961fa3f916396016592 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 14:27:38 +0300 Subject: [PATCH 0936/1140] (#18824) libbasisu: migrate to Conan v2 * libbasisu: migrate to Conan v2 * libbasisu: restore VirtualRunEnv in test_package * libbasisu: fix zstd linking, shared build C source files were not being compiled due to missing "LANGUAGES C" in CMakeLists.txt. --- recipes/libbasisu/all/CMakeLists.txt | 7 - recipes/libbasisu/all/conandata.yml | 1 - recipes/libbasisu/all/conanfile.py | 159 ++++++++++-------- .../all/patches/cmakelist_build_lib.patch | 12 +- .../libbasisu/all/test_package/CMakeLists.txt | 10 +- .../libbasisu/all/test_package/conanfile.py | 21 ++- .../all/test_v1_package/CMakeLists.txt | 8 + .../all/test_v1_package/conanfile.py | 17 ++ 8 files changed, 142 insertions(+), 93 deletions(-) delete mode 100644 recipes/libbasisu/all/CMakeLists.txt create mode 100644 recipes/libbasisu/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libbasisu/all/test_v1_package/conanfile.py diff --git a/recipes/libbasisu/all/CMakeLists.txt b/recipes/libbasisu/all/CMakeLists.txt deleted file mode 100644 index bd4164cb5c1c75..00000000000000 --- a/recipes/libbasisu/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.10) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/libbasisu/all/conandata.yml b/recipes/libbasisu/all/conandata.yml index 7cca98d66479be..7f4a8cfdd695f4 100644 --- a/recipes/libbasisu/all/conandata.yml +++ b/recipes/libbasisu/all/conandata.yml @@ -5,4 +5,3 @@ sources: patches: "1.15.0": - patch_file: "patches/cmakelist_build_lib.patch" - base_path: "source_subfolder" diff --git a/recipes/libbasisu/all/conanfile.py b/recipes/libbasisu/all/conanfile.py index 6dfaf4ee7f3dec..2c8606aca448ad 100644 --- a/recipes/libbasisu/all/conanfile.py +++ b/recipes/libbasisu/all/conanfile.py @@ -1,114 +1,133 @@ import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" class LibBasisUniversalConan(ConanFile): name = "libbasisu" description = "Basis Universal Supercompressed GPU Texture Codec" - homepage = "https://github.com/BinomialLLC/basis_universal" - topics = ("conan", "basis", "textures", "compression") - url = "https://github.com/conan-io/conan-center-index" license = "Apache-2.0" - exports_sources = ["CMakeLists.txt", "patches/*"] - generators = "cmake" - settings = "os", "compiler", "build_type", "arch" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/BinomialLLC/basis_universal" + topics = ("basis", "textures", "compression") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { - "fPIC": [True, False], "shared": [True, False], + "fPIC": [True, False], "use_sse4": [True, False], "with_zstd": [True, False], "enable_encoder": [True, False], - "custom_iterator_debug_level": [True, False] + "custom_iterator_debug_level": [True, False], } default_options = { - "fPIC": True, "shared": False, + "fPIC": True, "use_sse4": False, "with_zstd": True, "enable_encoder": True, - "custom_iterator_debug_level": False + "custom_iterator_debug_level": False, } - _cmake = None + def _minimum_compiler_version(self): + return { + "Visual Studio": "15", + "gcc": "5.4", + "clang": "3.9", + "apple-clang": "10", + } - @property - def _source_subfolder(self): - return "source_subfolder" + def _use_custom_iterator_debug_level(self): + return self.options.get_safe("custom_iterator_debug_level", + default=self.default_options["custom_iterator_debug_level"]) - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) - def _use_custom_iterator_debug_level(self): - return self.options.get_safe("custom_iterator_debug_level", default=self.default_options["custom_iterator_debug_level"]) - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - if self.settings.compiler != "Visual Studio": - del self.options.custom_iterator_debug_level + if not is_msvc(self): + self.options.rm_safe("custom_iterator_debug_level") - def _minimum_compiler_version(self) -> bool: - return { - "Visual Studio": "15", - "gcc": "5.4", - "clang": "3.9", - "apple-clang": "10" - } + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def requirements(self): + if self.options.with_zstd: + self.requires("zstd/1.5.5") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): min_version = self._minimum_compiler_version().get(str(self.settings.compiler)) if not min_version: - self.output.warn("{} recipe lacks information about the {} compiler support.".format( - self.name, self.settings.compiler)) - elif tools.Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration("{} {} does not support compiler with version {} {}, minimum supported compiler version is {} ".format(self.name, self.version, self.settings.compiler, self.settings.compiler.version, min_version)) + self.output.warning( + f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support." + ) + elif Version(self.settings.compiler.version) < min_version: + raise ConanInvalidConfiguration( + f"{self.name} {self.version} does not support compiler with version" + f" {self.settings.compiler} {self.settings.compiler.version}, minimum supported compiler" + f" version is {min_version} " + ) if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 11) - - def configure(self): - if self.options.shared: - del self.options.fPIC + check_min_cppstd(self, 11) def source(self): - tools.get(**self.conan_data["sources"][self.version], strip_root=True, destination=self._source_subfolder) - - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["SSE4"] = self.options.use_sse4 - self._cmake.definitions["ZSTD"] = self.options.with_zstd - self._cmake.definitions["ENABLE_ENCODER"] = self.options.enable_encoder - self._cmake.definitions["NO_ITERATOR_DEBUG_LEVEL"] = not self._use_custom_iterator_debug_level() - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["SSE4"] = self.options.use_sse4 + tc.variables["ZSTD"] = self.options.with_zstd + tc.variables["ENABLE_ENCODER"] = self.options.enable_encoder + tc.variables["NO_ITERATOR_DEBUG_LEVEL"] = not self._use_custom_iterator_debug_level() + tc.generate() + tc = CMakeDeps(self) + tc.generate() + def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - self.copy("*.h", dst=os.path.join("include", self.name, "transcoder"), src=os.path.join(self._source_subfolder, "transcoder")) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include", self.name, "transcoder"), + src=os.path.join(self.source_folder, "transcoder")) if self.options.enable_encoder: - self.copy("*.h", dst=os.path.join("include", self.name, "encoder"), src=os.path.join(self._source_subfolder, "encoder")) - self.copy(pattern="*.a", dst="lib", keep_path=False) - self.copy(pattern="*.so", dst="lib", keep_path=False) - self.copy(pattern="*.dylib*", dst="lib", keep_path=False) - self.copy(pattern="*.lib", dst="lib", keep_path=False) - self.copy(pattern="*.dll", dst="bin", keep_path=False) + copy(self,"*.h", + dst=os.path.join(self.package_folder, "include", self.name, "encoder"), + src=os.path.join(self.source_folder, "encoder")) + for pattern in ["*.a", "*.so*", "*.dylib*", "*.lib"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder, keep_path=False) + copy(self, "*.dll", + dst=os.path.join(self.package_folder, "bin"), + src=self.build_folder, keep_path=False) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - self.cpp_info.names["cmake_find_package"] = self.name - self.cpp_info.names["cmake_find_package_multi"] = self.name + self.cpp_info.libs = collect_libs(self) self.cpp_info.includedirs = ["include", os.path.join("include", self.name)] - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["m", "pthread"] - self.cpp_info.defines.append("BASISU_NO_ITERATOR_DEBUG_LEVEL={}".format("1" if self._use_custom_iterator_debug_level() else "0")) + self.cpp_info.defines.append( + "BASISU_NO_ITERATOR_DEBUG_LEVEL={}".format("1" if self._use_custom_iterator_debug_level() else "0") + ) diff --git a/recipes/libbasisu/all/patches/cmakelist_build_lib.patch b/recipes/libbasisu/all/patches/cmakelist_build_lib.patch index 043a9778c605d6..69bef6820b1385 100644 --- a/recipes/libbasisu/all/patches/cmakelist_build_lib.patch +++ b/recipes/libbasisu/all/patches/cmakelist_build_lib.patch @@ -17,7 +17,7 @@ -if( NOT CMAKE_BUILD_TYPE ) - set( CMAKE_BUILD_TYPE Release ) -endif() -+project(basisu VERSION 1.15.0 LANGUAGES CXX) ++project(basisu VERSION 1.15.0 LANGUAGES CXX C) -message( ${PROJECT_NAME} " build type: " ${CMAKE_BUILD_TYPE} ) - @@ -55,7 +55,7 @@ - if (NOT BUILD_X64) - set(GCC_COMPILE_FLAGS "${GCC_COMPILE_FLAGS} -m32") - endif() -+ set(GCC_COMPILE_FLAGS "-fPIC -fno-strict-aliasing -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 -Wall -Wextra -Wno-unused-local-typedefs -Wno-unused-value -Wno-unused-parameter -Wno-unused-variable") ++ set(GCC_COMPILE_FLAGS "-fno-strict-aliasing -D_LARGEFILE64_SOURCE=1 -D_FILE_OFFSET_BITS=64 -Wall -Wextra -Wno-unused-local-typedefs -Wno-unused-value -Wno-unused-parameter -Wno-unused-variable") - if (EMSCRIPTEN) - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -s ALLOW_MEMORY_GROWTH=1 -DBASISU_SUPPORT_SSE=0") @@ -99,7 +99,7 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -DBASISU_SUPPORT_SSE=1") set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DBASISU_SUPPORT_SSE=1") else() -@@ -93,64 +51,57 @@ else() +@@ -93,64 +51,63 @@ else() endif() endif() @@ -173,6 +173,12 @@ if (ZSTD) - target_compile_definitions(basisu PRIVATE BASISD_SUPPORT_KTX2_ZSTD=1) + target_compile_definitions(${PROJECT_NAME} PRIVATE BASISD_SUPPORT_KTX2_ZSTD=1) ++ find_package(zstd REQUIRED) ++ if (TARGET zstd::libzstd_static) ++ target_link_libraries(${PROJECT_NAME} PRIVATE zstd::libzstd_static) ++ else() ++ target_link_libraries(${PROJECT_NAME} PRIVATE zstd::libzstd_shared) ++ endif() else() - target_compile_definitions(basisu PRIVATE BASISD_SUPPORT_KTX2_ZSTD=0) + target_compile_definitions(${PROJECT_NAME} PRIVATE BASISD_SUPPORT_KTX2_ZSTD=0) diff --git a/recipes/libbasisu/all/test_package/CMakeLists.txt b/recipes/libbasisu/all/test_package/CMakeLists.txt index 2adca01f3e68a3..e4b4ddeb886b64 100644 --- a/recipes/libbasisu/all/test_package/CMakeLists.txt +++ b/recipes/libbasisu/all/test_package/CMakeLists.txt @@ -1,10 +1,8 @@ -cmake_minimum_required(VERSION 3.10) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(libbasisu REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) - -target_link_libraries(${PROJECT_NAME} PRIVATE CONAN_PKG::libbasisu) +target_link_libraries(${PROJECT_NAME} PRIVATE libbasisu::libbasisu) set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 11) diff --git a/recipes/libbasisu/all/test_package/conanfile.py b/recipes/libbasisu/all/test_package/conanfile.py index 12dd810a6ab3bc..ef5d7042163ecc 100644 --- a/recipes/libbasisu/all/test_package/conanfile.py +++ b/recipes/libbasisu/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libbasisu/all/test_v1_package/CMakeLists.txt b/recipes/libbasisu/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libbasisu/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libbasisu/all/test_v1_package/conanfile.py b/recipes/libbasisu/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..abcaeed3f89b67 --- /dev/null +++ b/recipes/libbasisu/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 071a19e039f8a60bbe148e4d80e4aaea3eba4638 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 15:16:04 +0300 Subject: [PATCH 0937/1140] (#20303) picobench: add version 2.05 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/picobench/all/conandata.yml | 7 +++++++ recipes/picobench/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/picobench/all/conandata.yml b/recipes/picobench/all/conandata.yml index 0bbacb7273fdfd..f6484b7236c423 100644 --- a/recipes/picobench/all/conandata.yml +++ b/recipes/picobench/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.05": + url: "https://github.com/iboB/picobench/archive/v2.05.tar.gz" + sha256: "4e10c3c7042c0519662565eed8949f5eb328333d2c9a2443464dede04ce0b00d" "2.02": url: "https://github.com/iboB/picobench/archive/refs/tags/v2.02.tar.gz" sha256: "22a896535d0e2fd8793cdc6c14bef42275f8de8d24ce2cfc55442ed1e0973c83" @@ -6,6 +9,10 @@ sources: url: "https://github.com/iboB/picobench/archive/refs/tags/v2.01.tar.gz" sha256: "164cb3b2d72a9b31e7559f6829ae38b6b955840571531117e0d6f53d669d3a2b" patches: + "2.05": + - patch_file: "patches/2.02-0001-add-install.patch" + patch_description: "add installer" + patch_type: "conan" "2.02": - patch_file: "patches/2.02-0001-add-install.patch" patch_description: "add installer" diff --git a/recipes/picobench/config.yml b/recipes/picobench/config.yml index d9b367577730d1..eb0d152fc4aa23 100644 --- a/recipes/picobench/config.yml +++ b/recipes/picobench/config.yml @@ -1,4 +1,6 @@ versions: + "2.05": + folder: all "2.02": folder: all "2.01": From 1a59abc920234a500da049748b9bb7524b7ddfad Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 15:55:04 +0300 Subject: [PATCH 0938/1140] (#20307) libmorton: add version 0.2.12 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libmorton/all/conandata.yml | 3 +++ recipes/libmorton/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libmorton/all/conandata.yml b/recipes/libmorton/all/conandata.yml index 388df27940d460..db08154a617a3b 100644 --- a/recipes/libmorton/all/conandata.yml +++ b/recipes/libmorton/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.2.12": + url: "https://github.com/Forceflow/libmorton/archive/v0.2.12.tar.gz" + sha256: "48ec3e4ad1d9348052dcb64bff012ff95db226da3fec5522ae6e674fabbd686f" "0.2.11": url: "https://github.com/Forceflow/libmorton/archive/refs/tags/v0.2.11.tar.gz" sha256: "3650ce8eb3deee28bc580e5bb1594fe07f7a33aa2531490bf09b5ab8207d55f6" diff --git a/recipes/libmorton/config.yml b/recipes/libmorton/config.yml index 88387c424a149d..056827a88e63b4 100644 --- a/recipes/libmorton/config.yml +++ b/recipes/libmorton/config.yml @@ -1,4 +1,6 @@ versions: + "0.2.12": + folder: all "0.2.11": folder: all "0.2.10": From 2a2069643e1f3e06e7d163bd8c74b2a9770a50ee Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 4 Oct 2023 22:35:31 +0900 Subject: [PATCH 0939/1140] (#20337) glaze: add version 1.5.2 --- recipes/glaze/all/conandata.yml | 3 +++ recipes/glaze/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/glaze/all/conandata.yml b/recipes/glaze/all/conandata.yml index d4df74aaa8ab0f..06afa0bf6a87b1 100644 --- a/recipes/glaze/all/conandata.yml +++ b/recipes/glaze/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.2": + url: "https://github.com/stephenberry/glaze/archive/v1.5.2.tar.gz" + sha256: "d9dff3570ae479123b8eadb890db41255c6c0c74c4cdb1b9ca3d1eb73f8ca5eb" "1.5.1": url: "https://github.com/stephenberry/glaze/archive/v1.5.1.tar.gz" sha256: "b119b0375d13ab34ebc156e1c12eacc65e7f4c8b0cfcf6ae93e8fe18744d1ad5" diff --git a/recipes/glaze/config.yml b/recipes/glaze/config.yml index bac143c8ee8f36..37445784d6356e 100644 --- a/recipes/glaze/config.yml +++ b/recipes/glaze/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.2": + folder: all "1.5.1": folder: all "1.5.0": From 49f3dcea02f289f0578a9bea5865f4438c781643 Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 4 Oct 2023 16:42:47 +0200 Subject: [PATCH 0940/1140] (#20291) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index bd4640c99ef65b..fc3d9282a9ef72 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -37,6 +37,7 @@ required_for_references: - args-parser - argtable2 - argtable3 +- armadillo - arrow - arsenalgear - artery-font-format @@ -81,6 +82,7 @@ required_for_references: - bazel - bdwgc - bear +- beauty - benchmark - bertrand - bgfx @@ -133,6 +135,7 @@ required_for_references: - catch2 - ccache - cccl +- ccfits - cctz - cd3-boost-unit-definitions - celero @@ -148,6 +151,7 @@ required_for_references: - charls - chef-fun - chipmunk2d +- choc - cimg - circularbuffer - cista @@ -162,10 +166,12 @@ required_for_references: - clipper2 - clove-unit - cmake +- cminpack - cmocka - cmp - cn-cbor - cnpy +- cocoyaxi - coin-cgl - coin-clp - coin-lemon @@ -176,6 +182,7 @@ required_for_references: - concurrentqueue - console_bridge - continuable +- coost - corrade - cotila - cpp-httplib @@ -205,6 +212,7 @@ required_for_references: - cpuinfo - cqrlib - crc32c +- crc_cpp - create-dmg - croncpp - crowcpp-crow @@ -215,6 +223,7 @@ required_for_references: - cspice - csvmonkey - ctml +- ctpg - ctre - cub - cubicinterpolation @@ -328,6 +337,9 @@ required_for_references: - flecs - flex - fltk +- fmi1 +- fmi2 +- fmi3 - fmt - fmtlog - fontconfig @@ -345,6 +357,7 @@ required_for_references: - freexl - fribidi - frozen +- frugally-deep - fruit - ftxui - function2 @@ -501,6 +514,7 @@ required_for_references: - ktx - kuba-zip - laszip +- lazycsv - lcms - ldns - lefticus-tools @@ -511,6 +525,7 @@ required_for_references: - lest - leveldb - lexbor +- libaesgm - libaio - libalsa - libaom-av1 @@ -522,6 +537,7 @@ required_for_references: - libb2 - libbacktrace - libbigwig +- libbpf - libbsd - libcap - libcbor @@ -602,6 +618,7 @@ required_for_references: - libnoise - libnop - libnova +- libnpy - libnuma - libpcap - libpciaccess @@ -792,6 +809,7 @@ required_for_references: - newmat - nextsilicon-cpp-subprocess - nfrechette-acl +- nghttp3 - ninja - nlohmann_json - nlopt @@ -816,6 +834,7 @@ required_for_references: - octo-encryption-cpp - octo-keygen-cpp - octo-logger-cpp +- octo-wildcardmatching-cpp - octomap - odbc - ode @@ -1027,6 +1046,7 @@ required_for_references: - sentry-crashpad - sentry-native - seqan +- seqan3 - serd - serdepp - sfml @@ -1069,6 +1089,7 @@ required_for_references: - sqlpp11 - squirrel - ssht +- ssp - st_tree - statslib - status-code @@ -1081,6 +1102,7 @@ required_for_references: - streamvbyte - string-view-lite - stringtoolbox +- stringzilla - strong_type - structopt - sundials From 60fa2611242221daf7ee99acc5b836c703022103 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 18:05:35 +0300 Subject: [PATCH 0941/1140] (#18344) resource_pool: migrate to Conan v2 * resource_pool: migrate to Conan v2 * resource_pool: bump boost to v1.79 Highest version resource_pool/cci.20210322 works with. * resource_pool: restore test_v1_package * Update recipes/resource_pool/all/conanfile.py * resource_pool: fix incorrect imports * resource_pool: use cmake_find_package_multi for v1 * resource_pool: use correct CMake target * resource_pool: remove accidental version attribute * resource_pool: restore VirtualRunEnv in test_package * resource_pool: Use a fixed Boost version instead of a range * resource_pool: fix boost dep --- recipes/resource_pool/all/conanfile.py | 80 +++++++++++-------- .../all/test_package/CMakeLists.txt | 7 +- .../all/test_package/conanfile.py | 23 ++++-- .../resource_pool/all/test_package/coro.cc | 6 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 92 insertions(+), 49 deletions(-) create mode 100644 recipes/resource_pool/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/resource_pool/all/test_v1_package/conanfile.py diff --git a/recipes/resource_pool/all/conanfile.py b/recipes/resource_pool/all/conanfile.py index 0e8accc6eec6ac..fc3ecee6a87611 100644 --- a/recipes/resource_pool/all/conanfile.py +++ b/recipes/resource_pool/all/conanfile.py @@ -1,32 +1,30 @@ -from conans import ConanFile, tools -from conans.errors import ConanInvalidConfiguration -from conans.tools import check_min_cppstd import os -import glob + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.files import copy, get +from conan.tools.layout import basic_layout +from conan.tools.scm import Version + +required_conan_version = ">=1.52.0" class ResourcePool(ConanFile): name = "resource_pool" description = "C++ header only library purposed to create pool of some resources like keepalive connections" - topics = ("conan", "resource pool", "resource_pool", "asio", "elsid", "c++17", "cpp17") + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "http://github.com/elsid/resource_pool" - license = "MIT" + topics = ("resource pool", "asio", "elsid", "c++17", "cpp17", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" - requires = ( - "boost/1.75.0" - ) - generators = "cmake_find_package" no_copy_source = True @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def _min_cppstd(self): + return 17 @property def _compilers_minimum_version(self): @@ -37,44 +35,56 @@ def _compilers_minimum_version(self): "apple-clang": "10", } - def _validate_compiler_settings(self): + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + # Only compatible with Boost up to v1.79 + self.requires("boost/1.79.0") + + def package_id(self): + self.info.clear() + + def validate(self): compiler = self.settings.compiler if compiler.get_safe("cppstd"): - check_min_cppstd(self, "17") + check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("resource_pool requires C++17. Your compiler is unknown. Assuming it supports C++17.") - elif tools.Version(self.settings.compiler.version) < minimum_version: + self.output.warning("resource_pool requires C++17. Your compiler is unknown. Assuming it supports C++17.") + elif Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration("resource_pool requires a compiler that supports at least C++17") - def validate(self): - self._validate_compiler_settings() - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob(self.name + "-*/")[0] - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - self.copy(pattern="*", dst=os.path.join("include", "yamail"), src=os.path.join(self._source_subfolder, "include", "yamail")) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - - def package_id(self): - self.info.header_only() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*", + dst=os.path.join(self.package_folder, "include", "yamail"), + src=os.path.join(self.source_folder, "include", "yamail")) def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] + main_comp = self.cpp_info.components["_resource_pool"] main_comp.requires = ["boost::boost", "boost::system", "boost::thread"] main_comp.defines = ["BOOST_ASIO_USE_TS_EXECUTOR_AS_DEFAULT"] - main_comp.names["cmake_find_package"] = "resource_pool" - main_comp.names["cmake_find_package_multi"] = "resource_pool" if self.settings.os == "Windows": main_comp.system_libs.append("ws2_32") - # Set up for compatibility with existing cmake configuration + # Set up for compatibility with existing cmake configuration: + # https://github.com/elsid/resource_pool/blob/3ea1f95/examples/CMakeLists.txt#L6C34-L6C54 + self.cpp_info.set_property("cmake_target_name", "elsid::resource_pool") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed self.cpp_info.filenames["cmake_find_package"] = "resource_pool" self.cpp_info.filenames["cmake_find_package_multi"] = "resource_pool" self.cpp_info.names["cmake_find_package"] = "elsid" self.cpp_info.names["cmake_find_package_multi"] = "elsid" + main_comp.names["cmake_find_package"] = "resource_pool" + main_comp.names["cmake_find_package_multi"] = "resource_pool" diff --git a/recipes/resource_pool/all/test_package/CMakeLists.txt b/recipes/resource_pool/all/test_package/CMakeLists.txt index 6e5e189f75c43d..e10fab1825ee4a 100644 --- a/recipes/resource_pool/all/test_package/CMakeLists.txt +++ b/recipes/resource_pool/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.12) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -find_package(resource_pool REQUIRED) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +find_package(resource_pool REQUIRED CONFIG) add_executable(example coro.cc) target_compile_features(example PRIVATE cxx_std_17) diff --git a/recipes/resource_pool/all/test_package/conanfile.py b/recipes/resource_pool/all/test_package/conanfile.py index 2f970874682b04..8d52b7021efe14 100644 --- a/recipes/resource_pool/all/test_package/conanfile.py +++ b/recipes/resource_pool/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class ResourcePoolTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake_find_package", "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/resource_pool/all/test_package/coro.cc b/recipes/resource_pool/all/test_package/coro.cc index 0e0b3049487750..88ad6ceb45f485 100644 --- a/recipes/resource_pool/all/test_package/coro.cc +++ b/recipes/resource_pool/all/test_package/coro.cc @@ -7,12 +7,14 @@ using ofstream_pool = yamail::resource_pool::async::pool>; using time_traits = yamail::resource_pool::time_traits; -struct null_buffer : std::streambuf { int overflow(int c) override { return c; } } null_buf; +struct null_buffer : std::streambuf { + int overflow(int c) override { return c; } +} null_buf; int main() { boost::asio::io_context service; ofstream_pool pool(1, 10); - boost::asio::spawn(service, [&](boost::asio::yield_context yield){ + boost::asio::spawn(service, [&](boost::asio::yield_context yield) { boost::system::error_code ec; auto handle = pool.get_auto_waste(service, yield[ec], time_traits::duration::max()); if (ec) { diff --git a/recipes/resource_pool/all/test_v1_package/CMakeLists.txt b/recipes/resource_pool/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/resource_pool/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/resource_pool/all/test_v1_package/conanfile.py b/recipes/resource_pool/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..fdaba4642f464d --- /dev/null +++ b/recipes/resource_pool/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class ResourcePoolTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake_find_package_multi", "cmake" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From a6b50902ebf02868617fbd1556192d2135dc547f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 18:25:55 +0300 Subject: [PATCH 0942/1140] (#18660) serial: migrate to Conan v2 * serial: migrate to Conan v2 * serial: use is_apple_os() --- recipes/serial/all/CMakeLists.txt | 7 +-- recipes/serial/all/conanfile.py | 63 ++++++++++--------- .../serial/all/test_package/CMakeLists.txt | 7 +-- recipes/serial/all/test_package/conanfile.py | 22 +++++-- .../serial/all/test_v1_package/CMakeLists.txt | 8 +++ .../serial/all/test_v1_package/conanfile.py | 16 +++++ .../all/test_v1_package/test_package.cpp | 23 +++++++ 7 files changed, 101 insertions(+), 45 deletions(-) create mode 100644 recipes/serial/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/serial/all/test_v1_package/conanfile.py create mode 100644 recipes/serial/all/test_v1_package/test_package.cpp diff --git a/recipes/serial/all/CMakeLists.txt b/recipes/serial/all/CMakeLists.txt index 25209c318b9855..bb8bfce6bd49dd 100644 --- a/recipes/serial/all/CMakeLists.txt +++ b/recipes/serial/all/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.5) +cmake_minimum_required(VERSION 3.12) project(cmake_wrapper) -include(conanbuildinfo.cmake) -conan_basic_setup() - # Work-around for https://github.com/wjwwood/serial/issues/135 list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_LIST_DIR}) @@ -11,6 +8,6 @@ if(WIN32 AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() -add_subdirectory(source_subfolder) +add_subdirectory(src) install(TARGETS serial) diff --git a/recipes/serial/all/conanfile.py b/recipes/serial/all/conanfile.py index d5553000bbddb3..895f0932cedd56 100644 --- a/recipes/serial/all/conanfile.py +++ b/recipes/serial/all/conanfile.py @@ -1,17 +1,22 @@ import os -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration, ConanException + +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name, is_apple_os +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class ConanRecipe(ConanFile): name = "serial" description = "Cross-platform library for interfacing with rs-232 serial like ports" - topics = ("serial", "rs-232", "com") - homepage = "http://wjwwood.io/serial/" - url = "https://github.com/conan-io/conan-center-index" license = "MIT" - exports_sources = ["CMakeLists.txt", "Findcatkin.cmake"] - generators = "cmake" + url = "https://github.com/conan-io/conan-center-index" + homepage = "http://wjwwood.io/serial/" + topics = ("rs-232", "com") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -22,11 +27,9 @@ class ConanRecipe(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) + copy(self, "Findcatkin.cmake", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): if self.settings.os == "Windows": @@ -34,35 +37,37 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename("{}-{}".format(self.name, self.version), - self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.export_sources_folder) cmake.build() def package(self): - self.copy("README.md", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "README.md", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["serial"] - if self.settings.os == "Linux": - self.cpp_info.system_libs = ["rt", "pthread"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs = ["m", "rt", "pthread"] elif self.settings.os == "Windows": self.cpp_info.system_libs = ["setupapi"] - elif tools.is_apple_os(self.settings.os): - self.cpp_info.frameworks = ["IOKit", "Foundation"] + elif is_apple_os(self): + self.cpp_info.frameworks = ["IOKit", "Foundation", "CoreFoundation"] diff --git a/recipes/serial/all/test_package/CMakeLists.txt b/recipes/serial/all/test_package/CMakeLists.txt index 328eaf93b7304d..344a587ace2193 100644 --- a/recipes/serial/all/test_package/CMakeLists.txt +++ b/recipes/serial/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(serial REQUIRED) +find_package(serial REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} serial::serial) diff --git a/recipes/serial/all/test_package/conanfile.py b/recipes/serial/all/test_package/conanfile.py index 5493d58611803c..ef5d7042163ecc 100644 --- a/recipes/serial/all/test_package/conanfile.py +++ b/recipes/serial/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/serial/all/test_v1_package/CMakeLists.txt b/recipes/serial/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/serial/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/serial/all/test_v1_package/conanfile.py b/recipes/serial/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..1bf1c7e26255d4 --- /dev/null +++ b/recipes/serial/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) diff --git a/recipes/serial/all/test_v1_package/test_package.cpp b/recipes/serial/all/test_v1_package/test_package.cpp new file mode 100644 index 00000000000000..8cb01ed6a8b53e --- /dev/null +++ b/recipes/serial/all/test_v1_package/test_package.cpp @@ -0,0 +1,23 @@ +#include +#include +#include +#include + +#include "serial/serial.h" + +using namespace std; + +int main() { + vector devices_found = serial::list_ports(); + + vector::iterator iter = devices_found.begin(); + + while (iter != devices_found.end()) { + serial::PortInfo device = *iter++; + + printf("(%s, %s, %s)\n", device.port.c_str(), + device.description.c_str(), device.hardware_id.c_str()); + } + + return 0; +} From 133c3c9a9d19f9b07a939770fe811b3ffcfc7cbc Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 19:05:19 +0300 Subject: [PATCH 0943/1140] (#18661) poshlib: migrate to Conan v2 * poshlib: migrate to Conan v2 * poshlib: add armv8 detection * poshlib: restore VirtualRunEnv in test_package * poshlib: tweak ARM detection --- recipes/poshlib/all/CMakeLists.txt | 18 ++--- recipes/poshlib/all/conanfile.py | 78 ++++++++++--------- .../poshlib/all/test_package/CMakeLists.txt | 7 +- recipes/poshlib/all/test_package/conanfile.py | 21 +++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../poshlib/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 92 insertions(+), 57 deletions(-) create mode 100644 recipes/poshlib/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/poshlib/all/test_v1_package/conanfile.py diff --git a/recipes/poshlib/all/CMakeLists.txt b/recipes/poshlib/all/CMakeLists.txt index 7e123f6b4b780d..ada768afc9da63 100644 --- a/recipes/poshlib/all/CMakeLists.txt +++ b/recipes/poshlib/all/CMakeLists.txt @@ -1,22 +1,16 @@ -cmake_minimum_required(VERSION 3.4) +cmake_minimum_required(VERSION 3.12) project(cmake_wrapper) -include(conanbuildinfo.cmake) -conan_basic_setup() - if(WIN32 AND BUILD_SHARED_LIBS) set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() -file(GLOB SRCS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/*.c) -file(GLOB HDRS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/*.h) +file(GLOB SRCS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/src/*.c) +file(GLOB HDRS_FILES ${CMAKE_CURRENT_SOURCE_DIR}/src/*.h) add_library(posh ${SRCS_FILES}) -target_include_directories(posh PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder) +target_include_directories(posh PUBLIC ${CMAKE_CURRENT_SOURCE_DIR}/src) -install(TARGETS posh - RUNTIME DESTINATION bin - LIBRARY DESTINATION lib - ARCHIVE DESTINATION lib -) +include(GNUInstallDirs) +install(TARGETS posh) install(FILES ${HDRS_FILES} DESTINATION include) diff --git a/recipes/poshlib/all/conanfile.py b/recipes/poshlib/all/conanfile.py index 8a2c26baad7242..7ad4e9bed544b8 100644 --- a/recipes/poshlib/all/conanfile.py +++ b/recipes/poshlib/all/conanfile.py @@ -1,17 +1,21 @@ import os -import glob -from conans import ConanFile, CMake, tools + +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import collect_libs, copy, get, replace_in_file + +required_conan_version = ">=1.53.0" class PoshlibConan(ConanFile): name = "poshlib" description = "Posh is a software framework used in cross-platform software development." - homepage = "https://github.com/PhilipLudington/poshlib" - url = "https://github.com/conan-io/conan-center-index" - topics = ("conan", "posh", "framework", "cross-platform") license = "BSD-2-Clause" - exports_sources = ["CMakeLists.txt"] - generators = "cmake" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/PhilipLudington/poshlib" + topics = ("posh", "framework", "cross-platform") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -22,47 +26,51 @@ class PoshlibConan(ConanFile): "fPIC": True, } - _cmake = None - - @property - def _source_subfolder(self): - return "source_subfolder" - - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = glob.glob('poshlib-*/')[0] - os.rename(extracted_dir, self._source_subfolder) + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) def config_options(self): - if self.settings.os == 'Windows': + if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def _patch_sources(self): + replace_in_file( + self, + os.path.join(self.source_folder, "posh.h"), + "defined _ARM", + "defined _ARM || defined __arm64 || defined __arm64__ || defined __aarch64__", + ) def build(self): - tools.replace_in_file(os.path.join(self._source_subfolder, "posh.h"), - "defined _ARM", - "defined _ARM || defined __arm64") - cmake = self._configure_cmake() + self._patch_sources() + cmake = CMake(self) + cmake.configure(build_script_folder=self.source_path.parent) cmake.build() def package(self): - cmake = self._configure_cmake() + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + cmake = CMake(self) cmake.install() - self.copy(pattern="LICENSE", dst="licenses", src=self._source_subfolder) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - if self.settings.os == 'Windows' and self.options.shared: + self.cpp_info.libs = collect_libs(self) + if self.settings.os == "Windows" and self.options.shared: self.cpp_info.defines.append("POSH_DLL") diff --git a/recipes/poshlib/all/test_package/CMakeLists.txt b/recipes/poshlib/all/test_package/CMakeLists.txt index 7b9b613cbb24a3..06a245507c5630 100644 --- a/recipes/poshlib/all/test_package/CMakeLists.txt +++ b/recipes/poshlib/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(poshlib REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE poshlib::poshlib) diff --git a/recipes/poshlib/all/test_package/conanfile.py b/recipes/poshlib/all/test_package/conanfile.py index 16ec9f68ef9742..ef5d7042163ecc 100644 --- a/recipes/poshlib/all/test_package/conanfile.py +++ b/recipes/poshlib/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/poshlib/all/test_v1_package/CMakeLists.txt b/recipes/poshlib/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/poshlib/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/poshlib/all/test_v1_package/conanfile.py b/recipes/poshlib/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..90eb89e3f2f46b --- /dev/null +++ b/recipes/poshlib/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 0f03fba46907f5827058420d95d7ef86b15c9b49 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 19:27:45 +0300 Subject: [PATCH 0944/1140] (#18744) xege: migrate to Conan v2 * xege: migrate to Conan v2 * xege: restore VirtualRunEnv in test_package * xege: shared builds are not supported --- recipes/xege/all/CMakeLists.txt | 7 -- recipes/xege/all/conanfile.py | 73 +++++++++++-------- recipes/xege/all/test_package/CMakeLists.txt | 7 +- recipes/xege/all/test_package/conanfile.py | 23 ++++-- recipes/xege/all/test_package/example.cpp | 1 - .../xege/all/test_v1_package/CMakeLists.txt | 8 ++ recipes/xege/all/test_v1_package/conanfile.py | 17 +++++ 7 files changed, 86 insertions(+), 50 deletions(-) delete mode 100644 recipes/xege/all/CMakeLists.txt create mode 100644 recipes/xege/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/xege/all/test_v1_package/conanfile.py diff --git a/recipes/xege/all/CMakeLists.txt b/recipes/xege/all/CMakeLists.txt deleted file mode 100644 index 0496b298385496..00000000000000 --- a/recipes/xege/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.0) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory(source_subfolder) diff --git a/recipes/xege/all/conanfile.py b/recipes/xege/all/conanfile.py index e3d748b348f875..9e838e4436fae4 100644 --- a/recipes/xege/all/conanfile.py +++ b/recipes/xege/all/conanfile.py @@ -1,33 +1,47 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get + +required_conan_version = ">=1.53.0" class XegeConan(ConanFile): name = "xege" + description = "Easy Graphics Engine, a lite graphics library in Windows" license = "LGPLv2.1" url = "https://github.com/conan-io/conan-center-index" homepage = "https://xege.org/" - description = "Easy Graphics Engine, a lite graphics library in Windows" topics = ("ege", "graphics", "gui") - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" - exports_sources = ["CMakeLists.txt"] - def configure(self): - if self.settings.os != "Windows": - raise ConanInvalidConfiguration( - "This library is only compatible for Windows") + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + options = { + "fPIC": [True, False], + } + default_options = { + "fPIC": True, + } - @property - def _source_subfolder(self): - return "source_subfolder" + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.settings.os != "Windows": + raise ConanInvalidConfiguration("This library is only compatible with Windows") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): cmake = CMake(self) @@ -35,24 +49,21 @@ def build(self): cmake.build() def package(self): - self.copy("*.h", dst="include", src=self._source_subfolder+"/src") - self.copy("*.lib", dst="lib", keep_path=False) - self.copy("*.dll", dst="bin", keep_path=False) - self.copy("*.so", dst="lib", keep_path=False) - self.copy("*.a", dst="lib", keep_path=False) - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) + copy(self, "LICENSE", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.h", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "src")) + for pattern in ["*.lib", "*.a"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder, + keep_path=False) def package_info(self): if self.settings.arch == "x86_64": self.cpp_info.libs = ["graphics64"] else: self.cpp_info.libs = ["graphics"] - self.cpp_info.system_libs = [ - "gdiplus", - "uuid", - "msimg32", - "gdi32", - "imm32", - "ole32", - "oleaut32" - ] + self.cpp_info.system_libs = ["gdiplus", "uuid", "msimg32", "gdi32", "imm32", "ole32", "oleaut32"] diff --git a/recipes/xege/all/test_package/CMakeLists.txt b/recipes/xege/all/test_package/CMakeLists.txt index dd28555a7ac65c..9e1250d39f5ee3 100644 --- a/recipes/xege/all/test_package/CMakeLists.txt +++ b/recipes/xege/all/test_package/CMakeLists.txt @@ -1,11 +1,10 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(xege REQUIRED CONFIG) add_executable(example example.cpp) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example PRIVATE xege::xege) if(MSYS OR MINGW) target_link_libraries(example -static-libgcc -static-libstdc++) diff --git a/recipes/xege/all/test_package/conanfile.py b/recipes/xege/all/test_package/conanfile.py index 2011b67ca68a5a..8d52b7021efe14 100644 --- a/recipes/xege/all/test_package/conanfile.py +++ b/recipes/xege/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -class XegeTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "example") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") diff --git a/recipes/xege/all/test_package/example.cpp b/recipes/xege/all/test_package/example.cpp index e167cd38f70ed7..658780d07761be 100644 --- a/recipes/xege/all/test_package/example.cpp +++ b/recipes/xege/all/test_package/example.cpp @@ -1,5 +1,4 @@ #include -#include using namespace ege; diff --git a/recipes/xege/all/test_v1_package/CMakeLists.txt b/recipes/xege/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/xege/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/xege/all/test_v1_package/conanfile.py b/recipes/xege/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..c48a6d9a1bd7a7 --- /dev/null +++ b/recipes/xege/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class XegeTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "example") + self.run(bin_path, run_environment=True) From 9042533cc89335a0692056418afaa39caea9ea2c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 19:47:02 +0300 Subject: [PATCH 0945/1140] (#18746) tweetnacl: migrate to Conan v2, correct license --- recipes/tweetnacl/all/CMakeLists.txt | 11 +-- recipes/tweetnacl/all/conandata.yml | 6 +- recipes/tweetnacl/all/conanfile.py | 68 +++++++++++-------- .../tweetnacl/all/test_package/CMakeLists.txt | 7 +- .../tweetnacl/all/test_package/conanfile.py | 21 ++++-- .../all/test_v1_package/CMakeLists.txt | 8 +++ .../all/test_v1_package/conanfile.py | 17 +++++ 7 files changed, 88 insertions(+), 50 deletions(-) create mode 100644 recipes/tweetnacl/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tweetnacl/all/test_v1_package/conanfile.py diff --git a/recipes/tweetnacl/all/CMakeLists.txt b/recipes/tweetnacl/all/CMakeLists.txt index 971f0647720b11..b90e7d4a682db8 100644 --- a/recipes/tweetnacl/all/CMakeLists.txt +++ b/recipes/tweetnacl/all/CMakeLists.txt @@ -1,17 +1,10 @@ -cmake_minimum_required(VERSION 2.8.12) +cmake_minimum_required(VERSION 3.12) project(tweetnacl C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() - -include(GNUInstallDirs) - add_library(tweetnacl tweetnacl.c) set_target_properties(tweetnacl PROPERTIES PUBLIC_HEADER "tweetnacl.h") +include(GNUInstallDirs) install(TARGETS tweetnacl - ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" - LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" - RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" PUBLIC_HEADER DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}" ) diff --git a/recipes/tweetnacl/all/conandata.yml b/recipes/tweetnacl/all/conandata.yml index 3dcc47bfef437f..a3fbddf32a9135 100644 --- a/recipes/tweetnacl/all/conandata.yml +++ b/recipes/tweetnacl/all/conandata.yml @@ -1,8 +1,6 @@ sources: "20140427": - url: https://tweetnacl.cr.yp.to/20140427/tweetnacl.c - sha256: 02e65bc3013ff2168983365e55906bc783c4c7e0a60d8100f17bb303a17175c4 + sha256: "02e65bc3013ff2168983365e55906bc783c4c7e0a60d8100f17bb303a17175c4" - url: https://tweetnacl.cr.yp.to/20140427/tweetnacl.h - sha256: 43f29ad721d9927b747b0100ab4160c119e7bb180c7c98a66e4bf79d31244287 - - url: https://unlicense.org/UNLICENSE - sha256: 7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c + sha256: "43f29ad721d9927b747b0100ab4160c119e7bb180c7c98a66e4bf79d31244287" diff --git a/recipes/tweetnacl/all/conanfile.py b/recipes/tweetnacl/all/conanfile.py index b5b3d196ced3ec..0c97672dae4cc7 100644 --- a/recipes/tweetnacl/all/conanfile.py +++ b/recipes/tweetnacl/all/conanfile.py @@ -1,19 +1,24 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.32.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, download, save + +required_conan_version = ">=1.53.0" class TweetnaclConan(ConanFile): name = "tweetnacl" - license = "Unlicense" - homepage = "https://tweetnacl.cr.yp.to" - url = "https://github.com/conan-io/conan-center-index" description = "TweetNaCl is the world's first auditable high-security cryptographic library" - topics = ("nacl", "tweetnacl", "encryption", "signature", "hashing") - exports_sources = "CMakeLists.txt" - generators = "cmake" + license = "Public domain" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://tweetnacl.cr.yp.to" + topics = ("nacl", "encryption", "signature", "hashing") + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], @@ -22,44 +27,53 @@ class TweetnaclConan(ConanFile): "shared": False, "fPIC": True, } - settings = "os", "compiler", "build_type", "arch" - _cmake = None + def export_sources(self): + copy(self, "CMakeLists.txt", + src=self.recipe_folder, + dst=os.path.join(self.export_sources_folder, "src")) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.cppstd - del self.settings.compiler.libcxx + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def validate(self): - if self.settings.os in ("Windows", "Macos"): + if self.settings.os == "Windows" or is_apple_os(self): if self.options.shared: - raise ConanInvalidConfiguration("tweetnacl does not support shared on Windows and Madcos: it needs a randombytes implementation") + raise ConanInvalidConfiguration( + "tweetnacl does not support shared on Windows and Macos: it needs a randombytes implementation" + ) def source(self): for url_sha in self.conan_data["sources"][self.version]: - tools.download(url_sha["url"], os.path.basename(url_sha["url"])) - tools.check_sha256(os.path.basename(url_sha["url"]), url_sha["sha256"]) + download(self, **url_sha, filename=os.path.basename(url_sha["url"])) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + tc = CMakeDeps(self) + tc.generate() def build(self): - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("UNLICENSE", dst=os.path.join(self.package_folder, "licenses")) - cmake = self._configure_cmake() + save(self, + os.path.join(self.package_folder, "licenses", "LICENSE"), + "TweetNaCl is a self-contained public-domain C library.") + cmake = CMake(self) cmake.install() def package_info(self): diff --git a/recipes/tweetnacl/all/test_package/CMakeLists.txt b/recipes/tweetnacl/all/test_package/CMakeLists.txt index 7b9b613cbb24a3..ff98951f060d9f 100644 --- a/recipes/tweetnacl/all/test_package/CMakeLists.txt +++ b/recipes/tweetnacl/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(tweetnacl REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE tweetnacl::tweetnacl) diff --git a/recipes/tweetnacl/all/test_package/conanfile.py b/recipes/tweetnacl/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/tweetnacl/all/test_package/conanfile.py +++ b/recipes/tweetnacl/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tweetnacl/all/test_v1_package/CMakeLists.txt b/recipes/tweetnacl/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/tweetnacl/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/tweetnacl/all/test_v1_package/conanfile.py b/recipes/tweetnacl/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/tweetnacl/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 447f1e2e9f2f76f9e625db6b7e5e1a0ee3bee5e5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 20:07:15 +0300 Subject: [PATCH 0946/1140] (#18822) log4cxx: migrate to Conan v2 * log4cxx: migrate to Conan v2 * log4cxx: restore VirtualRunEnv in test_package * log4cxx: bump deps * log4cxx: simplify recipe --- recipes/log4cxx/all/CMakeLists.txt | 7 - recipes/log4cxx/all/conandata.yml | 6 +- recipes/log4cxx/all/conanfile.py | 120 ++++++++---------- .../log4cxx/all/patches/0001-find-apr.patch | 5 +- .../log4cxx/all/test_package/CMakeLists.txt | 7 +- recipes/log4cxx/all/test_package/conanfile.py | 19 ++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../log4cxx/all/test_v1_package/conanfile.py | 18 +++ 8 files changed, 102 insertions(+), 88 deletions(-) delete mode 100644 recipes/log4cxx/all/CMakeLists.txt create mode 100644 recipes/log4cxx/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/log4cxx/all/test_v1_package/conanfile.py diff --git a/recipes/log4cxx/all/CMakeLists.txt b/recipes/log4cxx/all/CMakeLists.txt deleted file mode 100644 index b83949de59dc55..00000000000000 --- a/recipes/log4cxx/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 3.13) -project(cmake_wrapper CXX) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/log4cxx/all/conandata.yml b/recipes/log4cxx/all/conandata.yml index 4d9c222f7d839a..398cc493a41aef 100644 --- a/recipes/log4cxx/all/conandata.yml +++ b/recipes/log4cxx/all/conandata.yml @@ -7,8 +7,6 @@ sources: sha256: "bd5b5009ca914c8fa7944b92ea6b4ca6fb7d146f65d526f21bf8b3c6a0520e44" patches: "0.12.1": - - base_path: "source_subfolder" - patch_file: "patches/0001-find-apr.patch" + - patch_file: "patches/0001-find-apr.patch" "0.12.0": - - base_path: "source_subfolder" - patch_file: "patches/0001-find-apr.patch" + - patch_file: "patches/0001-find-apr.patch" diff --git a/recipes/log4cxx/all/conanfile.py b/recipes/log4cxx/all/conanfile.py index ac48eb45fc460f..282fa49ad39dc8 100644 --- a/recipes/log4cxx/all/conanfile.py +++ b/recipes/log4cxx/all/conanfile.py @@ -1,19 +1,25 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os import textwrap -required_conan_version = ">=1.43.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, save +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" class Log4cxxConan(ConanFile): name = "log4cxx" description = "Logging framework for C++ patterned after Apache log4j" - url = "https://github.com/conan-io/conan-center-index" license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" homepage = "https://logging.apache.org/log4cxx" topics = ("logging", "log") + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -24,21 +30,18 @@ class Log4cxxConan(ConanFile): "fPIC": True, } - generators = "cmake", "cmake_find_package", "pkg_config" - _cmake = None - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def _compilers_minimum_version(self): + return { + "gcc": "7", + "Visual Studio": "15", + "msvc": "191", + "clang": "5", + "apple-clang": "10", + } def export_sources(self): - self.copy("CMakeLists.txt") - for patch in self.conan_data.get("patches", {}).get(self.version, []): - self.copy(patch["patch_file"]) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -46,88 +49,73 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") def requirements(self): self.requires("apr/1.7.0") self.requires("apr-util/1.6.1") - self.requires("expat/2.4.2") + self.requires("expat/2.5.0") if self.settings.os != "Windows": - self.requires("odbc/2.3.9") - - @property - def _compilers_minimum_version(self): - return { - "gcc": "7", - "Visual Studio": "15", - "clang": "5", - "apple-clang": "10", - } + self.requires("odbc/2.3.11") def validate(self): # TODO: if compiler doesn't support C++17, boost can be used instead - if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, "17") + if self.settings.compiler.cppstd: + check_min_cppstd(self, 17) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) - if not minimum_version: - self.output.warn("log4cxx requires C++17. Your compiler is unknown. Assuming it supports C++17.") - elif tools.Version(self.settings.compiler.version) < minimum_version: + if minimum_version and Version(self.settings.compiler.version) < minimum_version: raise ConanInvalidConfiguration("log4cxx requires a compiler that supports at least C++17") def build_requirements(self): if self.settings.os != "Windows": - self.build_requires("pkgconf/1.7.4") + if not self.conf.get("tools.gnu:pkg_config", check_type=str): + self.tool_requires("pkgconf/2.0.3") def source(self): - #OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: - #'source_subfolder\\src\\test\\resources\\output\\xyz\\:' + # OSError: [WinError 123] The filename, directory name, or volume label syntax is incorrect: + # 'src\\test\\resources\\output\\xyz\\:' pattern = "*[!:]" - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True, - pattern=pattern) - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - - def _configure_cmake(self): - if not self._cmake: - self._cmake = CMake(self) - self._cmake.definitions["BUILD_TESTING"] = False - if self.settings.os == "Windows": - self._cmake.definitions["LOG4CXX_INSTALL_PDB"] = False - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + get(self, **self.conan_data["sources"][self.version], strip_root=True, pattern=pattern) + + def generate(self): + tc = CMakeToolchain(self) + tc.cache_variables["BUILD_TESTING"] = False + tc.cache_variables["LOG4CXX_INSTALL_PDB"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - self._patch_sources() - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", src=self._source_subfolder, dst="licenses") - self.copy("NOTICE", src=self._source_subfolder, dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + copy(self, "NOTICE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() - tools.rmdir(os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "share")) # TODO: to remove in conan v2 once cmake_find_package* generators removed self._create_cmake_module_alias_targets( - os.path.join(self.package_folder, self._module_file_rel_path), - {"log4cxx": "log4cxx::log4cxx"} + os.path.join(self.package_folder, self._module_file_rel_path), {"log4cxx": "log4cxx::log4cxx"} ) - @staticmethod - def _create_cmake_module_alias_targets(module_file, targets): + def _create_cmake_module_alias_targets(self, module_file, targets): content = "" for alias, aliased in targets.items(): - content += textwrap.dedent("""\ + content += textwrap.dedent(f"""\ if(TARGET {aliased} AND NOT TARGET {alias}) add_library({alias} INTERFACE IMPORTED) set_property(TARGET {alias} PROPERTY INTERFACE_LINK_LIBRARIES {aliased}) endif() - """.format(alias=alias, aliased=aliased)) - tools.save(module_file, content) + """) + save(self, module_file, content) @property def _module_file_rel_path(self): @@ -137,6 +125,7 @@ def package_info(self): self.cpp_info.set_property("cmake_file_name", "log4cxx") self.cpp_info.set_property("cmake_target_name", "log4cxx") self.cpp_info.set_property("pkg_config_name", "liblog4cxx") + if not self.options.shared: self.cpp_info.defines = ["LOG4CXX_STATIC"] self.cpp_info.libs = ["log4cxx"] @@ -146,4 +135,3 @@ def package_info(self): # TODO: to remove in conan v2 once cmake_find_package* & pkg_config generators removed self.cpp_info.build_modules["cmake_find_package"] = [self._module_file_rel_path] self.cpp_info.build_modules["cmake_find_package_multi"] = [self._module_file_rel_path] - self.cpp_info.names["pkg_config"] = "liblog4cxx" diff --git a/recipes/log4cxx/all/patches/0001-find-apr.patch b/recipes/log4cxx/all/patches/0001-find-apr.patch index 11635d23e734f6..9b75430996d184 100644 --- a/recipes/log4cxx/all/patches/0001-find-apr.patch +++ b/recipes/log4cxx/all/patches/0001-find-apr.patch @@ -1,6 +1,6 @@ --- a/CMakeLists.txt +++ b/CMakeLists.txt -@@ -25,10 +25,12 @@ if(NOT BUILD_SHARED_LIBS) +@@ -25,12 +25,14 @@ if(NOT BUILD_SHARED_LIBS) endif() # Find Apache Runtime @@ -15,3 +15,6 @@ find_package( Threads REQUIRED ) + # Find expat for XML parsing +-find_package(EXPAT REQUIRED) ++find_package(EXPAT REQUIRED MODULE) diff --git a/recipes/log4cxx/all/test_package/CMakeLists.txt b/recipes/log4cxx/all/test_package/CMakeLists.txt index 4b7ef0dd16dbbb..a9ec878c74ebe7 100644 --- a/recipes/log4cxx/all/test_package/CMakeLists.txt +++ b/recipes/log4cxx/all/test_package/CMakeLists.txt @@ -1,8 +1,5 @@ -cmake_minimum_required(VERSION 3.8) -project(test_package CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) find_package(log4cxx REQUIRED CONFIG) diff --git a/recipes/log4cxx/all/test_package/conanfile.py b/recipes/log4cxx/all/test_package/conanfile.py index 0aa45c8d4db18f..382876561a2038 100644 --- a/recipes/log4cxx/all/test_package/conanfile.py +++ b/recipes/log4cxx/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,7 +21,7 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") config_xml_name = os.path.join(self.source_folder, "log4cxx_config.xml") - bin_path = os.path.join("bin", "test_package") - self.run("{} {}".format(bin_path, config_xml_name), run_environment=True) + self.run(f"{bin_path} {config_xml_name}", env="conanrun") diff --git a/recipes/log4cxx/all/test_v1_package/CMakeLists.txt b/recipes/log4cxx/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/log4cxx/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/log4cxx/all/test_v1_package/conanfile.py b/recipes/log4cxx/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..0aa45c8d4db18f --- /dev/null +++ b/recipes/log4cxx/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + config_xml_name = os.path.join(self.source_folder, "log4cxx_config.xml") + bin_path = os.path.join("bin", "test_package") + self.run("{} {}".format(bin_path, config_xml_name), run_environment=True) From 5be8268a15ae885e07209bf7e67da638f5697f6b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 20:26:34 +0300 Subject: [PATCH 0947/1140] (#18941) libnetfilter_conntrack: migrate to Conan v2 * libnetfilter_conntrack: migrate to Conan v2 * libnetfilter_conntrack: improve os check * libnetfilter_conntrack: transitive_libs=True WHY?? --- .../libnetfilter_conntrack/all/conanfile.py | 97 +++++++++++-------- .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 23 +++-- .../all/test_package/example.c | 6 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 102 insertions(+), 58 deletions(-) create mode 100644 recipes/libnetfilter_conntrack/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/libnetfilter_conntrack/all/test_v1_package/conanfile.py diff --git a/recipes/libnetfilter_conntrack/all/conanfile.py b/recipes/libnetfilter_conntrack/all/conanfile.py index b4f68103f83c15..838c21aea601be 100644 --- a/recipes/libnetfilter_conntrack/all/conanfile.py +++ b/recipes/libnetfilter_conntrack/all/conanfile.py @@ -1,67 +1,78 @@ import os -from conans import ConanFile, tools, AutoToolsBuildEnvironment -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain, PkgConfigDeps +from conan.tools.layout import basic_layout + +required_conan_version = ">=1.53.0" + class Libnetfilter_conntrackConan(ConanFile): name = "libnetfilter_conntrack" + description = "userspace library that provides an API to the in-kernel connection tracking state table" license = "GPL-2.0-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://netfilter.org/projects/libnetfilter_conntrack/index.html" - description = "userspace library that provides an API to the in-kernel connection tracking state table" - topics = ("libnetfilter_conntrack", "netfilter") - settings = "os", "compiler", "build_type", "arch" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - generators = "pkg_config" - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" + topics = ("netfilter",) - def requirements(self): - self.requires("libmnl/1.0.4") - self.requires("libnfnetlink/1.0.1") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - os.rename(extracted_dir, self._source_subfolder) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC def configure(self): - if self.settings.os != "Linux": + if self.settings.os not in ["Linux", "FreeBSD"]: raise ConanInvalidConfiguration("libnetfilter_conntrack is only supported on Linux") if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self) - conf_args = [] - if self.options.shared: - conf_args.extend(["--enable-shared", "--disable-static"]) - else: - conf_args.extend(["--disable-shared", "--enable-static"]) - self._autotools.configure(configure_dir=self._source_subfolder, args=conf_args) - return self._autotools + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("libmnl/1.0.4", transitive_headers=True, transitive_libs=True) + self.requires("libnfnetlink/1.0.2", transitive_headers=True) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() + deps = PkgConfigDeps(self) + deps.generate() def build(self): - autotools = self._configure_autotools() + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy("COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + autotools = Autotools(self) autotools.install() - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.rmdir(os.path.join(self.package_folder, "etc")) - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "etc")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) def package_info(self): self.cpp_info.libs = ["netfilter_conntrack"] - self.cpp_info.names["pkg_config"] = "libnetfilter_conntrack" + self.cpp_info.set_property("pkg_config_name", "libnetfilter_conntrack") diff --git a/recipes/libnetfilter_conntrack/all/test_package/CMakeLists.txt b/recipes/libnetfilter_conntrack/all/test_package/CMakeLists.txt index 4dbc40cd2c4d9e..133b0de0016706 100644 --- a/recipes/libnetfilter_conntrack/all/test_package/CMakeLists.txt +++ b/recipes/libnetfilter_conntrack/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.10) -project(PackageTest) +cmake_minimum_required(VERSION 3.15) +project(PackageTest LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(libnetfilter_conntrack REQUIRED CONFIG) add_executable(example example.c) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example libnetfilter_conntrack::libnetfilter_conntrack) diff --git a/recipes/libnetfilter_conntrack/all/test_package/conanfile.py b/recipes/libnetfilter_conntrack/all/test_package/conanfile.py index 49596606491864..cf3b9d75009a72 100644 --- a/recipes/libnetfilter_conntrack/all/test_package/conanfile.py +++ b/recipes/libnetfilter_conntrack/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools -class Libnetfilter_conntrackTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") - self.run("{} {}".format(bin_path, 0), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(f"{bin_path} 0", env="conanrun") diff --git a/recipes/libnetfilter_conntrack/all/test_package/example.c b/recipes/libnetfilter_conntrack/all/test_package/example.c index 331a7d9d4f8548..ccdf8593d195fa 100644 --- a/recipes/libnetfilter_conntrack/all/test_package/example.c +++ b/recipes/libnetfilter_conntrack/all/test_package/example.c @@ -1,12 +1,12 @@ +#include +#include + #include #include #include #include #include -#include -#include - static int data_cb(const struct nlmsghdr *nlh, void *data) { struct nf_conntrack *ct; diff --git a/recipes/libnetfilter_conntrack/all/test_v1_package/CMakeLists.txt b/recipes/libnetfilter_conntrack/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/libnetfilter_conntrack/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/libnetfilter_conntrack/all/test_v1_package/conanfile.py b/recipes/libnetfilter_conntrack/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..ebd551d13e3991 --- /dev/null +++ b/recipes/libnetfilter_conntrack/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os + +from conans import ConanFile, CMake, tools + +class Libnetfilter_conntrackTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "example") + self.run("{} {}".format(bin_path, 0), run_environment=True) From df4a9c6de0e07f8bf20e94741b8d640eb4771567 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 20:46:19 +0300 Subject: [PATCH 0948/1140] (#18957) liboping: migrate to Conan v2 * liboping: migrate to Conan v2 * liboping: fix_apple_shared_install_name() * Update conandata.yml --- recipes/liboping/all/conandata.yml | 2 - recipes/liboping/all/conanfile.py | 99 ++++++++++--------- .../liboping/all/test_package/CMakeLists.txt | 7 +- .../liboping/all/test_package/conanfile.py | 21 ++-- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../liboping/all/test_v1_package/conanfile.py | 17 ++++ 6 files changed, 93 insertions(+), 61 deletions(-) create mode 100644 recipes/liboping/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/liboping/all/test_v1_package/conanfile.py diff --git a/recipes/liboping/all/conandata.yml b/recipes/liboping/all/conandata.yml index 383d4f884713fa..a9da5ce81e6952 100644 --- a/recipes/liboping/all/conandata.yml +++ b/recipes/liboping/all/conandata.yml @@ -5,5 +5,3 @@ sources: patches: "1.10.0": - patch_file: "patches/1.10.0-suppress_truncate.patch" - base_path: "source_subfolder" - diff --git a/recipes/liboping/all/conanfile.py b/recipes/liboping/all/conanfile.py index 21125770e672e3..811729afcf6e25 100644 --- a/recipes/liboping/all/conanfile.py +++ b/recipes/liboping/all/conanfile.py @@ -1,19 +1,26 @@ -from conans import ConanFile, AutoToolsBuildEnvironment, tools -from conans.errors import ConanInvalidConfiguration import os -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os, fix_apple_shared_install_name +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.47.0" class LibopingConan(ConanFile): name = "liboping" description = "A multi server ping library" - topics = ("oping", "ping", "icmp") + license = ["LGPL-2.1", "GPL-2.0"] url = "https://github.com/conan-io/conan-center-index" homepage = "https://noping.cc" - license = ["LGPL-2.1", "GPL-2.0"] + topics = ("oping", "ping", "icmp", "pre-built") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" - exports_sources = ["patches/**"] options = { "shared": [True, False], "fPIC": [True, False], @@ -23,81 +30,77 @@ class LibopingConan(ConanFile): "fPIC": True, } - _autotools = None - - @property - def _source_subfolder(self): - return "source_subfolder" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") def validate(self): - if self.settings.os == "Windows" and self.settings.compiler == "Visual Studio": + if is_msvc(self): raise ConanInvalidConfiguration("liboping is not supported by Visual Studio") if self.settings.os == "Windows" and self.options.shared: - raise ConanInvalidConfiguration("Liboping could not be built on {} as shared library".format(self.settings.os)) - if self.settings.os == "Macos" and self.settings.arch == "armv8": + raise ConanInvalidConfiguration( + f"Liboping could not be built on {self.settings.os} as shared library" + ) + if is_apple_os(self) and self.settings.arch == "armv8": # Build error - NO Access to a Mac/M1 - please fix when possible - see issue 8634 raise ConanInvalidConfiguration("Liboping cannot be built on a Mac/M1 at this time") def build_requirements(self): - if self._settings_build.os == "Windows" and not tools.get_env("CONAN_BASH_PATH"): - self.build_requires("msys2/cci.latest") + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:path", check_type=str): + self.tool_requires("msys2/cci.latest") def source(self): - tools.get(**self.conan_data["sources"][self.version], - destination=self._source_subfolder, strip_root=True) - - def _configure_autotools(self): - if self._autotools: - return self._autotools - self._autotools = AutoToolsBuildEnvironment(self, win_bash=tools.os_info.is_windows) - yes_no = lambda v: "yes" if v else "no" - args = [ - "--enable-shared={}".format(yes_no(self.options.shared)), - "--enable-static={}".format(yes_no(not self.options.shared)), + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.configure_args += [ "--without-ncurses", "--without-perl-bindings", ] - self._autotools.configure(args=args, configure_dir=self._source_subfolder) - return self._autotools - - def _patch_sources(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) + tc.generate() def build(self): - self._patch_sources() - autotools = self._configure_autotools() + apply_conandata_patches(self) + autotools = Autotools(self) + autotools.configure() autotools.make() def package(self): - self.copy(pattern="COPYING", dst="licenses", src=self._source_subfolder) - autotools = self._configure_autotools() + copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + autotools = Autotools(self) autotools.install() - - tools.rmdir(os.path.join(self.package_folder, "share")) - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.la") - tools.rmdir(os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", self.package_folder, recursive=True) + rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + fix_apple_shared_install_name(self) def package_info(self): - bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bindir)) - self.env_info.PATH.append(bindir) self.cpp_info.libs = ["oping"] if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs.append("m") elif self.settings.os == "Windows": self.cpp_info.system_libs.append("ws2_32") + + # TODO: Legacy, to be removed on Conan 2.0 + bindir = os.path.join(self.package_folder, "bin") + self.output.info("Appending PATH environment variable: {}".format(bindir)) + self.env_info.PATH.append(bindir) diff --git a/recipes/liboping/all/test_package/CMakeLists.txt b/recipes/liboping/all/test_package/CMakeLists.txt index 30961cdb0ded2e..76c10855ad585b 100644 --- a/recipes/liboping/all/test_package/CMakeLists.txt +++ b/recipes/liboping/all/test_package/CMakeLists.txt @@ -1,10 +1,7 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(test_package C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(liboping CONFIG REQUIRED) +find_package(liboping REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} liboping::liboping) diff --git a/recipes/liboping/all/test_package/conanfile.py b/recipes/liboping/all/test_package/conanfile.py index b7bbf79eba926c..ef5d7042163ecc 100644 --- a/recipes/liboping/all/test_package/conanfile.py +++ b/recipes/liboping/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "arch", "build_type" - generators = "cmake", "cmake_find_package_multi" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/liboping/all/test_v1_package/CMakeLists.txt b/recipes/liboping/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/liboping/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/liboping/all/test_v1_package/conanfile.py b/recipes/liboping/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..b7bbf79eba926c --- /dev/null +++ b/recipes/liboping/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "arch", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 9f3f3d7184a9509a509f91f8503abf64d647786a Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 5 Oct 2023 03:11:02 +0900 Subject: [PATCH 0949/1140] (#20094) libenvpp: add recipe * libenvpp: add recipe * require cmake >= 3.16 * make static-library * rename library name on windows --- recipes/libenvpp/all/conandata.yml | 9 ++ recipes/libenvpp/all/conanfile.py | 93 +++++++++++++++++++ .../all/patches/0001-use-cci-fmt.patch | 30 ++++++ .../libenvpp/all/test_package/CMakeLists.txt | 8 ++ .../libenvpp/all/test_package/conanfile.py | 26 ++++++ .../all/test_package/test_package.cpp | 23 +++++ recipes/libenvpp/config.yml | 3 + 7 files changed, 192 insertions(+) create mode 100644 recipes/libenvpp/all/conandata.yml create mode 100644 recipes/libenvpp/all/conanfile.py create mode 100644 recipes/libenvpp/all/patches/0001-use-cci-fmt.patch create mode 100644 recipes/libenvpp/all/test_package/CMakeLists.txt create mode 100644 recipes/libenvpp/all/test_package/conanfile.py create mode 100644 recipes/libenvpp/all/test_package/test_package.cpp create mode 100644 recipes/libenvpp/config.yml diff --git a/recipes/libenvpp/all/conandata.yml b/recipes/libenvpp/all/conandata.yml new file mode 100644 index 00000000000000..6d0d3123e3cdf3 --- /dev/null +++ b/recipes/libenvpp/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "1.3.0": + url: "https://github.com/ph3at/libenvpp/archive/refs/tags/v1.3.0.tar.gz" + sha256: "9201ae39dc67118ee46b4e60fe2e5d22b046faceae4a4b4eec6ab62bc48875dd" +patches: + "1.3.0": + - patch_file: "patches/0001-use-cci-fmt.patch" + patch_description: "use cci fmt package, remove static flag from add_library" + patch_type: "conan" diff --git a/recipes/libenvpp/all/conanfile.py b/recipes/libenvpp/all/conanfile.py new file mode 100644 index 00000000000000..06b2bc9d3e325f --- /dev/null +++ b/recipes/libenvpp/all/conanfile.py @@ -0,0 +1,93 @@ +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.build import check_min_cppstd +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +import os + +required_conan_version = ">=1.53.0" + +class LibenvppConan(ConanFile): + name = "libenvpp" + description = "A modern C++ library for type-safe environment variable parsing" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/ph3at/libenvpp" + topics = ("environment", "type-safe") + package_type = "static-library" + settings = "os", "arch", "compiler", "build_type" + options = { + "fPIC": [True, False], + } + default_options = { + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "Visual Studio": "16", + "msvc": "191", + "gcc": "7", + "clang": "7", + "apple-clang": "10", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("fmt/10.1.1", transitive_headers=True) + + def build_requirements(self): + self.tool_requires("cmake/[>=3.16 <4]") + + def validate(self): + if self.settings.compiler.get_safe("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) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["LIBENVPP_TESTS"] = False + tc.variables["LIBENVPP_EXAMPLES"] = False + tc.variables["LIBENVPP_CHECKS"] = False + tc.variables["LIBENVPP_INSTALL"] = True + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + apply_conandata_patches(self) + + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + self.cpp_info.libs = ["envpp" if self.settings.os != "Windows" else "libenvpp"] diff --git a/recipes/libenvpp/all/patches/0001-use-cci-fmt.patch b/recipes/libenvpp/all/patches/0001-use-cci-fmt.patch new file mode 100644 index 00000000000000..d89edb409485de --- /dev/null +++ b/recipes/libenvpp/all/patches/0001-use-cci-fmt.patch @@ -0,0 +1,30 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e3ecffb..49cae57 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -54,6 +54,7 @@ function(libenvpp_set_compiler_parameters TARGET) + endfunction() + + # External dependencies. ++if(0) + if(LIBENVPP_INSTALL) + set(FMT_INSTALL ON CACHE BOOL "" FORCE) + endif() +@@ -63,6 +63,8 @@ FetchContent_Declare(fmt + GIT_TAG 9.1.0 + ) + FetchContent_MakeAvailable(fmt) ++endif() ++find_package(fmt REQUIRED CONFIG) + + if(LIBENVPP_TESTS) + FetchContent_Declare(Catch2 +@@ -133,6 +134,8 @@ endif() + + # Installation target. + if(LIBENVPP_INSTALL) ++ include(CMakePackageConfigHelpers) ++ + # Libenvpp installation. + set(LIBENVPP_PROJECT_CONFIG_OUT "${CMAKE_CURRENT_BINARY_DIR}/libenvpp-config.cmake") + set(LIBENVPP_VERSION_CONFIG_FILE "${CMAKE_CURRENT_BINARY_DIR}/libenvpp-config-version.cmake") diff --git a/recipes/libenvpp/all/test_package/CMakeLists.txt b/recipes/libenvpp/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..59cf4056ecd208 --- /dev/null +++ b/recipes/libenvpp/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(libenvpp REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE libenvpp::libenvpp) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) diff --git a/recipes/libenvpp/all/test_package/conanfile.py b/recipes/libenvpp/all/test_package/conanfile.py new file mode 100644 index 00000000000000..a9fb96656f2039 --- /dev/null +++ b/recipes/libenvpp/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libenvpp/all/test_package/test_package.cpp b/recipes/libenvpp/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..9be10c22b43a73 --- /dev/null +++ b/recipes/libenvpp/all/test_package/test_package.cpp @@ -0,0 +1,23 @@ +#include + +#include "libenvpp/env.hpp" + +int main() +{ + auto pre = env::prefix("MYPROG"); + + const auto num_threads_id = pre.register_required_variable("NUM_THREADS"); + + const auto parsed_and_validated_pre = pre.parse_and_validate(); + + if (parsed_and_validated_pre.ok()) { + const auto num_threads = parsed_and_validated_pre.get(num_threads_id); + + std::cout << "Num threads: " << num_threads << std::endl; + } else { + std::cout << parsed_and_validated_pre.warning_message(); + std::cout << parsed_and_validated_pre.error_message(); + } + + return 0; +} diff --git a/recipes/libenvpp/config.yml b/recipes/libenvpp/config.yml new file mode 100644 index 00000000000000..426a0e4c79e9b1 --- /dev/null +++ b/recipes/libenvpp/config.yml @@ -0,0 +1,3 @@ +versions: + "1.3.0": + folder: all From 6ae46d4da88676b7f81b30de9d2f156485ac8338 Mon Sep 17 00:00:00 2001 From: Aleksei Latyshev Date: Wed, 4 Oct 2023 20:30:51 +0200 Subject: [PATCH 0950/1140] (#20187) s2geometry: add recipe --- recipes/s2geometry/all/conandata.yml | 13 +++ recipes/s2geometry/all/conanfile.py | 103 ++++++++++++++++++ .../add_message_to_static_assert.patch | 13 +++ .../all/patches/bump_cmake_cxx_standard.patch | 13 +++ .../all/test_package/CMakeLists.txt | 20 ++++ .../s2geometry/all/test_package/conanfile.py | 27 +++++ .../all/test_package/test_package.cpp | 18 +++ recipes/s2geometry/config.yml | 3 + 8 files changed, 210 insertions(+) create mode 100644 recipes/s2geometry/all/conandata.yml create mode 100644 recipes/s2geometry/all/conanfile.py create mode 100644 recipes/s2geometry/all/patches/add_message_to_static_assert.patch create mode 100644 recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch create mode 100644 recipes/s2geometry/all/test_package/CMakeLists.txt create mode 100644 recipes/s2geometry/all/test_package/conanfile.py create mode 100644 recipes/s2geometry/all/test_package/test_package.cpp create mode 100644 recipes/s2geometry/config.yml diff --git a/recipes/s2geometry/all/conandata.yml b/recipes/s2geometry/all/conandata.yml new file mode 100644 index 00000000000000..811d215efcb5e6 --- /dev/null +++ b/recipes/s2geometry/all/conandata.yml @@ -0,0 +1,13 @@ +sources: + 0.10.0: + url: https://github.com/google/s2geometry/archive/refs/tags/v0.10.0.zip + sha256: d03ae5566e9957c5b3bc6e0e62603370d1450feaf093d204d27b7af9e4d14909 +patches: + 0.10.0: + - patch_description: "Bump CMAKE_CXX_STANDARD to 14" + patch_file: "patches/bump_cmake_cxx_standard.patch" + patch_source: "https://github.com/google/s2geometry/issues/317" + patch_type: "portability" + - patch_description: "Add message to static_assert to be compatible with c++14 (MSVC)" + patch_file: "patches/add_message_to_static_assert.patch" + patch_type: "portability" diff --git a/recipes/s2geometry/all/conanfile.py b/recipes/s2geometry/all/conanfile.py new file mode 100644 index 00000000000000..7a3ed3284ec7c9 --- /dev/null +++ b/recipes/s2geometry/all/conanfile.py @@ -0,0 +1,103 @@ +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches +from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" + + +class S2GeometryConan(ConanFile): + name = "s2geometry" + description = "Computational geometry and spatial indexing on the sphere" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/google/s2geometry" + topics = ("geometry", "s2", "spherical-geometry", "spatial-indexing") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 14 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "5", + "clang": "7", + "apple-clang": "10", + } + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("abseil/20230125.3", transitive_headers=True, transitive_libs=True) + self.requires("openssl/[>=1.1 <4]", transitive_headers=True) + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + check_min_vs(self, 191) + if not is_msvc(self): + 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." + ) + if is_msvc(self) and self.options.shared: + raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["GOOGLETEST_ROOT"] = False + tc.variables["BUILD_EXAMPLES"] = False + tc.generate() + tc = CMakeDeps(self) + tc.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + + def package_info(self): + self.cpp_info.libs = ["s2"] + self.cpp_info.set_property("cmake_target_name", "s2") + + # TODO: to remove in conan v2 once cmake_find_package_* generators removed + self.cpp_info.names["cmake_find_package"] = "s2" + self.cpp_info.names["cmake_find_package_multi"] = "s2" diff --git a/recipes/s2geometry/all/patches/add_message_to_static_assert.patch b/recipes/s2geometry/all/patches/add_message_to_static_assert.patch new file mode 100644 index 00000000000000..1a458e9936c5d0 --- /dev/null +++ b/recipes/s2geometry/all/patches/add_message_to_static_assert.patch @@ -0,0 +1,13 @@ +diff --git a/src/s2/s2lax_polygon_shape.cc b/src/s2/s2lax_polygon_shape.cc +index e71476a..7bfe874 100644 +--- a/src/s2/s2lax_polygon_shape.cc ++++ b/src/s2/s2lax_polygon_shape.cc +@@ -33,7 +33,7 @@ namespace { + template + std::unique_ptr make_unique_for_overwrite(size_t n) { + // We only need to support this one variant. +- static_assert(std::is_array::value); ++ static_assert(std::is_array::value, ""); + return std::unique_ptr(new typename absl::remove_extent_t[n]); + } + } // namespace diff --git a/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch b/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch new file mode 100644 index 00000000000000..50b168d636d588 --- /dev/null +++ b/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch @@ -0,0 +1,13 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index f080b4b..b2699ee 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -19,7 +19,7 @@ endif() + # undefined symbol errors since ABSL_HAVE_STD_STRING_VIEW etc will + # end up defined differently. There is probably a better way to achieve + # this than assuming what absl used. +-set(CMAKE_CXX_STANDARD 11) ++set(CMAKE_CXX_STANDARD 14) + set(CMAKE_CXX_STANDARD_REQUIRED ON) + # No compiler-specific extensions, i.e. -std=c++11, not -std=gnu++11. + set(CMAKE_CXX_EXTENSIONS OFF) diff --git a/recipes/s2geometry/all/test_package/CMakeLists.txt b/recipes/s2geometry/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..6727aedf56df7a --- /dev/null +++ b/recipes/s2geometry/all/test_package/CMakeLists.txt @@ -0,0 +1,20 @@ +cmake_minimum_required(VERSION 3.15) + +project(test_package CXX) + +set(CMAKE_CXX_STANDARD 14) +set(CMAKE_CXX_STANDARD_REQUIRED ON) + +find_package(s2geometry REQUIRED CONFIG) + +if (MSVC) + # Use unsigned characters + add_definitions(-J) + # Make sure cmath header defines things like M_PI + add_definitions(-D_USE_MATH_DEFINES) + # Make sure Windows doesn't define min/max macros that interfere with STL + add_definitions(-DNOMINMAX) +endif () + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE s2) diff --git a/recipes/s2geometry/all/test_package/conanfile.py b/recipes/s2geometry/all/test_package/conanfile.py new file mode 100644 index 00000000000000..02eb5ce439fb40 --- /dev/null +++ b/recipes/s2geometry/all/test_package/conanfile.py @@ -0,0 +1,27 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +# It will become the standard on Conan 2.x +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/s2geometry/all/test_package/test_package.cpp b/recipes/s2geometry/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..1f6da7a09f6f29 --- /dev/null +++ b/recipes/s2geometry/all/test_package/test_package.cpp @@ -0,0 +1,18 @@ +#include +#include +#include +#include + +#include +#include + +int main() +{ + S2Builder builder{S2Builder::Options()}; + S2Polygon output; + builder.StartLayer(std::make_unique(&output)); + auto input = s2textformat::MakePolygonOrDie("0:0, 0:5, 5:5, 5:0; 1:1, 1:4, 4:4, 4:1"); + builder.AddShape(*input->index().shape(0)); + S2Error error; + std::cout << "Builder: " << (builder.Build(&error) ? "OK" : error.text()) << std::endl; +} diff --git a/recipes/s2geometry/config.yml b/recipes/s2geometry/config.yml new file mode 100644 index 00000000000000..1b582dcf6716ba --- /dev/null +++ b/recipes/s2geometry/config.yml @@ -0,0 +1,3 @@ +versions: + "0.10.0": + folder: all From 9ed4f1485b538df0faf1945573e68f869c1be455 Mon Sep 17 00:00:00 2001 From: Tux3 Date: Wed, 4 Oct 2023 21:11:31 +0200 Subject: [PATCH 0951/1140] (#20259) android-ndk: add r26 --- recipes/android-ndk/all/conandata.yml | 13 +++++++++++++ recipes/android-ndk/config.yml | 2 ++ 2 files changed, 15 insertions(+) diff --git a/recipes/android-ndk/all/conandata.yml b/recipes/android-ndk/all/conandata.yml index 020850fb262026..91ea41fe322a4d 100644 --- a/recipes/android-ndk/all/conandata.yml +++ b/recipes/android-ndk/all/conandata.yml @@ -1,4 +1,17 @@ sources: + "r26": + "Windows": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26-windows.zip" + sha256: "a748c6634b96991e15cb8902ffa4a498bba2ec6aa8028526de3c4c9dfcf00663" + "Linux": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26-linux.zip" + sha256: "1505c2297a5b7a04ed20b5d44da5665e91bac2b7c0fbcd3ae99b6ccc3a61289a" + "Macos": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26-darwin.zip" + sha256: "b2ab2fd17f71e2d2994c8c0ba2e48e99377806e05bf7477093344c26ab71dec0" "r25c": "Windows": "x86_64": diff --git a/recipes/android-ndk/config.yml b/recipes/android-ndk/config.yml index abc38391659913..afb825c16b4c6d 100644 --- a/recipes/android-ndk/config.yml +++ b/recipes/android-ndk/config.yml @@ -1,4 +1,6 @@ versions: + "r26": + folder: all "r25c": folder: all "r25b": From b7c0ba63820a0d0a6def11f205f1dc7586f93b73 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 22:32:24 +0300 Subject: [PATCH 0952/1140] (#20316) aws-kvs-pic: add v1.0.1, simplify patching --- recipes/aws-kvs-pic/all/conandata.yml | 6 +++--- recipes/aws-kvs-pic/all/conanfile.py | 10 +++++----- .../all/patches/0001-do-not-enforce-fpic.patch | 11 ----------- recipes/aws-kvs-pic/config.yml | 2 ++ 4 files changed, 10 insertions(+), 19 deletions(-) delete mode 100644 recipes/aws-kvs-pic/all/patches/0001-do-not-enforce-fpic.patch diff --git a/recipes/aws-kvs-pic/all/conandata.yml b/recipes/aws-kvs-pic/all/conandata.yml index 9d7d13929fbbc4..4be3843841ab1c 100644 --- a/recipes/aws-kvs-pic/all/conandata.yml +++ b/recipes/aws-kvs-pic/all/conandata.yml @@ -1,7 +1,7 @@ sources: + "1.0.1": + url: "https://github.com/awslabs/amazon-kinesis-video-streams-pic/archive/refs/tags/v1.0.1.tar.gz" + sha256: "d04732217c74687c5498665b353cb089d725ca7f5b5da61a3f984f7fbefb2ac9" "cci.20210812": url: "https://github.com/awslabs/amazon-kinesis-video-streams-pic/archive/bbf0e4ba749a6c045fc3958951c1c3a61a808dd0.tar.gz" sha256: "5a6d8da62af766ec86423ead2a45d9ff00cd80ddea679ce228ff9696a490fae5" -patches: - "cci.20210812": - - patch_file: "patches/0001-do-not-enforce-fpic.patch" diff --git a/recipes/aws-kvs-pic/all/conanfile.py b/recipes/aws-kvs-pic/all/conanfile.py index f9858a924f3048..a0653e082edea0 100644 --- a/recipes/aws-kvs-pic/all/conanfile.py +++ b/recipes/aws-kvs-pic/all/conanfile.py @@ -3,7 +3,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +from conan.tools.files import copy, get, rmdir, replace_in_file required_conan_version = ">=1.53.0" @@ -27,9 +27,6 @@ class awskvspicConan(ConanFile): "fPIC": True, } - def export_sources(self): - export_conandata_patches(self) - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -55,8 +52,11 @@ def generate(self): tc.variables["BUILD_DEPENDENCIES"] = False tc.generate() + def _patch_sources(self): + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), " -fPIC", "") + def build(self): - apply_conandata_patches(self) + self._patch_sources() cmake = CMake(self) cmake.configure() cmake.build() diff --git a/recipes/aws-kvs-pic/all/patches/0001-do-not-enforce-fpic.patch b/recipes/aws-kvs-pic/all/patches/0001-do-not-enforce-fpic.patch deleted file mode 100644 index 0286a964caa2c9..00000000000000 --- a/recipes/aws-kvs-pic/all/patches/0001-do-not-enforce-fpic.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/CMakeLists.txt 2021-08-06 17:10:31.808434572 -0300 -+++ b/CMakeLists.txt 2021-08-06 17:10:31.888434646 -0300 -@@ -79,7 +79,7 @@ - set(THREADS_PREFER_PTHREAD_FLAG ON) - find_package(Threads) - --set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fPIC") -+ - - if(MSVC) - add_definitions(-D_CRT_SECURE_NO_WARNINGS -D_CRT_NONSTDC_NO_WARNINGS -D_SILENCE_TR1_NAMESPACE_DEPRECATION_WARNING) diff --git a/recipes/aws-kvs-pic/config.yml b/recipes/aws-kvs-pic/config.yml index e6b575a0288450..42adf0e62a4df0 100644 --- a/recipes/aws-kvs-pic/config.yml +++ b/recipes/aws-kvs-pic/config.yml @@ -1,3 +1,5 @@ versions: + "1.0.1": + folder: all "cci.20210812": folder: all From bbb3c7ab4fe300d6f587e0ef20eec9a507af4e75 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 4 Oct 2023 23:07:44 +0300 Subject: [PATCH 0953/1140] (#18868) microprofile: migrate to Conan v2 * microprofile: migrate to Conan v2 * microprofile: restore VirtualRunEnv in test_package * microprofile: fix license URL * microprofile: tweak defines file creation * microprofile: bump deps --------- Co-authored-by: Daniel --- recipes/microprofile/all/CMakeLists.txt | 66 +++++- recipes/microprofile/all/conandata.yml | 5 +- recipes/microprofile/all/conanfile.py | 212 +++++++++--------- recipes/microprofile/all/patches/cmake.patch | 67 ------ .../all/test_package/CMakeLists.txt | 5 +- .../all/test_package/conanfile.py | 22 +- .../all/test_v1_package/CMakeLists.txt | 8 + .../all/test_v1_package/conanfile.py | 18 ++ 8 files changed, 212 insertions(+), 191 deletions(-) delete mode 100644 recipes/microprofile/all/patches/cmake.patch create mode 100644 recipes/microprofile/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/microprofile/all/test_v1_package/conanfile.py diff --git a/recipes/microprofile/all/CMakeLists.txt b/recipes/microprofile/all/CMakeLists.txt index ff45b79a8420c1..c54dc9657fda81 100644 --- a/recipes/microprofile/all/CMakeLists.txt +++ b/recipes/microprofile/all/CMakeLists.txt @@ -1,7 +1,63 @@ -cmake_minimum_required(VERSION 3.10) -project(cmake_wrapper) +cmake_minimum_required(VERSION 3.4) +project(microprofile) -include(conanbuildinfo.cmake) -conan_basic_setup(TARGETS) +option(MICROPROFILE_USE_CONFIG_FILE "Use user provided configuration in microprofile.config.h file." ON) -add_subdirectory("source_subfolder") +set(MICROPROFILE_EXPORT_FILENAME microprofile.export.h) +set(MICROPROFILE_CONFIG_HEADER ${PROJECT_SOURCE_DIR}/microprofile.config.h) +set(MICROPROFILE_PUBLIC_HEADERS + ${PROJECT_SOURCE_DIR}/microprofile.h + ${CMAKE_CURRENT_BINARY_DIR}/${MICROPROFILE_EXPORT_FILENAME} +) + +set(THREADS_PREFER_PTHREAD_FLAG ON) +find_package(Threads REQUIRED) + +add_library(${PROJECT_NAME} microprofile.h microprofile.cpp) + +include(GenerateExportHeader) +generate_export_header(${PROJECT_NAME} + EXPORT_MACRO_NAME MICROPROFILE_API + EXPORT_FILE_NAME ${MICROPROFILE_EXPORT_FILENAME} +) + +target_include_directories(${PROJECT_NAME} PUBLIC + $ + $ + $ +) + +if (MICROPROFILE_USE_CONFIG_FILE) + target_compile_definitions(${PROJECT_NAME} PUBLIC MICROPROFILE_USE_CONFIG) +endif() + +target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11) + +target_link_libraries(${PROJECT_NAME} PRIVATE Threads::Threads) + +if (WIN32) + target_link_libraries(${PROJECT_NAME} PRIVATE ws2_32) +endif() + +if (MP_MINIZ) + find_package(miniz REQUIRED CONFIG) + target_link_libraries(${PROJECT_NAME} PRIVATE miniz::miniz) +endif() + +if (MP_GPU_TIMERS_VULKAN) + find_package(Vulkan REQUIRED) + target_link_libraries(${PROJECT_NAME} PRIVATE Vulkan::Vulkan) +endif() + +set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER "${MICROPROFILE_PUBLIC_HEADERS}") + +include(GNUInstallDirs) +install(TARGETS ${PROJECT_NAME} + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME} +) +if (MICROPROFILE_USE_CONFIG_FILE) + install(FILES ${MICROPROFILE_CONFIG_HEADER} + DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME} + PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ + ) +endif() diff --git a/recipes/microprofile/all/conandata.yml b/recipes/microprofile/all/conandata.yml index 6715d7fabbe052..440ae9ec0e9eda 100644 --- a/recipes/microprofile/all/conandata.yml +++ b/recipes/microprofile/all/conandata.yml @@ -2,11 +2,8 @@ sources: "3.1": - url: "https://github.com/jonasmr/microprofile/archive/refs/tags/v3.1.tar.gz" sha256: "300e1d0d21e4c13ad1de72c5309ba02fbdb3bcbbe26e5ad9ff8b798380781527" - - url: "https://unlicense.org/UNLICENSE" + - url: "https://raw.githubusercontent.com/jonasmr/microprofile/v4.0/LICENSE" sha256: "7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c" patches: "3.1": - patch_file: "patches/sources_fix.patch" - base_path: "source_subfolder" - - patch_file: "patches/cmake.patch" - base_path: "source_subfolder" diff --git a/recipes/microprofile/all/conanfile.py b/recipes/microprofile/all/conanfile.py index 9f23e3872db580..abbded97a0b174 100644 --- a/recipes/microprofile/all/conanfile.py +++ b/recipes/microprofile/all/conanfile.py @@ -1,54 +1,59 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration import os +from collections import OrderedDict -required_conan_version = ">=1.33.0" +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, collect_libs, copy, download, export_conandata_patches, get, save + +required_conan_version = ">=1.53.0" class MicroprofileConan(ConanFile): name = "microprofile" + description = "Microprofile is a embeddable profiler in a few files, written in C++" license = "Unlicense" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/jonasmr/microprofile" - description = "Microprofile is a embeddable profiler in a few files, written in C++" topics = ("profiler", "embedded", "timer") - exports_sources = ["CMakeLists.txt", "patches/**"] - generators = "cmake" - settings = "os", "compiler", "build_type", "arch" + + package_type = "library" + settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], "fPIC": [True, False], "microprofile_enabled": [True, False], "with_miniz": [True, False], - "thread_buffer_size": "ANY", - "thread_gpu_buffer_size": "ANY", - "max_frame_history": "ANY", - "webserver_port": "ANY", - "webserver_maxframes": "ANY", - "webserver_socket_buffer_size": "ANY", - "gpu_frame_delay": "ANY", - "name_max_length": "ANY", - "max_timers": "ANY", - "max_threads": "ANY", - "max_string_length": "ANY", - "timeline_max_tokens": "ANY", - "thread_log_frames_reuse": "ANY", - "max_groups": "ANY", + "thread_buffer_size": ["ANY"], + "thread_gpu_buffer_size": ["ANY"], + "max_frame_history": ["ANY"], + "webserver_port": ["ANY"], + "webserver_maxframes": ["ANY"], + "webserver_socket_buffer_size": ["ANY"], + "gpu_frame_delay": ["ANY"], + "name_max_length": ["ANY"], + "max_timers": ["ANY"], + "max_threads": ["ANY"], + "max_string_length": ["ANY"], + "timeline_max_tokens": ["ANY"], + "thread_log_frames_reuse": ["ANY"], + "max_groups": ["ANY"], "use_big_endian": [True, False], "enable_gpu_timer_callbacks": [True, False], - "enable_timer": [None, "gl", "d3d11", "d3d12", "vulkan"] + "enable_timer": [None, "gl", "d3d11", "d3d12", "vulkan"], } default_options = { "shared": False, "fPIC": True, "microprofile_enabled": True, "with_miniz": False, - "thread_buffer_size": 2048 << 10, - "thread_gpu_buffer_size": 128 << 10, + "thread_buffer_size": 2097152, + "thread_gpu_buffer_size": 131072, "max_frame_history": 512, "webserver_port": 1338, "webserver_maxframes": 30, - "webserver_socket_buffer_size": 16 << 10, + "webserver_socket_buffer_size": 16384, "gpu_frame_delay": 5, "name_max_length": 64, "max_timers": 1024, @@ -59,23 +64,35 @@ class MicroprofileConan(ConanFile): "max_groups": 128, "use_big_endian": False, "enable_gpu_timer_callbacks": False, - "enable_timer": None + "enable_timer": None, } - _cmake = None + def export_sources(self): + export_conandata_patches(self) + copy(self, "CMakeLists.txt", + src=self.recipe_folder, + dst=os.path.join(self.export_sources_folder, "src")) - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + if self.options.with_miniz: + self.requires("miniz/3.0.2") + if self.options.enable_timer == "gl": + self.requires("opengl/system") + if self.options.enable_timer == "vulkan": + self.requires("vulkan-loader/1.3.243.0") + def _validate_int_options(self): positive_int_options = [ "thread_buffer_size", @@ -91,19 +108,19 @@ def _validate_int_options(self): "max_string_length", "timeline_max_tokens", "thread_log_frames_reuse", - "max_groups" + "max_groups", ] for opt in positive_int_options: try: - value = int(getattr(self.options, opt)) + value = int(self.options.get_safe(opt)) if value < 0: raise ValueError except ValueError: - raise ConanInvalidConfiguration("microprofile:{} must be a positive integer".format(opt)) + raise ConanInvalidConfiguration(f"microprofile:{opt} must be a positive integer") def validate(self): if self.settings.compiler.get_safe("cppstd"): - tools.check_min_cppstd(self, 11) + check_min_cppstd(self, 11) if self.settings.os != "Windows" and self.options.enable_timer in ["d3d11", "d3d12"]: raise ConanInvalidConfiguration("DirectX timers can only be used in Windows.") if self.options.enable_timer and self.options.enable_gpu_timer_callbacks: @@ -113,91 +130,78 @@ def validate(self): if int(self.options.max_groups) % 32 != 0: raise ConanInvalidConfiguration("microprofile:max_groups must be multiple of 32.") - if int(self.options.webserver_port) > 2 ** 16 - 1: + if int(self.options.webserver_port) > 2**16 - 1: raise ConanInvalidConfiguration("microprofile:webserver_port must be between 0 and 65535.") - def configure(self): - if self.options.shared: - del self.options.fPIC - - def requirements(self): - if self.options.with_miniz: - self.requires("miniz/2.2.0") - if self.options.enable_timer == "gl": - self.requires("opengl/system") - if self.options.enable_timer == "vulkan": - self.requires("vulkan-loader/1.2.182") - def source(self): - tools.get(**self.conan_data["sources"][self.version][0], strip_root=True, destination=self._source_subfolder) - tools.download(filename="LICENSE", **self.conan_data["sources"][self.version][1]) + get(self, **self.conan_data["sources"][self.version][0], strip_root=True) + download(self, filename="LICENSE", **self.conan_data["sources"][self.version][1]) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["MP_MINIZ"] = self.options.with_miniz + tc.variables["MP_GPU_TIMERS_VULKAN"] = self.options.enable_timer == "vulkan" + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - self._create_defines_file(os.path.join(self._source_subfolder, "microprofile.config.h")) - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + self._create_defines_file(os.path.join(self.source_folder, "microprofile.config.h")) + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["MP_MINIZ"] = self.options.with_miniz - self._cmake.definitions["MP_GPU_TIMERS_VULKAN"] = self.options.enable_timer == "vulkan" - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake - def package(self): - self.copy("LICENSE", dst="licenses") - cmake = self._configure_cmake() + copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) cmake.install() def _create_defines(self): - return [ - "MICROPROFILE_EXPORT", - ("MICROPROFILE_ENABLED", ("1" if self.options.microprofile_enabled else "0")), - ("MICROPROFILE_DEBUG", ("1" if self.settings.build_type == "Debug" else "0")), - ("MICROPROFILE_MINIZ", ("1" if self.options.with_miniz else "0")), - ("MICROPROFILE_BIG_ENDIAN", ("1" if self.options.use_big_endian else "0")), - ("MICROPROFILE_GPU_TIMERS", ("1" if self.options.enable_timer else "0")), - ("MICROPROFILE_GPU_TIMER_CALLBACKS", ("1" if self.options.enable_gpu_timer_callbacks else "0")), - ("MICROPROFILE_GPU_TIMERS_GL", ("1" if self.options.enable_timer == "gl" else "0")), - ("MICROPROFILE_GPU_TIMERS_D3D11", ("1" if self.options.enable_timer == "d3d11" else "0")), - ("MICROPROFILE_GPU_TIMERS_D3D12", ("1" if self.options.enable_timer == "d3d12" else "0")), - ("MICROPROFILE_GPU_TIMERS_VULKAN", ("1" if self.options.enable_timer == "vulkan" else "0")), - ("MICROPROFILE_PER_THREAD_BUFFER_SIZE", str(self.options.thread_buffer_size)), - ("MICROPROFILE_PER_THREAD_GPU_BUFFER_SIZE", str(self.options.thread_gpu_buffer_size)), - ("MICROPROFILE_MAX_FRAME_HISTORY", str(self.options.max_frame_history)), - ("MICROPROFILE_WEBSERVER_PORT", str(self.options.webserver_port)), - ("MICROPROFILE_WEBSERVER_MAXFRAMES", str(self.options.webserver_maxframes)), - ("MICROPROFILE_WEBSERVER_SOCKET_BUFFER_SIZE", str(self.options.webserver_socket_buffer_size)), - ("MICROPROFILE_GPU_FRAME_DELAY", str(self.options.gpu_frame_delay)), - ("MICROPROFILE_NAME_MAX_LEN", str(self.options.name_max_length)), - ("MICROPROFILE_MAX_TIMERS", str(self.options.max_timers)), - ("MICROPROFILE_MAX_THREADS", str(self.options.max_threads)), - ("MICROPROFILE_MAX_STRING", str(self.options.max_string_length)), - ("MICROPROFILE_TIMELINE_MAX_TOKENS", str(self.options.timeline_max_tokens)), - ("MICROPROFILE_THREAD_LOG_FRAMES_REUSE", str(self.options.thread_log_frames_reuse)), - ("MICROPROFILE_MAX_GROUPS", str(self.options.max_groups)) - ] + defines = OrderedDict() + defines["MICROPROFILE_EXPORT"] = None + defines["MICROPROFILE_ENABLED"] = bool(self.options.microprofile_enabled) + defines["MICROPROFILE_DEBUG"] = bool(self.settings.build_type == "Debug") + defines["MICROPROFILE_MINIZ"] = bool(self.options.with_miniz) + defines["MICROPROFILE_BIG_ENDIAN"] = bool(self.options.use_big_endian) + defines["MICROPROFILE_GPU_TIMERS"] = bool(self.options.enable_timer) + defines["MICROPROFILE_GPU_TIMER_CALLBACKS"] = bool(self.options.enable_gpu_timer_callbacks) + defines["MICROPROFILE_GPU_TIMERS_GL"] = bool(self.options.enable_timer == "gl") + defines["MICROPROFILE_GPU_TIMERS_D3D11"] = bool(self.options.enable_timer == "d3d11") + defines["MICROPROFILE_GPU_TIMERS_D3D12"] = bool(self.options.enable_timer == "d3d12") + defines["MICROPROFILE_GPU_TIMERS_VULKAN"] = bool(self.options.enable_timer == "vulkan") + defines["MICROPROFILE_PER_THREAD_BUFFER_SIZE"] = self.options.thread_buffer_size + defines["MICROPROFILE_PER_THREAD_GPU_BUFFER_SIZE"] = self.options.thread_gpu_buffer_size + defines["MICROPROFILE_MAX_FRAME_HISTORY"] = self.options.max_frame_history + defines["MICROPROFILE_WEBSERVER_PORT"] = self.options.webserver_port + defines["MICROPROFILE_WEBSERVER_MAXFRAMES"] = self.options.webserver_maxframes + defines["MICROPROFILE_WEBSERVER_SOCKET_BUFFER_SIZE"] = self.options.webserver_socket_buffer_size + defines["MICROPROFILE_GPU_FRAME_DELAY"] = self.options.gpu_frame_delay + defines["MICROPROFILE_NAME_MAX_LEN"] = self.options.name_max_length + defines["MICROPROFILE_MAX_TIMERS"] = self.options.max_timers + defines["MICROPROFILE_MAX_THREADS"] = self.options.max_threads + defines["MICROPROFILE_MAX_STRING"] = self.options.max_string_length + defines["MICROPROFILE_TIMELINE_MAX_TOKENS"] = self.options.timeline_max_tokens + defines["MICROPROFILE_THREAD_LOG_FRAMES_REUSE"] = self.options.thread_log_frames_reuse + defines["MICROPROFILE_MAX_GROUPS"] = self.options.max_groups + return defines def _create_defines_file(self, filename): defines = self._create_defines() defines_list = ["#pragma once\n"] - for define in defines: - if isinstance(define, tuple) or isinstance(define, list): - defines_list.append("#define {} {}\n".format(define[0], define[1])) + for define, value in defines.items(): + if value is None or value == "": + defines_list.append(f"#define {define}\n") + elif value in [True, False]: + defines_list.append(f"#define {define} {'1' if value else '0'}\n") else: - defines_list.append("#define {}\n".format(define)) - tools.save(filename, "".join(defines_list)) + defines_list.append(f"#define {define} {value}\n") + save(self, filename, "".join(defines_list)) def package_info(self): - self.cpp_info.libs = tools.collect_libs(self) - self.cpp_info.names["cmake_find_package"] = self.name - self.cpp_info.names["cmake_find_package_multi"] = self.name + self.cpp_info.libs = collect_libs(self) if self.settings.os == "Windows": self.cpp_info.system_libs = ["ws2_32"] - elif self.settings.os == "Linux": + elif self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["pthread"] self.cpp_info.defines.append("MICROPROFILE_USE_CONFIG") diff --git a/recipes/microprofile/all/patches/cmake.patch b/recipes/microprofile/all/patches/cmake.patch deleted file mode 100644 index b92ba025b0a43b..00000000000000 --- a/recipes/microprofile/all/patches/cmake.patch +++ /dev/null @@ -1,67 +0,0 @@ ---- /dev/null -+++ b/CMakeLists.txt -@@ -0,0 +1,64 @@ -+cmake_minimum_required(VERSION 3.4) -+project(microprofile) -+ -+option(MICROPROFILE_USE_CONFIG_FILE "Use user provided configuration in microprofile.config.h file." ON) -+ -+set(MICROPROFILE_EXPORT_FILENAME microprofile.export.h) -+set(MICROPROFILE_CONFIG_HEADER ${PROJECT_SOURCE_DIR}/microprofile.config.h) -+set(MICROPROFILE_PUBLIC_HEADERS -+ ${PROJECT_SOURCE_DIR}/microprofile.h -+ ${CMAKE_CURRENT_BINARY_DIR}/${MICROPROFILE_EXPORT_FILENAME} -+) -+ -+set(THREADS_PREFER_PTHREAD_FLAG ON) -+find_package(Threads REQUIRED) -+ -+add_library(${PROJECT_NAME} microprofile.h microprofile.cpp) -+ -+include(GenerateExportHeader) -+generate_export_header(${PROJECT_NAME} -+ EXPORT_MACRO_NAME MICROPROFILE_API -+ EXPORT_FILE_NAME ${MICROPROFILE_EXPORT_FILENAME} -+) -+ -+target_include_directories(${PROJECT_NAME} PUBLIC -+ $ -+ $ -+ $ -+) -+ -+if (MICROPROFILE_USE_CONFIG_FILE) -+ target_compile_definitions(${PROJECT_NAME} PUBLIC MICROPROFILE_USE_CONFIG) -+endif() -+ -+target_compile_features(${PROJECT_NAME} PUBLIC cxx_std_11) -+ -+target_link_libraries(${PROJECT_NAME} PRIVATE Threads::Threads) -+ -+if (WIN32) -+ target_link_libraries(${PROJECT_NAME} PRIVATE ws2_32) -+endif() -+ -+if (MP_MINIZ) -+ target_link_libraries(${PROJECT_NAME} PRIVATE CONAN_PKG::miniz) -+endif() -+ -+if (MP_GPU_TIMERS_VULKAN) -+ target_link_libraries(${PROJECT_NAME} PRIVATE CONAN_PKG::vulkan-loader) -+endif() -+ -+set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER "${MICROPROFILE_PUBLIC_HEADERS}") -+ -+include(GNUInstallDirs) -+install(TARGETS ${PROJECT_NAME} -+ RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} -+ LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} -+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} -+ PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME} -+) -+if (MICROPROFILE_USE_CONFIG_FILE) -+ install(FILES ${MICROPROFILE_CONFIG_HEADER} -+ DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/${PROJECT_NAME} -+ PERMISSIONS OWNER_WRITE OWNER_READ GROUP_READ WORLD_READ -+ ) -+endif() diff --git a/recipes/microprofile/all/test_package/CMakeLists.txt b/recipes/microprofile/all/test_package/CMakeLists.txt index ed091dc6c1aeed..34366c2d4346f2 100644 --- a/recipes/microprofile/all/test_package/CMakeLists.txt +++ b/recipes/microprofile/all/test_package/CMakeLists.txt @@ -1,9 +1,6 @@ -cmake_minimum_required(VERSION 3.10) +cmake_minimum_required(VERSION 3.15) project(test_package CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - find_package(microprofile REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) diff --git a/recipes/microprofile/all/test_package/conanfile.py b/recipes/microprofile/all/test_package/conanfile.py index 30f8c8cfb09756..ef5d7042163ecc 100644 --- a/recipes/microprofile/all/test_package/conanfile.py +++ b/recipes/microprofile/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class MicroprofileTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/microprofile/all/test_v1_package/CMakeLists.txt b/recipes/microprofile/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/microprofile/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/microprofile/all/test_v1_package/conanfile.py b/recipes/microprofile/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..30f8c8cfb09756 --- /dev/null +++ b/recipes/microprofile/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class MicroprofileTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From d48ad2ec00295936cd19a02462b0f10f25e4515e Mon Sep 17 00:00:00 2001 From: Samuel Dowling Date: Thu, 5 Oct 2023 07:19:41 +1030 Subject: [PATCH 0954/1140] (#19909) [armadillo] Prevent static builds when use_wrapper=True * [armadillo] Prevent static builds when use_wrapper=True For armadillo to wrap other libraries, these other libraries must be either statically compiled into the armadillo binary or dynamically linked to by libarmadillo. This is not possible when armadillo is a static library itself, without doing some unusual modification of the armadillo archive. This change ensures that armadillo is built as a shared library when use_wrapper=True, which is the only configuration that would enable libarmadillo to be used this way. Closes #7840 * [armadillo] Prevent transitive library propagate when use_wrapper=True The armadillo run-time library wrapper is designed to provide an opaque integration with upstream libraries, and so these are not required to be passed transitively. * Bump hdf5 version Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/armadillo/all/conanfile.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/recipes/armadillo/all/conanfile.py b/recipes/armadillo/all/conanfile.py index ef77af6e7bf330..88da815dbce2ad 100644 --- a/recipes/armadillo/all/conanfile.py +++ b/recipes/armadillo/all/conanfile.py @@ -174,6 +174,9 @@ def validate(self): "The wrapper requires the use of an external RNG. Set use_extern_rng=True and try again." ) + if not self.options.shared and self.options.use_wrapper: + raise ConanInvalidConfiguration("Building the armadillo run-time wrapper library requires armadillo/*:shared=True") + def requirements(self): # Optional requirements # TODO: "atlas/3.10.3" # Pending https://github.com/conan-io/conan-center-index/issues/6757 @@ -186,10 +189,12 @@ def requirements(self): # See https://gitlab.com/conradsnicta/armadillo-code/-/issues/227 for more information. if self.options.use_hdf5 and Version(self.version) < "12": # Use the conan dependency if the system lib isn't being used - self.requires("hdf5/1.14.0", transitive_headers=True, transitive_libs=True) + # Libraries not required to be propagated transitively when the armadillo run-time wrapper is used + self.requires("hdf5/1.14.1", transitive_headers=True, transitive_libs=not self.options.use_wrapper) if self.options.use_blas == "openblas": - self.requires("openblas/0.3.20", transitive_libs=True) + # Libraries not required to be propagated transitively when the armadillo run-time wrapper is used + self.requires("openblas/0.3.20", transitive_libs=not self.options.use_wrapper) if ( self.options.use_blas == "intel_mkl" and self.options.use_lapack == "intel_mkl" From df2780df40710985b1f86451c02364f922653be5 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 4 Oct 2023 23:56:26 +0200 Subject: [PATCH 0955/1140] (#19983) xkbcommon/all: bump deps * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xkbcommon/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * use * wayland-protocols is never a requirement * wayland-protocols is a tool_requirement * fixup --- recipes/xkbcommon/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/xkbcommon/all/conanfile.py b/recipes/xkbcommon/all/conanfile.py index d6a9ac9f0458dc..73fdaedd84c66f 100644 --- a/recipes/xkbcommon/all/conanfile.py +++ b/recipes/xkbcommon/all/conanfile.py @@ -67,7 +67,7 @@ def requirements(self): if self.options.get_safe("xkbregistry"): self.requires("libxml2/2.11.4") if self.options.get_safe("with_wayland"): - self.requires("wayland/1.21.0") + self.requires("wayland/1.22.0") if not self._has_build_profile: self.requires("wayland-protocols/1.31") @@ -76,12 +76,12 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} is only compatible with Linux and FreeBSD") def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.2") self.tool_requires("bison/3.8.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._has_build_profile and self.options.get_safe("with_wayland"): - self.tool_requires("wayland/1.21.0") + self.tool_requires("wayland/") self.tool_requires("wayland-protocols/1.31") def source(self): From 88388a32bf8af56adf7230d7e7c9298e690f4ce5 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Wed, 4 Oct 2023 18:01:13 -0500 Subject: [PATCH 0956/1140] (#20318) libevdev: Add recipe * libevdev: Add recipe * Don't set PATH --- recipes/libevdev/all/conandata.yml | 4 + recipes/libevdev/all/conanfile.py | 79 +++++++++++++++++++ .../libevdev/all/test_package/conanfile.py | 32 ++++++++ recipes/libevdev/all/test_package/meson.build | 5 ++ .../libevdev/all/test_package/test_package.c | 8 ++ recipes/libevdev/config.yml | 3 + 6 files changed, 131 insertions(+) create mode 100644 recipes/libevdev/all/conandata.yml create mode 100644 recipes/libevdev/all/conanfile.py create mode 100644 recipes/libevdev/all/test_package/conanfile.py create mode 100644 recipes/libevdev/all/test_package/meson.build create mode 100644 recipes/libevdev/all/test_package/test_package.c create mode 100644 recipes/libevdev/config.yml diff --git a/recipes/libevdev/all/conandata.yml b/recipes/libevdev/all/conandata.yml new file mode 100644 index 00000000000000..36ae01fb48f05b --- /dev/null +++ b/recipes/libevdev/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.13.1": + url: "https://www.freedesktop.org/software/libevdev/libevdev-1.13.1.tar.xz" + sha256: "06a77bf2ac5c993305882bc1641017f5bec1592d6d1b64787bad492ab34f2f36" diff --git a/recipes/libevdev/all/conanfile.py b/recipes/libevdev/all/conanfile.py new file mode 100644 index 00000000000000..bd31989739c14f --- /dev/null +++ b/recipes/libevdev/all/conanfile.py @@ -0,0 +1,79 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import copy, get, rmdir +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson, MesonToolchain +from conan.tools.scm import Version +import os + + +required_conan_version = ">=1.53.0" + +class LibEvdevConan(ConanFile): + name = "libevdev" + description = "libevdev is a wrapper library for evdev devices." + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://www.freedesktop.org/wiki/Software/libevdev" + topics = ("device", "evdev", "freedesktop", "input") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") + + def validate(self): + if not self.settings.os in ["FreeBSD", "Linux"]: + raise ConanInvalidConfiguration(f"{self.name} Only supports FreeBSD and Linux") + + def build_requirements(self): + self.tool_requires("meson/1.2.2") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = MesonToolchain(self) + tc.project_options["tests"] = "disabled" + tc.project_options["documentation"] = "disabled" + tc.project_options["coverity"] = "false" + tc.generate() + tc = VirtualBuildEnv(self) + tc.generate() + + def build(self): + meson = Meson(self) + meson.configure() + meson.build() + + def package(self): + copy(self, "COPYING", self.source_folder, os.path.join(self.package_folder, "licenses")) + meson = Meson(self) + meson.install() + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rmdir(self, os.path.join(self.package_folder, "share")) + + def package_info(self): + self.cpp_info.libs = ["evdev"] + self.cpp_info.includedirs = [os.path.join("include", f"libevdev-{Version(self.version).major}.0")] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.extend(["m", "rt"]) diff --git a/recipes/libevdev/all/test_package/conanfile.py b/recipes/libevdev/all/test_package/conanfile.py new file mode 100644 index 00000000000000..5aab0703e7a4ef --- /dev/null +++ b/recipes/libevdev/all/test_package/conanfile.py @@ -0,0 +1,32 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "PkgConfigDeps", "MesonToolchain", "VirtualRunEnv", "VirtualBuildEnv" + test_type = "explicit" + + def layout(self): + basic_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build_requirements(self): + self.tool_requires("meson/1.2.2") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/2.0.3") + + def build(self): + meson = Meson(self) + meson.configure() + meson.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libevdev/all/test_package/meson.build b/recipes/libevdev/all/test_package/meson.build new file mode 100644 index 00000000000000..16df74e848742a --- /dev/null +++ b/recipes/libevdev/all/test_package/meson.build @@ -0,0 +1,5 @@ +project('test_package', 'c') +libevdev_dep = dependency('libevdev') +executable('test_package', + sources : ['test_package.c'], + dependencies : [libevdev_dep]) diff --git a/recipes/libevdev/all/test_package/test_package.c b/recipes/libevdev/all/test_package/test_package.c new file mode 100644 index 00000000000000..c8e6a5edda83f7 --- /dev/null +++ b/recipes/libevdev/all/test_package/test_package.c @@ -0,0 +1,8 @@ +#include + +#include + +int main(void) { + libevdev_new_from_fd(0, NULL); + return 0; +} diff --git a/recipes/libevdev/config.yml b/recipes/libevdev/config.yml new file mode 100644 index 00000000000000..aac1819cc10c01 --- /dev/null +++ b/recipes/libevdev/config.yml @@ -0,0 +1,3 @@ +versions: + "1.13.1": + folder: all From 91ec6bda94921ca37f12961f29aed86a53e5488f Mon Sep 17 00:00:00 2001 From: Luis Andres Cesena <84929991+cesenaLA@users.noreply.github.com> Date: Wed, 4 Oct 2023 18:54:52 -0500 Subject: [PATCH 0957/1140] (#19593) libdwarf: add version 0.7.0, fix missing header in v0.5.0 * libdwarf: Fix missing dwarf.h in package v0.5.0 Updated CMake patch to also install dwarf.h. The patch was already in place for version v20191104 but was missed when the recipe got updated to v0.5.0. Also updated tests to use Dwarf Attributes defined in dwarf.h. * Remove dependency on libelf if build_dwargen=False libdwarf doesn't depend on libelf since version 0.1.0. The dependency is only needed if dwarfgen is built. The patch drops the REQUIRED parameter for find_package on libelf, it should be available only when build_dwarfgen=True. Fixed syntax error in conanfile when calling append. * libdwarf: add version 0.7.0 * Check BUILD_DWARGEN before looking for libelf Instead of dropping the REQUIRED options from find_package, don't search for it if we don't need it. * Stop exporting libdwarf.pc file --------- Co-authored-by: Uilian Ries --- recipes/libdwarf/all/conandata.yml | 10 ++ recipes/libdwarf/all/conanfile.py | 5 +- .../all/patches/0.5.0-0001-fix-cmake.patch | 12 +- .../all/patches/0.7.0-0001-fix-cmake.patch | 128 ++++++++++++++++++ .../libdwarf/all/test_package/test_package.c | 3 + recipes/libdwarf/config.yml | 2 + 6 files changed, 157 insertions(+), 3 deletions(-) create mode 100644 recipes/libdwarf/all/patches/0.7.0-0001-fix-cmake.patch diff --git a/recipes/libdwarf/all/conandata.yml b/recipes/libdwarf/all/conandata.yml index 75d6fc5547c895..45a483876642a7 100644 --- a/recipes/libdwarf/all/conandata.yml +++ b/recipes/libdwarf/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.7.0": + url: "https://www.prevanders.net/libdwarf-0.7.0.tar.xz" + sha256: "23b71829de875fa5842e49f232c8ee1a5043805749738bc61424d9abc1189f38" "0.5.0": url: "https://www.prevanders.net/libdwarf-0.5.0.tar.xz" sha256: "11fa822c60317fa00e1a01a2ac9e8388f6693e8662ab72d352c5f50c7e0112a9" @@ -6,6 +9,13 @@ sources: url: "https://www.prevanders.net/libdwarf-20191104.tar.gz" sha256: "45f50a966314421b7dab525859853616df6c9680f0ccf2f44b030c505236eaba" patches: + "0.7.0": + - patch_file: "patches/0.7.0-0001-fix-cmake.patch" + patch_description: "use cci package, remove lib64/bin64 install folders" + patch_type: "conan" + - patch_file: "patches/0.5.0-0001-fix-DW_API.patch" + patch_description: "fix DW_API definition" + patch_type: "portability" "0.5.0": - patch_file: "patches/0.5.0-0001-fix-cmake.patch" patch_description: "use cci package, remove lib64/bin64 install folders" diff --git a/recipes/libdwarf/all/conanfile.py b/recipes/libdwarf/all/conanfile.py index aa284382df444c..0149255b7e4f03 100644 --- a/recipes/libdwarf/all/conanfile.py +++ b/recipes/libdwarf/all/conanfile.py @@ -47,7 +47,8 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libelf/0.8.13") + if self.options.with_dwarfgen or self.version == "20191104": + self.requires("libelf/0.8.13") self.requires("zlib/[>=1.2.11 <2]") def source(self): @@ -104,4 +105,4 @@ def package_info(self): self.env_info.PATH.append(bindir) if self.version != "20191104": - self.cpp_info.libs.append = ["dwarfp"] + self.cpp_info.libs.append("dwarfp") diff --git a/recipes/libdwarf/all/patches/0.5.0-0001-fix-cmake.patch b/recipes/libdwarf/all/patches/0.5.0-0001-fix-cmake.patch index fce5a0373f748e..cd8664d42f3dc9 100644 --- a/recipes/libdwarf/all/patches/0.5.0-0001-fix-cmake.patch +++ b/recipes/libdwarf/all/patches/0.5.0-0001-fix-cmake.patch @@ -6,7 +6,7 @@ index 4f58f43..69e0238 100644 ### cmake provides no way to guarantee uint32_t present. ### configure does guarantee that. -+find_package(libelf REQUIRED) ++find_package(libelf) if(HAVE_STDINT_H) check_c_source_compiles(" #include @@ -103,3 +103,13 @@ index 0b7d578..62b67da 100644 set(LIBDIR lib${SUFFIX}) set(BINDIR bin${SUFFIX}) +@@ -119,6 +121,9 @@ install( + ) + install(DIRECTORY libdwarf DESTINATION include/ + FILES_MATCHING PATTERN "*.h") ++install( ++ FILES ${CMAKE_CURRENT_SOURCE_DIR}/dwarf.h ++ DESTINATION include/libdwarf) + install( + FILES ${CMAKE_CURRENT_SOURCE_DIR}/libdwarf.h + DESTINATION include/libdwarf) diff --git a/recipes/libdwarf/all/patches/0.7.0-0001-fix-cmake.patch b/recipes/libdwarf/all/patches/0.7.0-0001-fix-cmake.patch new file mode 100644 index 00000000000000..bb0a859d8fd823 --- /dev/null +++ b/recipes/libdwarf/all/patches/0.7.0-0001-fix-cmake.patch @@ -0,0 +1,128 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index dd09dde8..8162a985 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -129,6 +129,9 @@ check_include_file( "libelf/libelf.h" HAVE_LIBELF_LIBELF_H) + + ### cmake provides no way to guarantee uint32_t present. + ### configure does guarantee that. ++if (BUILD_DWARFGEN) ++ find_package(libelf REQUIRED) ++endif() + if(HAVE_STDINT_H) + check_c_source_compiles(" + #include +@@ -192,7 +195,8 @@ elseif(HAVE_LIBELF_LIBELF_H) + endif() + + if (HAVE_LIBELF_H OR HAVE_LIBELF_LIBELF_H) +- set (CMAKE_REQUIRED_LIBRARIES elf) ++ set (CMAKE_REQUIRED_LIBRARIES libelf::libelf) ++ set (CMAKE_REQUIRED_DEFINITIONS -D__LIBELF64=1) + message(STATUS "libelf header ${PLAIN_JUST_LIBELF} checking for elf64_getehdr") + check_symbol_exists( elf64_getehdr ${PLAIN_JUST_LIBELF} HAVE_ELF64_GETEHDR) + message(STATUS "libelf header ${PLAIN_JUST_LIBELF} checking for elf64_getshdr") +@@ -216,6 +220,9 @@ if (DWARF_WITH_LIBELF) + message(STATUS "checking using elf header ... ${HAVE_LOCATION_OF_LIBELFHEADER}") + message(STATUS "checking using libelf header ... ${JUST_LIBELF}") + ++set (CMAKE_REQUIRED_LIBRARIES libelf::libelf) ++set (CMAKE_REQUIRED_DEFINITIONS -D__LIBELF64=1) ++ + check_c_source_compiles(" + #include ${HAVE_LOCATION_OF_LIBELFHEADER} + int main() +@@ -361,7 +368,6 @@ message(STATUS "Building api tests ... ${DOTESTS}") + ### end what was configure.cmake + + # This references cmake/FindLibElf.cmake. See cmake documentation. +-find_package(LibElf REQUIRED) + list(APPEND CMAKE_REQUIRED_INCLUDES ${LIBELF_INCLUDE_DIRS}) + + configure_file(cmake/config.h.cmake config.h) +@@ -384,7 +390,6 @@ if(BUILD_SHARED) + endif() + + add_subdirectory(src/lib/libdwarf) +-add_subdirectory(src/bin/dwarfdump) + + if ( BUILD_DWARFEXAMPLE ) + add_subdirectory(src/bin/dwarfexample) +diff --git a/src/bin/dwarfdump/CMakeLists.txt b/src/bin/dwarfdump/CMakeLists.txt +index 507f761d..8ddb0d90 100644 +--- a/src/bin/dwarfdump/CMakeLists.txt ++++ b/src/bin/dwarfdump/CMakeLists.txt +@@ -64,7 +64,7 @@ target_compile_options(dwarfdump PRIVATE ${DW_FWALL}) + + target_link_libraries(dwarfdump PRIVATE ${dwarf-target} ${DW_FZLIB} ${DW_FZSTD} ) + +-if(${CMAKE_SIZEOF_VOID_P} EQUAL 8) ++if(0) + set(SUFFIX 64) + endif() + set(LIBDIR lib${SUFFIX}) +diff --git a/src/bin/dwarfgen/CMakeLists.txt b/src/bin/dwarfgen/CMakeLists.txt +index a7f5d78e..60293f6b 100644 +--- a/src/bin/dwarfgen/CMakeLists.txt ++++ b/src/bin/dwarfgen/CMakeLists.txt +@@ -28,7 +28,7 @@ target_include_directories(dwarfgen PRIVATE + ${CMAKE_CURRENT_SOURCE_DIR}/../../lib/libdwarfp) + + target_link_libraries(dwarfgen PRIVATE ${dwarfp-target} +- ${dwarf-target} ${DW_FZLIB}) ++ ${dwarf-target} ${DW_FZLIB} libelf::libelf) + + set(SUFFIX $<$:64>) + set(LIBDIR lib${SUFFIX}) +diff --git a/src/lib/libdwarf/CMakeLists.txt b/src/lib/libdwarf/CMakeLists.txt +index 913274b8..8515e2b0 100644 +--- a/src/lib/libdwarf/CMakeLists.txt ++++ b/src/lib/libdwarf/CMakeLists.txt +@@ -70,7 +70,7 @@ set_source_group(CONFIGURATION_FILES "Configuration Files" + + list(LENGTH DWARF_TARGETS targetCount) + math(EXPR targetCount "${targetCount} - 1") +-list(APPEND DWARF_LIBS ${LIBELF_LIBRARIES}) ++list(APPEND DWARF_LIBS ${libelf_LIBRARIES}) + if (DW_FZLIB) + list(APPEND DWARF_LIBS z) + endif() +@@ -88,13 +88,15 @@ foreach(i RANGE ${targetCount}) + ${LIBELF_INCLUDE_DIRS}) + target_compile_options(${target} PRIVATE -DLIBDWARF_BUILD + ${DW_FWALL}) +- msvc_posix(${target}) ++ if(BUILD_SHARED) ++ target_compile_definitions(${target} PRIVATE LIBDWARF_SHARED) ++ endif() ++ msvc_posix(${target}) + + target_link_libraries(${target} PUBLIC ${LIBELF_LIBRARIES} ${DW_FZLIB} ${DW_FZSTD} ) + + set_target_properties(${target} PROPERTIES OUTPUT_NAME dwarf) + +- set(SUFFIX $<$:64>) + set(LIBDIR lib${SUFFIX}) + set(BINDIR bin${SUFFIX}) + +@@ -105,7 +107,6 @@ foreach(i RANGE ${targetCount}) + endforeach() + + # add_library(libdwarf) +-configure_file(libdwarf.pc.cmake libdwarf.pc @ONLY ) + + # The install has to be here, not in + # another CMakeLists.txt to make install work properly +@@ -126,9 +127,9 @@ install( + ) + install(DIRECTORY libdwarf DESTINATION include/ + FILES_MATCHING PATTERN "*.h") ++install( ++ FILES ${CMAKE_CURRENT_SOURCE_DIR}/dwarf.h ++ DESTINATION include/libdwarf) + install( + FILES ${CMAKE_CURRENT_SOURCE_DIR}/libdwarf.h + DESTINATION include/libdwarf) +-install( FILES ${PROJECT_BINARY_DIR}/src/lib/libdwarf/libdwarf.pc +- DESTINATION lib/pkgconfig +-) diff --git a/recipes/libdwarf/all/test_package/test_package.c b/recipes/libdwarf/all/test_package/test_package.c index 33cfec6d8bf917..27d0d196b5a8d4 100644 --- a/recipes/libdwarf/all/test_package/test_package.c +++ b/recipes/libdwarf/all/test_package/test_package.c @@ -7,6 +7,7 @@ #include "dwarf.h" #include "libdwarf.h" #else + #include "libdwarf/dwarf.h" #include "libdwarf/libdwarf.h" #endif @@ -20,6 +21,8 @@ void example1(Dwarf_Die somedie) { errv = dwarf_attrlist(somedie, &atlist, &atcount, &error); if (errv == DW_DLV_OK) { for (i = 0; i < atcount; ++i) { + Dwarf_Bool is_string; + dwarf_hasform(atlist[i], DW_FORM_string, &is_string, &error); dwarf_dealloc(dbg, atlist[i], DW_DLA_ATTR); } dwarf_dealloc(dbg, atlist, DW_DLA_LIST); diff --git a/recipes/libdwarf/config.yml b/recipes/libdwarf/config.yml index aa4d403dacd897..9d902d9eff5205 100644 --- a/recipes/libdwarf/config.yml +++ b/recipes/libdwarf/config.yml @@ -1,4 +1,6 @@ versions: + "0.7.0": + folder: all "0.5.0": folder: all "20191104": From 5e09f0a600cab2b2611d577bcc42009928118ad5 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 5 Oct 2023 02:33:44 +0200 Subject: [PATCH 0958/1140] (#19649) harfbuzz: remove unused versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * harfbuzz: remove unused versions * Add 7.3.0 back to keep one minor version from 7 --------- Co-authored-by: Rubén Rincón Blanco --- recipes/harfbuzz/all/conandata.yml | 26 ----- recipes/harfbuzz/all/conanfile.py | 5 +- .../0000-fix-freetype-lookup-4.4.1.patch | 99 ------------------- recipes/harfbuzz/config.yml | 14 --- 4 files changed, 2 insertions(+), 142 deletions(-) delete mode 100644 recipes/harfbuzz/all/patches/0000-fix-freetype-lookup-4.4.1.patch diff --git a/recipes/harfbuzz/all/conandata.yml b/recipes/harfbuzz/all/conandata.yml index 779ff0fde3b71c..d7feed1d663dde 100644 --- a/recipes/harfbuzz/all/conandata.yml +++ b/recipes/harfbuzz/all/conandata.yml @@ -8,44 +8,18 @@ sources: "8.0.1": url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.0.1/harfbuzz-8.0.1.tar.xz" sha256: "c1ce780acd385569f25b9a29603d1d5bc71e6940e55bfdd4f7266fad50e42620" - "8.0.0": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/8.0.0/harfbuzz-8.0.0.tar.xz" - sha256: "1f98b5e3d06a344fe667d7e8210094ced458791499839bddde98c167ce6a7c79" "7.3.0": url: "https://github.com/harfbuzz/harfbuzz/releases/download/7.3.0/harfbuzz-7.3.0.tar.xz" sha256: "20770789749ac9ba846df33983dbda22db836c70d9f5d050cb9aa5347094a8fb" - "7.1.0": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/7.1.0/harfbuzz-7.1.0.tar.xz" - sha256: "f135a61cd464c9ed6bc9823764c188f276c3850a8dc904628de2a87966b7077b" "6.0.0": url: "https://github.com/harfbuzz/harfbuzz/releases/download/6.0.0/harfbuzz-6.0.0.tar.xz" sha256: "1d1010a1751d076d5291e433c138502a794d679a7498d1268ee21e2d4a140eb4" - "5.3.1": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/5.3.1/harfbuzz-5.3.1.tar.xz" - sha256: "4a6ce097b75a8121facc4ba83b5b083bfec657f45b003cd5a3424f2ae6b4434d" - "5.3.0": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/5.3.0/harfbuzz-5.3.0.tar.xz" - sha256: "a05e19e3f52da24ed071522f0fddf872157d7d25e869cfd156cd6f1e81c42152" - "5.2.0": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/5.2.0/harfbuzz-5.2.0.tar.xz" - sha256: "735a94917b47936575acb4d4fa7e7986522f8a89527e4635721474dee2bc942c" "5.1.0": url: "https://github.com/harfbuzz/harfbuzz/releases/download/5.1.0/harfbuzz-5.1.0.tar.xz" sha256: "2edb95db668781aaa8d60959d21be2ff80085f31b12053cdd660d9a50ce84f05" - "4.4.1": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/4.4.1/harfbuzz-4.4.1.tar.xz" - sha256: "c5bc33ac099b2e52f01d27cde21cee4281b9d5bfec7684135e268512478bc9ee" - "3.2.0": - url: "https://github.com/harfbuzz/harfbuzz/releases/download/3.2.0/harfbuzz-3.2.0.tar.xz" - sha256: "0ada50a1c199bb6f70843ab893c55867743a443b84d087d54df08ad883ebc2cd" patches: "5.1.0": - patch_file: "patches/0000-fix-freetype-lookup-5.1.0.patch" patch_type: "portability" patch_description: "fix fretype and icu dependency lookup" patch_source: "https://github.com/harfbuzz/harfbuzz/pull/3811" - "4.4.1": - - patch_file: "patches/0000-fix-freetype-lookup-4.4.1.patch" - patch_type: "portability" - patch_description: "fix fretype and icu dependency lookup" - patch_source: "https://github.com/harfbuzz/harfbuzz/pull/3811" diff --git a/recipes/harfbuzz/all/conanfile.py b/recipes/harfbuzz/all/conanfile.py index ce1aa84efb199e..5aba73dab807f9 100644 --- a/recipes/harfbuzz/all/conanfile.py +++ b/recipes/harfbuzz/all/conanfile.py @@ -87,9 +87,8 @@ def validate(self): raise ConanInvalidConfiguration( "Linking a shared library against static glib can cause unexpected behaviour." ) - if Version(self.version) >= "4.4.0": - if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "7": - raise ConanInvalidConfiguration("New versions of harfbuzz require at least gcc 7") + if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "7": + raise ConanInvalidConfiguration("New versions of harfbuzz require at least gcc 7") if self.options.with_glib and self.dependencies["glib"].options.shared and is_msvc_static_runtime(self): raise ConanInvalidConfiguration( diff --git a/recipes/harfbuzz/all/patches/0000-fix-freetype-lookup-4.4.1.patch b/recipes/harfbuzz/all/patches/0000-fix-freetype-lookup-4.4.1.patch deleted file mode 100644 index 708b5d9734b00b..00000000000000 --- a/recipes/harfbuzz/all/patches/0000-fix-freetype-lookup-4.4.1.patch +++ /dev/null @@ -1,99 +0,0 @@ -diff --git a/meson.build b/meson.build -index 4a69d6d9e..a82ff598c 100644 ---- a/meson.build -+++ b/meson.build -@@ -21,7 +21,7 @@ pkgmod = import('pkgconfig') - cpp = meson.get_compiler('cpp') - null_dep = dependency('', required: false) - --if cpp.get_id() == 'msvc' -+if cpp.get_argument_syntax() == 'msvc' - # Ignore several spurious warnings for things HarfBuzz does very commonly. - # If a warning is completely useless and spammy, use '/wdXXXX' to suppress it - # If a warning is harmless but hard to fix, use '/woXXXX' so it's shown once -@@ -83,25 +83,39 @@ check_funcs = [ - - m_dep = cpp.find_library('m', required: false) - --# https://github.com/harfbuzz/harfbuzz/pull/2498 --freetype_dep = dependency(cpp.get_argument_syntax() == 'msvc' ? 'freetype' : 'freetype2', -- required: get_option('freetype'), -- default_options: ['harfbuzz=disabled']) -+ -+# Try pkgconfig name -+freetype_dep = dependency('freetype2', required: false) -+if not freetype_dep.found() -+ # Try cmake name -+ freetype_dep = dependency('freetype', required: false) -+endif -+if not freetype_dep.found() -+ # Subproject fallback, `allow_fallback: true` means the fallback will be -+ # tried even if the freetype option is set to `auto`. -+ freetype_dep = dependency('freetype2', -+ required: get_option('freetype'), -+ default_options: ['harfbuzz=disabled'], -+ allow_fallback: true) -+endif - - glib_dep = dependency('glib-2.0', required: get_option('glib')) - gobject_dep = dependency('gobject-2.0', required: get_option('gobject')) - graphite2_dep = dependency('graphite2', required: get_option('graphite2')) - graphite_dep = dependency('graphite2', required: get_option('graphite')) - --if cpp.get_argument_syntax() == 'msvc' -+# Try pkgconfig name -+icu_dep = dependency('icu-uc', required: false) -+if not icu_dep.found() -+ # Try cmake name - icu_dep = dependency('ICU', -- required: get_option('icu'), -+ required: false, - components: 'uc', - method: 'cmake') --else -- icu_dep = dependency('icu-uc', -- required: get_option('icu'), -- method: 'pkg-config') -+endif -+if not icu_dep.found() -+ # Subproject fallback if icu option is enabled -+ icu_dep = dependency('icu-uc', required: get_option('icu')) - endif - - if icu_dep.found() and icu_dep.type_name() == 'pkgconfig' -@@ -118,7 +132,7 @@ if not get_option('cairo').disabled() - cairo_ft_dep = dependency('cairo-ft', required: false) - - if (not cairo_dep.found() and -- cpp.get_id() == 'msvc' and -+ cpp.get_argument_syntax() == 'msvc' and - cpp.has_header('cairo.h')) - cairo_dep = cpp.find_library('cairo', required: false) - if cairo_dep.found() and cpp.has_function('cairo_ft_font_face_create_for_ft_face', -@@ -198,6 +212,7 @@ if freetype_dep.found() - ['FT_Get_Var_Blend_Coordinates', {'deps': freetype_dep}], - ['FT_Set_Var_Blend_Coordinates', {'deps': freetype_dep}], - ['FT_Done_MM_Var', {'deps': freetype_dep}], -+ ['FT_Get_Transform', {'deps': freetype_dep}], - ] - - if freetype_dep.type_name() == 'internal' -@@ -232,17 +247,12 @@ if host_machine.system() == 'windows' and not get_option('gdi').disabled() - endif - - # DirectWrite (Windows) --directwrite_dep = null_dep - if host_machine.system() == 'windows' and not get_option('directwrite').disabled() - if get_option('directwrite').enabled() and not cpp.has_header('dwrite_1.h') - error('DirectWrite was enabled explicitly, but required header is missing.') - endif - -- directwrite_dep = cpp.find_library('dwrite', required: get_option('directwrite')) -- -- if directwrite_dep.found() -- conf.set('HAVE_DIRECTWRITE', 1) -- endif -+ conf.set('HAVE_DIRECTWRITE', 1) - endif - - # CoreText (macOS) diff --git a/recipes/harfbuzz/config.yml b/recipes/harfbuzz/config.yml index bff626c84bf864..5cf33eaf299d06 100644 --- a/recipes/harfbuzz/config.yml +++ b/recipes/harfbuzz/config.yml @@ -5,23 +5,9 @@ versions: folder: all "8.0.1": folder: all - "8.0.0": - folder: all "7.3.0": folder: all - "7.1.0": - folder: all "6.0.0": folder: all - "5.3.1": - folder: all - "5.3.0": - folder: all - "5.2.0": - folder: all "5.1.0": folder: all - "4.4.1": - folder: all - "3.2.0": - folder: all From 37b81df453bbfcc06d23c94b8c8d764502d1b69e Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Wed, 4 Oct 2023 20:33:38 -0500 Subject: [PATCH 0959/1140] (#20320) mtdev: Add recipe * mtdev: Add recipe * Update recipes/mtdev/all/conanfile.py Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> * Update recipes/mtdev/all/conanfile.py Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> * Update recipes/mtdev/all/conanfile.py Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/mtdev/all/conandata.yml | 4 ++ recipes/mtdev/all/conanfile.py | 63 +++++++++++++++++++ recipes/mtdev/all/test_package/CMakeLists.txt | 7 +++ recipes/mtdev/all/test_package/conanfile.py | 26 ++++++++ recipes/mtdev/all/test_package/test_package.c | 8 +++ recipes/mtdev/config.yml | 3 + 6 files changed, 111 insertions(+) create mode 100644 recipes/mtdev/all/conandata.yml create mode 100644 recipes/mtdev/all/conanfile.py create mode 100644 recipes/mtdev/all/test_package/CMakeLists.txt create mode 100644 recipes/mtdev/all/test_package/conanfile.py create mode 100644 recipes/mtdev/all/test_package/test_package.c create mode 100644 recipes/mtdev/config.yml diff --git a/recipes/mtdev/all/conandata.yml b/recipes/mtdev/all/conandata.yml new file mode 100644 index 00000000000000..62fe05ee3b5180 --- /dev/null +++ b/recipes/mtdev/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.1.6": + url: "https://bitmath.org/code/mtdev/mtdev-1.1.6.tar.gz" + sha256: "1325f389a2f25cd5f5a8ea4d29aad24aa7c3ec30401d679400dd79eb9c0a8dbb" diff --git a/recipes/mtdev/all/conanfile.py b/recipes/mtdev/all/conanfile.py new file mode 100644 index 00000000000000..14422989518f0d --- /dev/null +++ b/recipes/mtdev/all/conanfile.py @@ -0,0 +1,63 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get, rm, rmdir +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +import os + + +required_conan_version = ">=1.54.0" + + +class MtdevConan(ConanFile): + name = "mtdev" + description = "The mtdev library transforms all variants of kernel MT events to the slotted type B protocol." + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://bitmath.org/code/mtdev/" + topics = ("device", "freedesktop", "input", "mt", "multitouch", "touch") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + basic_layout(self, src_folder="src") + + def validate(self): + if self.settings.os not in ["Linux", "FreeBSD"]: + raise ConanInvalidConfiguration(f"{self.ref} is not supported on {self.settings.os}.") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = AutotoolsToolchain(self) + tc.generate() + + def build(self): + autotools = Autotools(self) + autotools.configure() + autotools.make() + + def package(self): + copy(self, "COPYING", self.source_folder, os.path.join(self.package_folder, "licenses")) + autotools = Autotools(self) + autotools.install() + rm(self, "*.la", os.path.join(self.package_folder, "lib")) + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + self.cpp_info.libs = ["mtdev"] diff --git a/recipes/mtdev/all/test_package/CMakeLists.txt b/recipes/mtdev/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..bfa4f8ba62c05c --- /dev/null +++ b/recipes/mtdev/all/test_package/CMakeLists.txt @@ -0,0 +1,7 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) + +find_package(mtdev REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.c) +target_link_libraries(${PROJECT_NAME} PRIVATE mtdev::mtdev) diff --git a/recipes/mtdev/all/test_package/conanfile.py b/recipes/mtdev/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/mtdev/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/mtdev/all/test_package/test_package.c b/recipes/mtdev/all/test_package/test_package.c new file mode 100644 index 00000000000000..8cce2788bfac4a --- /dev/null +++ b/recipes/mtdev/all/test_package/test_package.c @@ -0,0 +1,8 @@ +#include +#include "mtdev.h" + + +int main(void) { + mtdev_close(NULL); + return EXIT_SUCCESS; +} diff --git a/recipes/mtdev/config.yml b/recipes/mtdev/config.yml new file mode 100644 index 00000000000000..42b92d9f27e7f9 --- /dev/null +++ b/recipes/mtdev/config.yml @@ -0,0 +1,3 @@ +versions: + "1.1.6": + folder: all From 24adb50ef8df782b49c2a5074bfb3899856dd05e Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 5 Oct 2023 04:12:22 +0200 Subject: [PATCH 0960/1140] (#20331) playrho: cleanup recipe in order to remove unnecessay/misleading logic --- recipes/playrho/all/conandata.yml | 1 - recipes/playrho/all/conanfile.py | 29 +++++++++++------------------ 2 files changed, 11 insertions(+), 19 deletions(-) diff --git a/recipes/playrho/all/conandata.yml b/recipes/playrho/all/conandata.yml index 9c08727b484840..df36531f2762c4 100644 --- a/recipes/playrho/all/conandata.yml +++ b/recipes/playrho/all/conandata.yml @@ -2,7 +2,6 @@ sources: "1.1.0": url: "https://github.com/louis-langholtz/PlayRho/archive/refs/tags/v1.1.0.tar.gz" sha256: "45c0337440387a85a97a4b7907b79f780233bf2062635471b71a32245b0c0158" - patches: "1.1.0": - patch_file: "patches/1.1.0-0001-fix-target-name.patch" diff --git a/recipes/playrho/all/conanfile.py b/recipes/playrho/all/conanfile.py index b2457aa21b0743..619e24882a4630 100644 --- a/recipes/playrho/all/conanfile.py +++ b/recipes/playrho/all/conanfile.py @@ -3,7 +3,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir, rename from conan.tools.scm import Version @@ -29,6 +29,10 @@ class PlayrhoConan(ConanFile): "fPIC": True, } + @property + def _min_cppstd(self): + return "17" + @property def _compilers_minimum_versions(self): return { @@ -55,18 +59,12 @@ def layout(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, 17) - - compilers_minimum_version = self._compilers_minimum_versions - minimum_version = compilers_minimum_version.get(str(self.settings.compiler), False) - if minimum_version: - if Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration( - f"{self.name} requires C++17, which your compiler does not support." - ) - else: - self.output.warning( - f"{self.name} requires C++17. Your compiler is unknown. Assuming it supports C++17." + check_min_cppstd(self, self._min_cppstd) + + minimum_version = self._compilers_minimum_versions.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): @@ -80,9 +78,6 @@ def generate(self): tc.variables["PLAYRHO_INSTALL"] = True tc.generate() - tc = CMakeDeps(self) - tc.generate() - def build(self): apply_conandata_patches(self) cmake = CMake(self) @@ -97,8 +92,6 @@ def package(self): cmake.install() rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) rmdir(self, os.path.join(self.package_folder, "lib", "PlayRho")) - for dll in (self.package_path / "lib").glob("*.dll"): - rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.libs = ["PlayRho"] From f067ed55b82faefa0845326d5b0ba1107ed4580d Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 5 Oct 2023 05:52:37 +0300 Subject: [PATCH 0961/1140] (#20340) libb2: fix install() in CMakeLists.txt --- recipes/libb2/all/CMakeLists.txt | 3 +++ recipes/libb2/all/conanfile.py | 4 +--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes/libb2/all/CMakeLists.txt b/recipes/libb2/all/CMakeLists.txt index ff47fce826321a..9834b369a4d4be 100644 --- a/recipes/libb2/all/CMakeLists.txt +++ b/recipes/libb2/all/CMakeLists.txt @@ -41,4 +41,7 @@ set_target_properties(${CMAKE_PROJECT_NAME} PROPERTIES PUBLIC_HEADER ${src}/ref/ include(GNUInstallDirs) install(TARGETS ${CMAKE_PROJECT_NAME} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/libb2) diff --git a/recipes/libb2/all/conanfile.py b/recipes/libb2/all/conanfile.py index faf2474da04c45..ffc67ff6345fe6 100644 --- a/recipes/libb2/all/conanfile.py +++ b/recipes/libb2/all/conanfile.py @@ -4,7 +4,7 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, rename +from conan.tools.files import copy, get required_conan_version = ">=1.53.0" @@ -77,8 +77,6 @@ def package(self): copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) cmake = CMake(self) cmake.install() - for dll in (self.package_path / "lib").glob("*.dll"): - rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.libs = ["b2"] From 8dc3c4b73a9d45b86fe37a993eb1ac7fc40e508f Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 5 Oct 2023 06:32:10 +0300 Subject: [PATCH 0962/1140] (#20341) qdbm: fix install() in CMakeLists.txt --- recipes/qdbm/all/CMakeLists.txt | 7 +++++-- recipes/qdbm/all/conanfile.py | 4 +--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/recipes/qdbm/all/CMakeLists.txt b/recipes/qdbm/all/CMakeLists.txt index 1f080a697bce55..504c6e681a7127 100644 --- a/recipes/qdbm/all/CMakeLists.txt +++ b/recipes/qdbm/all/CMakeLists.txt @@ -60,8 +60,11 @@ set_target_properties( # ---- Install ---- include(GNUInstallDirs) - -install(TARGETS qdbm) +install(TARGETS qdbm + RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" + LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" + ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" +) install( FILES diff --git a/recipes/qdbm/all/conanfile.py b/recipes/qdbm/all/conanfile.py index 583704293b76fc..7de5afa132670e 100644 --- a/recipes/qdbm/all/conanfile.py +++ b/recipes/qdbm/all/conanfile.py @@ -2,7 +2,7 @@ from conan import ConanFile from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, rename +from conan.tools.files import copy, get required_conan_version = ">=1.53.0" @@ -77,8 +77,6 @@ def package(self): copy(self, "COPYING", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) cmake = CMake(self) cmake.install() - for dll in (self.package_path / "lib").glob("*.dll"): - rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.libs = ["qdbm"] From 91666717630b823b2dc4957944f2062af283093a Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 5 Oct 2023 07:01:14 +0300 Subject: [PATCH 0963/1140] (#20342) uchardet: fix unnecessary copying of DLLs --- recipes/uchardet/all/conanfile.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/uchardet/all/conanfile.py b/recipes/uchardet/all/conanfile.py index 6163692ad75f83..dc6c7c2cfb3273 100644 --- a/recipes/uchardet/all/conanfile.py +++ b/recipes/uchardet/all/conanfile.py @@ -3,7 +3,7 @@ from conan import ConanFile from conan.tools.apple import fix_apple_shared_install_name from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, replace_in_file, rmdir, rename +from conan.tools.files import copy, get, replace_in_file, rmdir required_conan_version = ">=1.53.0" @@ -100,8 +100,6 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "share")) fix_apple_shared_install_name(self) - for dll in (self.package_path / "lib").glob("*.dll"): - rename(self, dll, self.package_path / "bin" / dll.name) def package_info(self): self.cpp_info.set_property("pkg_config_name", "libuchardet") From 854292e05e9484e9dfe46d9911d8cb6315b7b929 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 5 Oct 2023 07:22:48 +0200 Subject: [PATCH 0964/1140] (#20157) libcurl: add GitHub mirror & prefer .tar.xz * add github mirror url and prefer .tar.xz tarballs * proper brolti find_package fix in libcurl >= 8.2.0 --- recipes/libcurl/all/conandata.yml | 90 ++++++++++++++++++++----------- recipes/libcurl/all/conanfile.py | 2 + 2 files changed, 62 insertions(+), 30 deletions(-) diff --git a/recipes/libcurl/all/conandata.yml b/recipes/libcurl/all/conandata.yml index e0c9dcbbb24845..df4b2442214e4a 100644 --- a/recipes/libcurl/all/conandata.yml +++ b/recipes/libcurl/all/conandata.yml @@ -1,46 +1,76 @@ sources: "8.2.1": - url: "https://curl.se/download/curl-8.2.1.tar.gz" - sha256: "f98bdb06c0f52bdd19e63c4a77b5eb19b243bcbbd0f5b002b9f3cba7295a3a42" + url: + - "https://curl.se/download/curl-8.2.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-8_2_1/curl-8.2.1.tar.xz" + sha256: "dd322f6bd0a20e6cebdfd388f69e98c3d183bed792cf4713c8a7ef498cba4894" "8.2.0": - url: "https://curl.se/download/curl-8.2.0.tar.gz" - sha256: "c67849462d171a3fee08b605cdd837d18ee22ecc3ee2c6a0393c9cec5d1a137e" + url: + - "https://curl.se/download/curl-8.2.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-8_2_0/curl-8.2.0.tar.xz" + sha256: "2859ec79e2cd96e976a99493547359b8001af1d1e21f3a3a3b846544ef54500f" "8.1.2": - url: "https://curl.se/download/curl-8.1.2.tar.gz" - sha256: "2e5a9b8fcdc095bdd2f079561f369de71c5eb3b80f00a702fbe9a8b8d9897891" + url: + - "https://curl.se/download/curl-8.1.2.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-8_1_2/curl-8.1.2.tar.xz" + sha256: "31b1118eb8bfd43cd95d9a3f146f814ff874f6ed3999b29d94f4d1e7dbac5ef6" "8.1.1": - url: "https://curl.se/download/curl-8.1.1.tar.gz" - sha256: "44915e6708551bff2b4fd1615d593bc843b00ba013012634c04208702e354ab2" + url: + - "https://curl.se/download/curl-8.1.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-8_1_1/curl-8.1.1.tar.xz" + sha256: "08a948e061929645597c1ef7194e07b308b22084ff03fa7400b465e6c05149e5" "8.0.1": - url: "https://curl.se/download/curl-8.0.1.tar.gz" - sha256: "5fd29000a4089934f121eff456101f0a5d09e2a3e89da1d714adf06c4be887cb" + url: + - "https://curl.se/download/curl-8.0.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-8_0_1/curl-8.0.1.tar.xz" + sha256: "0a381cd82f4d00a9a334438b8ca239afea5bfefcfa9a1025f2bf118e79e0b5f0" "7.88.1": - url: "https://curl.se/download/curl-7.88.1.tar.gz" - sha256: "cdb38b72e36bc5d33d5b8810f8018ece1baa29a8f215b4495e495ded82bbf3c7" + url: + - "https://curl.se/download/curl-7.88.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_88_1/curl-7.88.1.tar.xz" + sha256: "1dae31b2a7c1fe269de99c0c31bb488346aab3459b5ffca909d6938249ae415f" "7.87.0": - url: "https://curl.se/download/curl-7.87.0.tar.gz" - sha256: "8a063d664d1c23d35526b87a2bf15514962ffdd8ef7fd40519191b3c23e39548" + url: + - "https://curl.se/download/curl-7.87.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_87_0/curl-7.87.0.tar.xz" + sha256: "ee5f1a1955b0ed413435ef79db28b834ea5f0fb7c8cfb1ce47175cc3bee08fff" "7.86.0": - url: "https://curl.se/download/curl-7.86.0.tar.gz" - sha256: "3dfdd39ba95e18847965cd3051ea6d22586609d9011d91df7bc5521288987a82" + url: + - "https://curl.se/download/curl-7.86.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_86_0/curl-7.86.0.tar.xz" + sha256: "2d61116e5f485581f6d59865377df4463f2e788677ac43222b496d4e49fb627b" "7.85.0": - url: "https://curl.se/download/curl-7.85.0.tar.gz" - sha256: "78a06f918bd5fde3c4573ef4f9806f56372b32ec1829c9ec474799eeee641c27" + url: + - "https://curl.se/download/curl-7.85.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_85_0/curl-7.85.0.tar.xz" + sha256: "88b54a6d4b9a48cb4d873c7056dcba997ddd5b7be5a2d537a4acb55c20b04be6" "7.84.0": - url: "https://curl.se/download/curl-7.84.0.tar.gz" - sha256: "3c6893d38d054d4e378267166858698899e9d87258e8ff1419d020c395384535" + url: + - "https://curl.se/download/curl-7.84.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_84_0/curl-7.84.0.tar.xz" + sha256: "2d118b43f547bfe5bae806d8d47b4e596ea5b25a6c1f080aef49fbcd817c5db8" "7.83.1": - url: "https://curl.se/download/curl-7.83.1.tar.gz" - sha256: "93fb2cd4b880656b4e8589c912a9fd092750166d555166370247f09d18f5d0c0" + url: + - "https://curl.se/download/curl-7.83.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_83_1/curl-7.83.1.tar.xz" + sha256: "2cb9c2356e7263a1272fd1435ef7cdebf2cd21400ec287b068396deb705c22c4" "7.82.0": - url: "https://curl.se/download/curl-7.82.0.tar.gz" - sha256: "910cc5fe279dc36e2cca534172c94364cf3fcf7d6494ba56e6c61a390881ddce" + url: + - "https://curl.se/download/curl-7.82.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_82_0/curl-7.82.0.tar.xz" + sha256: "0aaa12d7bd04b0966254f2703ce80dd5c38dbbd76af0297d3d690cdce58a583c" "7.80.0": - url: "https://curl.se/download/curl-7.80.0.tar.gz" - sha256: "dab997c9b08cb4a636a03f2f7f985eaba33279c1c52692430018fae4a4878dc7" + url: + - "https://curl.se/download/curl-7.80.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_80_0/curl-7.80.0.tar.xz" + sha256: "a132bd93188b938771135ac7c1f3ac1d3ce507c1fcbef8c471397639214ae2ab" "7.79.1": - url: "https://curl.se/download/curl-7.79.1.tar.gz" - sha256: "370b11201349816287fb0ccc995e420277fbfcaf76206e309b3f60f0eda090c2" + url: + - "https://curl.se/download/curl-7.79.1.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_79_1/curl-7.79.1.tar.xz" + sha256: "0606f74b1182ab732a17c11613cbbaf7084f2e6cca432642d0e3ad7c224c3689" "7.78.0": - url: "https://curl.se/download/curl-7.78.0.tar.gz" - sha256: "ed936c0b02c06d42cf84b39dd12bb14b62d77c7c4e875ade022280df5dcc81d7" + url: + - "https://curl.se/download/curl-7.78.0.tar.xz" + - "https://github.com/curl/curl/releases/download/curl-7_78_0/curl-7.78.0.tar.xz" + sha256: "be42766d5664a739c3974ee3dfbbcbe978a4ccb1fe628bb1d9b59ac79e445fb5" diff --git a/recipes/libcurl/all/conanfile.py b/recipes/libcurl/all/conanfile.py index 1496108f12e8d4..2d7615fa135409 100644 --- a/recipes/libcurl/all/conanfile.py +++ b/recipes/libcurl/all/conanfile.py @@ -336,6 +336,8 @@ def _patch_cmake(self): # brotli if Version(self.version) < "8.2.0": replace_in_file(self, cmakelists, "find_package(Brotli QUIET)", "find_package(brotli REQUIRED CONFIG)") + else: + replace_in_file(self, cmakelists, "find_package(Brotli REQUIRED)", "find_package(brotli REQUIRED CONFIG)") replace_in_file(self, cmakelists, "if(BROTLI_FOUND)", "if(brotli_FOUND)") replace_in_file(self, cmakelists, "${BROTLI_LIBRARIES}", "brotli::brotli") replace_in_file(self, cmakelists, "${BROTLI_INCLUDE_DIRS}", "${brotli_INCLUDE_DIRS}") From cd35c913e510e487b00c1fa736cc78d4b4999a1e Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 5 Oct 2023 08:41:43 +0200 Subject: [PATCH 0965/1140] (#20074) nanodbc: no warnings as errors + bump deps + don't raise if apple-clang and nanodbc > 2.14.0 * several changes & fixes - disable warnings as errors - add required_conan_version - bump boost & odbc - don't raise for version > 2.14.0 if apple-clang - explicit CMake names since upstream export nanodbc::nanodbc target * sort version by desc order * minor change in test package * drop maintenance of cci.20200807 --- recipes/nanodbc/all/conandata.yml | 23 ++-------- recipes/nanodbc/all/conanfile.py | 46 +++++++++++-------- .../nanodbc/all/test_package/CMakeLists.txt | 2 +- recipes/nanodbc/all/test_package/conanfile.py | 1 + recipes/nanodbc/config.yml | 4 +- 5 files changed, 35 insertions(+), 41 deletions(-) diff --git a/recipes/nanodbc/all/conandata.yml b/recipes/nanodbc/all/conandata.yml index 7a0d0542f3be6a..c6835a8c270b4b 100644 --- a/recipes/nanodbc/all/conandata.yml +++ b/recipes/nanodbc/all/conandata.yml @@ -1,24 +1,18 @@ sources: - "cci.20200807": - url: "https://github.com/nanodbc/nanodbc/archive/ab8d176262f92d5f75aa2d441bfce27041032201.zip" - sha256: "9de057ae6e8d0b9192df1d16ccc70ce7525ca9fe52e56fa8d13cfae9206f8286" - "2.13.0": - url: "https://github.com/nanodbc/nanodbc/archive/v2.13.0.zip" - sha256: "1287869b6ca82728cb6cc53c54f836c72cde15370c16f32d81c9ef6c257f7e43" "2.14.0": url: "https://github.com/nanodbc/nanodbc/archive/v2.14.0.tar.gz" sha256: "56228372042b689beccd96b0ac3476643ea85b3f57b3f23fb11ca4314e68b9a5" + "2.13.0": + url: "https://github.com/nanodbc/nanodbc/archive/v2.13.0.zip" + sha256: "1287869b6ca82728cb6cc53c54f836c72cde15370c16f32d81c9ef6c257f7e43" patches: - "cci.20200807": + "2.14.0": - patch_file: "patches/0001-odbc-from-cci.patch" patch_description: "Allow compilation on CI with ODBC library" patch_type: "portability" - patch_file: "patches/0002-allow-windows-shared.patch" patch_description: "Allow windows to compile shared libraries" patch_type: "portability" - - patch_file: "patches/0003-add-missing-include.patch" - patch_description: "Add missing include to fix compilation for v2.13 and v20200807" - patch_type: "portability" "2.13.0": - patch_file: "patches/0001-odbc-from-cci.patch" patch_description: "Allow compilation on CI with ODBC library" @@ -27,12 +21,5 @@ patches: patch_description: "Allow windows to compile shared libraries" patch_type: "portability" - patch_file: "patches/0003-add-missing-include.patch" - patch_description: "Add missing include to fix compilation for v2.13 and v20200807" - patch_type: "portability" - "2.14.0": - - patch_file: "patches/0001-odbc-from-cci.patch" - patch_description: "Allow compilation on CI with ODBC library" - patch_type: "portability" - - patch_file: "patches/0002-allow-windows-shared.patch" - patch_description: "Allow windows to compile shared libraries" + patch_description: "Add missing include to fix compilation" patch_type: "portability" diff --git a/recipes/nanodbc/all/conanfile.py b/recipes/nanodbc/all/conanfile.py index e2bd806901885d..c0ece807489787 100644 --- a/recipes/nanodbc/all/conanfile.py +++ b/recipes/nanodbc/all/conanfile.py @@ -2,18 +2,21 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMakeToolchain, CMakeDeps, CMake, cmake_layout -from conan.tools.files import get, apply_conandata_patches, export_conandata_patches, rmdir, copy +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rmdir from conan.tools.scm import Version import os +required_conan_version = ">=1.53.0" + + class NanodbcConan(ConanFile): name = "nanodbc" description = "A small C++ wrapper for the native C ODBC API" - topics = ("conan", "nanodbc", "odbc", "database") + topics = ("odbc", "database") license = "MIT" homepage = "https://github.com/nanodbc/nanodbc/" - package_type = "library" url = "https://github.com/conan-io/conan-center-index" + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -30,25 +33,24 @@ class NanodbcConan(ConanFile): "with_boost": False, } + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - def export_sources(self): - export_conandata_patches(self) - - def layout(self): - cmake_layout(self, src_folder="src") - def configure(self): if self.options.shared: self.options.rm_safe("fPIC") + def layout(self): + cmake_layout(self, src_folder="src") + @property def _min_cppstd(self): return 14 - + @property def _compilers_minimum_version(self): return { @@ -59,6 +61,12 @@ def _compilers_minimum_version(self): "apple-clang": "9.1", # FIXME: this is a guess } + def requirements(self): + if self.options.with_boost: + self.requires("boost/1.83.0") + if self.settings.os != "Windows": + self.requires("odbc/2.3.11") + def validate(self): if self.settings.compiler.cppstd: check_min_cppstd(self, 14) @@ -69,18 +77,12 @@ def validate(self): f"{self.ref} requires C++{self._min_cppstd}, which your compiler does not support.", ) - if self.settings.compiler == "apple-clang" and Version(self.version) != "2.14.0": + if self.settings.compiler == "apple-clang" and Version(self.version) < "2.14.0": raise ConanInvalidConfiguration(""" `apple-clang` compilation is supported only for version 2.14.0 and up. See https://github.com/nanodbc/nanodbc/issues/274 for more details. """) - def requirements(self): - if self.options.with_boost: - self.requires("boost/1.76.0") - if self.settings.os != "Windows": - self.requires("odbc/2.3.9") - def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -95,13 +97,17 @@ def generate(self): tc.cache_variables["NANODBC_DISABLE_TESTS"] = True tc.cache_variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True tc.generate() - + deps = CMakeDeps(self) deps.generate() - def build(self): + def _patch_sources(self): apply_conandata_patches(self) + # No warnings as errors + replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), "-Werror", "") + def build(self): + self._patch_sources() cmake = CMake(self) cmake.configure() cmake.build() @@ -116,6 +122,8 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) def package_info(self): + self.cpp_info.set_property("cmake_file_name", "nanodbc") + self.cpp_info.set_property("cmake_target_name", "nanodbc::nanodbc") self.cpp_info.libs = ["nanodbc"] if not self.options.shared and self.settings.os == "Windows": diff --git a/recipes/nanodbc/all/test_package/CMakeLists.txt b/recipes/nanodbc/all/test_package/CMakeLists.txt index 2b2d9256562615..0f37b02603638f 100644 --- a/recipes/nanodbc/all/test_package/CMakeLists.txt +++ b/recipes/nanodbc/all/test_package/CMakeLists.txt @@ -5,4 +5,4 @@ find_package(nanodbc REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) target_link_libraries(${PROJECT_NAME} PRIVATE nanodbc::nanodbc) -set_property(TARGET ${PROJECT_NAME} PROPERTY CXX_STANDARD 14) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) diff --git a/recipes/nanodbc/all/test_package/conanfile.py b/recipes/nanodbc/all/test_package/conanfile.py index c1e9a5dd84db0a..9153dc938c4846 100644 --- a/recipes/nanodbc/all/test_package/conanfile.py +++ b/recipes/nanodbc/all/test_package/conanfile.py @@ -6,6 +6,7 @@ class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + test_type = "explicit" def layout(self): cmake_layout(self) diff --git a/recipes/nanodbc/config.yml b/recipes/nanodbc/config.yml index 35d045402c05f1..ccdd596aaff35a 100644 --- a/recipes/nanodbc/config.yml +++ b/recipes/nanodbc/config.yml @@ -1,7 +1,5 @@ versions: - "cci.20200807": + "2.14.0": folder: "all" "2.13.0": folder: "all" - "2.14.0": - folder: "all" From ba7ca5d0ba56fe05a72499ee7e8631d9ef8ea373 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Thu, 5 Oct 2023 02:07:45 -0500 Subject: [PATCH 0966/1140] (#20328) libliftoff: Add recipe * libliftoff: Add recipe * Disable werror --- recipes/libliftoff/all/conandata.yml | 4 + recipes/libliftoff/all/conanfile.py | 83 +++++++++++++++++++ .../libliftoff/all/test_package/conanfile.py | 32 +++++++ .../libliftoff/all/test_package/meson.build | 5 ++ .../all/test_package/test_package.c | 7 ++ recipes/libliftoff/config.yml | 3 + 6 files changed, 134 insertions(+) create mode 100644 recipes/libliftoff/all/conandata.yml create mode 100644 recipes/libliftoff/all/conanfile.py create mode 100644 recipes/libliftoff/all/test_package/conanfile.py create mode 100644 recipes/libliftoff/all/test_package/meson.build create mode 100644 recipes/libliftoff/all/test_package/test_package.c create mode 100644 recipes/libliftoff/config.yml diff --git a/recipes/libliftoff/all/conandata.yml b/recipes/libliftoff/all/conandata.yml new file mode 100644 index 00000000000000..9cc2caed8889e3 --- /dev/null +++ b/recipes/libliftoff/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.4.1": + url: "https://gitlab.freedesktop.org/emersion/libliftoff/-/archive/v0.4.1/libliftoff-v0.4.1.tar.bz2" + sha256: "2ec4a6b467dda20476acb4d6bd864538ccdaa946e8666f96efa98156bf25cfb5" diff --git a/recipes/libliftoff/all/conanfile.py b/recipes/libliftoff/all/conanfile.py new file mode 100644 index 00000000000000..28626c0146534f --- /dev/null +++ b/recipes/libliftoff/all/conanfile.py @@ -0,0 +1,83 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.env import VirtualBuildEnv +from conan.tools.files import copy, get, replace_in_file, rmdir +from conan.tools.gnu import PkgConfigDeps +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson, MesonToolchain +import os + + +required_conan_version = ">=1.53.0" + + +class LibliftoffConan(ConanFile): + name = "libliftoff" + description = "Lightweight KMS plane library." + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/project/package" + topics = ("drm", "KMS", "plane") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + basic_layout(self, src_folder="src") + + def requirements(self): + self.requires("libdrm/2.4.114") + + def validate(self): + if self.settings.os not in ["Linux", "FreeBSD"]: + raise ConanInvalidConfiguration(f"{self.name} only supports FreeBSD and Linux") + + def build_requirements(self): + self.tool_requires("meson/1.2.2") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/2.0.3") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = MesonToolchain(self) + tc.project_options["werror"] = False + tc.generate() + tc = PkgConfigDeps(self) + tc.generate() + tc = VirtualBuildEnv(self) + tc.generate() + + def _patch_sources(self): + replace_in_file(self, os.path.join(self.source_folder, "meson.build"), "subdir('test')", "#subdir('test')") + + def build(self): + self._patch_sources() + meson = Meson(self) + meson.configure() + meson.build() + + def package(self): + copy(self, "LICENSE", self.source_folder, os.path.join(self.package_folder, "licenses")) + meson = Meson(self) + meson.install() + rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + + def package_info(self): + self.cpp_info.libs = ["liftoff"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.extend(["m", "pthread", "dl"]) diff --git a/recipes/libliftoff/all/test_package/conanfile.py b/recipes/libliftoff/all/test_package/conanfile.py new file mode 100644 index 00000000000000..5aab0703e7a4ef --- /dev/null +++ b/recipes/libliftoff/all/test_package/conanfile.py @@ -0,0 +1,32 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.layout import basic_layout +from conan.tools.meson import Meson +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "PkgConfigDeps", "MesonToolchain", "VirtualRunEnv", "VirtualBuildEnv" + test_type = "explicit" + + def layout(self): + basic_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build_requirements(self): + self.tool_requires("meson/1.2.2") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/2.0.3") + + def build(self): + meson = Meson(self) + meson.configure() + meson.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/libliftoff/all/test_package/meson.build b/recipes/libliftoff/all/test_package/meson.build new file mode 100644 index 00000000000000..a943f09604a97f --- /dev/null +++ b/recipes/libliftoff/all/test_package/meson.build @@ -0,0 +1,5 @@ +project('test_package', 'c') +package_dep = dependency('libliftoff') +executable('test_package', + sources : ['test_package.c'], + dependencies : [package_dep]) diff --git a/recipes/libliftoff/all/test_package/test_package.c b/recipes/libliftoff/all/test_package/test_package.c new file mode 100644 index 00000000000000..82017ed512aff1 --- /dev/null +++ b/recipes/libliftoff/all/test_package/test_package.c @@ -0,0 +1,7 @@ +#include +#include + +int main(void) { + liftoff_log_set_priority(LIFTOFF_DEBUG); + return EXIT_SUCCESS; +} diff --git a/recipes/libliftoff/config.yml b/recipes/libliftoff/config.yml new file mode 100644 index 00000000000000..3a9d5538921fcd --- /dev/null +++ b/recipes/libliftoff/config.yml @@ -0,0 +1,3 @@ +versions: + "0.4.1": + folder: all From cca4454e350a13d2f1f2567904e781e21e1796ae Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 5 Oct 2023 11:15:40 +0200 Subject: [PATCH 0967/1140] (#20352) xege: remove unused fPIC option + cleanup test package * remove fPIC option this option doesn't make sense for this library since it's Windows only * cleanup test package * small fix --- recipes/xege/all/conanfile.py | 10 ---------- recipes/xege/all/test_package/CMakeLists.txt | 10 +++------- recipes/xege/all/test_package/conanfile.py | 8 ++++---- .../all/test_package/{example.cpp => test_package.cpp} | 0 recipes/xege/all/test_v1_package/conanfile.py | 2 +- 5 files changed, 8 insertions(+), 22 deletions(-) rename recipes/xege/all/test_package/{example.cpp => test_package.cpp} (100%) diff --git a/recipes/xege/all/conanfile.py b/recipes/xege/all/conanfile.py index 9e838e4436fae4..eb147f1dcfc1f2 100644 --- a/recipes/xege/all/conanfile.py +++ b/recipes/xege/all/conanfile.py @@ -18,16 +18,6 @@ class XegeConan(ConanFile): package_type = "static-library" settings = "os", "arch", "compiler", "build_type" - options = { - "fPIC": [True, False], - } - default_options = { - "fPIC": True, - } - - def config_options(self): - if self.settings.os == "Windows": - del self.options.fPIC def layout(self): cmake_layout(self, src_folder="src") diff --git a/recipes/xege/all/test_package/CMakeLists.txt b/recipes/xege/all/test_package/CMakeLists.txt index 9e1250d39f5ee3..26ea67c5823c3e 100644 --- a/recipes/xege/all/test_package/CMakeLists.txt +++ b/recipes/xege/all/test_package/CMakeLists.txt @@ -1,11 +1,7 @@ cmake_minimum_required(VERSION 3.15) -project(PackageTest CXX) +project(test_package LANGUAGES CXX) find_package(xege REQUIRED CONFIG) -add_executable(example example.cpp) -target_link_libraries(example PRIVATE xege::xege) - -if(MSYS OR MINGW) - target_link_libraries(example -static-libgcc -static-libstdc++) -endif() +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE xege::xege) diff --git a/recipes/xege/all/test_package/conanfile.py b/recipes/xege/all/test_package/conanfile.py index 8d52b7021efe14..e845ae751a3017 100644 --- a/recipes/xege/all/test_package/conanfile.py +++ b/recipes/xege/all/test_package/conanfile.py @@ -9,12 +9,12 @@ class TestPackageConan(ConanFile): generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" test_type = "explicit" - def requirements(self): - self.requires(self.tested_reference_str) - def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() @@ -22,5 +22,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindir, "example") + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") self.run(bin_path, env="conanrun") diff --git a/recipes/xege/all/test_package/example.cpp b/recipes/xege/all/test_package/test_package.cpp similarity index 100% rename from recipes/xege/all/test_package/example.cpp rename to recipes/xege/all/test_package/test_package.cpp diff --git a/recipes/xege/all/test_v1_package/conanfile.py b/recipes/xege/all/test_v1_package/conanfile.py index c48a6d9a1bd7a7..423b8142d5f259 100644 --- a/recipes/xege/all/test_v1_package/conanfile.py +++ b/recipes/xege/all/test_v1_package/conanfile.py @@ -13,5 +13,5 @@ def build(self): def test(self): if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "example") + bin_path = os.path.join("bin", "test_package") self.run(bin_path, run_environment=True) From 71b01e2fdb7788572dca7b45175db3343ebc6f8f Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 5 Oct 2023 17:46:15 +0200 Subject: [PATCH 0968/1140] (#19499) m4: less verbose package_info() --- recipes/m4/all/conanfile.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/recipes/m4/all/conanfile.py b/recipes/m4/all/conanfile.py index 881f4c539d77d5..9065a183bd21ab 100644 --- a/recipes/m4/all/conanfile.py +++ b/recipes/m4/all/conanfile.py @@ -117,7 +117,5 @@ def package_info(self): self.buildenv_info.define_path("M4", m4_bin) # TODO: to remove in conan v2 - bin_path = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bin_path}") - self.env_info.PATH.append(bin_path) + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) self.env_info.M4 = m4_bin From f13f26e0e1e77e05a7427f67e0831d3f5911d50c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 5 Oct 2023 20:13:32 +0300 Subject: [PATCH 0969/1140] (#20304) uwebsockets: add version 20.47.0, remove old versions * uwebsockets: add version 20.47.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * uwebsockets: remove old versions --------- Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/uwebsockets/all/conandata.yml | 24 +++--------------------- recipes/uwebsockets/config.yml | 16 ++-------------- 2 files changed, 5 insertions(+), 35 deletions(-) diff --git a/recipes/uwebsockets/all/conandata.yml b/recipes/uwebsockets/all/conandata.yml index 02893378e4419e..9289579f16fd37 100644 --- a/recipes/uwebsockets/all/conandata.yml +++ b/recipes/uwebsockets/all/conandata.yml @@ -1,31 +1,13 @@ sources: + "20.47.0": + url: "https://github.com/uNetworking/uWebSockets/archive/v20.47.0.tar.gz" + sha256: "00641b7cd2ffadd2c505e2a83a2e32bf342f01c2538bf7470f655e707adde31a" "20.45.0": url: "https://github.com/uNetworking/uWebSockets/archive/v20.45.0.tar.gz" sha256: "db7599e9eac0c18b76740e7c391663652e0d7188b992a1a5a8dc28f347f483ec" - "20.36.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v20.36.0.tar.gz" - sha256: "cda266f7ed6abe67ef3cae6e223a580fe5091db9156c1f4123ee328ae21511c9" - "20.17.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v20.17.0.tar.gz" - sha256: "62027b0b847563bcc65a760045dc4233328229fc551f97fe5814e518e272141c" - "20.14.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v20.14.0.tar.gz" - sha256: "15cf995844a930c9a36747e8d714b94ff886b6814b5d4e3b3ee176f05681cccc" - "20.9.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v20.9.0.tar.gz" - sha256: "91897568291a2081ffc1ae27c354446cc130c168a25892b2289f25e185af8676" - "20.8.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v20.8.0.tar.gz" - sha256: "6ab4bc0207f44eacbb9c82fd0dc59a49ef84e13698ccdbfb44b92c6a0eaa951a" "19.3.0": url: "https://github.com/uNetworking/uWebSockets/archive/v19.3.0.tar.gz" sha256: "6f709b4e5fe053a94a952da93c07c919b36bcb8c838c69067560ae85f97c5621" - "19.2.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v19.2.0.tar.gz" - sha256: "2956075293090754bc2431c53634f93a1e74739c61392be6040cb3ed29430ec2" - "19.1.0": - url: "https://github.com/uNetworking/uWebSockets/archive/v19.1.0.tar.gz" - sha256: "65afa329b0c768a7443ea2621f3f371bc5ce0e1c3518d59bb11b9a2c7adb65dd" "18.3.0": url: "https://github.com/uNetworking/uWebSockets/archive/v18.3.0.tar.gz" sha256: "f51317e2a8cd743e6ff9dfd215569824eaca489c24f7d8fd94eaca44443a9728" diff --git a/recipes/uwebsockets/config.yml b/recipes/uwebsockets/config.yml index 06958fe4bce177..b73567fea69a51 100644 --- a/recipes/uwebsockets/config.yml +++ b/recipes/uwebsockets/config.yml @@ -1,21 +1,9 @@ versions: - "20.45.0": - folder: all - "20.36.0": - folder: all - "20.17.0": - folder: all - "20.14.0": + "20.47.0": folder: all - "20.9.0": - folder: all - "20.8.0": + "20.45.0": folder: all "19.3.0": folder: all - "19.2.0": - folder: all - "19.1.0": - folder: all "18.3.0": folder: all From ca3e58ae83b3f8e17c2f63eced56ed25ba1b3043 Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Fri, 6 Oct 2023 04:28:05 +0200 Subject: [PATCH 0970/1140] (#20264) cyrus-sasl: bump libpq to 14.9 --- recipes/cyrus-sasl/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cyrus-sasl/all/conanfile.py b/recipes/cyrus-sasl/all/conanfile.py index 53ce5027335572..00a9b1d22a9a79 100644 --- a/recipes/cyrus-sasl/all/conanfile.py +++ b/recipes/cyrus-sasl/all/conanfile.py @@ -80,7 +80,7 @@ def requirements(self): if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_postgresql: - self.requires("libpq/14.7") + self.requires("libpq/14.9") if self.options.with_mysql: self.requires("libmysqlclient/8.0.31") if self.options.with_sqlite3: From 1ea697d2312b999e4627a798a26f0f9161bc6390 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 07:10:22 +0200 Subject: [PATCH 0971/1140] (#20152) ffmpeg: fix shared with apple clang 15 + use version range for zlib + bump deps MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix shared build with apple-clang 15 * bump deps and use version range for zlib --------- Co-authored-by: Rubén Rincón Blanco --- recipes/ffmpeg/all/conanfile.py | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/recipes/ffmpeg/all/conanfile.py b/recipes/ffmpeg/all/conanfile.py index 05d36e30042e7b..21f8ed905bd3ba 100644 --- a/recipes/ffmpeg/all/conanfile.py +++ b/recipes/ffmpeg/all/conanfile.py @@ -257,7 +257,7 @@ def layout(self): def requirements(self): if self.options.with_zlib: - self.requires("zlib/1.3") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.with_lzma: @@ -273,11 +273,11 @@ def requirements(self): if self.options.with_vorbis: self.requires("vorbis/1.3.7") if self.options.with_opus: - self.requires("opus/1.3.1") + self.requires("opus/1.4") if self.options.with_zeromq: self.requires("zeromq/4.3.4") if self.options.with_sdl: - self.requires("sdl/2.26.5") + self.requires("sdl/2.28.2") if self.options.with_libx264: self.requires("libx264/cci.20220602") if self.options.with_libx265: @@ -289,11 +289,11 @@ def requirements(self): if self.options.with_libfdk_aac: self.requires("libfdk_aac/2.0.2") if self.options.with_libwebp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_libalsa"): - self.requires("libalsa/1.2.7.2") + self.requires("libalsa/1.2.10") if self.options.get_safe("with_xcb") or self.options.get_safe("with_vaapi"): self.requires("xorg/system") if self.options.get_safe("with_pulse"): @@ -324,7 +324,7 @@ def build_requirements(self): if self.settings.arch in ("x86", "x86_64"): self.tool_requires("yasm/1.3.0") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): @@ -606,6 +606,9 @@ def opt_append_disable_if_set(args, what, v): if not check_min_vs(self, "190", raise_invalid=False): # Visual Studio 2013 (and earlier) doesn't support "inline" keyword for C (only for C++) tc.extra_defines.append("inline=__inline") + if self.settings.compiler == "apple-clang" and Version(self.settings.compiler.version) >= "15": + # Workaround for link error "ld: building exports trie: duplicate symbol '_av_ac3_parse_header'" + tc.extra_ldflags.append("-Wl,-ld_classic") if cross_building(self): args.append(f"--target-os={self._target_os}") if is_apple_os(self) and self.options.with_audiotoolbox: From 51a2f58eb3e88d27017f47acf784243fa9745746 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 08:13:51 +0200 Subject: [PATCH 0972/1140] (#20364) harfbuzz: bump dependencies --- recipes/harfbuzz/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/harfbuzz/all/conanfile.py b/recipes/harfbuzz/all/conanfile.py index 5aba73dab807f9..29d9a1aea73ba8 100644 --- a/recipes/harfbuzz/all/conanfile.py +++ b/recipes/harfbuzz/all/conanfile.py @@ -80,7 +80,7 @@ def requirements(self): if self.options.with_icu: self.requires("icu/73.2") if self.options.with_glib: - self.requires("glib/2.77.0") + self.requires("glib/2.78.0") def validate(self): if self.options.shared and self.options.with_glib and not self.dependencies["glib"].options.shared: @@ -96,9 +96,9 @@ def validate(self): ) def build_requirements(self): - self.tool_requires("meson/1.1.0") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self.options.with_glib: self.tool_requires("glib/") if self.settings.os == "Macos": From ea5b3ae147c63f6336c89f0f9b556947a8af3052 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 6 Oct 2023 09:00:55 +0200 Subject: [PATCH 0973/1140] (#20382) libgphoto2: bump deps * libgphoto2: bump deps, use version range for libcurl * bump libcurl --- recipes/libgphoto2/all/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/libgphoto2/all/conanfile.py b/recipes/libgphoto2/all/conanfile.py index e3382ba23526ba..ea327fb8a2c335 100644 --- a/recipes/libgphoto2/all/conanfile.py +++ b/recipes/libgphoto2/all/conanfile.py @@ -55,11 +55,11 @@ def requirements(self): if self.options.with_libusb: self.requires("libusb/1.0.26") if self.options.with_libcurl: - self.requires("libcurl/8.0.0") + self.requires("libcurl/8.2.1") if self.options.with_libxml2: - self.requires("libxml2/2.10.3") + self.requires("libxml2/2.11.4") if self.options.with_libexif: - self.requires("libexif/0.6.23") + self.requires("libexif/0.6.24") if self.options.with_libjpeg: self.requires("libjpeg/9e") @@ -69,7 +69,7 @@ def validate(self): def build_requirements(self): if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From 4c67e9488a7965ef58df080d9ce7dbd180afb663 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 6 Oct 2023 09:15:32 +0200 Subject: [PATCH 0974/1140] (#20386) netcdf/all: bump deps --- recipes/netcdf/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/netcdf/all/conanfile.py b/recipes/netcdf/all/conanfile.py index 5e71e1ec032be4..ef365e834e7311 100644 --- a/recipes/netcdf/all/conanfile.py +++ b/recipes/netcdf/all/conanfile.py @@ -68,10 +68,10 @@ def requirements(self): # So we will require the older hdf5 to keep the older behaviour. self.requires("hdf5/1.12.0") else: - self.requires("hdf5/1.14.0") + self.requires("hdf5/1.14.1") if self.options.dap or self.options.byterange: - self.requires("libcurl/7.88.1") + self.requires("libcurl/8.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) From c42d0d1176bf1acbedd71d5927475e31b56b8a61 Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Fri, 6 Oct 2023 09:51:38 +0200 Subject: [PATCH 0975/1140] (#20263) Poco: bump libpq to 14.9 --- recipes/poco/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/poco/all/conanfile.py b/recipes/poco/all/conanfile.py index db83584f38915e..4c1811de04efb6 100644 --- a/recipes/poco/all/conanfile.py +++ b/recipes/poco/all/conanfile.py @@ -126,7 +126,7 @@ def requirements(self): if self.options.enable_data_odbc and self.settings.os != "Windows": self.requires("odbc/2.3.11") if self.options.get_safe("enable_data_postgresql"): - self.requires("libpq/14.7") + self.requires("libpq/14.9") if self.options.get_safe("enable_data_mysql"): self.requires("libmysqlclient/8.0.31") From ab29a8ebf25d3fe113f8e6b7866028393d525640 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 6 Oct 2023 10:29:38 +0200 Subject: [PATCH 0976/1140] (#20387) libxslt/all: bump deps --- recipes/libxslt/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libxslt/all/conanfile.py b/recipes/libxslt/all/conanfile.py index 35861075ebb78d..f3241de947d7f0 100644 --- a/recipes/libxslt/all/conanfile.py +++ b/recipes/libxslt/all/conanfile.py @@ -60,7 +60,7 @@ def layout(self): def requirements(self): # see https://github.com/conan-io/conan-center-index/pull/16205#discussion_r1149570846 - self.requires("libxml2/2.10.3", transitive_headers=True, transitive_libs=True) + self.requires("libxml2/2.11.4", transitive_headers=True, transitive_libs=True) def validate(self): if self.options.plugins and not self.options.shared: From f00f9308d65323edecec3360253fa91424506168 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 11:07:59 +0200 Subject: [PATCH 0977/1140] (#19497) pkgconf: less verbose package_info() + bump meson * less verbose package_info() * cleanup imports * bump meson * cleanup again --- recipes/pkgconf/all/conanfile.py | 20 ++++++-------------- 1 file changed, 6 insertions(+), 14 deletions(-) diff --git a/recipes/pkgconf/all/conanfile.py b/recipes/pkgconf/all/conanfile.py index 2645619ecf3209..18f5f79fa547c2 100644 --- a/recipes/pkgconf/all/conanfile.py +++ b/recipes/pkgconf/all/conanfile.py @@ -7,7 +7,6 @@ from conan.tools.meson import Meson, MesonToolchain from conan.tools.microsoft import is_msvc, unix_path_package_info_legacy from conan.tools.scm import Version -from conan.errors import ConanInvalidConfiguration required_conan_version = ">=1.57.0" @@ -52,11 +51,15 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def package_id(self): + if not self.info.options.enable_lib: + del self.info.settings.compiler + def build_requirements(self): - self.tool_requires("meson/1.0.0") + self.tool_requires("meson/1.2.1") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def _patch_sources(self): apply_conandata_patches(self) @@ -112,10 +115,6 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "share")) rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) - def package_id(self): - if not self.info.options.enable_lib: - del self.info.settings.compiler - def package_info(self): if self.options.enable_lib: self.cpp_info.set_property("pkg_config_name", "libpkgconf") @@ -129,12 +128,10 @@ def package_info(self): self.cpp_info.libdirs = [] bindir = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH env var: {}".format(bindir)) self.env_info.PATH.append(bindir) exesuffix = ".exe" if self.settings.os == "Windows" else "" pkg_config = os.path.join(bindir, "pkgconf" + exesuffix).replace("\\", "/") - self.output.info("Setting PKG_CONFIG env var: {}".format(pkg_config)) self.buildenv_info.define_path("PKG_CONFIG", pkg_config) pkgconf_aclocal = os.path.join(self.package_folder, "bin", "aclocal") @@ -144,10 +141,5 @@ def package_info(self): # TODO: remove in conanv2 automake_extra_includes = unix_path_package_info_legacy(self, pkgconf_aclocal.replace("\\", "/")) - self.output.info("Appending AUTOMAKE_CONAN_INCLUDES env var: {}".format(automake_extra_includes)) self.env_info.PKG_CONFIG = pkg_config self.env_info.AUTOMAKE_CONAN_INCLUDES.append(automake_extra_includes) - - # TODO: to remove in conan v2 once pkg_config generator removed - if self.options.enable_lib: - self.cpp_info.names["pkg_config"] = "libpkgconf" From 133d708185692a9d92743d6e30f8d7d988cb676d Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 11:46:46 +0200 Subject: [PATCH 0978/1140] (#20003) gdbm: Inject `-headerpad_max_install_names` to ensure that `install_name_tool` can succeed on Apple --- recipes/gdbm/all/conanfile.py | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/recipes/gdbm/all/conanfile.py b/recipes/gdbm/all/conanfile.py index 71b092ccff400c..0dbe22e531a7e7 100644 --- a/recipes/gdbm/all/conanfile.py +++ b/recipes/gdbm/all/conanfile.py @@ -1,8 +1,8 @@ from conan import ConanFile -from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.apple import fix_apple_shared_install_name, is_apple_os from conan.tools.build import cross_building from conan.tools.env import VirtualBuildEnv, VirtualRunEnv -from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get, rm, rmdir +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm, rmdir from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain from conan.tools.layout import basic_layout from conan.errors import ConanInvalidConfiguration @@ -105,6 +105,10 @@ def generate(self): "--without-libiconv-prefix", "--without-libintl-prefix" ]) + if is_apple_os(self): + # Inject -headerpad_max_install_names, otherwise fix_apple_shared_install_name() may fail. + # See https://github.com/conan-io/conan-center-index/issues/20002 + tc.extra_ldflags.append("-headerpad_max_install_names") tc.generate() autotools_deps = AutotoolsDeps(self) autotools_deps.generate() From ef0e30f08aee5dff70a4a751a707be5e837d327f Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 6 Oct 2023 11:59:34 +0200 Subject: [PATCH 0979/1140] (#20101) at-spi2-core: enable non-linux MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * at-spi2-core 2.50.0 * at-spi2-core: enable non-linux * fix windows cf https://gitlab.gnome.org/GNOME/at-spi2-core/-/commit/20ee2e533794e0d5a3437e5b272da0a648d73c3e * fix typo * fix windows support version cf https://gitlab.gnome.org/GNOME/at-spi2-core/-/commit/c3e2e480cf7e8587be26fd1174672c295b3f2f9c * only test atk it is the only common feature subset of all platforms * disable macos before 2.50.0 https://gitlab.gnome.org/GNOME/at-spi2-core/-/commit/e6f431beb47d2aadab7d2020e547e0b559557914 fixes a compilation error * fix fPIC * Update conanfile.py * Update conanfile.py * add debug log * Update conanfile.py * dbus is also needed at compile time a test executable is run during meson configuratoin * another shot * Update conanfile.py * bump deps * Update recipes/at-spi2-core/new/conanfile.py Co-authored-by: Rubén Rincón Blanco * Update conanfile.py --------- Co-authored-by: Rubén Rincón Blanco --- recipes/at-spi2-core/config.yml | 2 + recipes/at-spi2-core/new/conandata.yml | 3 + recipes/at-spi2-core/new/conanfile.py | 67 ++++++++++++++----- .../new/test_package/conanfile.py | 4 +- .../at-spi2-core/new/test_package/meson.build | 2 +- .../new/test_package/test_package.c | 11 +-- 6 files changed, 65 insertions(+), 24 deletions(-) diff --git a/recipes/at-spi2-core/config.yml b/recipes/at-spi2-core/config.yml index 3a9a2fb50465f4..f0d6f514974e47 100644 --- a/recipes/at-spi2-core/config.yml +++ b/recipes/at-spi2-core/config.yml @@ -21,3 +21,5 @@ versions: folder: new "2.49.1": folder: new + "2.50.0": + folder: new diff --git a/recipes/at-spi2-core/new/conandata.yml b/recipes/at-spi2-core/new/conandata.yml index 14543d255e3d0d..b27bb3ef5a258f 100644 --- a/recipes/at-spi2-core/new/conandata.yml +++ b/recipes/at-spi2-core/new/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.50.0": + sha256: e9f5a8c8235c9dd963b2171de9120301129c677dde933955e1df618b949c4adc + url: https://ftp.gnome.org/pub/gnome/sources/at-spi2-core/2.50/at-spi2-core-2.50.0.tar.xz "2.49.1": sha256: 53ed9eb77e4c48b3bf6ac4afb5689391e0d7d0f44f7ca4443d8b13c7dd26119c url: https://ftp.gnome.org/pub/gnome/sources/at-spi2-core/2.49/at-spi2-core-2.49.1.tar.xz diff --git a/recipes/at-spi2-core/new/conanfile.py b/recipes/at-spi2-core/new/conanfile.py index 041ae5da456f18..02a871957ee4fb 100644 --- a/recipes/at-spi2-core/new/conanfile.py +++ b/recipes/at-spi2-core/new/conanfile.py @@ -1,7 +1,8 @@ from conan import ConanFile -from conan.errors import ConanInvalidConfiguration +from conan.errors import ConanException, ConanInvalidConfiguration +from conan.tools.apple import fix_apple_shared_install_name from conan.tools.env import VirtualBuildEnv -from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rmdir +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, replace_in_file, rm, rmdir from conan.tools.gnu import PkgConfigDeps from conan.tools.layout import basic_layout from conan.tools.meson import Meson, MesonToolchain @@ -37,6 +38,10 @@ class AtSpi2CoreConan(ConanFile): def export_sources(self): export_conandata_patches(self) + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + def configure(self): if self.options.shared: self.options.rm_safe("fPIC") @@ -44,24 +49,29 @@ def configure(self): self.settings.rm_safe("compiler.cppstd") def build_requirements(self): - self.tool_requires("meson/1.2.0") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") self.tool_requires("glib/") def requirements(self): - self.requires("glib/2.77.0") + self.requires("glib/2.78.0") if self.options.with_x11: self.requires("xorg/system") - self.requires("dbus/1.15.6") + if self.settings.os == "Linux": + self.requires("dbus/1.15.8") def validate(self): if self.options.shared and not self.dependencies["glib"].options.shared: raise ConanInvalidConfiguration( "Linking a shared library against static glib can cause unexpected behaviour." ) - if self.settings.os != "Linux": - raise ConanInvalidConfiguration("only linux is supported by this recipe") + if Version(self.version) < "2.49.1": + if self.settings.os == "Windows": + raise ConanInvalidConfiguration("Windows is not supported before version 2.49.1") + if Version(self.version) < "2.50.0": + if self.settings.os == "Macos": + raise ConanInvalidConfiguration("macos is not supported before version 2.50.0") def layout(self): basic_layout(self, src_folder="src") @@ -80,6 +90,9 @@ def generate(self): else: tc.project_options["introspection"] = "no" tc.project_options["x11"] = "yes" if self.options.with_x11 else "no" + if self.settings.os != "Linux": + tc.project_options["atk_only"] = "true" + tc.project_options["docs"] = "false" tc.generate() tc = PkgConfigDeps(self) @@ -107,20 +120,42 @@ def package(self): meson.install() rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) rmdir(self, os.path.join(self.package_folder, "etc")) + rm(self, "*.pdb", os.path.join(self.package_folder, "bin")) + fix_apple_shared_install_name(self) + fix_msvc_libname(self) def package_info(self): - self.cpp_info.components["atspi"].libs = ['atspi'] - self.cpp_info.components["atspi"].includedirs = ["include/at-spi-2.0"] - self.cpp_info.components["atspi"].requires = ["dbus::dbus", "glib::glib"] - self.cpp_info.components["atspi"].set_property("pkg_config_name", "atspi-2") + if self.settings.os == "Linux": + self.cpp_info.components["atspi"].libs = ['atspi'] + self.cpp_info.components["atspi"].includedirs = ["include/at-spi-2.0"] + self.cpp_info.components["atspi"].requires = ["dbus::dbus", "glib::glib"] + self.cpp_info.components["atspi"].set_property("pkg_config_name", "atspi-2") self.cpp_info.components["atk"].libs = ["atk-1.0"] self.cpp_info.components["atk"].includedirs = ['include/atk-1.0'] self.cpp_info.components["atk"].requires = ["glib::glib"] self.cpp_info.components["atk"].set_property("pkg_config_name", 'atk') - self.cpp_info.components["atk-bridge"].libs = ['atk-bridge-2.0'] - self.cpp_info.components["atk-bridge"].includedirs = [os.path.join('include', 'at-spi2-atk', '2.0')] - self.cpp_info.components["atk-bridge"].requires = ["dbus::dbus", "atk", "glib::glib", "atspi"] - self.cpp_info.components["atk-bridge"].set_property("pkg_config_name", 'atk-bridge-2.0') + if self.settings.os == "Linux": + self.cpp_info.components["atk-bridge"].libs = ['atk-bridge-2.0'] + self.cpp_info.components["atk-bridge"].includedirs = [os.path.join('include', 'at-spi2-atk', '2.0')] + self.cpp_info.components["atk-bridge"].requires = ["dbus::dbus", "atk", "glib::glib", "atspi"] + self.cpp_info.components["atk-bridge"].set_property("pkg_config_name", 'atk-bridge-2.0') + + +def fix_msvc_libname(conanfile, remove_lib_prefix=True): + """remove lib prefix & change extension to .lib in case of cl like compiler""" + if not conanfile.settings.get_safe("compiler.runtime"): + return + from conan.tools.files import rename + import glob + libdirs = getattr(conanfile.cpp.package, "libdirs") + for libdir in libdirs: + for ext in [".dll.a", ".dll.lib", ".a"]: + full_folder = os.path.join(conanfile.package_folder, libdir) + for filepath in glob.glob(os.path.join(full_folder, f"*{ext}")): + libname = os.path.basename(filepath)[0:-len(ext)] + if remove_lib_prefix and libname[0:3] == "lib": + libname = libname[3:] + rename(conanfile, filepath, os.path.join(os.path.dirname(filepath), f"{libname}.lib")) diff --git a/recipes/at-spi2-core/new/test_package/conanfile.py b/recipes/at-spi2-core/new/test_package/conanfile.py index 74125d16c3d5f5..5aab0703e7a4ef 100644 --- a/recipes/at-spi2-core/new/test_package/conanfile.py +++ b/recipes/at-spi2-core/new/test_package/conanfile.py @@ -17,9 +17,9 @@ def requirements(self): self.requires(self.tested_reference_str) def build_requirements(self): - self.tool_requires("meson/1.2.0") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") def build(self): meson = Meson(self) diff --git a/recipes/at-spi2-core/new/test_package/meson.build b/recipes/at-spi2-core/new/test_package/meson.build index a6950ebe6d4ab2..896df272078652 100644 --- a/recipes/at-spi2-core/new/test_package/meson.build +++ b/recipes/at-spi2-core/new/test_package/meson.build @@ -1,5 +1,5 @@ project('test_package', 'c') -package_dep = dependency('atspi-2') +package_dep = dependency('atk') executable('test_package', sources : ['test_package.c'], dependencies : [package_dep]) diff --git a/recipes/at-spi2-core/new/test_package/test_package.c b/recipes/at-spi2-core/new/test_package/test_package.c index c155308c155baf..284086622ab26a 100644 --- a/recipes/at-spi2-core/new/test_package/test_package.c +++ b/recipes/at-spi2-core/new/test_package/test_package.c @@ -1,9 +1,10 @@ -#include "atspi/atspi.h" -#include "assert.h" +#include +#include int main() { - atspi_init (); - assert(atspi_get_desktop_count() > 0); - return atspi_exit(); + printf("ATK version %d.%d.%d\n",atk_get_major_version(), atk_get_minor_version(), atk_get_micro_version()); + printf("binary age %d\n", atk_get_binary_age()); + printf("interface age %d\n", atk_get_interface_age()); + return 0; } From 26d5dbb1c09d207c5bbe55c88e8871f100e4f9bb Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Fri, 6 Oct 2023 14:03:47 +0200 Subject: [PATCH 0980/1140] (#20375) Qt 5.15.11 * qt 5.15.11 generated with: ``` conan config install https://github.com/conan-io/conan-extensions.git conan cci:upgrade-qt-recipe 5.15.11 ``` * bump zlib --- recipes/qt/5.x.x/conandata.yml | 43 ++++ recipes/qt/5.x.x/conanfile.py | 2 +- recipes/qt/5.x.x/qtmodules5.15.11.conf | 326 +++++++++++++++++++++++++ recipes/qt/config.yml | 2 + 4 files changed, 372 insertions(+), 1 deletion(-) create mode 100644 recipes/qt/5.x.x/qtmodules5.15.11.conf diff --git a/recipes/qt/5.x.x/conandata.yml b/recipes/qt/5.x.x/conandata.yml index d0847c695c3717..964c01a809272b 100644 --- a/recipes/qt/5.x.x/conandata.yml +++ b/recipes/qt/5.x.x/conandata.yml @@ -1,4 +1,26 @@ sources: + "5.15.11": + url: + - "https://download.qt.io/official_releases/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://download.qt.io/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://qt.mirror.constant.com/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirrors.ukfast.co.uk/sites/qt.io/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirrors.20i.com/pub/qt.io/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.nluug.nl/languages/qt/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirror.netcologne.de/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirror.web4africa.ng/qt/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://qt-mirror.dannhauer.de/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.fau.de/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirrors.dotsrc.org/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.icm.edu.pl/packages/qt/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.acc.umu.se/mirror/qt.io/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://www.nic.funet.fi/pub/mirrors/download.qt-project.org/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://qtproject.mirror.liquidtelecom.com/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://mirrors.sjtug.sjtu.edu.cn/qt/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.jaist.ac.jp/pub/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + - "https://ftp.yz.yamagata-u.ac.jp/pub/qtproject/archive/qt/5.15/5.15.11/single/qt-everywhere-opensource-src-5.15.11.tar.xz" + sha256: "7426b1eaab52ed169ce53804bdd05dfe364f761468f888a0f15a308dc1dc2951" "5.15.10": url: - "https://download.qt.io/official_releases/qt/5.15/5.15.10/single/qt-everywhere-opensource-src-5.15.10.tar.xz" @@ -55,6 +77,27 @@ sources: - "https://ftp.fau.de/qtproject/archive/qt/5.15/5.15.7/single/qt-everywhere-opensource-src-5.15.7.tar.xz" sha256: "8a71986676a3f37a198a9113acedbfd5bc5606a459b6b85816d951458adbe9a0" patches: + "5.15.11": + - "base_path": "qt5/qtbase" + "patch_file": "patches/aa2a39dea5.diff" + - "base_path": "qt5/qtwebengine" + "patch_file": "patches/c72097e.diff" + - "base_path": "qt5/qttools" + "patch_file": "patches/fix-macdeployqt.diff" + - "base_path": "qt5/qtwebengine/src/3rdparty/chromium/v8" + "patch_file": "patches/chromium-v8-missing-constexpr.patch" + - "base_path": "qt5/qtwebengine/src/3rdparty" + "patch_file": "patches/chromium-skia-missing-iterator-include.patch" + - "base_path": "qt5/qtwebengine/src/3rdparty/chromium/third_party/skia" + "patch_file": "patches/skia-cd397f3.diff" + - "base_path": "qt5/qtwebengine/src/3rdparty" + "patch_file": "patches/0001-Find-fontconfig-using-pkg-config.patch" + - "base_path": "qt5/qtbase" + "patch_file": "patches/android-backtrace.diff" + - "base_path": "qt5/qtbase" + "patch_file": "patches/android-openssl.diff" + - "base_path": "qt5/qtbase" + "patch_file": "patches/android-new-ndk.diff" "5.15.10": - "base_path": "qt5/qtbase" "patch_file": "patches/aa2a39dea5.diff" diff --git a/recipes/qt/5.x.x/conanfile.py b/recipes/qt/5.x.x/conanfile.py index 8e54f6b2a47b08..55687915747f74 100644 --- a/recipes/qt/5.x.x/conanfile.py +++ b/recipes/qt/5.x.x/conanfile.py @@ -339,7 +339,7 @@ def validate(self): raise ConanInvalidConfiguration("sqlite3 option enable_column_metadata must be enabled for qt") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_pcre2: diff --git a/recipes/qt/5.x.x/qtmodules5.15.11.conf b/recipes/qt/5.x.x/qtmodules5.15.11.conf new file mode 100644 index 00000000000000..452233655f279d --- /dev/null +++ b/recipes/qt/5.x.x/qtmodules5.15.11.conf @@ -0,0 +1,326 @@ +[submodule "qtbase"] + path = qtbase + url = ../qtbase.git + branch = 5.15 + status = essential +[submodule "qtsvg"] + depends = qtbase + path = qtsvg + url = ../qtsvg.git + branch = 5.15 + status = addon +[submodule "qtdeclarative"] + depends = qtbase + recommends = qtsvg + path = qtdeclarative + url = ../qtdeclarative.git + branch = 5.15 + status = essential +[submodule "qtactiveqt"] + depends = qtbase + path = qtactiveqt + url = ../qtactiveqt.git + branch = 5.15 + status = addon +[submodule "qtscript"] + depends = qtbase + recommends = qttools + path = qtscript + url = ../qtscript.git + branch = 5.15 + status = deprecated +[submodule "qtmultimedia"] + depends = qtbase + recommends = qtdeclarative + path = qtmultimedia + url = ../qtmultimedia.git + branch = 5.15 + status = essential +[submodule "qttools"] + depends = qtbase + recommends = qtdeclarative qtactiveqt + path = qttools + url = ../qttools.git + branch = 5.15 + status = essential +[submodule "qtxmlpatterns"] + depends = qtbase + recommends = qtdeclarative + path = qtxmlpatterns + url = ../qtxmlpatterns.git + branch = 5.15 + status = deprecated +[submodule "qttranslations"] + depends = qttools + path = qttranslations + url = ../qttranslations.git + branch = 5.15 + status = essential + priority = 30 +[submodule "qtdoc"] + depends = qtdeclarative qttools + recommends = qtmultimedia qtquickcontrols qtquickcontrols2 + path = qtdoc + url = ../qtdoc.git + branch = 5.15 + status = essential + priority = 40 +[submodule "qtrepotools"] + path = qtrepotools + url = ../qtrepotools.git + branch = master + status = essential + project = - +[submodule "qtqa"] + depends = qtbase + path = qtqa + url = ../qtqa.git + branch = master + status = essential + priority = 50 +[submodule "qtlocation"] + depends = qtbase + recommends = qtdeclarative qtquickcontrols qtquickcontrols2 qtserialport + path = qtlocation + url = ../qtlocation.git + branch = 5.15 + status = addon +[submodule "qtsensors"] + depends = qtbase + recommends = qtdeclarative + path = qtsensors + url = ../qtsensors.git + branch = 5.15 + status = addon +[submodule "qtsystems"] + depends = qtbase + recommends = qtdeclarative + path = qtsystems + url = ../qtsystems.git + branch = dev + status = ignore +[submodule "qtfeedback"] + depends = qtdeclarative + recommends = qtmultimedia + path = qtfeedback + url = ../qtfeedback.git + branch = master + status = ignore +[submodule "qtdocgallery"] + depends = qtdeclarative + path = qtdocgallery + url = ../qtdocgallery.git + branch = master + status = ignore +[submodule "qtpim"] + depends = qtdeclarative + path = qtpim + url = ../qtpim.git + branch = dev + status = ignore +[submodule "qtconnectivity"] + depends = qtbase + recommends = qtdeclarative qtandroidextras + path = qtconnectivity + url = ../qtconnectivity.git + branch = 5.15 + status = addon +[submodule "qtwayland"] + depends = qtbase + recommends = qtdeclarative + path = qtwayland + url = ../qtwayland.git + branch = 5.15 + status = addon +[submodule "qt3d"] + depends = qtbase + recommends = qtdeclarative qtimageformats qtgamepad + path = qt3d + url = ../qt3d.git + branch = 5.15 + status = addon +[submodule "qtimageformats"] + depends = qtbase + path = qtimageformats + url = ../qtimageformats.git + branch = 5.15 + status = addon +[submodule "qtgraphicaleffects"] + depends = qtdeclarative + path = qtgraphicaleffects + url = ../qtgraphicaleffects.git + branch = 5.15 + status = essential +[submodule "qtquickcontrols"] + depends = qtdeclarative + recommends = qtgraphicaleffects + path = qtquickcontrols + url = ../qtquickcontrols.git + branch = 5.15 + status = addon +[submodule "qtserialbus"] + depends = qtbase + recommends = qtserialport + path = qtserialbus + url = ../qtserialbus.git + branch = 5.15 + status = addon +[submodule "qtserialport"] + depends = qtbase + path = qtserialport + url = ../qtserialport.git + branch = 5.15 + status = addon +[submodule "qtx11extras"] + depends = qtbase + path = qtx11extras + url = ../qtx11extras.git + branch = 5.15 + status = addon +[submodule "qtmacextras"] + depends = qtbase + path = qtmacextras + url = ../qtmacextras.git + branch = 5.15 + status = addon +[submodule "qtwinextras"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtwinextras + url = ../qtwinextras.git + branch = 5.15 + status = addon +[submodule "qtandroidextras"] + depends = qtbase + path = qtandroidextras + url = ../qtandroidextras.git + branch = 5.15 + status = addon +[submodule "qtwebsockets"] + depends = qtbase + recommends = qtdeclarative + path = qtwebsockets + url = ../qtwebsockets.git + branch = 5.15 + status = addon +[submodule "qtwebchannel"] + depends = qtbase + recommends = qtdeclarative qtwebsockets + path = qtwebchannel + url = ../qtwebchannel.git + branch = 5.15 + status = addon +[submodule "qtwebengine"] + depends = qtdeclarative + recommends = qtquickcontrols qtquickcontrols2 qtlocation qtwebchannel qttools + path = qtwebengine + url = ../qtwebengine.git + branch = 5.15 + status = addon + priority = 10 +[submodule "qtcanvas3d"] + depends = qtdeclarative + path = qtcanvas3d + url = ../qtcanvas3d.git + branch = dev + status = ignore +[submodule "qtwebview"] + depends = qtdeclarative + recommends = qtwebengine + path = qtwebview + url = ../qtwebview.git + branch = 5.15 + status = addon +[submodule "qtquickcontrols2"] + depends = qtgraphicaleffects + recommends = qtimageformats + path = qtquickcontrols2 + url = ../qtquickcontrols2.git + branch = 5.15 + status = essential +[submodule "qtpurchasing"] + depends = qtbase + recommends = qtdeclarative qtandroidextras + path = qtpurchasing + url = ../qtpurchasing.git + branch = 5.15 + status = addon +[submodule "qtcharts"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtcharts + url = ../qtcharts.git + branch = 5.15 + status = addon +[submodule "qtdatavis3d"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtdatavis3d + url = ../qtdatavis3d.git + branch = 5.15 + status = addon +[submodule "qtvirtualkeyboard"] + depends = qtbase qtdeclarative qtsvg + recommends = qtmultimedia qtquickcontrols + path = qtvirtualkeyboard + url = ../qtvirtualkeyboard.git + branch = 5.15 + status = addon +[submodule "qtgamepad"] + depends = qtbase + recommends = qtdeclarative + path = qtgamepad + url = ../qtgamepad.git + branch = 5.15 + status = addon +[submodule "qtscxml"] + depends = qtbase qtdeclarative + path = qtscxml + url = ../qtscxml.git + branch = 5.15 + status = addon +[submodule "qtspeech"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtspeech + url = ../qtspeech.git + branch = 5.15 + status = addon +[submodule "qtnetworkauth"] + depends = qtbase + path = qtnetworkauth + url = ../qtnetworkauth.git + branch = 5.15 + status = addon +[submodule "qtremoteobjects"] + depends = qtbase + recommends = qtdeclarative + path = qtremoteobjects + url = ../qtremoteobjects.git + branch = 5.15 + status = addon +[submodule "qtwebglplugin"] + depends = qtbase qtwebsockets + recommends = qtdeclarative + path = qtwebglplugin + url = ../qtwebglplugin.git + branch = 5.15 + status = addon +[submodule "qtlottie"] + depends = qtbase qtdeclarative + path = qtlottie + url = ../qtlottie.git + branch = 5.15 + status = addon +[submodule "qtquicktimeline"] + depends = qtbase qtdeclarative + path = qtquicktimeline + url = ../qtquicktimeline + branch = 5.15 + status = addon +[submodule "qtquick3d"] + depends = qtbase qtdeclarative + path = qtquick3d + url = ../qtquick3d.git + branch = 5.15 + status = addon diff --git a/recipes/qt/config.yml b/recipes/qt/config.yml index 6d034f7e112276..1ccfd2e7da0a7f 100644 --- a/recipes/qt/config.yml +++ b/recipes/qt/config.yml @@ -9,6 +9,8 @@ versions: folder: 6.x.x "6.3.2": folder: 6.x.x + "5.15.11": + folder: 5.x.x "5.15.10": folder: 5.x.x "5.15.9": From 91e67bdec23d59d4e2a104a3343762142b300058 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 6 Oct 2023 14:46:33 +0200 Subject: [PATCH 0981/1140] (#20384) cfitsio/all: bump deps * cfitsio/all: use version range for libcurl * bump libcurl --- recipes/cfitsio/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cfitsio/all/conanfile.py b/recipes/cfitsio/all/conanfile.py index 72a03672b23c24..3726c4a8835d14 100644 --- a/recipes/cfitsio/all/conanfile.py +++ b/recipes/cfitsio/all/conanfile.py @@ -63,7 +63,7 @@ def requirements(self): if self.options.with_bzip2: self.requires("bzip2/1.0.8") if self.options.get_safe("with_curl"): - self.requires("libcurl/8.0.0") + self.requires("libcurl/8.2.1") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From 7335e24ba98e44a6a2698eda41e0944e43d13983 Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Fri, 6 Oct 2023 16:19:53 +0200 Subject: [PATCH 0982/1140] (#20254) Bump libwebp in opencv to 1.3.2 --- recipes/opencv/3.x/conanfile.py | 2 +- recipes/opencv/4.x/conanfile.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/opencv/3.x/conanfile.py b/recipes/opencv/3.x/conanfile.py index 0abc75587237cb..ffb81b4e364d52 100644 --- a/recipes/opencv/3.x/conanfile.py +++ b/recipes/opencv/3.x/conanfile.py @@ -98,7 +98,7 @@ def requirements(self): # opencv 3.x doesn't support onetbb >= 2021 self.requires("onetbb/2020.3") if self.options.with_webp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") if self.options.contrib: self.requires("freetype/2.13.0") self.requires("harfbuzz/6.0.0") diff --git a/recipes/opencv/4.x/conanfile.py b/recipes/opencv/4.x/conanfile.py index 12bcded86e10ee..0f533c33789b50 100644 --- a/recipes/opencv/4.x/conanfile.py +++ b/recipes/opencv/4.x/conanfile.py @@ -1047,7 +1047,7 @@ def requirements(self): if self.options.get_safe("with_tiff"): self.requires("libtiff/4.5.1") if self.options.get_safe("with_webp"): - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") if self.options.get_safe("with_gdal"): self.requires("gdal/3.5.2") if self.options.get_safe("with_gdcm"): From 9b753ea232f00ed299c781cd5ea0489dd4980ef5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 6 Oct 2023 17:56:57 +0300 Subject: [PATCH 0983/1140] (#18725) easylzma: migrate to Conan v2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * easylzma: migrate to Conan v2 * easylzma: restore VirtualRunEnv in test_package * easylzma: fix copying of DLLs * easylzma: fix license * easylzma: fix shared build * easylzma: add fix_apple_shared_install_name() * Fix library attribution --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Daniel --- recipes/easylzma/all/CMakeLists.txt | 7 -- recipes/easylzma/all/conandata.yml | 3 - recipes/easylzma/all/conanfile.py | 105 +++++++++++------- .../easylzma/all/test_package/CMakeLists.txt | 9 +- .../easylzma/all/test_package/conanfile.py | 22 +++- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../easylzma/all/test_v1_package/conanfile.py | 16 +++ 7 files changed, 108 insertions(+), 62 deletions(-) delete mode 100644 recipes/easylzma/all/CMakeLists.txt create mode 100644 recipes/easylzma/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/easylzma/all/test_v1_package/conanfile.py diff --git a/recipes/easylzma/all/CMakeLists.txt b/recipes/easylzma/all/CMakeLists.txt deleted file mode 100644 index 8b2a23892d7dec..00000000000000 --- a/recipes/easylzma/all/CMakeLists.txt +++ /dev/null @@ -1,7 +0,0 @@ -cmake_minimum_required(VERSION 2.6) -project(cmake_wrapper) - -include(conanbuildinfo.cmake) -conan_basic_setup() - -add_subdirectory("source_subfolder") diff --git a/recipes/easylzma/all/conandata.yml b/recipes/easylzma/all/conandata.yml index ce63d9a78cbcc2..80c52f3ee8642b 100644 --- a/recipes/easylzma/all/conandata.yml +++ b/recipes/easylzma/all/conandata.yml @@ -5,7 +5,4 @@ sources: patches: "0.0.7": - patch_file: "patches/memleaksfix.patch" - base_path: "source_subfolder" - patch_file: "patches/cmake-no-cflags.patch" - base_path: "source_subfolder" - diff --git a/recipes/easylzma/all/conanfile.py b/recipes/easylzma/all/conanfile.py index 5e527b60909114..500d0f8e783aad 100644 --- a/recipes/easylzma/all/conanfile.py +++ b/recipes/easylzma/all/conanfile.py @@ -1,72 +1,95 @@ import os -from conans import ConanFile, tools, CMake + +from conan import ConanFile +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, load, save +from conan.tools.microsoft import is_msvc, msvc_runtime_flag + +required_conan_version = ">=1.53.0" class EazylzmaConan(ConanFile): name = "easylzma" - license = "Unlicense" + description = ( + "An easy to use, tiny, public domain, C wrapper library around " + "Igor Pavlov's work that can be used to compress and extract lzma files" + ) + license = "DocumentRef-README:LicenseRef-PublicDomain-WITH-Attribution" # Public Domain with attribution request url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/lloyd/easylzma" - description = ("An easy to use, tiny, public domain, C wrapper library around \ - Igor Pavlov's work that can be used to compress and extract lzma files") - settings = "os", "arch", "compiler", "build_type" - generators = "cmake" - topics = ("conan", "eazylzma", "lzma") - exports_sources = ["CMakeLists.txt", "patches/*"] - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} + topics = ("lzma",) - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _license_text(self): - # Extract the License/s from the README to a file - tmp = tools.load(os.path.join("source_subfolder", "README")) - return tmp[tmp.find("License",1):tmp.find("work.", 1)+5] + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - @property - def _libname(self): - return "easylzma" if self.options.shared else "easylzma_s" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": - del self.options.fPIC + del self.options.fPIC def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - extracted_dir = self.name + "-" + self.version - os.rename(extracted_dir, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) + apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build(target=self._libname) - def package(self): - tools.save(os.path.join(self.package_folder, "licenses", "LICENSE"), self._license_text) + @property + def _license_text(self): + # Extract the License/s from the README to a file + tmp = load(self, os.path.join(self.source_folder, "README")) + return tmp[tmp.find("License", 1) : tmp.find("work.", 1) + 5] - self.copy(pattern="*.dylib*", dst="lib", src="lib", keep_path=False, symlinks=True) - self.copy(pattern="*.so*", dst="lib", src="lib", keep_path=False, symlinks=True) - self.copy(pattern="*.dll", dst="bin", src="bin", keep_path=False) - self.copy(pattern="*.a", dst="lib", src="lib", keep_path=False) - self.copy(pattern="*.lib", dst="lib", src="lib", keep_path=False) + def package(self): + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), self._license_text) + for pattern in ["*.lib", "*.a", "*.so*", "*.dylib"]: + copy(self, pattern, + dst=os.path.join(self.package_folder, "lib"), + src=self.build_folder, + keep_path=False) + copy(self, "*.dll", + dst=os.path.join(self.package_folder, "bin"), + src=self.build_folder, + keep_path=False) + copy(self, "easylzma/*", + dst=os.path.join(self.package_folder, "include"), + src=os.path.join(self.source_folder, "src")) + fix_apple_shared_install_name(self) - self.copy("easylzma/*", dst="include", src=os.path.join(self._source_subfolder, "src")) + @property + def _libname(self): + return "easylzma" if self.options.shared else "easylzma_s" def package_info(self): self.cpp_info.libs = [self._libname] if self.options.shared: self.cpp_info.defines = ["EASYLZMA_SHARED"] - if self.settings.compiler == "Visual Studio": - if "d" in str(self.settings.compiler.runtime): + if is_msvc(self): + if "d" in msvc_runtime_flag(self): self.cpp_info.defines.append("DEBUG") diff --git a/recipes/easylzma/all/test_package/CMakeLists.txt b/recipes/easylzma/all/test_package/CMakeLists.txt index 34af13462f44f8..6e6b478dec699f 100644 --- a/recipes/easylzma/all/test_package/CMakeLists.txt +++ b/recipes/easylzma/all/test_package/CMakeLists.txt @@ -1,8 +1,7 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(easylzma REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE easylzma::easylzma) diff --git a/recipes/easylzma/all/test_package/conanfile.py b/recipes/easylzma/all/test_package/conanfile.py index 4903f1a7e8fa0f..ef5d7042163ecc 100644 --- a/recipes/easylzma/all/test_package/conanfile.py +++ b/recipes/easylzma/all/test_package/conanfile.py @@ -1,9 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os + class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -11,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/easylzma/all/test_v1_package/CMakeLists.txt b/recipes/easylzma/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/easylzma/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/easylzma/all/test_v1_package/conanfile.py b/recipes/easylzma/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..6c9d5dba712c72 --- /dev/null +++ b/recipes/easylzma/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools +import os + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From c72db666923646b530994ef87293d6ea4bf13b7b Mon Sep 17 00:00:00 2001 From: Paul Harris Date: Fri, 6 Oct 2023 23:21:44 +0800 Subject: [PATCH 0984/1140] (#19633) [sentry-crashpad] add #include to fix compile with gcc13 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * sentry-crashpad: add #include to fix compile with gcc13 * Adjusted patch_type to portability * Properly source patch * Use upstream patch --------- Co-authored-by: Rubén Rincón Blanco Co-authored-by: Daniel --- recipes/sentry-crashpad/all/conandata.yml | 7 ++ ...0.2.6-0001-missing-installed-headers.patch | 66 ------------------- .../patches/0.6.5-0001-fix-for-gcc13.patch | 20 ++++++ 3 files changed, 27 insertions(+), 66 deletions(-) delete mode 100644 recipes/sentry-crashpad/all/patches/0.2.6-0001-missing-installed-headers.patch create mode 100644 recipes/sentry-crashpad/all/patches/0.6.5-0001-fix-for-gcc13.patch diff --git a/recipes/sentry-crashpad/all/conandata.yml b/recipes/sentry-crashpad/all/conandata.yml index ced5e36dba275c..26aa302e7bd27b 100644 --- a/recipes/sentry-crashpad/all/conandata.yml +++ b/recipes/sentry-crashpad/all/conandata.yml @@ -14,3 +14,10 @@ sources: "0.4.18": url: "https://github.com/getsentry/sentry-native/releases/download/0.4.18/sentry-native.zip" sha256: "41fdf6499cd8576142beb03104badcc9e0b80b8ef27080ca71cd4408cc1d7ece" + +patches: + "0.6.5": + - patch_file: "patches/0.6.5-0001-fix-for-gcc13.patch" + patch_type: "backport" + patch_description: "Extra header required for gcc13" + patch_source: "https://chromium-review.googlesource.com/c/chromium/mini_chromium/+/4847514" diff --git a/recipes/sentry-crashpad/all/patches/0.2.6-0001-missing-installed-headers.patch b/recipes/sentry-crashpad/all/patches/0.2.6-0001-missing-installed-headers.patch deleted file mode 100644 index 4f57a94cccd7d1..00000000000000 --- a/recipes/sentry-crashpad/all/patches/0.2.6-0001-missing-installed-headers.patch +++ /dev/null @@ -1,66 +0,0 @@ ---- external/crashpad/compat/CMakeLists.txt -+++ external/crashpad/compat/CMakeLists.txt -@@ -108,12 +108,13 @@ - endif() - - if(LINUX OR ANDROID) -- target_include_directories(crashpad_compat ${TI_YPE} "$") -+ target_include_directories(crashpad_compat ${TI_TYPE} "$") -+ target_link_libraries(crashpad_compat ${TI_TYPE} ${CMAKE_DL_LIBS}) - endif() - - if(ANDROID) -- target_include_directories(crashpad_compat ${TI_YPE} "$") -+ target_include_directories(crashpad_compat ${TI_TYPE} "$") - endif() - - set_property(TARGET crashpad_compat PROPERTY EXPORT_NAME compat) - add_library(crashpad::compat ALIAS crashpad_compat) ---- external/crashpad/third_party/mini_chromium/CMakeLists.txt -+++ external/crashpad/third_party/mini_chromium/CMakeLists.txt -@@ -172,3 +172,7 @@ - DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/crashpad" - FILES_MATCHING PATTERN "*.h" - ) -+crashpad_install_dev(DIRECTORY build -+ DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/crashpad/mini_chromium" -+ FILES_MATCHING PATTERN "*.h" -+) ---- external/crashpad/util/CMakeLists.txt -+++ external/crashpad/util/CMakeLists.txt -@@ -237,7 +237,7 @@ - linux/thread_info.cc - linux/thread_info.h - linux/traits.h -- misc/capture_context_linux.S -+ misc/capture_context_linux.S misc/time_linux.cc - misc/paths_linux.cc - posix/process_info_linux.cc - process/process_memory_linux.cc -@@ -353,7 +353,7 @@ - target_include_directories(crashpad_util PRIVATE - $ - ) - target_link_libraries(crashpad_util - PRIVATE - $ - PUBLIC -@@ -371,6 +371,10 @@ - ) - endif() - -+if(LINUX) -+ target_link_libraries(crashpad_util PRIVATE rt pthread) -+endif() -+ - if(WIN32) - target_link_libraries(crashpad_util PRIVATE user32 version winhttp) - if(MSVC) -@@ -395,3 +399,7 @@ - add_library(crashpad::util ALIAS crashpad_util) - - crashpad_install_target(crashpad_util) -+crashpad_install_dev(DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/" -+ DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}/crashpad/util" -+ FILES_MATCHING PATTERN "*.h" -+) diff --git a/recipes/sentry-crashpad/all/patches/0.6.5-0001-fix-for-gcc13.patch b/recipes/sentry-crashpad/all/patches/0.6.5-0001-fix-for-gcc13.patch new file mode 100644 index 00000000000000..b3a766009b3a74 --- /dev/null +++ b/recipes/sentry-crashpad/all/patches/0.6.5-0001-fix-for-gcc13.patch @@ -0,0 +1,20 @@ +--- a/external/crashpad/third_party/mini_chromium/mini_chromium/base/logging.h 2023-08-25 09:55:27.677142704 +0800 ++++ b/external/crashpad/third_party/mini_chromium/mini_chromium/base/logging.h 2023-08-25 10:06:01.654142494 +0800 +@@ -11,6 +11,7 @@ + #include + #include + #include ++#include + + #include "base/check.h" + #include "base/check_op.h" +--- a/external/crashpad/third_party/mini_chromium/mini_chromium/base/strings/utf_string_conversion_utils.h 2023-08-25 10:11:28.084886020 +0800 ++++ b/external/crashpad/third_party/mini_chromium/mini_chromium/base/strings/utf_string_conversion_utils.h 2023-08-25 11:06:37.044297949 +0800 +@@ -6,6 +6,7 @@ + #define MINI_CHROMIUM_BASE_STRINGS_UTF_STRING_CONVERSION_UTILS_H_ + + #include ++#include + + namespace base { + From c076a5dd8c0049a8e5b610b7d96eb5cc0ee21baf Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 6 Oct 2023 18:27:42 +0300 Subject: [PATCH 0985/1140] (#18726) twitch-native-ipc: migrate to Conan v2 * twitch-native-ipc: migrate to Conan v2 * twitch-native-ipc: move DLLs from lib to bin * twitch-native-ipc: restore VirtualRunEnv in test_package * twitch-native-ipc: bump deps * twitch-native-ipc: remove unnecessary copying of DLLs --------- Co-authored-by: Daniel --- recipes/twitch-native-ipc/all/CMakeLists.txt | 6 -- recipes/twitch-native-ipc/all/conandata.yml | 3 - recipes/twitch-native-ipc/all/conanfile.py | 101 ++++++++++-------- .../all/patches/cmake-fixes.patch | 57 ++++++---- .../all/patches/linux-build-fixes.patch | 12 +++ .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 24 +++-- .../all/test_package/example.c | 10 +- .../all/test_package/example2.cpp | 5 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 18 ++++ 11 files changed, 157 insertions(+), 96 deletions(-) delete mode 100644 recipes/twitch-native-ipc/all/CMakeLists.txt create mode 100644 recipes/twitch-native-ipc/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/twitch-native-ipc/all/test_v1_package/conanfile.py diff --git a/recipes/twitch-native-ipc/all/CMakeLists.txt b/recipes/twitch-native-ipc/all/CMakeLists.txt deleted file mode 100644 index 3f96a3374441cc..00000000000000 --- a/recipes/twitch-native-ipc/all/CMakeLists.txt +++ /dev/null @@ -1,6 +0,0 @@ -cmake_minimum_required(VERSION 3.1) -project(cmake_wrapper) -include(conanbuildinfo.cmake) - -conan_basic_setup(TARGETS) -add_subdirectory("source_subfolder") diff --git a/recipes/twitch-native-ipc/all/conandata.yml b/recipes/twitch-native-ipc/all/conandata.yml index 4ddda5e545311f..0ca341563c80b5 100644 --- a/recipes/twitch-native-ipc/all/conandata.yml +++ b/recipes/twitch-native-ipc/all/conandata.yml @@ -5,8 +5,5 @@ sources: patches: "3.1.1": - patch_file: "patches/cmake-fixes.patch" - base_path: "source_subfolder" - patch_file: "patches/linux-build-fixes.patch" - base_path: "source_subfolder" - patch_file: "patches/export-fixes.patch" - base_path: "source_subfolder" diff --git a/recipes/twitch-native-ipc/all/conanfile.py b/recipes/twitch-native-ipc/all/conanfile.py index 9e025ba63f9933..72b9b555dec987 100644 --- a/recipes/twitch-native-ipc/all/conanfile.py +++ b/recipes/twitch-native-ipc/all/conanfile.py @@ -1,31 +1,34 @@ -from conans import ConanFile, CMake, tools -from conans.errors import ConanInvalidConfiguration -from conans.tools import Version import os +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd, stdcpp_library +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm +from conan.tools.microsoft import is_msvc_static_runtime +from conan.tools.scm import Version + +required_conan_version = ">=1.53.0" + + class TwitchNativeIpcConan(ConanFile): name = "twitch-native-ipc" + description = "Twitch native IPC library" license = "MIT" - homepage = "https://github.com/twitchtv/twitch-native-ipc" url = "https://github.com/conan-io/conan-center-index" - description = "Twitch natve ipc library" + homepage = "https://github.com/twitchtv/twitch-native-ipc" topics = ("twitch", "ipc") - settings = "os", "compiler", "build_type", "arch" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - generators = "cmake" - exports = ["CMakeLists.txt", "patches/**"] - requires = "libuv/1.40.0" - - _cmake = None - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } @property def _compilers_min_version(self): @@ -33,63 +36,69 @@ def _compilers_min_version(self): "gcc": "8", "clang": "8", "apple-clang": "10", + "msvc": "191", "Visual Studio": "15", } + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): if self.settings.compiler.cppstd: - tools.check_min_cppstd(self, 17) + check_min_cppstd(self, 17) min_version = self._compilers_min_version.get(str(self.settings.compiler), False) if min_version: - if tools.Version(self.settings.compiler.version) < min_version: + if Version(self.settings.compiler.version) < min_version: raise ConanInvalidConfiguration("twitch-native-ipc requires C++17") else: - self.output.warn("unknown compiler, assuming C++17 support") + self.output.warning("unknown compiler, assuming C++17 support") if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename("{}-{}".format(self.name, self.version), self._source_subfolder) + def layout(self): + cmake_layout(self, src_folder="src") - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.definitions["ENABLE_CODE_FORMATTING"] = False - self._cmake.definitions["BUILD_TESTING"] = False + def requirements(self): + self.requires("libuv/1.46.0") - if self.settings.os == "Windows": - self._cmake.definitions["MSVC_DYNAMIC_RUNTIME"] = self.settings.compiler.runtime in ("MD", "MDd") + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) - self._cmake.configure(build_folder=self._build_subfolder) - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.variables["ENABLE_CODE_FORMATTING"] = False + tc.variables["BUILD_TESTING"] = False + if self.settings.os == "Windows": + tc.variables["MSVC_DYNAMIC_RUNTIME"] = not is_msvc_static_runtime(self) + tc.generate() + tc = CMakeDeps(self) + tc.generate() def build(self): - for patch in self.conan_data.get("patches", {}).get(self.version, []): - tools.patch(**patch) - cmake = self._configure_cmake() + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() cmake.build() def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) cmake.install() - tools.remove_files_by_mask(os.path.join(self.package_folder, "lib"), "*.pdb") + rm(self, "*.pdb", os.path.join(self.package_folder, "lib"), recursive=True) def package_info(self): self.cpp_info.libs = ["nativeipc"] if self.settings.os == "Windows" and self.options.shared: self.cpp_info.defines = ["NATIVEIPC_IMPORT"] - if self.settings.os == "Linux": + if self.settings.os in ["Linux", "FreeBSD"]: self.cpp_info.system_libs = ["m"] - if tools.stdcpp_library(self): - self.cpp_info.system_libs.append(tools.stdcpp_library(self)) + if stdcpp_library(self): + self.cpp_info.system_libs.append(stdcpp_library(self)) diff --git a/recipes/twitch-native-ipc/all/patches/cmake-fixes.patch b/recipes/twitch-native-ipc/all/patches/cmake-fixes.patch index e9ef8141281a0d..0b516bd88e5393 100644 --- a/recipes/twitch-native-ipc/all/patches/cmake-fixes.patch +++ b/recipes/twitch-native-ipc/all/patches/cmake-fixes.patch @@ -9,26 +9,30 @@ index 491ae46..c0a4f3d 100644 include(setup) project(nativeipc) -diff --git a/cmakeUtils/conanutils.cmake b/cmakeUtils/conanutils.cmake -index cc6c07c..cbf0cd6 100644 ---- a/cmakeUtils/conanutils.cmake -+++ b/cmakeUtils/conanutils.cmake -@@ -59,7 +59,8 @@ macro(run_conan) - set(_keeprpath "KEEP_RPATHS") - endif() - -- conan_cmake_run(CONANFILE conan/conanfile.py -+ if(NOT CONAN_EXPORTED) -+ conan_cmake_run(CONANFILE conan/conanfile.py - BASIC_SETUP - CMAKE_TARGETS - NO_OUTPUT_DIRS -@@ -71,4 +72,5 @@ macro(run_conan) - RELWITHDEBINFO_PROFILE ${_profile} - ENV "CONAN_CMAKE_BINARY_DIR_PATH=${CMAKE_BINARY_DIR}" - ) -+ endif() - endmacro() +diff --git a/cmakeUtils/setup.cmake b/cmakeUtils/setup.cmake +--- cmakeUtils/setup.cmake ++++ cmakeUtils/setup.cmake +@@ -1,6 +1,4 @@ + include(utilities) +-include(conan) +-include(conanutils) + + macro(setup_project) + if(NOT CMAKE_BUILD_TYPE) +@@ -13,13 +11,9 @@ + option(ENABLE_CODE_DOCUMENTATION "enable code documenation generation" OFF) + option(MSVC_DYNAMIC_RUNTIME "change default runtime" ON) + +- conan_check(VERSION 1.22.2 REQUIRED) +- + setup_default_cxx_compile_options() + + set_output_directories(${CMAKE_BINARY_DIR}/bin) +- +- run_conan() + + include(CTest) + if(BUILD_TESTING) diff --git a/cmakeUtils/unix.cmake b/cmakeUtils/unix.cmake index 5f4bb4c..9b2856a 100644 --- a/cmakeUtils/unix.cmake @@ -46,7 +50,18 @@ diff --git a/libnativeipc/CMakeLists.txt b/libnativeipc/CMakeLists.txt index fe5cc30..173a156 100644 --- a/libnativeipc/CMakeLists.txt +++ b/libnativeipc/CMakeLists.txt -@@ -81,7 +81,9 @@ if(MSVC) +@@ -59,8 +59,9 @@ + include/nativeipc + ) + ++find_package(libuv REQUIRED CONFIG) + target_link_libraries(nativeipc PRIVATE +- CONAN_PKG::libuv) ++ uv) + + target_compile_definitions(nativeipc PRIVATE) + +@@ -81,7 +82,9 @@ endif() install(TARGETS nativeipc diff --git a/recipes/twitch-native-ipc/all/patches/linux-build-fixes.patch b/recipes/twitch-native-ipc/all/patches/linux-build-fixes.patch index d62079e114cc88..6ce9e9cc4ff9bf 100644 --- a/recipes/twitch-native-ipc/all/patches/linux-build-fixes.patch +++ b/recipes/twitch-native-ipc/all/patches/linux-build-fixes.patch @@ -83,3 +83,15 @@ index 40154b7..9772073 100644 ); #if DO_EXPLICIT_CHECKS +diff --git a/tests/UVServerTransport.h b/libnativeipc/src/UVServerTransport.h +index 40154b7..9772073 100644 +--- a/libnativeipc/src/UVServerTransport.h ++++ b/libnativeipc/src/UVServerTransport.h +@@ -7,6 +7,7 @@ + #include + #include + #include ++#include + + namespace Twitch::IPC { + class UVServerTransport diff --git a/recipes/twitch-native-ipc/all/test_package/CMakeLists.txt b/recipes/twitch-native-ipc/all/test_package/CMakeLists.txt index 667b93ec41536f..9e540f91ccbcd6 100644 --- a/recipes/twitch-native-ipc/all/test_package/CMakeLists.txt +++ b/recipes/twitch-native-ipc/all/test_package/CMakeLists.txt @@ -1,12 +1,11 @@ -cmake_minimum_required(VERSION 3.1) +cmake_minimum_required(VERSION 3.15) project(PackageTest) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(KEEP_RPATHS) +find_package(twitch-native-ipc REQUIRED CONFIG) add_executable(example example.c) -target_link_libraries(example ${CONAN_LIBS}) +target_link_libraries(example twitch-native-ipc::twitch-native-ipc) add_executable(example2 example2.cpp) -target_link_libraries(example2 ${CONAN_LIBS}) +target_link_libraries(example2 twitch-native-ipc::twitch-native-ipc) target_compile_features(example2 PRIVATE cxx_std_17) diff --git a/recipes/twitch-native-ipc/all/test_package/conanfile.py b/recipes/twitch-native-ipc/all/test_package/conanfile.py index d9dd1034a82725..673b6b659b1666 100644 --- a/recipes/twitch-native-ipc/all/test_package/conanfile.py +++ b/recipes/twitch-native-ipc/all/test_package/conanfile.py @@ -1,11 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" -class TwitchNativeIpcTestConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -13,6 +21,8 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self): - self.run(os.path.join("bin", "example"), run_environment=True) - self.run(os.path.join("bin", "example2"), run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "example") + self.run(bin_path, env="conanrun") + bin_path = os.path.join(self.cpp.build.bindir, "example2") + self.run(bin_path, env="conanrun") diff --git a/recipes/twitch-native-ipc/all/test_package/example.c b/recipes/twitch-native-ipc/all/test_package/example.c index 5ba8bef81f80ec..8d7d208570a6e5 100644 --- a/recipes/twitch-native-ipc/all/test_package/example.c +++ b/recipes/twitch-native-ipc/all/test_package/example.c @@ -1,19 +1,17 @@ +#include + #include #include -#include int main() { void *server = Twitch_IPC_ConnectionCreateServer("test"); void *client = Twitch_IPC_ConnectionCreateClient("test"); - if(server && client) - { + if (server && client) { printf("success\n"); Twitch_IPC_ConnectionDestroy(server); Twitch_IPC_ConnectionDestroy(client); - } - else - { + } else { abort(); } } diff --git a/recipes/twitch-native-ipc/all/test_package/example2.cpp b/recipes/twitch-native-ipc/all/test_package/example2.cpp index 42a57ddd919136..e2e24904356299 100644 --- a/recipes/twitch-native-ipc/all/test_package/example2.cpp +++ b/recipes/twitch-native-ipc/all/test_package/example2.cpp @@ -1,12 +1,13 @@ -#include #include +#include + int main() { using namespace Twitch::IPC; auto server = ConnectionFactory::newServerConnection("test"); auto client = ConnectionFactory::newClientConnection("test"); - if(server && client) { + if (server && client) { std::cout << "success\n"; server.reset(); client.reset(); diff --git a/recipes/twitch-native-ipc/all/test_v1_package/CMakeLists.txt b/recipes/twitch-native-ipc/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/twitch-native-ipc/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/twitch-native-ipc/all/test_v1_package/conanfile.py b/recipes/twitch-native-ipc/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..bbac244c5a058a --- /dev/null +++ b/recipes/twitch-native-ipc/all/test_v1_package/conanfile.py @@ -0,0 +1,18 @@ +import os + +from conans import ConanFile, CMake, tools + + +class TwitchNativeIpcTestConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(os.path.join("bin", "example"), run_environment=True) + self.run(os.path.join("bin", "example2"), run_environment=True) From a7191f25c1e880c4929b226ef9a3c36067129821 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 17:55:21 +0200 Subject: [PATCH 0986/1140] (#20370) wasmtime: several fixes for conan v2 - this recipes requires at least conan 1.53.0 due to usage of rm_safe - consistent min version between legacy Visual Studio and new msvc - do not use self.output.warn since it doesn't exist in conan v2 --- recipes/wasmtime/all/conanfile.py | 36 +++++++++++-------------------- 1 file changed, 13 insertions(+), 23 deletions(-) diff --git a/recipes/wasmtime/all/conanfile.py b/recipes/wasmtime/all/conanfile.py index 1ceb2e856e7777..4aec54bb577f27 100644 --- a/recipes/wasmtime/all/conanfile.py +++ b/recipes/wasmtime/all/conanfile.py @@ -1,12 +1,12 @@ +import os + from conan import ConanFile -from conan.tools.files import get, copy -from conan.tools.scm import Version from conan.errors import ConanInvalidConfiguration +from conan.tools.files import copy, get from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version -import os - -required_conan_version = ">=1.47.0" +required_conan_version = ">=1.53.0" class WasmtimeConan(ConanFile): @@ -27,14 +27,14 @@ class WasmtimeConan(ConanFile): no_copy_source = True @property - def _minimum_cpp_standard(self): + def _min_cppstd(self): return 11 @property def _minimum_compilers_version(self): return { "Visual Studio": "15", - "msvc": "190", + "msvc": "191", "apple-clang": "9.4", "clang": "3.3", "gcc": "5.1", @@ -58,27 +58,17 @@ def package_id(self): self.info.settings.compiler = "gcc" def validate(self): - compiler = self.settings.compiler - min_version = self._minimum_compilers_version[str(compiler)] - try: - if Version(compiler.version) < min_version: - msg = ( - f"{self.name} requires C{self._minimum_cpp_standard} features " - f"which are not supported by compiler {compiler} {compiler.version} !!" - ) - raise ConanInvalidConfiguration(msg) - except KeyError: - msg = ( - f"{self.name} recipe lacks information about the {compiler} compiler, " - f"support for the required C{self._minimum_cpp_standard} features is assumed" - ) - self.output.warn(msg) - try: self.conan_data["sources"][self.version][self._sources_os_key][str(self.settings.arch)] except KeyError: raise ConanInvalidConfiguration("Binaries for this combination of architecture/version/os are not available") + minimum_version = self._minimum_compilers_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 build(self): # This is packaging binaries so the download needs to be in build get(self, **self.conan_data["sources"][self.version][self._sources_os_key][str(self.settings.arch)], From 06986c931e97dd0b3268a3c70cd53e62aed457db Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Fri, 6 Oct 2023 18:42:52 +0200 Subject: [PATCH 0987/1140] (#20389) Add llvm to larger timeout list Signed-off-by: Uilian Ries --- .c3i/config_v1.yml | 3 ++- .c3i/config_v2.yml | 3 ++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index 7f7dc6d5833da2..9a047a70fde584 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -44,10 +44,11 @@ tasks: build_single_reference: package_id_cache_type: "none" timeout_minutes: 600 - large_timeout_minutes: 800 + large_timeout_minutes: 900 large_timeout_references: - boost - qt + - llvm cci: conan_v2_run_export: false write_comments: true diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index 26bfec81b6d30c..dae018bdc79517 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -35,10 +35,11 @@ tasks: build_single_reference: package_id_cache_type: "none" timeout_minutes: 600 - large_timeout_minutes: 800 + large_timeout_minutes: 900 large_timeout_references: - boost - qt + - llvm cci: conan_v2_run_export: false detailed_status_checks: false From fb0d85ca29cd42284556ddabc080ff3da0296712 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 6 Oct 2023 19:56:42 +0300 Subject: [PATCH 0988/1140] (#18732) cgltf: migrate to Conan v2 --- recipes/cgltf/all/CMakeLists.txt | 18 +-- recipes/cgltf/all/conanfile.py | 103 +++++++++--------- recipes/cgltf/all/test_package/CMakeLists.txt | 9 +- recipes/cgltf/all/test_package/conanfile.py | 21 +++- .../cgltf/all/test_v1_package/CMakeLists.txt | 8 ++ .../cgltf/all/test_v1_package/conanfile.py | 17 +++ 6 files changed, 101 insertions(+), 75 deletions(-) create mode 100644 recipes/cgltf/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/cgltf/all/test_v1_package/conanfile.py diff --git a/recipes/cgltf/all/CMakeLists.txt b/recipes/cgltf/all/CMakeLists.txt index 083b3a7d15fec0..86b1d0c12f5415 100644 --- a/recipes/cgltf/all/CMakeLists.txt +++ b/recipes/cgltf/all/CMakeLists.txt @@ -1,16 +1,15 @@ cmake_minimum_required(VERSION 3.4) project(cgltf C) -include(conanbuildinfo.cmake) -conan_basic_setup() +set(SOURCES_DIR ${CMAKE_CURRENT_LIST_DIR}/src) set(SRC_FILES - ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/cgltf.c - ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/cgltf_write.c + ${SOURCES_DIR}/cgltf.c + ${SOURCES_DIR}/cgltf_write.c ) set(HEADER_FILES - ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/cgltf.h - ${CMAKE_CURRENT_SOURCE_DIR}/source_subfolder/cgltf_write.h + ${SOURCES_DIR}/cgltf.h + ${SOURCES_DIR}/cgltf_write.h ) add_library(${PROJECT_NAME} ${SRC_FILES}) @@ -20,10 +19,5 @@ if(MSVC AND BUILD_SHARED_LIBS) endif() include(GNUInstallDirs) -install( - TARGETS ${PROJECT_NAME} - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} -) +install(TARGETS ${PROJECT_NAME}) install(FILES ${HEADER_FILES} DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) diff --git a/recipes/cgltf/all/conanfile.py b/recipes/cgltf/all/conanfile.py index bc0e435d4c8c58..df487c5e826cd2 100644 --- a/recipes/cgltf/all/conanfile.py +++ b/recipes/cgltf/all/conanfile.py @@ -1,26 +1,34 @@ -from conans import ConanFile, CMake, tools import os +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, export_conandata_patches, get, load, replace_in_file, save, rename + +required_conan_version = ">=1.53.0" + class CgltfConan(ConanFile): name = "cgltf" description = "Single-file glTF 2.0 loader and writer written in C99." license = "MIT" - topics = ("conan", "cgltf", "gltf", "header-only") - homepage = "https://github.com/jkuhlmann/cgltf" url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/jkuhlmann/cgltf" + topics = ("gltf", "header-only") + package_type = "library" settings = "os", "arch", "compiler", "build_type" - options = {"shared": [True, False], "fPIC": [True, False]} - default_options = {"shared": False, "fPIC": True} - - exports_sources = "CMakeLists.txt" - generators = "cmake" - _cmake = None + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } - @property - def _source_subfolder(self): - return "source_subfolder" + def export_sources(self): + copy(self, "CMakeLists.txt", src=self.recipe_folder, dst=self.export_sources_folder) + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": @@ -28,62 +36,53 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename(self.name + "-" + self.version, self._source_subfolder) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def _create_source_files(self): - cgltf_c = ( - "#define CGLTF_IMPLEMENTATION\n" - "#include \"cgltf.h\"\n" - ) - cgltf_write_c = ( - "#define CGLTF_WRITE_IMPLEMENTATION\n" - "#include \"cgltf_write.h\"\n" - ) - tools.save(os.path.join(self.build_folder, self._source_subfolder, "cgltf.c"), cgltf_c) - tools.save(os.path.join(self.build_folder, self._source_subfolder, "cgltf_write.c"), cgltf_write_c) + cgltf_c = '#define CGLTF_IMPLEMENTATION\n#include "cgltf.h"\n' + cgltf_write_c = '#define CGLTF_WRITE_IMPLEMENTATION\n#include "cgltf_write.h"\n' + save(self, os.path.join(self.build_folder, self.source_folder, "cgltf.c"), cgltf_c) + save(self, os.path.join(self.build_folder, self.source_folder, "cgltf_write.c"), cgltf_write_c) - def _configure_cmake(self): - if self._cmake: - return self._cmake - self._cmake = CMake(self) - self._cmake.configure() - return self._cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): self._create_source_files() - cmake = self._configure_cmake() + cmake = CMake(self) + cmake.configure(build_script_folder=self.source_path.parent) cmake.build() - def package(self): - self.copy("LICENSE", dst="licenses", src=self._source_subfolder) - cmake = self._configure_cmake() - cmake.install() - for header_file in ["cgltf.h", "cgltf_write.h"]: - header_fullpath = os.path.join(self.package_folder, "include", header_file) - self._remove_implementation(header_fullpath) - - @staticmethod - def _remove_implementation(header_fullpath): - header_content = tools.load(header_fullpath) + def _remove_implementation(self, header_fullpath): + header_content = load(self, header_fullpath) begin = header_content.find("/*\n *\n * Stop now, if you are only interested in the API.") end = header_content.find("/* cgltf is distributed under MIT license:", begin) implementation = header_content[begin:end] - tools.replace_in_file( + replace_in_file( + self, header_fullpath, implementation, - ( - "/**\n" - " * Implementation removed by conan during packaging.\n" - " * Don't forget to link libs provided in this package.\n" - " */\n\n" - ) + "/**\n * Implementation removed by conan during packaging.\n * Don't forget to link libs provided in this package.\n */\n\n", ) + def package(self): + copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + for header_file in ["cgltf.h", "cgltf_write.h"]: + header_fullpath = os.path.join(self.package_folder, "include", header_file) + self._remove_implementation(header_fullpath) + for dll in (self.package_path / "lib").glob("*.dll"): + rename(self, dll, self.package_path / "bin" / dll.name) + def package_info(self): self.cpp_info.libs = ["cgltf"] diff --git a/recipes/cgltf/all/test_package/CMakeLists.txt b/recipes/cgltf/all/test_package/CMakeLists.txt index 5f056d0a34a03b..ca0a3cec6c73ec 100644 --- a/recipes/cgltf/all/test_package/CMakeLists.txt +++ b/recipes/cgltf/all/test_package/CMakeLists.txt @@ -1,11 +1,10 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +find_package(cgltf REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE cgltf::cgltf) if(MSVC) target_compile_definitions(${PROJECT_NAME} PRIVATE _CRT_SECURE_NO_WARNINGS) endif() diff --git a/recipes/cgltf/all/test_package/conanfile.py b/recipes/cgltf/all/test_package/conanfile.py index ea57a464900be9..ef5d7042163ecc 100644 --- a/recipes/cgltf/all/test_package/conanfile.py +++ b/recipes/cgltf/all/test_package/conanfile.py @@ -1,10 +1,19 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os -from conans import ConanFile, CMake, tools class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/cgltf/all/test_v1_package/CMakeLists.txt b/recipes/cgltf/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/cgltf/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/cgltf/all/test_v1_package/conanfile.py b/recipes/cgltf/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..84ee68733e5167 --- /dev/null +++ b/recipes/cgltf/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +import os + +from conans import ConanFile, CMake, tools + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 4f467aae1811d4105259e0390599d7638cd0a053 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 6 Oct 2023 20:47:14 +0300 Subject: [PATCH 0989/1140] (#18977) tcp-wrappers: migrate to Conan v2 * tcp-wrappers: migrate to Conan v2 * tcp-wrappers: add -fPIC * tcp-wrappers: disable cross-building --- recipes/tcp-wrappers/all/conandata.yml | 3 - recipes/tcp-wrappers/all/conanfile.py | 117 ++++++++++-------- .../all/test_package/CMakeLists.txt | 9 +- .../all/test_package/conanfile.py | 21 +++- .../all/test_package/test_package.c | 2 +- .../all/test_v1_package/CMakeLists.txt | 8 ++ .../all/test_v1_package/conanfile.py | 17 +++ 7 files changed, 111 insertions(+), 66 deletions(-) create mode 100644 recipes/tcp-wrappers/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/tcp-wrappers/all/test_v1_package/conanfile.py diff --git a/recipes/tcp-wrappers/all/conandata.yml b/recipes/tcp-wrappers/all/conandata.yml index 59e770ecf55f2c..9aa6d859497fa2 100644 --- a/recipes/tcp-wrappers/all/conandata.yml +++ b/recipes/tcp-wrappers/all/conandata.yml @@ -5,8 +5,5 @@ sources: patches: "7.6": - patch_file: "patches/0001-shared-clang.patch" - base_path: "source_subfolder" - patch_file: "patches/0002-fix-warnings-by-include-headers.patch" - base_path: "source_subfolder" - patch_file: "patches/0003-add-severity-level-to-library.patch" - base_path: "source_subfolder" diff --git a/recipes/tcp-wrappers/all/conanfile.py b/recipes/tcp-wrappers/all/conanfile.py index 505aeec0d08d68..43c0049890c3cc 100644 --- a/recipes/tcp-wrappers/all/conanfile.py +++ b/recipes/tcp-wrappers/all/conanfile.py @@ -1,16 +1,26 @@ import os -from conans import AutoToolsBuildEnvironment, ConanFile, tools -from conans.errors import ConanInvalidConfiguration + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.apple import is_apple_os +from conan.tools.build import cross_building +from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get +from conan.tools.gnu import Autotools, AutotoolsToolchain +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc + +required_conan_version = ">=1.53.0" class TcpWrappersConan(ConanFile): name = "tcp-wrappers" - homepage = "ftp://ftp.porcupine.org/pub/security/index.html" description = "A security tool which acts as a wrapper for TCP daemons" - topics = ("conan", "tcp", "ip", "daemon", "wrapper") - url = "https://github.com/conan-io/conan-center-index" license = "BSD" - exports_sources = "patches/**" + url = "https://github.com/conan-io/conan-center-index" + homepage = "http://ftp.porcupine.org/pub/security/" + topics = ("tcp", "ip", "daemon", "wrapper") + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -20,76 +30,81 @@ class TcpWrappersConan(ConanFile): "shared": False, "fPIC": True, } - generators = "cmake" - @property - def _source_subfolder(self): - return "source_subfolder" - - @property - def _build_subfolder(self): - return "build_subfolder" + def export_sources(self): + export_conandata_patches(self) def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - if self.settings.compiler == "Visual Studio": + if is_msvc(self): raise ConanInvalidConfiguration("Visual Studio is not supported") if self.options.shared: - del self.options.fPIC - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.libcxx") + self.settings.rm_safe("compiler.cppstd") - def source(self): - tools.get(**self.conan_data["sources"][self.version]) - os.rename("tcp_wrappers_{}-ipv6.4".format(self.version), self._source_subfolder) + def layout(self): + basic_layout(self, src_folder="src") - def _patch_sources(self): - for patch in self.conan_data["patches"][self.version]: - tools.patch(**patch) + def validate(self): + if cross_building(self): + raise ConanInvalidConfiguration("Cross-building is not current supported.") - def build(self): - self._patch_sources() - with tools.chdir(self._source_subfolder): - autotools = AutoToolsBuildEnvironment(self) - make_args = [ - "REAL_DAEMON_DIR={}".format(tools.unix_path(os.path.join(self.package_folder, "bin"))), - "-j1", - "SHEXT={}".format(self._shext), - ] - if self.options.shared: - make_args.append("shared=1") - env_vars = autotools.vars - if self.options.get_safe("fPIC", True): - env_vars["CFLAGS"] += " -fPIC" - env_vars["ENV_CFLAGS"] = env_vars["CFLAGS"] - # env_vars["SHEXT"] = self._shext - print(env_vars) - with tools.environment_append(env_vars): - autotools.make(target="linux", args=make_args) + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) @property def _shext(self): - if tools.is_apple_os(self.settings.os): + if is_apple_os(self): return ".dylib" return ".so" - def package(self): - self.copy(pattern="DISCLAIMER", src=self._source_subfolder, dst="licenses") + def generate(self): + tc = AutotoolsToolchain(self) + tc.make_args.append("REAL_DAEMON_DIR=/bin") + tc.make_args.append(f"SHEXT={self._shext}") + if self.options.shared: + tc.make_args.append("shared=1") + if self.options.get_safe("fPIC") or self.options.shared: + tc.make_args.append("ENV_CFLAGS=-fPIC") + tc.generate() + + def build(self): + apply_conandata_patches(self) + with chdir(self, self.source_folder): + autotools = Autotools(self) + autotools.make(target="linux") + def package(self): + copy(self, "DISCLAIMER", + src=self.source_folder, + dst=os.path.join(self.package_folder, "licenses")) for exe in ("safe_finger", "tcpd", "tcpdchk", "tcpdmatch", "try-from"): - self.copy(exe, src=self._source_subfolder, dst="bin", keep_path=False) - self.copy("tcpd.h", src=self._source_subfolder, dst="include", keep_path=False) + copy(self, exe, + src=self.source_folder, + dst=os.path.join(self.package_folder, "bin"), + keep_path=False) + copy(self, "tcpd.h", + src=self.source_folder, + dst=os.path.join(self.package_folder, "include"), + keep_path=False) if self.options.shared: - self.copy("libwrap{}".format(self._shext), src=self._source_subfolder, dst="lib", keep_path=False) + copy(self, f"libwrap{self._shext}", + src=self.source_folder, + dst=os.path.join(self.package_folder, "lib"), + keep_path=False) else: - self.copy("libwrap.a", src=self._source_subfolder, dst="lib", keep_path=False) + copy(self, "libwrap.a", + src=self.source_folder, + dst=os.path.join(self.package_folder, "lib"), + keep_path=False) def package_info(self): self.cpp_info.libs = ["wrap"] bin_path = os.path.join(self.package_folder, "bin") - self.output.info("Appending PATH environment variable: {}".format(bin_path)) + self.output.info(f"Appending PATH environment variable: {bin_path}") self.env_info.PATH.append(bin_path) diff --git a/recipes/tcp-wrappers/all/test_package/CMakeLists.txt b/recipes/tcp-wrappers/all/test_package/CMakeLists.txt index 6226de918d1daa..6bc29bd3fc5c56 100644 --- a/recipes/tcp-wrappers/all/test_package/CMakeLists.txt +++ b/recipes/tcp-wrappers/all/test_package/CMakeLists.txt @@ -1,9 +1,8 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES C) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup() +find_package(tcp-wrappers REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE tcp-wrappers::tcp-wrappers) diff --git a/recipes/tcp-wrappers/all/test_package/conanfile.py b/recipes/tcp-wrappers/all/test_package/conanfile.py index bd7165a553cf41..ef5d7042163ecc 100644 --- a/recipes/tcp-wrappers/all/test_package/conanfile.py +++ b/recipes/tcp-wrappers/all/test_package/conanfile.py @@ -1,10 +1,19 @@ -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -12,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not tools.cross_building(self.settings): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/tcp-wrappers/all/test_package/test_package.c b/recipes/tcp-wrappers/all/test_package/test_package.c index 99571f42118169..297a2849f1a11f 100644 --- a/recipes/tcp-wrappers/all/test_package/test_package.c +++ b/recipes/tcp-wrappers/all/test_package/test_package.c @@ -6,6 +6,6 @@ int main (int argc, char *argv[]) { struct request_info req; request_init(&req, RQ_DAEMON, argv[0], RQ_FILE, 0, 0); - printf("host_acces: %d\n", hosts_access(&req)); + printf("host_access: %d\n", hosts_access(&req)); return 0; } diff --git a/recipes/tcp-wrappers/all/test_v1_package/CMakeLists.txt b/recipes/tcp-wrappers/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..91630d79f4abb3 --- /dev/null +++ b/recipes/tcp-wrappers/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package) + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package/ + ${CMAKE_CURRENT_BINARY_DIR}/test_package/) diff --git a/recipes/tcp-wrappers/all/test_v1_package/conanfile.py b/recipes/tcp-wrappers/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..7e2dfe859bb27b --- /dev/null +++ b/recipes/tcp-wrappers/all/test_v1_package/conanfile.py @@ -0,0 +1,17 @@ +from conans import ConanFile, CMake, tools +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self.settings): + bin_path = os.path.join("bin", "test_package") + self.run(bin_path, run_environment=True) From 6cb3836bffa35d5b31bb1b385e4d2982adf81f4b Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 6 Oct 2023 21:09:44 +0200 Subject: [PATCH 0990/1140] (#20076) onnxruntime: add version 1.16.0 * onnxruntime: add version 1.16.0 * set minimum gcc version to 9 for 1.16+ * set minimum msvc version to 193 for 1.16+ --- recipes/onnxruntime/all/conandata.yml | 10 ++ recipes/onnxruntime/all/conanfile.py | 23 +++- .../1.16.0-0001-cmake-dependencies.patch | 129 ++++++++++++++++++ recipes/onnxruntime/config.yml | 2 + 4 files changed, 160 insertions(+), 4 deletions(-) create mode 100644 recipes/onnxruntime/all/patches/1.16.0-0001-cmake-dependencies.patch diff --git a/recipes/onnxruntime/all/conandata.yml b/recipes/onnxruntime/all/conandata.yml index c1f4ac489cb97c..978433ed6b132c 100644 --- a/recipes/onnxruntime/all/conandata.yml +++ b/recipes/onnxruntime/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.16.0": + url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.16.0.tar.gz" + sha256: "3a4e57d454bce4349e11e2262fc47728a78b86ef1e0754514bbbc7d709e0a80d" "1.15.1": url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.15.1.tar.gz" sha256: "93a9b6f148639938ccbaa48d0f641d8f33312fdfcc69ee9466e11362b43917c4" @@ -6,6 +9,13 @@ sources: url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.14.1.tar.gz" sha256: "f998352b131bb89fa7dd1f1d87ddbafe647dfaddd11929b6b5168b3f4ef857de" patches: + "1.16.0": + - patch_file: "patches/1.16.0-0001-cmake-dependencies.patch" + patch_description: "CMake: ensure conan dependencies are used" + patch_type: "conan" + - patch_file: "patches/1.14.1-0004-abseil-no-string-view.patch" + patch_description: "allow to build with abseil built without c++17 support" + patch_type: "portability" "1.15.1": - patch_file: "patches/1.15.1-0001-cmake-dependencies.patch" patch_description: "CMake: ensure conan dependencies are used" diff --git a/recipes/onnxruntime/all/conanfile.py b/recipes/onnxruntime/all/conanfile.py index dc0f2dce95435e..7413919fad0ee3 100644 --- a/recipes/onnxruntime/all/conanfile.py +++ b/recipes/onnxruntime/all/conanfile.py @@ -41,10 +41,18 @@ def _min_cppstd(self): @property def _compilers_minimum_version(self): + if Version(self.version) < "1.16.0": + return { + "Visual Studio": "16", + "msvc": "192", + "gcc": "7", + "clang": "5", + "apple-clang": "10", + } return { - "Visual Studio": "16", - "msvc": "192", - "gcc": "7", + "Visual Studio": "17", + "msvc": "193", + "gcc": "9", "clang": "5", "apple-clang": "10", } @@ -69,6 +77,7 @@ def _onnx_version(self): return { "1.14": "1.13.1", "1.15": "1.14.1", + "1.16": "1.14.1", }[f"{version.major}.{version.minor}"] def requirements(self): @@ -249,7 +258,10 @@ def package_info(self): onnxruntime_libs.append("providers_xnnpack") self.cpp_info.libs = [f"onnxruntime_{lib}" for lib in onnxruntime_libs] - self.cpp_info.includedirs.append("include/onnxruntime/core/session") + if Version(self.version) < "1.16.0" or not self.options.shared: + self.cpp_info.includedirs.append("include/onnxruntime/core/session") + else: + self.cpp_info.includedirs.append("include/onnxruntime") if self.settings.os in ["Linux", "Android", "FreeBSD", "SunOS", "AIX"]: self.cpp_info.system_libs.append("m") @@ -259,5 +271,8 @@ def package_info(self): if self.settings.os == "Windows": self.cpp_info.system_libs.append("shlwapi") + # https://github.com/microsoft/onnxruntime/blob/v1.16.0/cmake/CMakeLists.txt#L1759-L1763 + self.cpp_info.set_property("cmake_file_name", "onnxruntime") + self.cpp_info.set_property("cmake_target_name", "onnxruntime::onnxruntime") # https://github.com/microsoft/onnxruntime/blob/v1.14.1/cmake/CMakeLists.txt#L1584 self.cpp_info.set_property("pkg_config_name", "onnxruntime") diff --git a/recipes/onnxruntime/all/patches/1.16.0-0001-cmake-dependencies.patch b/recipes/onnxruntime/all/patches/1.16.0-0001-cmake-dependencies.patch new file mode 100644 index 00000000000000..dacb2b9b27a86e --- /dev/null +++ b/recipes/onnxruntime/all/patches/1.16.0-0001-cmake-dependencies.patch @@ -0,0 +1,129 @@ +From a30759bc61768883302290d34efd6d0a5e09dc9f Mon Sep 17 00:00:00 2001 +From: mayeut +Date: Thu, 21 Sep 2023 23:20:46 +0200 +Subject: [PATCH] CMake: ensure conan dependencies are used + +--- + cmake/external/eigen.cmake | 5 +++-- + cmake/external/onnxruntime_external_deps.cmake | 15 ++++++++------- + cmake/external/xnnpack.cmake | 11 +++++++---- + cmake/onnxruntime_mlas.cmake | 2 +- + 4 files changed, 19 insertions(+), 14 deletions(-) + +diff --git a/cmake/external/eigen.cmake b/cmake/external/eigen.cmake +index c0f7ddc50e..a47de64cbd 100644 +--- a/cmake/external/eigen.cmake ++++ b/cmake/external/eigen.cmake +@@ -16,8 +16,9 @@ else () + eigen + URL ${DEP_URL_eigen} + URL_HASH SHA1=${DEP_SHA1_eigen} ++ FIND_PACKAGE_ARGS REQUIRED CONFIG NAMES Eigen3 + ) + endif() +- FetchContent_Populate(eigen) +- set(eigen_INCLUDE_DIRS "${eigen_SOURCE_DIR}") ++ onnxruntime_fetchcontent_makeavailable(eigen) ++ get_target_property(eigen_INCLUDE_DIRS Eigen3::Eigen INTERFACE_INCLUDE_DIRECTORIES) + endif() +diff --git a/cmake/external/onnxruntime_external_deps.cmake b/cmake/external/onnxruntime_external_deps.cmake +index 8e412c7847..0e2482d7de 100644 +--- a/cmake/external/onnxruntime_external_deps.cmake ++++ b/cmake/external/onnxruntime_external_deps.cmake +@@ -187,6 +187,7 @@ FetchContent_Declare( + date + URL ${DEP_URL_date} + URL_HASH SHA1=${DEP_SHA1_date} ++ FIND_PACKAGE_ARGS NAMES date + ) + onnxruntime_fetchcontent_makeavailable(date) + +@@ -196,6 +197,7 @@ FetchContent_Declare( + mp11 + URL ${DEP_URL_mp11} + URL_HASH SHA1=${DEP_SHA1_mp11} ++ FIND_PACKAGE_ARGS NAMES Boost + ) + + set(JSON_BuildTests OFF CACHE INTERNAL "") +@@ -314,6 +316,7 @@ FetchContent_Declare( + safeint + URL ${DEP_URL_safeint} + URL_HASH SHA1=${DEP_SHA1_safeint} ++ FIND_PACKAGE_ARGS NAMES safeint + ) + + # The next line will generate an error message "fatal: not a git repository", but it is ok. It is from flatbuffers +@@ -410,6 +413,7 @@ FetchContent_Declare( + URL ${DEP_URL_onnx} + URL_HASH SHA1=${DEP_SHA1_onnx} + PATCH_COMMAND ${ONNXRUNTIME_ONNX_PATCH_COMMAND} ++ FIND_PACKAGE_ARGS NAMES ONNX + ) + + +@@ -437,9 +441,6 @@ endif() + set(GSL_TARGET "Microsoft.GSL::GSL") + set(GSL_INCLUDE_DIR "$") + +-add_library(safeint_interface INTERFACE) +-target_include_directories(safeint_interface INTERFACE ${safeint_SOURCE_DIR}) +- + # XNNPACK EP + if (onnxruntime_USE_XNNPACK) + if (onnxruntime_DISABLE_CONTRIB_OPS) +@@ -467,10 +468,10 @@ set(onnxruntime_EXTERNAL_LIBRARIES ${onnxruntime_EXTERNAL_LIBRARIES_XNNPACK} ${W + # The other libs do not have the problem. All the sources are already there. We can compile them in any order. + set(onnxruntime_EXTERNAL_DEPENDENCIES onnx_proto flatbuffers::flatbuffers) + +-target_compile_definitions(onnx PUBLIC $ PRIVATE "__ONNX_DISABLE_STATIC_REGISTRATION") +-if (NOT onnxruntime_USE_FULL_PROTOBUF) +- target_compile_definitions(onnx PUBLIC "__ONNX_NO_DOC_STRINGS") +-endif() ++# target_compile_definitions(onnx PUBLIC $ PRIVATE "__ONNX_DISABLE_STATIC_REGISTRATION") ++# if (NOT onnxruntime_USE_FULL_PROTOBUF) ++# target_compile_definitions(onnx PUBLIC "__ONNX_NO_DOC_STRINGS") ++# endif() + + if (onnxruntime_RUN_ONNX_TESTS) + add_definitions(-DORT_RUN_EXTERNAL_ONNX_TESTS) +diff --git a/cmake/external/xnnpack.cmake b/cmake/external/xnnpack.cmake +index 7455584f1a..85d8177f45 100644 +--- a/cmake/external/xnnpack.cmake ++++ b/cmake/external/xnnpack.cmake +@@ -25,12 +25,15 @@ set(FXDIV_SOURCE_DIR ${fxdiv_SOURCE_DIR}) + + FetchContent_Declare(pthreadpool URL ${DEP_URL_pthreadpool} URL_HASH SHA1=${DEP_SHA1_pthreadpool}) + onnxruntime_fetchcontent_makeavailable(pthreadpool) +-FetchContent_Declare(googlexnnpack URL ${DEP_URL_googlexnnpack} URL_HASH SHA1=${DEP_SHA1_googlexnnpack} +-PATCH_COMMAND ${Patch_EXECUTABLE} --binary --ignore-whitespace -p1 < ${PROJECT_SOURCE_DIR}/patches/xnnpack/AddEmscriptenAndIosSupport.patch) ++FetchContent_Declare( ++ googlexnnpack ++ URL ${DEP_URL_googlexnnpack} ++ URL_HASH SHA1=${DEP_SHA1_googlexnnpack} ++ PATCH_COMMAND ${Patch_EXECUTABLE} --binary --ignore-whitespace -p1 < ${PROJECT_SOURCE_DIR}/patches/xnnpack/AddEmscriptenAndIosSupport.patch ++ FIND_PACKAGE_ARGS NAMES xnnpack ++) + + onnxruntime_fetchcontent_makeavailable(googlexnnpack) +-set(XNNPACK_DIR ${googlexnnpack_SOURCE_DIR}) +-set(XNNPACK_INCLUDE_DIR ${XNNPACK_DIR}/include) + + set(onnxruntime_EXTERNAL_LIBRARIES_XNNPACK XNNPACK pthreadpool) + +diff --git a/cmake/onnxruntime_mlas.cmake b/cmake/onnxruntime_mlas.cmake +index e0ccc504d7..819ffba884 100644 +--- a/cmake/onnxruntime_mlas.cmake ++++ b/cmake/onnxruntime_mlas.cmake +@@ -609,7 +609,7 @@ if (NOT onnxruntime_ORT_MINIMAL_BUILD) + + target_link_libraries(onnxruntime_mlas_q4dq PRIVATE ${ONNXRUNTIME_MLAS_LIBS} onnxruntime_common) + if (CPUINFO_SUPPORTED AND NOT CMAKE_SYSTEM_NAME STREQUAL "Emscripten") +- target_link_libraries(onnxruntime_mlas_q4dq PRIVATE cpuinfo) ++ target_link_libraries(onnxruntime_mlas_q4dq PRIVATE cpuinfo::cpuinfo) + endif() + if(NOT WIN32) + target_link_libraries(onnxruntime_mlas_q4dq PRIVATE nsync::nsync_cpp ${CMAKE_DL_LIBS}) +-- +2.39.2 (Apple Git-143) + diff --git a/recipes/onnxruntime/config.yml b/recipes/onnxruntime/config.yml index 4b89de81e9882d..af60133f50aa30 100644 --- a/recipes/onnxruntime/config.yml +++ b/recipes/onnxruntime/config.yml @@ -1,4 +1,6 @@ versions: + "1.16.0": + folder: all "1.15.1": folder: all "1.14.1": From 8d4d2e56ea0e477744db6cafe6f9b20ac70be9ac Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Fri, 6 Oct 2023 22:12:01 +0200 Subject: [PATCH 0991/1140] (#20288) mfast: improve creation of executable imported target + add package_type + bump sqlite3 * improve creation of executable imported target * fix test package * bump sqlite3 * add package_type * fix traits of boost --- recipes/mfast/all/conanfile.py | 23 +++++++++++++++------ recipes/mfast/all/test_package/conanfile.py | 15 +++----------- 2 files changed, 20 insertions(+), 18 deletions(-) diff --git a/recipes/mfast/all/conanfile.py b/recipes/mfast/all/conanfile.py index 41c45b6db58d81..11a8e4f600fa40 100644 --- a/recipes/mfast/all/conanfile.py +++ b/recipes/mfast/all/conanfile.py @@ -24,7 +24,7 @@ class mFASTConan(ConanFile): ) topics = ("fast", "fix", "fix-adapted-for-streaming", "financial-information-exchange", "libraries", "cpp") - + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -71,10 +71,11 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.75.0") + # transitive_headers=True because mfast/mfast_export.h includes boost/config.hpp + self.requires("boost/1.75.0", transitive_headers=True) self.requires("tinyxml2/9.0.0") if self.options.with_sqlite3: - self.requires("sqlite3/3.40.1") + self.requires("sqlite3/3.43.1") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -169,18 +170,28 @@ def _prepend_exec_target_in_fasttypegentarget(self): fast_type_filename = "fast_type_gen" + extension module_folder_depth = len(os.path.normpath(self._new_mfast_config_dir).split(os.path.sep)) fast_type_rel_path = "{}bin/{}".format("".join(["../"] * module_folder_depth), fast_type_filename) - exec_target_content = textwrap.dedent("""\ + exec_target_content = textwrap.dedent(f"""\ if(NOT TARGET fast_type_gen) + # Locate fast_type_gen executable + ## Workaround for legacy "cmake" generator in case of cross-build if(CMAKE_CROSSCOMPILING) - find_program(MFAST_EXECUTABLE fast_type_gen PATHS ENV PATH NO_DEFAULT_PATH) + find_program(MFAST_EXECUTABLE NAMES fast_type_gen PATHS ENV PATH NO_DEFAULT_PATH) + endif() + ## And here this will work fine with "CMakeToolchain" (for native & cross-build) + ## and legacy "cmake" generator in case of native build + if(NOT MFAST_EXECUTABLE) + find_program(MFAST_EXECUTABLE NAMES fast_type_gen) endif() + ## Last resort: we search in package folder directly if(NOT MFAST_EXECUTABLE) get_filename_component(MFAST_EXECUTABLE "${{CMAKE_CURRENT_LIST_DIR}}/{fast_type_rel_path}" ABSOLUTE) endif() + + # Create executable imported target fast_type_gen add_executable(fast_type_gen IMPORTED) set_property(TARGET fast_type_gen PROPERTY IMPORTED_LOCATION ${{MFAST_EXECUTABLE}}) endif() - """.format(fast_type_rel_path=fast_type_rel_path)) + """) module_abs_path = os.path.join(self.package_folder, self._fast_type_gen_target_file) old_content = load(self, module_abs_path) new_content = exec_target_content + old_content diff --git a/recipes/mfast/all/test_package/conanfile.py b/recipes/mfast/all/test_package/conanfile.py index fecd6e83f0b2f8..6f661e72969a0b 100644 --- a/recipes/mfast/all/test_package/conanfile.py +++ b/recipes/mfast/all/test_package/conanfile.py @@ -1,13 +1,12 @@ from conan import ConanFile -from conan.tools.build import can_run, cross_building +from conan.tools.build import can_run from conan.tools.cmake import CMake, cmake_layout -from conan.tools.env import VirtualBuildEnv, VirtualRunEnv import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "CMakeToolchain", "CMakeDeps" + generators = "CMakeToolchain", "CMakeDeps", "VirtualBuildEnv", "VirtualRunEnv" test_type = "explicit" def layout(self): @@ -17,15 +16,7 @@ def requirements(self): self.requires(self.tested_reference_str) def build_requirements(self): - if hasattr(self, "settings_build") and cross_building(self): - self.tool_requires(self.tested_reference_str) - - def generate(self): - VirtualRunEnv(self).generate() - if hasattr(self, "settings_build") and cross_building(self): - VirtualBuildEnv(self).generate() - else: - VirtualRunEnv(self).generate(scope="build") + self.tool_requires(self.tested_reference_str) def build(self): cmake = CMake(self) From fb30f195eefbf1f1645d7be74de4d239e14678b1 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 7 Oct 2023 06:20:49 +0900 Subject: [PATCH 0992/1140] (#20347) cppcommon: add version 1.0.4.0 --- recipes/cppcommon/all/conandata.yml | 10 ++ recipes/cppcommon/all/conanfile.py | 4 +- .../0001-update-cmakelists-1-0-4-0.patch | 108 ++++++++++++++++++ .../0003-define-win32-winnt-1-0-4-0.patch | 14 +++ recipes/cppcommon/config.yml | 2 + 5 files changed, 136 insertions(+), 2 deletions(-) create mode 100644 recipes/cppcommon/all/patches/0001-update-cmakelists-1-0-4-0.patch create mode 100644 recipes/cppcommon/all/patches/0003-define-win32-winnt-1-0-4-0.patch diff --git a/recipes/cppcommon/all/conandata.yml b/recipes/cppcommon/all/conandata.yml index c2897878ad2bc7..0a74dfd6a553f8 100644 --- a/recipes/cppcommon/all/conandata.yml +++ b/recipes/cppcommon/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.0.4.0": + url: "https://github.com/chronoxor/CppCommon/archive/1.0.4.0.tar.gz" + sha256: "724865a64309ab24b3e10d29b04dfec821003013635eff84dd2108f98e7a6fc3" "1.0.3.0": url: "https://github.com/chronoxor/CppCommon/archive/1.0.3.0.tar.gz" sha256: "af530d3550a050d4ed73a680b016e043ea6f4f56e11163226f2a6e24d9eae4ca" @@ -15,6 +18,13 @@ sources: url: "https://github.com/chronoxor/CppCommon/archive/cacfa9554d367467808663d9d5a695933ae566bb.tar.gz" sha256: "d2e717798e1668c831ee977763eaff7413ef48e6e0914a6322c9918016092048" patches: + "1.0.4.0": + - patch_file: "patches/0001-update-cmakelists-1-0-4-0.patch" + patch_description: "use cci packages" + patch_type: "conan" + - patch_file: "patches/0003-define-win32-winnt-1-0-4-0.patch" + patch_description: "define _WIN32_WINNT" + patch_type: "portability" "1.0.3.0": - patch_file: "patches/0001-update-cmakelists-1-0-3-0.patch" patch_description: "use cci packages" diff --git a/recipes/cppcommon/all/conanfile.py b/recipes/cppcommon/all/conanfile.py index 4997a9d1cf9fba..9e2726f3581c59 100644 --- a/recipes/cppcommon/all/conanfile.py +++ b/recipes/cppcommon/all/conanfile.py @@ -62,12 +62,12 @@ def requirements(self): if Version(self.version) < "1.0.3" or self.version == "cci.20201104": self.requires("fmt/8.1.1") else: - self.requires("fmt/10.1.0") + self.requires("fmt/10.1.0", transitive_headers=True) if self.settings.os == "Linux": self.requires("util-linux-libuuid/2.39") def validate(self): - if self.settings.compiler.cppstd: + if self.settings.compiler.get_safe("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: diff --git a/recipes/cppcommon/all/patches/0001-update-cmakelists-1-0-4-0.patch b/recipes/cppcommon/all/patches/0001-update-cmakelists-1-0-4-0.patch new file mode 100644 index 00000000000000..0d4c06013abe8a --- /dev/null +++ b/recipes/cppcommon/all/patches/0001-update-cmakelists-1-0-4-0.patch @@ -0,0 +1,108 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index daa796b..c76bfef 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -18,30 +18,31 @@ if(DOXYGEN_FOUND) + endif() + + # CMake module path +-set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") ++#set(CMAKE_MODULE_PATH "${CMAKE_CURRENT_SOURCE_DIR}/cmake") + + # Compiler features +-include(SetCompilerFeatures) +-include(SetCompilerWarnings) +-include(SetPlatformFeatures) +-include(SystemInformation) ++#include(SetCompilerFeatures) ++#include(SetCompilerWarnings) ++#include(SetPlatformFeatures) ++#include(SystemInformation) + + # External packages + find_package(Threads REQUIRED) ++find_package(fmt REQUIRED) + if(UNIX AND NOT APPLE AND NOT MSYS) + find_package(LibBFD) + find_package(LibDL) + find_package(LibRT) +- find_package(LibUUID) ++ find_package(libuuid) + endif() + if(WIN32 OR MSYS) + find_package(DbgHelp) + find_package(RPC) +- find_package(Userenv) ++# find_package(Userenv) + endif() + + # Modules +-add_subdirectory("modules") ++#add_subdirectory("modules") + + # Link libraries + list(APPEND LINKLIBS Threads::Threads) +@@ -49,17 +50,18 @@ if(UNIX AND NOT APPLE AND NOT MSYS) + list(APPEND LINKLIBS ${LIBBFD_LIBRARIES}) + list(APPEND LINKLIBS ${LIBDL_LIBRARIES}) + list(APPEND LINKLIBS ${LIBRT_LIBRARIES}) +- list(APPEND LINKLIBS ${LIBUUID_LIBRARIES}) ++ list(APPEND LINKLIBS libuuid::libuuid) + endif() + if(WIN32 OR MSYS) + list(APPEND LINKLIBS ${DBGHELP_LIBRARIES}) + list(APPEND LINKLIBS ${RPC_LIBRARIES}) +- list(APPEND LINKLIBS ${USERENV_LIBRARIES}) ++ list(APPEND LINKLIBS userenv) ++ list(APPEND LINKLIBS rpcrt4) + list(APPEND LINKLIBS ${VLD_LIBRARIES}) + endif() + + # System directories +-include_directories(SYSTEM "${CMAKE_CURRENT_SOURCE_DIR}/modules") ++#include_directories(SYSTEM "${CMAKE_CURRENT_SOURCE_DIR}/modules") + include_directories(SYSTEM "${CMAKE_CURRENT_SOURCE_DIR}/plugins") + + # Library +@@ -68,8 +70,9 @@ file(GLOB_RECURSE LIB_INLINE_FILES "include/*.inl" "source/*.inl") + file(GLOB_RECURSE LIB_SOURCE_FILES "include/*.cpp" "source/*.cpp") + add_library(cppcommon ${LIB_HEADER_FILES} ${LIB_INLINE_FILES} ${LIB_SOURCE_FILES}) + set_target_properties(cppcommon PROPERTIES COMPILE_FLAGS "${PEDANTIC_COMPILE_FLAGS}" FOLDER "libraries") +-target_include_directories(cppcommon PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include" PUBLIC ${vld}) +-target_link_libraries(cppcommon ${LINKLIBS} fmt) ++target_include_directories(cppcommon PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include") ++target_compile_features(cppcommon PUBLIC cxx_std_17) ++target_link_libraries(cppcommon PUBLIC ${LINKLIBS} fmt::fmt) + list(APPEND INSTALL_TARGETS cppcommon) + list(APPEND LINKLIBS cppcommon) + +@@ -91,6 +94,7 @@ if(NOT CPPCOMMON_MODULE) + list(APPEND INSTALL_TARGETS_PDB ${PLUGIN_TARGET}) + endforeach() + ++ if (0) + # Examples + file(GLOB EXAMPLE_HEADER_FILES "examples/*.h") + file(GLOB EXAMPLE_INLINE_FILES "examples/*.inl") +@@ -136,15 +140,16 @@ if(NOT CPPCOMMON_MODULE) + # CTest + enable_testing() + add_test(cppcommon-tests cppcommon-tests --durations yes --order lex) ++ endif() + + # Install + install(TARGETS ${INSTALL_TARGETS} +- RUNTIME DESTINATION "${PROJECT_SOURCE_DIR}/bin" +- LIBRARY DESTINATION "${PROJECT_SOURCE_DIR}/bin" +- ARCHIVE DESTINATION "${PROJECT_SOURCE_DIR}/bin") +- ++ RUNTIME DESTINATION bin ++ LIBRARY DESTINATION lib ++ ARCHIVE DESTINATION lib) ++ + # Install *.pdb files +- if(MSVC) ++ if(FALSE) + foreach(INSTALL_TARGET_PDB ${INSTALL_TARGETS_PDB}) + install(FILES $ DESTINATION "${PROJECT_SOURCE_DIR}/bin") + endforeach() diff --git a/recipes/cppcommon/all/patches/0003-define-win32-winnt-1-0-4-0.patch b/recipes/cppcommon/all/patches/0003-define-win32-winnt-1-0-4-0.patch new file mode 100644 index 00000000000000..076bc12bf2beb6 --- /dev/null +++ b/recipes/cppcommon/all/patches/0003-define-win32-winnt-1-0-4-0.patch @@ -0,0 +1,14 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index c76bfef..f57f05b 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -75,6 +75,9 @@ target_compile_features(cppcommon PUBLIC cxx_std_17) + target_link_libraries(cppcommon PUBLIC ${LINKLIBS} fmt::fmt) + list(APPEND INSTALL_TARGETS cppcommon) + list(APPEND LINKLIBS cppcommon) ++if(WIN32 AND NOT MSVC) ++ target_compile_definitions(cppcommon PUBLIC -D_WIN32_WINNT=_WIN32_WINNT_VISTA) ++endif() + + # Additional module components: benchmarks, examples, plugins, tests, tools and install + if(NOT CPPCOMMON_MODULE) diff --git a/recipes/cppcommon/config.yml b/recipes/cppcommon/config.yml index ee34523110204d..dfd13b4693a862 100644 --- a/recipes/cppcommon/config.yml +++ b/recipes/cppcommon/config.yml @@ -1,4 +1,6 @@ versions: + "1.0.4.0": + folder: all "1.0.3.0": folder: all "1.0.2.0": From 07624c1de1c6854c0921ef2503b79f72bbed30d2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Sat, 7 Oct 2023 01:03:31 +0200 Subject: [PATCH 0993/1140] (#20213) Bump fltk's zlib requirement to [>=1.2.11 <2] range --- recipes/fltk/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/fltk/all/conanfile.py b/recipes/fltk/all/conanfile.py index a7feaec5a6e94b..f32dd94a48036a 100644 --- a/recipes/fltk/all/conanfile.py +++ b/recipes/fltk/all/conanfile.py @@ -64,7 +64,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") self.requires("libjpeg/9e") self.requires("libpng/1.6.40") if self.settings.os in ["Linux", "FreeBSD"]: From 99e643cec63d435960689b9dde0775d2f35cf54b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Sat, 7 Oct 2023 02:03:09 +0200 Subject: [PATCH 0994/1140] (#20215) Bump thrift's zlib requirement to [>=1.2.11 <2] range --- recipes/thrift/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/thrift/all/conanfile.py b/recipes/thrift/all/conanfile.py index 54cc1c65d6945b..3f576411eeb0da 100644 --- a/recipes/thrift/all/conanfile.py +++ b/recipes/thrift/all/conanfile.py @@ -71,7 +71,7 @@ def requirements(self): if self.options.with_openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_libevent: self.requires("libevent/2.1.12") if self.options.with_qt5: From 9348f6a1a8b5d32b3e1e26351dabcfc52fb31a26 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 7 Oct 2023 03:10:27 +0200 Subject: [PATCH 0995/1140] (#20349) serial: better way to set install_name to `@rpath` in shared lib macOS --- recipes/serial/all/conanfile.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/recipes/serial/all/conanfile.py b/recipes/serial/all/conanfile.py index 895f0932cedd56..b0bd05408cdc0d 100644 --- a/recipes/serial/all/conanfile.py +++ b/recipes/serial/all/conanfile.py @@ -1,7 +1,7 @@ import os from conan import ConanFile -from conan.tools.apple import fix_apple_shared_install_name, is_apple_os +from conan.tools.apple import is_apple_os from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import copy, get @@ -47,6 +47,8 @@ def source(self): def generate(self): tc = CMakeToolchain(self) + # Relocatable shared lib on Macos + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" tc.generate() def build(self): @@ -60,7 +62,6 @@ def package(self): src=self.source_folder) cmake = CMake(self) cmake.install() - fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["serial"] From 6fb7f24bcf0cbac36fa56b7d4333d7cae690b1b3 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 7 Oct 2023 04:12:35 +0200 Subject: [PATCH 0996/1140] (#20367) mpfr: package correct LGPL license + few minor fixes * install COPYING.LESSER license file since mpfr is LGPL * explicit pkg_config_name * few fixes & cleanup - use export_conandata_patches() - call VirtualBuildEnv since there might be build requirements - do not add -FS is msvc < 180 * modernize test package a little bit --- recipes/mpfr/all/conanfile.py | 56 +++++++++++-------- recipes/mpfr/all/test_package/CMakeLists.txt | 4 +- recipes/mpfr/all/test_package/conanfile.py | 4 +- .../mpfr/all/test_v1_package/CMakeLists.txt | 12 ++-- 4 files changed, 41 insertions(+), 35 deletions(-) diff --git a/recipes/mpfr/all/conanfile.py b/recipes/mpfr/all/conanfile.py index e163c514a2dea6..77727bc0de6380 100644 --- a/recipes/mpfr/all/conanfile.py +++ b/recipes/mpfr/all/conanfile.py @@ -1,16 +1,20 @@ +import os +import re +import shlex + from conan import ConanFile -from conan.tools.files import save, load, copy, get, rmdir, replace_in_file, apply_conandata_patches -from conan.tools.layout import basic_layout +from conan.errors import ConanException +from conan.tools.apple import fix_apple_shared_install_name +from conan.tools.build import cross_building from conan.tools.cmake import CMakeToolchain, CMakeDeps, CMake, cmake_layout +from conan.tools.env import VirtualBuildEnv, VirtualRunEnv +from conan.tools.files import ( + apply_conandata_patches, copy, export_conandata_patches, get, load, + replace_in_file, rm, rmdir, save +) from conan.tools.gnu import Autotools, AutotoolsToolchain, AutotoolsDeps +from conan.tools.layout import basic_layout from conan.tools.microsoft import is_msvc, check_min_vs, unix_path -from conan.tools.apple import fix_apple_shared_install_name -from conan.tools.env import VirtualRunEnv -from conan.tools.build import cross_building -from conan.errors import ConanException -import os -import re -import shlex required_conan_version = ">=1.58.0" @@ -28,7 +32,7 @@ class MpfrConan(ConanFile): options = { "shared": [True, False], "fPIC": [True, False], - "exact_int": ["mpir", "gmp",], + "exact_int": ["mpir", "gmp"], } default_options = { "shared": False, @@ -36,12 +40,14 @@ class MpfrConan(ConanFile): "exact_int": "gmp", } - exports_sources = "CMakeLists.txt.in", "patches/**" - @property def _settings_build(self): return getattr(self, "settings_build", self.settings) + def export_sources(self): + copy(self, "CMakeLists.txt.in", src=self.recipe_folder, dst=self.export_sources_folder) + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": self.options.rm_safe("fPIC") @@ -52,6 +58,12 @@ def configure(self): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def layout(self): + if self.settings.os == "Windows": + cmake_layout(self, src_folder="src") + else: + basic_layout(self, src_folder="src") + def requirements(self): if self.options.exact_int == "gmp": self.requires("gmp/6.3.0", transitive_headers=True) @@ -64,17 +76,12 @@ def build_requirements(self): if not self.conf.get("tools.microsoft.bash:path", check_type=str): self.tool_requires("msys2/cci.latest") - def layout(self): - if self.settings.os == "Windows": - cmake_layout(self, src_folder="src") - else: - basic_layout(self, src_folder="src") - def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): + env = VirtualBuildEnv(self) + env.generate() if not cross_building(self): env = VirtualRunEnv(self) env.generate(scope="build") @@ -106,7 +113,7 @@ def generate(self): if self.options.exact_int == "mpir": tc.extra_cflags.append(f"-I{self.build_folder}") - if is_msvc(self): + if is_msvc(self) and check_min_vs(self, "180", raise_invalid=False): tc.extra_cflags.append("-FS") env = tc.environment() @@ -170,19 +177,20 @@ def build(self): autotools.make(args=["V=0"]) def package(self): - copy(self, "COPYING", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy(self, "COPYING.LESSER", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) if self.settings.os == "Windows": cmake = CMake(self) cmake.install() else: autotools = Autotools(self) autotools.install() - fix_apple_shared_install_name(self) - os.unlink(os.path.join(self.package_folder, "lib", "libmpfr.la")) rmdir(self, os.path.join(self.package_folder, "share")) rmdir(self, os.path.join(self.package_folder, "lib", "pkgconfig")) + rm(self, "*.la", os.path.join(self.package_folder, "lib")) + fix_apple_shared_install_name(self) def package_info(self): + self.cpp_info.set_property("pkg_config_name", "mpfr") self.cpp_info.libs = ["mpfr"] if self.settings.os == "Windows" and self.options.shared: self.cpp_info.defines = ["MPFR_DLL"] diff --git a/recipes/mpfr/all/test_package/CMakeLists.txt b/recipes/mpfr/all/test_package/CMakeLists.txt index f4253e8466cb9d..734c455f60d093 100644 --- a/recipes/mpfr/all/test_package/CMakeLists.txt +++ b/recipes/mpfr/all/test_package/CMakeLists.txt @@ -1,7 +1,7 @@ -cmake_minimum_required(VERSION 3.3.0) +cmake_minimum_required(VERSION 3.15) project(test_package LANGUAGES C) -find_package(mpfr REQUIRED) +find_package(mpfr REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) target_link_libraries(${PROJECT_NAME} PRIVATE mpfr::mpfr) diff --git a/recipes/mpfr/all/test_package/conanfile.py b/recipes/mpfr/all/test_package/conanfile.py index a63e741acf6714..862d248f1946f8 100644 --- a/recipes/mpfr/all/test_package/conanfile.py +++ b/recipes/mpfr/all/test_package/conanfile.py @@ -1,6 +1,6 @@ from conan import ConanFile +from conan.tools.build import can_run from conan.tools.cmake import CMake, cmake_layout -from conan.tools.build import cross_building import os @@ -21,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): + if can_run(self): bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") self.run(bin_path, env="conanrun") diff --git a/recipes/mpfr/all/test_v1_package/CMakeLists.txt b/recipes/mpfr/all/test_v1_package/CMakeLists.txt index 222d09629eb12c..0d20897301b68b 100644 --- a/recipes/mpfr/all/test_v1_package/CMakeLists.txt +++ b/recipes/mpfr/all/test_v1_package/CMakeLists.txt @@ -1,10 +1,8 @@ -cmake_minimum_required(VERSION 3.3.0) -project(test_package C) +cmake_minimum_required(VERSION 3.1) +project(test_package) -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) conan_basic_setup(TARGETS) -find_package(mpfr CONFIG REQUIRED) - -add_executable(${PROJECT_NAME} ../test_package/test_package.c) -target_link_libraries(${PROJECT_NAME} mpfr::mpfr) +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) From 98066bac39a44d21e3821410912c450fe9489183 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 7 Oct 2023 05:13:37 +0200 Subject: [PATCH 0997/1140] (#20372) usockets: several fixes for conan v2 * several fixes for conan v2 - do not use self.output.warn since it doesn't exist in conan v2 - test self.dependencies["wolfssl"].options.opensslextra instead of self.options["wolfssl"].opensslextra - add VirtualBuildEnv in autotools branch since there are build requirements if build machine is windows * methods by order of execution --- recipes/usockets/all/conanfile.py | 90 ++++++++++++++++--------------- 1 file changed, 46 insertions(+), 44 deletions(-) diff --git a/recipes/usockets/all/conanfile.py b/recipes/usockets/all/conanfile.py index d7b3860e4e1662..c1bcf6244f7dc3 100644 --- a/recipes/usockets/all/conanfile.py +++ b/recipes/usockets/all/conanfile.py @@ -1,6 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd +from conan.tools.env import VirtualBuildEnv from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir, chdir, replace_in_file from conan.tools.gnu import Autotools, AutotoolsDeps, AutotoolsToolchain from conan.tools.layout import basic_layout @@ -32,19 +33,19 @@ class UsocketsConan(ConanFile): } @property - def _minimum_cpp_standard(self): - version = False + def _min_cppstd(self): if self.options.eventloop == "boost": - version = "14" + return "14" # OpenSSL wrapper of uSockets uses C++17 features. if self.options.with_ssl == "openssl": - version = "17" + return "17" - return version + return False + @property def _minimum_compilers_version(self, cppstd): - standards = { + return { "14": { "Visual Studio": "15", "msvc": "191", @@ -59,11 +60,7 @@ def _minimum_compilers_version(self, cppstd): "clang": "6", "apple-clang": "10", }, - } - return standards.get(cppstd) or {} - - def layout(self): - basic_layout(self, src_folder="src") + }.get(self._min_cppstd, {}) @property def _settings_build(self): @@ -81,41 +78,14 @@ def config_options(self): del self.options.fPIC self.options.eventloop = "libuv" - def validate(self): - if self.options.eventloop == "syscall" and self.settings.os == "Windows": - raise ConanInvalidConfiguration("syscall is not supported on Windows") - - if self.options.eventloop == "gcd" and (self.settings.os != "Linux" or self.settings.compiler != "clang"): - raise ConanInvalidConfiguration("eventloop=gcd is only supported on Linux with clang") - - if Version(self.version) < "0.8.0" and self.options.eventloop not in ("syscall", "libuv", "gcd"): - raise ConanInvalidConfiguration(f"eventloop={self.options.eventloop} is not supported with {self.name}/{self.version}") - - if Version(self.version) >= "0.5.0" and self.options.with_ssl == "wolfssl": - raise ConanInvalidConfiguration(f"with_ssl={self.options.with_ssl} is not supported with {self.name}/{self.version}. https://github.com/uNetworking/uSockets/issues/147") - - if self.options.with_ssl == "wolfssl" and not self.options["wolfssl"].opensslextra: - raise ConanInvalidConfiguration("wolfssl needs opensslextra option enabled for usockets") - - cppstd = self._minimum_cpp_standard - if not cppstd: - return - - if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, cppstd) - - minimum_version = self._minimum_compilers_version(cppstd).get(str(self.settings.compiler), False) - if minimum_version: - if Version(self.settings.compiler.version) < minimum_version: - raise ConanInvalidConfiguration("{} requires C++{}, which your compiler does not support.".format(self.name, cppstd)) - else: - self.output.warn("{0} requires C++{1}. Your compiler is unknown. Assuming it supports C++{1}.".format(self.name, cppstd)) - def configure(self): - if bool(self._minimum_cpp_standard) == False: + if not bool(self._min_cppstd): self.settings.rm_safe("compiler.libcxx") self.settings.rm_safe("compiler.cppstd") + def layout(self): + basic_layout(self, src_folder="src") + def requirements(self): if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") @@ -129,6 +99,35 @@ def requirements(self): elif self.options.eventloop == "boost": self.requires("boost/1.83.0") + def validate(self): + if self.options.eventloop == "syscall" and self.settings.os == "Windows": + raise ConanInvalidConfiguration("syscall is not supported on Windows") + + if self.options.eventloop == "gcd" and not (self.settings.os == "Linux" and self.settings.compiler == "clang"): + raise ConanInvalidConfiguration("eventloop=gcd is only supported on Linux with clang") + + if Version(self.version) < "0.8.0" and self.options.eventloop not in ("syscall", "libuv", "gcd"): + raise ConanInvalidConfiguration(f"{self.ref} doesn't support eventloop={self.options.eventloop}") + + if Version(self.version) >= "0.5.0" and self.options.with_ssl == "wolfssl": + raise ConanInvalidConfiguration( + f"{self.ref} doesn't support with_ssl={self.options.with_ssl}. " + "See https://github.com/uNetworking/uSockets/issues/147" + ) + + if self.options.with_ssl == "wolfssl" and not self.dependencies["wolfssl"].options.opensslextra: + raise ConanInvalidConfiguration("wolfssl needs opensslextra option enabled for usockets") + + if bool(self._min_cppstd): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + minimum_version = self._minimum_compilers_version(self._min_cppstd) + 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 build_requirements(self): if self._settings_build.os == "Windows" and not self._uses_msbuild: self.win_bash = True @@ -170,6 +169,9 @@ def generate(self): deps = MSBuildDeps(self) deps.generate() else: + env = VirtualBuildEnv(self) + env.generate() + tc = AutotoolsToolchain(self) env = tc.environment() if is_msvc(self): @@ -187,7 +189,8 @@ def generate(self): if self.options.eventloop == "libuv": # Workaround for: https://github.com/conan-io/conan/issues/12784 # Otherwise AutotoolsDeps should suffice - env.append("CPPFLAGS", "-I" + unix_path(self, self.dependencies["libuv"].cpp_info.includedirs[0])) + libuv_includes = self.dependencies["libuv"].cpp_info.aggregated_components().includedirs + env.append("CPPFLAGS", " ".join([f"-I{unix_path(self, p)}" for p in libuv_includes])) tc.generate(env) deps = AutotoolsDeps(self) @@ -200,7 +203,6 @@ def _build_msvc(self): def _build_autotools(self): autotools = Autotools(self) - autotools.fpic = self.options.get_safe("fPIC", False) with chdir(self, self.source_folder): args = ["WITH_LTO=0"] if self.options.with_ssl == "openssl": From 9e6afa3056ed7146135ce0d5d8e805c269d0f3d0 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sat, 7 Oct 2023 06:10:44 +0200 Subject: [PATCH 0998/1140] (#20377) dcmtk: fix regression on `enable_stl` option MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * fix enable_stl option mapping * improve a little bit _collect_cmake_required() * typo --------- Co-authored-by: Rubén Rincón Blanco --- recipes/dcmtk/all/conanfile.py | 44 +++++++++++++++++++--------------- 1 file changed, 25 insertions(+), 19 deletions(-) diff --git a/recipes/dcmtk/all/conanfile.py b/recipes/dcmtk/all/conanfile.py index c91c7cb9ec81d6..6980bbc99c18d5 100644 --- a/recipes/dcmtk/all/conanfile.py +++ b/recipes/dcmtk/all/conanfile.py @@ -144,7 +144,9 @@ def generate(self): tc.variables["DCMTK_WITH_DOXYGEN"] = False tc.variables["DCMTK_WIDE_CHAR_FILE_IO_FUNCTIONS"] = self.options.wide_io tc.variables["DCMTK_WIDE_CHAR_MAIN_FUNCTION"] = self.options.wide_io - tc.variables["DCMTK_ENABLE_STL"] = self.options.enable_stl + # Upstream CMakeLists really expects ON value and no other value (like TRUE) in its internal logic + # to enable STL features (see DCMTK_TEST_ENABLE_STL_FEATURE() function in CMake/GenerateDCMTKConfigure.cmake) + tc.variables["DCMTK_ENABLE_STL"] = "ON" if self.options.enable_stl else "OFF" tc.variables["DCMTK_ENABLE_CXX11"] = True tc.variables["DCMTK_ENABLE_MANPAGE"] = False tc.cache_variables["DCMTK_DEFAULT_DICT"] = self.options.default_dict @@ -159,32 +161,34 @@ def generate(self): deps = CMakeDeps(self) deps.generate() - def _collect_cmake_required(self, dependency): - dep = self.dependencies.host[dependency] + def _collect_cmake_required(self, host_dependency): + """ + Collect all compile & link flags of a host dependency so that they can be used in: + - CMAKE_REQUIRED_FLAGS + - CMAKE_REQUIRED_INCLUDES + - CMAKE_REQUIRED_DEFINITIONS + - CMAKE_REQUIRED_LINK_OPTIONS + - CMAKE_REQUIRED_LIBRARIES + These variables are listened by CMake functions like check_symbol_exists() etc + """ + # Aggregate cpp_info of dependency and all its depencencies (direct and transitive) + dep = self.dependencies.host[host_dependency] dep_cpp_info = dep.cpp_info.aggregated_components() + for _, trans_dep in dep.dependencies.items(): + if trans_dep.context == "host": + dep_cpp_info.merge(trans_dep.cpp_info.aggregated_components()) + dep_includes = [p.replace("\\", "/") for p in dep_cpp_info.includedirs] - dep_defs = [d for d in dep_cpp_info.defines] libdirs_flag = "/LIBPATH:" if is_msvc(self) else "-L" dep_libdirs = ["{}{}".format(libdirs_flag, p.replace("\\", "/")) for p in dep_cpp_info.libdirs] - dep_libs = [l for l in dep_cpp_info.libs] - dep_system_libs = [s for s in dep_cpp_info.system_libs] dep_frameworks = [f"-framework {f}" for f in dep_cpp_info.frameworks] - for _, trans_dependency in dep.dependencies.items(): - if trans_dependency.context != "host": - continue - trans_dep_cpp_info = trans_dependency.cpp_info.aggregated_components() - dep_includes.extend([p.replace("\\", "/") for p in trans_dep_cpp_info.includedirs]) - dep_defs.extend([d for d in trans_dep_cpp_info.defines]) - dep_libdirs.extend(["{}{}".format(libdirs_flag, p.replace("\\", "/")) for p in trans_dep_cpp_info.libdirs]) - dep_libs.extend([l for l in trans_dep_cpp_info.libs]) - dep_system_libs.extend([s for s in trans_dep_cpp_info.system_libs]) - dep_frameworks.extend([f"-framework {f}" for f in trans_dep_cpp_info.frameworks]) return { + "flags": ";".join(dep_cpp_info.cflags + dep_cpp_info.cxxflags), "includes": ";".join(dep_includes), - "definitions": ";".join(dep_defs), - "link_options": ";".join(dep_libdirs + dep_frameworks), - "libraries": ";".join(dep_libs + dep_system_libs), + "definitions": ";".join(dep_cpp_info.defines), + "link_options": ";".join(dep_libdirs + dep_cpp_info.exelinkflags + dep_frameworks), + "libraries": ";".join(dep_cpp_info.libs + dep_cpp_info.system_libs), } def _patch_sources(self): @@ -199,6 +203,7 @@ def _patch_sources(self): os.path.join(self.source_folder, "CMake", "dcmtkPrepare.cmake"), "set(CMAKE_REQUIRED_LIBRARIES ${CMAKE_REQUIRED_LIBRARIES} ${OPENSSL_LIBS} ${THREAD_LIBS})", textwrap.dedent(f"""\ + list(APPEND CMAKE_REQUIRED_FLAGS "{cmake_required['flags']}") list(APPEND CMAKE_REQUIRED_INCLUDES "{cmake_required['includes']}") list(APPEND CMAKE_REQUIRED_DEFINITIONS "{cmake_required['definitions']}") list(APPEND CMAKE_REQUIRED_LINK_OPTIONS "{cmake_required['link_options']}") @@ -213,6 +218,7 @@ def _patch_sources(self): os.path.join(self.source_folder, "CMake", "3rdparty.cmake"), "set(CMAKE_REQUIRED_LIBRARIES ${LIBICONV_LIBS})", textwrap.dedent(f"""\ + list(APPEND CMAKE_REQUIRED_FLAGS "{cmake_required['flags']}") list(APPEND CMAKE_REQUIRED_DEFINITIONS "{cmake_required['definitions']}") list(APPEND CMAKE_REQUIRED_LINK_OPTIONS "{cmake_required['link_options']}") list(APPEND CMAKE_REQUIRED_LIBRARIES "{cmake_required['libraries']}") From 903e5b16ac431e4ae046f0a33a773b51998e126f Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 07:11:49 +0200 Subject: [PATCH 0999/1140] (#20395) prometheus-cpp/all: bump libcurl --- recipes/prometheus-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/prometheus-cpp/all/conanfile.py b/recipes/prometheus-cpp/all/conanfile.py index 42d1c971e35ee4..ad2bd633fa5956 100644 --- a/recipes/prometheus-cpp/all/conanfile.py +++ b/recipes/prometheus-cpp/all/conanfile.py @@ -66,7 +66,7 @@ def requirements(self): if self.options.with_pull: self.requires("civetweb/1.16") if self.options.with_push: - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.2.1") if self.options.get_safe("with_compression"): self.requires("zlib/[>=1.2.11 <2]") From cd8ffd01b6448cba98922fd8f506524d258b6c7e Mon Sep 17 00:00:00 2001 From: igormironchik Date: Sat, 7 Oct 2023 16:40:42 +0300 Subject: [PATCH 1000/1140] (#20409) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index d726da5cad811b..89f9c14aa5d1b9 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.1.0": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.1.0.tar.gz" + sha256: "cfbf515adecd798a3f1a4f2e007021b4b31742dd0b36805c273b3b8316fd820d" "2.0.18": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.0.18.tar.gz" sha256: "4fe70a63eb78cdf0355f6a6b292c40c8cc8ed4a62bcbec17afefa713b19c28b1" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 948892a125b470..6e3494f0799608 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.1.0": + folder: all "2.0.18": folder: all "2.0.16": From f5145131db0472043c06ebc03cce4f93db4a9514 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 17:15:10 +0200 Subject: [PATCH 1001/1140] (#20402) mariadb-connector-c/all: bump libcurl --- recipes/mariadb-connector-c/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mariadb-connector-c/all/conanfile.py b/recipes/mariadb-connector-c/all/conanfile.py index 2a47e8904ad348..835db83c0b42d6 100644 --- a/recipes/mariadb-connector-c/all/conanfile.py +++ b/recipes/mariadb-connector-c/all/conanfile.py @@ -58,7 +58,7 @@ def requirements(self): if self.options.get_safe("with_iconv"): self.requires("libiconv/1.17") if self.options.with_curl: - self.requires("libcurl/8.1.2") + self.requires("libcurl/8.2.1") if self.options.with_ssl == "openssl": self.requires("openssl/[>=1.1 <4]") From c653b9fbffda32f2c6d5d2560e5675f125ae31e1 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 18:10:39 +0200 Subject: [PATCH 1002/1140] (#20404) libbigwig/all: bump libcurl --- recipes/libbigwig/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libbigwig/all/conanfile.py b/recipes/libbigwig/all/conanfile.py index abb1b4a35b398b..92c3a5f4a85af2 100644 --- a/recipes/libbigwig/all/conanfile.py +++ b/recipes/libbigwig/all/conanfile.py @@ -45,7 +45,7 @@ def requirements(self): if self.options.with_curl: # transitive_headers=True is required due to includes in bigWigIO.h # https://github.com/dpryan79/libBigWig/blob/master/bigWigIO.h#L5 - self.requires("libcurl/8.1.2", transitive_headers=True) + self.requires("libcurl/8.2.1", transitive_headers=True) if self.options.with_zlibng: self.requires("zlib-ng/2.1.3") else: From 90c887f0b13760c8414c63dbe97bc2c628edf2f2 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 19:15:05 +0200 Subject: [PATCH 1003/1140] (#20403) libmediainfo/all: bump libcurl --- recipes/libmediainfo/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libmediainfo/all/conanfile.py b/recipes/libmediainfo/all/conanfile.py index d68e2deed8e875..942170afa983b5 100644 --- a/recipes/libmediainfo/all/conanfile.py +++ b/recipes/libmediainfo/all/conanfile.py @@ -49,7 +49,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libcurl/8.1.2") + self.requires("libcurl/8.2.1") self.requires("libzen/0.4.38", transitive_headers=True, transitive_libs=True) self.requires("tinyxml2/9.0.0") self.requires("zlib/[>=1.2.11 <2]") From d0948137f93d7001ad60effb649375d7c8803587 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 20:21:00 +0200 Subject: [PATCH 1004/1140] (#20407) czmq/all: bump libcurl --- recipes/czmq/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/czmq/all/conanfile.py b/recipes/czmq/all/conanfile.py index 1ea4a28e1852a5..d711089dd0289e 100644 --- a/recipes/czmq/all/conanfile.py +++ b/recipes/czmq/all/conanfile.py @@ -66,7 +66,7 @@ def requirements(self): if self.options.get_safe("with_libmicrohttpd"): self.requires("libmicrohttpd/0.9.75") if self.options.get_safe("with_libcurl"): - self.requires("libcurl/7.87.0") + self.requires("libcurl/8.2.1") if self.options.with_lz4: self.requires("lz4/1.9.4") if self.options.get_safe("with_libuuid"): From ab8c14dfbfc45e053be49ceddd3bbefe7da1b969 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 21:12:03 +0200 Subject: [PATCH 1005/1140] (#20408) imutils-cpp/all: bump libcurl --- recipes/imutils-cpp/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/imutils-cpp/all/conanfile.py b/recipes/imutils-cpp/all/conanfile.py index f6e8787dbdea2a..f542311be0b20f 100644 --- a/recipes/imutils-cpp/all/conanfile.py +++ b/recipes/imutils-cpp/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): def requirements(self): self.requires("opencv/4.5.5", transitive_headers=True, transitive_libs=True) - self.requires("libcurl/7.87.0") + self.requires("libcurl/8.2.1") def validate(self): if self.settings.compiler.get_safe("cppstd"): From 4c292885d0ced62a2dedc7ba4d991c8bb205e65f Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 7 Oct 2023 22:15:09 +0200 Subject: [PATCH 1006/1140] (#20406) sentry-crashpad/all: bump libcurl --- recipes/sentry-crashpad/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/sentry-crashpad/all/conanfile.py b/recipes/sentry-crashpad/all/conanfile.py index 4217d488f0b1c3..097dc9f7336e92 100644 --- a/recipes/sentry-crashpad/all/conanfile.py +++ b/recipes/sentry-crashpad/all/conanfile.py @@ -62,7 +62,7 @@ def build_requirements(self): def requirements(self): self.requires("zlib/[>=1.2.11 <2]") if self.settings.os in ("Linux", "FreeBSD"): - self.requires("libcurl/8.2.0") + self.requires("libcurl/8.2.1") if self.options.get_safe("with_tls"): self.requires("openssl/[>=1.1 <4]") From 4c26bf76f75ab42aa2ad9517adde0eb4c50668b2 Mon Sep 17 00:00:00 2001 From: Toni Neubert Date: Sun, 8 Oct 2023 16:50:09 +0200 Subject: [PATCH 1007/1140] (#20428) emio: add version 0.5.0 * emio: add version 0.5.0 * Update config.yml --- recipes/emio/all/conandata.yml | 3 +++ recipes/emio/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/emio/all/conandata.yml b/recipes/emio/all/conandata.yml index e7d7963735f4c2..f62ffc65b5b74e 100644 --- a/recipes/emio/all/conandata.yml +++ b/recipes/emio/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.5.0": + url: "https://github.com/viatorus/emio/archive/0.5.0.tar.gz" + sha256: "14cfa81d96db6ef74b8da7b5d2ffbd26535f2930d0d423e4fde7b526ddb3b308" "0.4.0": url: "https://github.com/viatorus/emio/archive/0.4.0.tar.gz" sha256: "847198a37fbf9dcc00ac85fbc64b283e41a018f53c39363129a4bdb9939338a6" diff --git a/recipes/emio/config.yml b/recipes/emio/config.yml index 3842372f8b1f4d..9582e7461fbc51 100644 --- a/recipes/emio/config.yml +++ b/recipes/emio/config.yml @@ -1,4 +1,6 @@ versions: + "0.5.0": + folder: all "0.4.0": folder: all "0.3.0": From 139ce52d78cb6968ec3c2b86c37a62a5c61b8198 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 8 Oct 2023 19:16:42 +0200 Subject: [PATCH 1008/1140] (#20424) tmx/all: bump deps --- recipes/tmx/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/tmx/all/conanfile.py b/recipes/tmx/all/conanfile.py index 53b614a724111f..532a780023daa0 100644 --- a/recipes/tmx/all/conanfile.py +++ b/recipes/tmx/all/conanfile.py @@ -52,11 +52,11 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libxml2/2.9.14") + self.requires("libxml2/2.11.4") if self.options.with_zlib: self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: - self.requires("zstd/1.5.2") + self.requires("zstd/1.5.5") def source(self): get(self, **self.conan_data["sources"][self.version], From d096ebbeb7559105916b4e3b552f56de8318dff5 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 8 Oct 2023 20:10:55 +0200 Subject: [PATCH 1009/1140] (#20427) norm/all: bump libxml2 --- recipes/norm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/norm/all/conanfile.py b/recipes/norm/all/conanfile.py index 0a0ac61c170c3e..d900ba9bfd4b99 100644 --- a/recipes/norm/all/conanfile.py +++ b/recipes/norm/all/conanfile.py @@ -39,7 +39,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libxml2/2.10.4") # dependency of protolib actually + self.requires("libxml2/2.11.4") # dependency of protolib actually def source(self): get(self, **self.conan_data["sources"][self.version]) From 509664c8477c7dbf367838db4a174b2f42a96cd7 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 8 Oct 2023 22:12:02 +0200 Subject: [PATCH 1010/1140] (#20432) civetweb/all: bump OpenSSL --- recipes/civetweb/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/civetweb/all/conanfile.py b/recipes/civetweb/all/conanfile.py index a2b502ff165bbb..b393da542821b2 100644 --- a/recipes/civetweb/all/conanfile.py +++ b/recipes/civetweb/all/conanfile.py @@ -83,7 +83,7 @@ def layout(self): def requirements(self): if self.options.with_ssl: if Version(self.version) < "1.16": - self.requires("openssl/1.1.1t") + self.requires("openssl/1.1.1w") else: self.requires("openssl/[>=1 <4]") if self.options.get_safe("with_zlib"): From 3b74fe48b6434c82afa4b2c88365f42ba96555ca Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sun, 8 Oct 2023 23:12:49 +0200 Subject: [PATCH 1011/1140] (#20433) libmysqlclient/all: bump deps --- recipes/libmysqlclient/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/libmysqlclient/all/conanfile.py b/recipes/libmysqlclient/all/conanfile.py index 8d96f1dd528287..37c00e1110d015 100644 --- a/recipes/libmysqlclient/all/conanfile.py +++ b/recipes/libmysqlclient/all/conanfile.py @@ -63,7 +63,7 @@ def layout(self): def requirements(self): if Version(self.version) < "8.0.30": - self.requires("openssl/1.1.1u") + self.requires("openssl/1.1.1w") else: self.requires("openssl/[>=1.1 <4]") self.requires("zlib/[>=1.2.11 <2]") @@ -104,7 +104,7 @@ def build_requirements(self): if is_apple_os(self): self.tool_requires("cmake/[>=3.18 <4]") if self.settings.os == "FreeBSD" and not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From c142dd0ada6368619b2e7ae72aebed038bff920c Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 01:12:48 +0200 Subject: [PATCH 1012/1140] (#20429) libwebsockets/all: bump OpenSSL --- recipes/libwebsockets/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libwebsockets/all/conanfile.py b/recipes/libwebsockets/all/conanfile.py index fbda27117b43ef..b15cf76410c453 100644 --- a/recipes/libwebsockets/all/conanfile.py +++ b/recipes/libwebsockets/all/conanfile.py @@ -225,7 +225,7 @@ def requirements(self): if self.options.with_ssl == "openssl": # Cannot add the [>=1.1 <4] range, as it seems openssl3 makes it fail - self.requires("openssl/1.1.1t", transitive_headers=True) + self.requires("openssl/1.1.1w", transitive_headers=True) elif self.options.with_ssl == "mbedtls": self.requires("mbedtls/2.25.0") elif self.options.with_ssl == "wolfssl": From fb7fc2710d957b7e0f9abfae5e085b5cbb7892f3 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 02:14:04 +0200 Subject: [PATCH 1013/1140] (#20434) libpq/all: bump OpenSSL --- recipes/libpq/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libpq/all/conanfile.py b/recipes/libpq/all/conanfile.py index cc7d54df6ee850..53f51b549f74e9 100644 --- a/recipes/libpq/all/conanfile.py +++ b/recipes/libpq/all/conanfile.py @@ -66,7 +66,7 @@ def layout(self): def requirements(self): if self.options.with_openssl: if Version(self.version) < "13.5": - self.requires("openssl/1.1.1u") + self.requires("openssl/1.1.1w") else: self.requires("openssl/[>=1.1 <4]") From d77f37b6abdeb985ccfcd963813d41511888f447 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 11:12:47 +0200 Subject: [PATCH 1014/1140] (#20413) cocoyaxi/all: bump lib curl, use version range for OpenSSL, make deprecated * cocoyaxi/all: bump lib curl, use version range for OpenSSL * fix missing system libs * cocoyaxi: make deprecated * fix removal of fPIC in configure() --------- Co-authored-by: toge --- recipes/cocoyaxi/all/conanfile.py | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/recipes/cocoyaxi/all/conanfile.py b/recipes/cocoyaxi/all/conanfile.py index 217d2d1b7c4e18..adafa0cb6a0df1 100644 --- a/recipes/cocoyaxi/all/conanfile.py +++ b/recipes/cocoyaxi/all/conanfile.py @@ -30,6 +30,7 @@ class CocoyaxiConan(ConanFile): "with_libcurl": False, "with_openssl": False, } + deprecated = "coost" def config_options(self): if self.settings.os == "Windows": @@ -37,13 +38,13 @@ def config_options(self): def configure(self): if self.options.shared: - del self.options.fPIC + self.options.rm_safe("fPIC") def requirements(self): if self.options.with_libcurl: - self.requires("libcurl/7.80.0") + self.requires("libcurl/8.2.1") if self.options.with_libcurl or self.options.with_openssl: - self.requires("openssl/1.1.1q") + self.requires("openssl/[>=1.1 <4]") def validate(self): if self.info.settings.compiler.cppstd: @@ -95,3 +96,7 @@ def package_info(self): self.cpp_info.components["co"].requires.append("libcurl::libcurl") if self.options.with_libcurl or self.options.with_openssl: self.cpp_info.components["co"].requires.append("openssl::openssl") + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.components["co"].system_libs.extend(["pthread", "dl", "m"]) + elif self.settings.os == "Windows": + self.cpp_info.components["co"].system_libs.append("ws2_32") From 165418fa06400142cb97e5a24f9df45fb9dab851 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Mon, 9 Oct 2023 13:02:18 +0200 Subject: [PATCH 1015/1140] (#20457) [changelog] New C3I Release: 2023-Oct-06 Signed-off-by: Uilian Ries --- docs/changelog.md | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index 167e8aafcbc3ea..e1a988f3032537 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,14 @@ # Changelog +### 06-Oct-2023 - 10:15 CEST + +- [feature] Label PRs with version conflict properly +- [feature] Add motivation message when under maintenance +- [feature] Wait for sibling job in master right before promote +- [fix] No longer run Conan v2 export step +- [fix] Ensure build order follows only static first +- [fix] Disable quiet period for all jobs except CCI multibranch + ### 25-Sep-2023 - 14:33 CEST - [feature] Label PRs that have missing dependencies. From d9140c8547114211d57a419a7c65648b6f0bd3dd Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 16:13:27 +0200 Subject: [PATCH 1016/1140] (#20422) hwloc/all: bump libxml2 --- recipes/hwloc/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/hwloc/all/conanfile.py b/recipes/hwloc/all/conanfile.py index ac1264a7b4049c..07f03ed1489887 100644 --- a/recipes/hwloc/all/conanfile.py +++ b/recipes/hwloc/all/conanfile.py @@ -41,7 +41,7 @@ def configure(self): def requirements(self): if self.options.with_libxml2: - self.requires("libxml2/2.9.12") + self.requires("libxml2/2.11.4") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From f5a44dc0006eb1ceddabf964771d193030eb89a3 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 16:35:32 +0200 Subject: [PATCH 1017/1140] (#20423) opentdf-client/all: bump deps, use zlib version range, remove old versions --- recipes/opentdf-client/all/conandata.yml | 18 +------ recipes/opentdf-client/all/conanfile.py | 24 ++++----- .../all/patches/1.1.6-0001-cmake-fixes.patch | 51 ------------------- recipes/opentdf-client/config.yml | 4 -- 4 files changed, 13 insertions(+), 84 deletions(-) delete mode 100644 recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch diff --git a/recipes/opentdf-client/all/conandata.yml b/recipes/opentdf-client/all/conandata.yml index ead069b25a72d5..74961dd8639fd5 100644 --- a/recipes/opentdf-client/all/conandata.yml +++ b/recipes/opentdf-client/all/conandata.yml @@ -8,22 +8,8 @@ sources: "1.3.10": url: "https://github.com/opentdf/client-cpp/archive/1.3.10.tar.gz" sha256: "539bd5e64bceb86f63b3f7db75de470d5ea1d52ae6436a6a2d6789f7d0710dd4" - "1.2.0": - url: "https://github.com/opentdf/client-cpp/archive/1.2.0.tar.gz" - sha256: "15828038809ed291ff7881206a675abc5162e1175c8b515363b9c584aebb08f7" - "1.1.6": - url: "https://github.com/opentdf/client-cpp/archive/1.1.6.tar.gz" - sha256: "83992c37c9a58ae2152660a4ffbf1784fe63d7a9e7b8466d10ca1074697b3d3a" patches: - "1.1.6": - - patch_file: "patches/1.1.6-0001-cmake-fixes.patch" - patch_description: "CMake build fixes for Conan 2.0-compatible recipe" - patch_type: "conan" - "1.2.0": - - patch_file: "patches/1.1.6-0001-cmake-fixes.patch" - patch_description: "CMake build fixes for Conan 2.0-compatible recipe" - patch_type: "conan" - "1.3.10": + "1.5.0": - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" patch_description: "CMake build fixes for Conan 2.0-compatible recipe" patch_type: "conan" @@ -31,7 +17,7 @@ patches: - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" patch_description: "CMake build fixes for Conan 2.0-compatible recipe" patch_type: "conan" - "1.5.0": + "1.3.10": - patch_file: "patches/1.3.10-0001-cmake-fixes.patch" patch_description: "CMake build fixes for Conan 2.0-compatible recipe" patch_type: "conan" diff --git a/recipes/opentdf-client/all/conanfile.py b/recipes/opentdf-client/all/conanfile.py index e22c9867361c73..8d420a25df14ff 100644 --- a/recipes/opentdf-client/all/conanfile.py +++ b/recipes/opentdf-client/all/conanfile.py @@ -43,9 +43,9 @@ def _minimum_compilers_version(self): return { "Visual Studio": "17" if Version(self.version) < "1.1.5" else "15", "msvc": "193" if Version(self.version) < "1.1.5" else "191", - "gcc": "7.5.0", + "gcc": "7.5", "clang": "12", - "apple-clang": "12.0.0", + "apple-clang": "12", } def config_options(self): @@ -64,21 +64,16 @@ def requirements(self): if Version(self.version) >= "1.5.0": self.requires("openssl/[>=3.1 <4]") else: - self.requires("openssl/1.1.1u") + self.requires("openssl/1.1.1w") # Uses magic_enum for 1.4.0 and newer if Version(self.version) >= "1.4.0": self.requires("magic_enum/0.8.2") self.requires("ms-gsl/2.1.0") - self.requires("nlohmann_json/3.11.1") + self.requires("nlohmann_json/3.11.2") self.requires("jwt-cpp/0.4.0") - self.requires("zlib/1.2.13") - # Use newer boost+libxml2 after 1.3.6 - if Version(self.version) <= "1.3.6": - self.requires("boost/1.79.0") - self.requires("libxml2/2.9.14") - else: - self.requires("boost/1.82.0") - self.requires("libxml2/2.11.4") + self.requires("zlib/[>=1.2.11 <2]") + self.requires("boost/1.83.0") + self.requires("libxml2/2.11.4") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -98,7 +93,7 @@ def validate(self): # Disallow MT and MTd if is_msvc_static_runtime(self): raise ConanInvalidConfiguration(f"{self.name} can not be built with MT or MTd at this time") - + if self.options.shared and self.settings.os == "Windows": raise ConanInvalidConfiguration(f"{self.name} does not currently support shared library on Windows") @@ -164,3 +159,6 @@ def package_info(self): self.cpp_info.components["libopentdf"].requires.append("libarchive::libarchive") if Version(self.version) >= "1.4.0": self.cpp_info.components["libopentdf"].requires.append("magic_enum::magic_enum") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") diff --git a/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch b/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch deleted file mode 100644 index 7b784e35e922b3..00000000000000 --- a/recipes/opentdf-client/all/patches/1.1.6-0001-cmake-fixes.patch +++ /dev/null @@ -1,51 +0,0 @@ -diff --git a/src/lib/CMakeLists.txt b/src/lib/CMakeLists.txt -index f1ef646..2414ffc 100644 ---- a/src/lib/CMakeLists.txt -+++ b/src/lib/CMakeLists.txt -@@ -99,7 +99,9 @@ set(TDF_COMBINED_LIB_FULL_PATH ${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME}) - message(STATUS "Combined full path: ${TDF_COMBINED_LIB_FULL_PATH}") - - #TODO: Also need to handle iOS and Android(arm64). --if(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") -+if(TRUE) -+ message(STATUS "Skipping generation of combined static library") -+elseif(${CMAKE_SYSTEM_NAME} MATCHES "Darwin") - - FOREACH (LDIR ${CONAN_LIB_DIRS}) - set(V_COMBINED_LIB_DIRS ${V_COMBINED_LIB_DIRS} -L${LDIR}) -@@ -154,8 +156,6 @@ elseif (${CMAKE_SYSTEM_NAME} MATCHES "Windows") - lib -out:${TDF_LIB_DIR}/${TDF_COMBINED_LIB_FILENAME} ${TDF_LIB_DIR}/${TDF_STATIC_LIB_FILENAME} ${V_COMBINED_LIB_DIRS} ${V_COMBINED_LIB_NAMES} - ) - ) --else() -- message(STATUS "${CMAKE_SYSTEM_NAME} - unknown system FIXME........") - endif() - - # generate the shared library from the library sources -@@ -186,16 +186,19 @@ install(DIRECTORY DESTINATION ${TDF_LIB_INSTALL_LOCATION}) - # move the headers(to include) and tdf(to lib) directory under tdf-lib-cpp - install(DIRECTORY ${PROJECT_SOURCE_DIR}/include/ - DESTINATION ${TDF_LIB_INSTALL_LOCATION}/include) -- --install(FILES ${TDF_STATIC_LIB_FULL_PATH} -- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) - --install(FILES ${TDF_COMBINED_LIB_FULL_PATH} -- DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) -+if(NOT BUILD_SHARED_LIBS) -+ install(FILES $ -+ DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) -+endif() -+ -+# Skip combined static library for Conan Center Index package -+# install(FILES ${TDF_COMBINED_LIB_FULL_PATH} -+# DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) - - if(${CMAKE_SYSTEM_NAME} MATCHES "Windows") - message(STATUS "Skipping shared lib on windows") --else() -- install(FILES ${TDF_SHARED_LIB_FULL_PATH} -+elseif(BUILD_SHARED_LIBS) -+ install(FILES $ - DESTINATION ${TDF_LIB_INSTALL_LOCATION}/lib) - endif() diff --git a/recipes/opentdf-client/config.yml b/recipes/opentdf-client/config.yml index ab5feb490bdb88..99d76618997f83 100644 --- a/recipes/opentdf-client/config.yml +++ b/recipes/opentdf-client/config.yml @@ -5,7 +5,3 @@ versions: folder: all "1.3.10": folder: all - "1.2.0": - folder: all - "1.1.6": - folder: all From f03355f204f095d99225efa72572661c3e0c536e Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Mon, 9 Oct 2023 17:02:29 +0200 Subject: [PATCH 1018/1140] (#20459) [bot] Update authorized users list (2023-10-09) --- .c3i/authorized_users.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 5ec8bdc0fdecce..3b442dae2045d4 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1237,3 +1237,9 @@ authorized_users: - CJaccarino - gagoi - tux3 +- jan-grimo +- petermbauer +- Rdk-T +- fixstars-sonali +- FranzPoize +- SoShiny From 6b52934b218fb0bc597a091eb30b8c9512b9b9b7 Mon Sep 17 00:00:00 2001 From: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> Date: Mon, 9 Oct 2023 10:19:52 -0600 Subject: [PATCH 1019/1140] (#20443) arrow: fix issue when building with aws-cpp-sdk * arrow: fix issue when building with aws-cpp-sdk * add missing endlin * Update project includes --- recipes/arrow/all/conan_cmake_project_include.cmake | 13 +++++++++++++ recipes/arrow/all/conanfile.py | 3 +++ 2 files changed, 16 insertions(+) create mode 100644 recipes/arrow/all/conan_cmake_project_include.cmake diff --git a/recipes/arrow/all/conan_cmake_project_include.cmake b/recipes/arrow/all/conan_cmake_project_include.cmake new file mode 100644 index 00000000000000..1bf900def3e567 --- /dev/null +++ b/recipes/arrow/all/conan_cmake_project_include.cmake @@ -0,0 +1,13 @@ +if(ARROW_S3) + find_package(AWSSDK REQUIRED) + # Fix issue where scripts expect a variable called "AWSSDK_LINK_LIBRARIES" + # which is not defined by the generated AWSSDKConfig.cmake + if(NOT DEFINED AWSSDK_LINK_LIBRARIES) + set(AWSSDK_LINK_LIBRARIES "${AWSSDK_LIBRARIES}") + endif() + + # Causes logic used for generated .pc file to not run + # avoiding instropection of target `aws-cpp-sdk::aws-cpp-sdk` + # This is fine because the generated .pc file is not of use + set(AWSSDK_SOURCE "conan") +endif() diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index cb60b5bb95dea0..00c6c39a561ae8 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -139,6 +139,7 @@ def _compilers_minimum_version(self): def export_sources(self): export_conandata_patches(self) + copy(self, "conan_cmake_project_include.cmake", self.recipe_folder, os.path.join(self.export_sources_folder, "src")) def config_options(self): if self.settings.os == "Windows": @@ -499,6 +500,8 @@ def generate(self): tc.variables["ARROW_USE_STATIC_CRT"] = is_msvc_static_runtime(self) if self.options.with_llvm: tc.variables["LLVM_DIR"] = self.dependencies["llvm-core"].package_folder.replace("\\", "/") + + tc.cache_variables["CMAKE_PROJECT_arrow_INCLUDE"] = os.path.join(self.source_folder, "conan_cmake_project_include.cmake") tc.generate() deps = CMakeDeps(self) From 2ec1c8dc1a762f4bee9b964c9c3ea3abfc623947 Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Mon, 9 Oct 2023 21:41:23 +0400 Subject: [PATCH 1020/1140] (#20245) [openvino] ported upstream patches to 2023.1.0 --- recipes/openvino/all/conandata.yml | 14 +- recipes/openvino/all/conanfile.py | 70 +- .../dependencies/dependencies-2023.1.0.yml | 2 + .../0003-fixed-gpu-with-onednn-build.patch | 644 +++- .../0004-fixed-gpu-plugin-with-clang.patch | 2836 +++++++++++++++++ 5 files changed, 3526 insertions(+), 40 deletions(-) create mode 100644 recipes/openvino/all/dependencies/dependencies-2023.1.0.yml create mode 100644 recipes/openvino/all/patches/2023.1.0/0004-fixed-gpu-plugin-with-clang.patch diff --git a/recipes/openvino/all/conandata.yml b/recipes/openvino/all/conandata.yml index 375c797c46fca2..754a9fdac40d34 100644 --- a/recipes/openvino/all/conandata.yml +++ b/recipes/openvino/all/conandata.yml @@ -1,8 +1,8 @@ sources: "2023.1.0": "openvino": - url: "https://github.com/openvinotoolkit/openvino/archive/47b736f63edda256d66e2bbb572f42a9d6549f6e.tar.gz" - sha256: "8a1dd5b35fe4b60440e97ee61e12e01aa4dd78b5be30550aa08fcd96c416e1d7" + url: "https://github.com/openvinotoolkit/openvino/archive/refs/tags/2023.1.0.tar.gz" + sha256: "ff88596b342440185874ddbe22874b47ad7b923f14671921af760b15c98aacd6" "arm_compute": url: "https://github.com/ARM-software/ComputeLibrary/archive/refs/tags/v23.02.1.tar.gz" sha256: "c3a443e26539f866969242e690cf0651ef629149741ee18732f954c734da6763" @@ -30,5 +30,11 @@ patches: patch_type: "portability" # severals PR are merged into a single patch including: # https://github.com/openvinotoolkit/openvino/pull/19668, - # https://github.com/openvinotoolkit/openvino/pull/19715 and - patch_source: "https://github.com/openvinotoolkit/openvino/pull/19716" + # https://github.com/openvinotoolkit/openvino/pull/19715, + # https://github.com/openvinotoolkit/openvino/pull/19716, + # https://github.com/openvinotoolkit/openvino/pull/19762 and + patch_source: "https://github.com/openvinotoolkit/openvino/pull/19811" + - patch_file: "patches/2023.1.0/0004-fixed-gpu-plugin-with-clang.patch" + patch_description: "Fixed order of initialization of static variables in GPU plugin compiled with clang" + patch_type: "portability" + patch_source: "https://github.com/openvinotoolkit/openvino/pull/19768" diff --git a/recipes/openvino/all/conanfile.py b/recipes/openvino/all/conanfile.py index de1677f7edab65..60ab6b910442c0 100644 --- a/recipes/openvino/all/conanfile.py +++ b/recipes/openvino/all/conanfile.py @@ -1,10 +1,12 @@ from conan import ConanFile -from conan.errors import ConanInvalidConfiguration +from conan.errors import ConanException, ConanInvalidConfiguration from conan.tools.build import check_min_cppstd, cross_building from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeToolchain, CMakeDeps, cmake_layout -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, rmdir +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir +import functools import os +import yaml required_conan_version = ">=1.60.0 <2.0 || >=2.0.8" @@ -63,6 +65,24 @@ class OpenvinoConan(ConanFile): "enable_pytorch_frontend": True } + @property + def _dependencies_filename(self): + return f"dependencies-{self.version}.yml" + + @property + @functools.lru_cache(1) + def _dependencies_versions(self): + dependencies_filepath = os.path.join(self.recipe_folder, "dependencies", self._dependencies_filename) + if not os.path.isfile(dependencies_filepath): + raise ConanException(f"Cannot find {dependencies_filepath}") + cached_dependencies = yaml.safe_load(open(dependencies_filepath, encoding='UTF-8')) + return cached_dependencies + + def _require(self, dependency): + if dependency not in self._dependencies_versions: + raise ConanException(f"{dependency} is missing in {self._dependencies_filename}") + return f"{dependency}/{self._dependencies_versions[dependency]}" + @property def _protobuf_required(self): return self.options.enable_tf_frontend or self.options.enable_onnx_frontend or self.options.enable_paddle_frontend @@ -85,12 +105,7 @@ def _gpu_option_available(self): @property def _preprocessing_available(self): - return Version(self.version) < "2023.2.0" - - @property - def _onnx_version(self): - if Version(self.version) == "2023.1.0": - return "1.13.1" + return "ade" in self._dependencies_versions @property def _compilers_minimum_version(self): @@ -112,8 +127,12 @@ def source(self): destination=f"{self.source_folder}/src/plugins/intel_cpu/thirdparty/ComputeLibrary") get(self, **self.conan_data["sources"][self.version]["onednn_gpu"], strip_root=True, destination=f"{self.source_folder}/src/plugins/intel_gpu/thirdparty/onednn_gpu") + rmdir(self, f"{self.source_folder}/src/plugins/intel_gpu/thirdparty/rapidjson") apply_conandata_patches(self) + def export(self): + copy(self, f"dependencies/{self._dependencies_filename}", self.recipe_folder, self.export_folder) + def export_sources(self): export_conandata_patches(self) @@ -130,20 +149,17 @@ def configure(self): # we need to use static protobuf to overcome potential issues with multiple registrations inside # protobuf when frontends (implemented as plugins) are loaded multiple times in runtime self.options["protobuf"].shared = False - # disable GPU plugin when clang is used; plugin has issues with static variables initialization - if self.settings.compiler == "clang" and self.options.get_safe("enable_gpu"): - self.options.enable_gpu = False def build_requirements(self): if self._target_arm: - self.tool_requires("scons/[>=4.2.0]") + self.tool_requires("scons/4.3.0") if cross_building(self): if self._protobuf_required: self.tool_requires("protobuf/") if self.options.enable_tf_lite_frontend: self.tool_requires("flatbuffers/") if not self.options.shared: - self.tool_requires("cmake/[>=3.18]") + self.tool_requires("cmake/[>=3.18 <4]") def requirements(self): self.requires("onetbb/2021.9.0") @@ -152,16 +168,17 @@ def requirements(self): self.requires("xbyak/6.73") if self.options.get_safe("enable_gpu"): self.requires("opencl-icd-loader/2023.04.17") + self.requires("rapidjson/cci.20220822") if self._protobuf_required: self.requires("protobuf/3.21.12") if self.options.enable_tf_frontend: self.requires("snappy/1.1.10") if self.options.enable_onnx_frontend: - self.requires(f"onnx/{self._onnx_version}") + self.requires(self._require("onnx")) if self.options.enable_tf_lite_frontend: self.requires("flatbuffers/22.9.24") if self._preprocessing_available: - self.requires("ade/0.1.2c") + self.requires(self._require("ade")) def layout(self): cmake_layout(self, src_folder="src") @@ -175,7 +192,7 @@ def generate(self): toolchain.cache_variables["ENABLE_INTEL_CPU"] = self.options.enable_cpu if self._gpu_option_available: toolchain.cache_variables["ENABLE_INTEL_GPU"] = self.options.enable_gpu - toolchain.cache_variables["ENABLE_ONEDNN_FOR_GPU"] = self.options.shared + toolchain.cache_variables["ENABLE_ONEDNN_FOR_GPU"] = self.options.shared or not self.options.enable_cpu if self._gna_option_available: toolchain.cache_variables["ENABLE_INTEL_GNA"] = False # SW plugins @@ -248,17 +265,12 @@ def validate(self): if self._protobuf_required and self.options.shared and self.dependencies["protobuf"].options.shared: raise ConanInvalidConfiguration(f"{self.ref}:shared=True requires protobuf:shared=False for correct work.") - if self.options.get_safe("enable_gpu"): - # GPU does not support oneDNN in static build configuration, warn about it - if not self.options.shared: - self.output.warning(f"{self.name} recipe builds GPU plugin without oneDNN (dGPU) support during static build.") - - # GPU plugin is currently not stable when compiled with clang compiler - if self.settings.compiler == "clang": - raise ConanInvalidConfiguration( - "GPU plugin cannot be built with clang compiler." - "Please, disable GPU plugin (openvino/*:enable_gpu=False) or change the compiler" - ) + if self.options.get_safe("enable_gpu") and not self.options.shared and self.options.enable_cpu: + # GPU and CPU plugins cannot be simultaneously built statically, because they use different oneDNN versions + self.output.warning(f"{self.name} recipe builds GPU plugin without oneDNN (dGPU) support during static build," + "because CPU plugin compiled with different oneDNN version may cause ODR violation." + "To enable oneDNN support for GPU plugin, please, either use shared build configuration" + "or disable CPU plugin by setting 'enable_cpu' option to False.") def build(self): cmake = CMake(self) @@ -305,6 +317,8 @@ def package_info(self): if self.options.get_safe("enable_gpu"): openvino_runtime.libs.extend(["openvino_intel_gpu_plugin", "openvino_intel_gpu_graph", "openvino_intel_gpu_runtime", "openvino_intel_gpu_kernels"]) + if not self.options.enable_cpu: + openvino_runtime.libs.append("openvino_onednn_gpu") # SW plugins if self.options.enable_auto: openvino_runtime.libs.append("openvino_auto_plugin") @@ -346,7 +360,7 @@ def package_info(self): openvino_runtime.defines = ["OPENVINO_STATIC_LIBRARY"] if self.options.get_safe("enable_gpu"): - openvino_runtime.requires.append("opencl-icd-loader::opencl-icd-loader") + openvino_runtime.requires.extend(["opencl-icd-loader::opencl-icd-loader", "rapidjson::rapidjson"]) if self.settings.os == "Windows": openvino_runtime.system_libs.append("setupapi") diff --git a/recipes/openvino/all/dependencies/dependencies-2023.1.0.yml b/recipes/openvino/all/dependencies/dependencies-2023.1.0.yml new file mode 100644 index 00000000000000..e789abb75808e0 --- /dev/null +++ b/recipes/openvino/all/dependencies/dependencies-2023.1.0.yml @@ -0,0 +1,2 @@ +onnx: "1.13.1" +ade: "0.1.2c" diff --git a/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch b/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch index fc7beb3b5ec368..e5791b37c7a7ac 100644 --- a/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch +++ b/recipes/openvino/all/patches/2023.1.0/0003-fixed-gpu-with-onednn-build.patch @@ -1,10 +1,548 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 461f1a209c..0b552b3da3 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -47,6 +47,7 @@ message (STATUS "CMAKE_GENERATOR ....................... " ${CMAKE_GENERATOR}) + message (STATUS "CPACK_GENERATOR ....................... " ${CPACK_GENERATOR}) + message (STATUS "CMAKE_C_COMPILER_ID ................... " ${CMAKE_C_COMPILER_ID}) + message (STATUS "CMAKE_CXX_COMPILER_ID ................. " ${CMAKE_CXX_COMPILER_ID}) ++message (STATUS "CMAKE_CXX_STANDARD .................... " ${CMAKE_CXX_STANDARD}) + if(OV_GENERATOR_MULTI_CONFIG) + string(REPLACE ";" " " config_types "${CMAKE_CONFIGURATION_TYPES}") + message (STATUS "CMAKE_CONFIGURATION_TYPES ............. " ${config_types}) +diff --git a/cmake/developer_package/plugins/plugins.cmake b/cmake/developer_package/plugins/plugins.cmake +index 436685355a..ea187411d1 100644 +--- a/cmake/developer_package/plugins/plugins.cmake ++++ b/cmake/developer_package/plugins/plugins.cmake +@@ -117,6 +117,10 @@ function(ov_add_plugin) + # install rules + if(NOT OV_PLUGIN_SKIP_INSTALL OR NOT BUILD_SHARED_LIBS) + string(TOLOWER "${OV_PLUGIN_DEVICE_NAME}" install_component) ++ if(NOT BUILD_SHARED_LIBS) ++ # in case of static libs everything is installed to 'core' ++ set(install_component ${OV_CPACK_COMP_CORE}) ++ endif() + + if(OV_PLUGIN_PSEUDO_DEVICE) + set(plugin_hidden HIDDEN) +diff --git a/cmake/features.cmake b/cmake/features.cmake +index e4b60c89e0..7327b262a2 100644 +--- a/cmake/features.cmake ++++ b/cmake/features.cmake +@@ -23,7 +23,7 @@ endif() + + ie_dependent_option (ENABLE_INTEL_GPU "GPU OpenCL-based plugin for OpenVINO Runtime" ${ENABLE_INTEL_GPU_DEFAULT} "X86_64 OR AARCH64;NOT APPLE;NOT WINDOWS_STORE;NOT WINDOWS_PHONE" OFF) + +-if (ANDROID OR (CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0) OR NOT BUILD_SHARED_LIBS) ++if (ANDROID OR MINGW OR (CMAKE_COMPILER_IS_GNUCXX AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS 7.0) OR (NOT BUILD_SHARED_LIBS AND ENABLE_INTEL_CPU)) + # oneDNN doesn't support old compilers and android builds for now, so we'll build GPU plugin without oneDNN + # also, in case of static build CPU's and GPU's oneDNNs will conflict, so we are disabling GPU's one in this case + set(ENABLE_ONEDNN_FOR_GPU_DEFAULT OFF) +diff --git a/cmake/templates/OpenVINOConfig.cmake.in b/cmake/templates/OpenVINOConfig.cmake.in +index 9eb1cfdd35..7dda80d8a3 100644 +--- a/cmake/templates/OpenVINOConfig.cmake.in ++++ b/cmake/templates/OpenVINOConfig.cmake.in +@@ -223,6 +223,10 @@ macro(_ov_find_tbb) + PATHS ${_tbb_bind_dir} + NO_CMAKE_FIND_ROOT_PATH + NO_DEFAULT_PATH) ++ if(TARGET TBBbind::tbbbind_2_5) ++ # To solve https://cmake.org/cmake/help/latest/policy/CMP0111.html warnings ++ set_property(TARGET TBBbind::tbbbind_2_5 PROPERTY IMPORTED_CONFIGURATIONS RELEASE DEBUG) ++ endif() + unset(_tbb_bind_dir) + endif() + unset(install_tbbbind) +@@ -343,11 +347,15 @@ endmacro() + macro(_ov_find_intel_cpu_dependencies) + set(_OV_ENABLE_CPU_ACL "@DNNL_USE_ACL@") + if(_OV_ENABLE_CPU_ACL) +- set(_ov_in_install_tree "@PACKAGE_ARM_COMPUTE_LIB_DIR@") ++ set(_ov_in_install_tree "@PACKAGE_OPENVINO_LIB_DIR@") + if(_ov_in_install_tree) +- set_and_check(ARM_COMPUTE_LIB_DIR "@PACKAGE_ARM_COMPUTE_LIB_DIR@") ++ set_and_check(ARM_COMPUTE_LIB_DIR "@PACKAGE_OPENVINO_LIB_DIR@") + set(ACL_DIR "${CMAKE_CURRENT_LIST_DIR}") + else() ++ if(NOT TARGET arm_compute::arm_compute) ++ # for case when build tree is used separately, e.g. OpenVINODeveloperPackageConfig.cmake ++ set_and_check(ARM_COMPUTE_LIB_DIR "@PACKAGE_CMAKE_ARCHIVE_OUTPUT_DIRECTORY@") ++ endif() + set_and_check(ACL_DIR "@PACKAGE_FIND_ACL_PATH@") + endif() + +@@ -363,16 +371,50 @@ macro(_ov_find_intel_gpu_dependencies) + set(_OV_ENABLE_INTEL_GPU "@ENABLE_INTEL_GPU@") + set(_OV_ENABLE_SYSTEM_OPENCL "@ENABLE_SYSTEM_OPENCL@") + if(_OV_ENABLE_INTEL_GPU AND _OV_ENABLE_SYSTEM_OPENCL) +- set(_OV_OpenCLICDLoader_FOUND "@OpenCLICDLoader_FOUND@") +- if(_OV_OpenCLICDLoader_FOUND) +- _ov_find_dependency(OpenCLICDLoader) +- else() +- _ov_find_dependency(OpenCL) +- endif() +- unset(_OV_OpenCLICDLoader_FOUND) ++ _ov_find_dependency(OpenCL) + endif() + unset(_OV_ENABLE_INTEL_GPU) + unset(_OV_ENABLE_SYSTEM_OPENCL) ++ ++ set(_OV_ENABLE_ONEDNN_FOR_GPU "@ENABLE_ONEDNN_FOR_GPU@") ++ if(_OV_ENABLE_ONEDNN_FOR_GPU AND NOT TARGET onednn_gpu_tgt) ++ set(_OV_DNNL_GPU_LIBRARY_NAME "@DNNL_GPU_LIBRARY_NAME@") ++ ++ set(_ov_in_install_tree "@PACKAGE_OPENVINO_LIB_DIR@") ++ if(_ov_in_install_tree) ++ set(onednn_gpu_lib "${CMAKE_STATIC_LIBRARY_PREFIX}${_OV_DNNL_GPU_LIBRARY_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}") ++ set_and_check(onednn_gpu_lib_root "@PACKAGE_OPENVINO_LIB_DIR@") ++ if(WIN32) ++ if(OV_GENERATOR_MULTI_CONFIG) ++ set(extra_args PATH_SUFFIXES ${CMAKE_CONFIGURATION_TYPES}) ++ else() ++ set(extra_args PATH_SUFFIXES ${CMAKE_BUILD_TYPE}) ++ endif() ++ endif() ++ ++ find_library(onednn_gpu_lib_path ++ NAMES ${_OV_DNNL_GPU_LIBRARY_NAME} ++ PATHS ${onednn_gpu_lib_root} ++ ${extra_args}) ++ ++ if(NOT onednn_gpu_lib_path) ++ message(FATAL_ERROR "Internal error: failed to find '${_OV_DNNL_GPU_LIBRARY_NAME}' in '${onednn_gpu_lib_root}'") ++ endif() ++ ++ unset(extra_args) ++ unset(onednn_gpu_lib) ++ else() ++ set_and_check(onednn_gpu_lib_path "@PACKAGE_ONEDNN_GPU_LIB_PATH@") ++ endif() ++ ++ set_target_properties(openvino::onednn_gpu_tgt PROPERTIES ++ INTERFACE_LINK_LIBRARIES "${onednn_gpu_lib_path}") ++ ++ unset(onednn_gpu_lib_path) ++ unset(_ov_in_install_tree) ++ unset(_OV_DNNL_GPU_LIBRARY_NAME) ++ endif() ++ unset(_OV_ENABLE_ONEDNN_FOR_GPU) + endmacro() + + macro(_ov_find_intel_gna_dependencies) +@@ -455,6 +497,7 @@ set(_OV_ENABLE_OPENVINO_BUILD_SHARED "@BUILD_SHARED_LIBS@") + + if(NOT TARGET openvino) + set(_ov_as_external_package ON) ++ include("${CMAKE_CURRENT_LIST_DIR}/OpenVINOTargets.cmake") + endif() + + if(NOT _OV_ENABLE_OPENVINO_BUILD_SHARED) +@@ -487,8 +530,6 @@ set(_ov_imported_libs openvino::runtime openvino::runtime::c + openvino::frontend::pytorch openvino::frontend::tensorflow_lite) + + if(_ov_as_external_package) +- include("${CMAKE_CURRENT_LIST_DIR}/OpenVINOTargets.cmake") +- + foreach(target IN LISTS _ov_imported_libs) + if(TARGET ${target}) + get_target_property(imported_configs ${target} IMPORTED_CONFIGURATIONS) +diff --git a/src/cmake/openvino.cmake b/src/cmake/openvino.cmake +index eb9a54354e..1d2996482b 100644 +--- a/src/cmake/openvino.cmake ++++ b/src/cmake/openvino.cmake +@@ -157,9 +157,12 @@ if(ENABLE_INTEL_GNA) + list(APPEND PATH_VARS "GNA_PATH") + endif() + if(DNNL_USE_ACL) +- list(APPEND BUILD_PATH_VARS "FIND_ACL_PATH") ++ list(APPEND BUILD_PATH_VARS "FIND_ACL_PATH;CMAKE_ARCHIVE_OUTPUT_DIRECTORY") + set(FIND_ACL_PATH "${intel_cpu_thirdparty_SOURCE_DIR}") + endif() ++if(ENABLE_ONEDNN_FOR_GPU) ++ list(APPEND BUILD_PATH_VARS "ONEDNN_GPU_LIB_PATH") ++endif() + + set(PUBLIC_HEADERS_DIR "${OpenVINO_SOURCE_DIR}/src/inference/include") + set(IE_INCLUDE_DIR "${PUBLIC_HEADERS_DIR}/ie") +@@ -177,12 +180,10 @@ configure_package_config_file("${OpenVINO_SOURCE_DIR}/cmake/templates/OpenVINOCo + + # install tree + +-if(DNNL_USE_ACL) +- list(APPEND INSTALL_PATH_VARS "ARM_COMPUTE_LIB_DIR") +- # remove generator expression at the end, because searching in Release / Debug will be +- # done by ACLConfig.cmake itself +- string(REPLACE "$" "" ARM_COMPUTE_LIB_DIR "${OV_CPACK_LIBRARYDIR}") +-endif() ++list(APPEND INSTALL_PATH_VARS "OPENVINO_LIB_DIR") ++# remove generator expression at the end, because searching in Release / Debug ++# will be done by inside OpenVINOConfig.cmak / ACLConfig.cmake ++string(REPLACE "$" "" OPENVINO_LIB_DIR "${OV_CPACK_LIBRARYDIR}") + + set(IE_INCLUDE_DIR "${OV_CPACK_INCLUDEDIR}/ie") + set(IE_TBB_DIR "${IE_TBB_DIR_INSTALL}") +diff --git a/src/plugins/intel_cpu/thirdparty/CMakeLists.txt b/src/plugins/intel_cpu/thirdparty/CMakeLists.txt +index 98935a0792..7e8325acef 100644 +--- a/src/plugins/intel_cpu/thirdparty/CMakeLists.txt ++++ b/src/plugins/intel_cpu/thirdparty/CMakeLists.txt +@@ -117,7 +117,7 @@ function(ov_add_onednn) + add_subdirectory(onednn EXCLUDE_FROM_ALL) + + # install static libraries +- ov_install_static_lib(dnnl cpu) ++ ov_install_static_lib(dnnl ${OV_CPACK_COMP_CORE}) + + if(DNNL_USE_ACL AND NOT BUILD_SHARED_LIBS) + # use ACLConfig.cmake in OpenVINOConfig.cmake in case of static build +@@ -125,16 +125,16 @@ function(ov_add_onednn) + # but for this we need to install library files + install(FILES $ + DESTINATION ${OV_CPACK_ARCHIVEDIR} +- COMPONENT cpu) ++ COMPONENT ${OV_CPACK_COMP_CORE}) + install(FILES "${intel_cpu_thirdparty_SOURCE_DIR}/ACLConfig.cmake" + DESTINATION ${OV_CPACK_OPENVINO_CMAKEDIR} +- COMPONENT core_dev) ++ COMPONENT ${OV_CPACK_COMP_CORE_DEV}) + endif() + endfunction() + + if(ENABLE_MLAS_FOR_CPU) + add_subdirectory(mlas) +- ov_install_static_lib(mlas cpu) ++ ov_install_static_lib(mlas ${OV_CPACK_COMP_CORE}) + endif() + + ov_add_onednn() +diff --git a/src/plugins/intel_gpu/CMakeLists.txt b/src/plugins/intel_gpu/CMakeLists.txt +index 1770b34b65..4e8a9d0e68 100644 +--- a/src/plugins/intel_gpu/CMakeLists.txt ++++ b/src/plugins/intel_gpu/CMakeLists.txt +@@ -35,6 +35,7 @@ set(MAIN_DIR "${CMAKE_CURRENT_SOURCE_DIR}") + set(INCLUDE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/include") + + add_subdirectory(thirdparty) ++include(thirdparty/cmake/rapidjson.cmake) + + if(CMAKE_COMPILER_IS_GNUCXX) + ie_add_compiler_flags(-Werror) +diff --git a/src/plugins/intel_gpu/src/graph/CMakeLists.txt b/src/plugins/intel_gpu/src/graph/CMakeLists.txt +index 0b2093d2a0..fac58ec0fa 100644 +--- a/src/plugins/intel_gpu/src/graph/CMakeLists.txt ++++ b/src/plugins/intel_gpu/src/graph/CMakeLists.txt +@@ -58,7 +58,7 @@ elseif((NOT ANDROID) AND (UNIX)) + target_link_libraries(${TARGET_NAME} PRIVATE pthread) + endif() + +-ov_install_static_lib(${TARGET_NAME} gpu) ++ov_install_static_lib(${TARGET_NAME} ${OV_CPACK_COMP_CORE}) + + if(ENABLE_SSE42) + ie_sse42_optimization_flags(sse4_2_flags) +diff --git a/src/plugins/intel_gpu/src/kernel_selector/CMakeLists.txt b/src/plugins/intel_gpu/src/kernel_selector/CMakeLists.txt +index b76d8ee732..99ebf5331a 100644 +--- a/src/plugins/intel_gpu/src/kernel_selector/CMakeLists.txt ++++ b/src/plugins/intel_gpu/src/kernel_selector/CMakeLists.txt +@@ -61,7 +61,8 @@ endif() + target_include_directories(${TARGET_NAME} PUBLIC $ + $ + $ +- $) ++ $ ++ PRIVATE $) + + target_compile_options(${TARGET_NAME} PRIVATE + $<$:$,/Os,-Os>>) +@@ -70,7 +71,7 @@ if(COMMAND add_cpplint_target) + add_cpplint_target(${TARGET_NAME}_cpplint FOR_TARGETS ${TARGET_NAME}) + endif() + +-target_link_libraries(${TARGET_NAME} PUBLIC OpenCL::OpenCL rapidjson inference_engine_plugin_api) ++target_link_libraries(${TARGET_NAME} PUBLIC OpenCL::OpenCL inference_engine_plugin_api) + + set_target_properties(${TARGET_NAME} PROPERTIES INTERPROCEDURAL_OPTIMIZATION_RELEASE ${ENABLE_LTO}) + +@@ -90,8 +91,16 @@ add_custom_command( + TARGET ${TARGET_NAME} POST_BUILD + COMMAND "${CMAKE_COMMAND}" -E copy_if_different ${CMAKE_CURRENT_SOURCE_DIR}/cache/cache.json ${TUNING_CACHE_PATH}/cache.json) + ++if(BUILD_SHARED_LIBS) ++ set(CACHE_JSON_INSTALL_DIR ${OV_CPACK_PLUGINSDIR}) ++ set(CACHE_JSON_COMPONENT gpu) ++else() ++ set(CACHE_JSON_INSTALL_DIR ${OV_CPACK_ARCHIVEDIR}) ++ set(CACHE_JSON_COMPONENT ${OV_CPACK_COMP_CORE}) ++endif() ++ + install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/cache/cache.json +- DESTINATION ${OV_CPACK_PLUGINSDIR} +- COMPONENT gpu) ++ DESTINATION ${CACHE_JSON_INSTALL_DIR} ++ COMPONENT ${CACHE_JSON_COMPONENT}) + +-ov_install_static_lib(${TARGET_NAME} gpu) ++ov_install_static_lib(${TARGET_NAME} ${OV_CPACK_COMP_CORE}) +diff --git a/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.cpp b/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.cpp +index cfac486cdf..a5d0711f61 100644 +--- a/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.cpp ++++ b/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.cpp +@@ -3,18 +3,21 @@ + // + + #include "auto_tuner.h" ++ + #include + #include + #include + #include + #include +-#include "istreamwrapper.h" +-#include "stringbuffer.h" +-#include "prettywriter.h" + #include + #include + #include + ++#include "rapidjson/istreamwrapper.h" ++#include "rapidjson/stringbuffer.h" ++#include "rapidjson/prettywriter.h" ++#include "rapidjson/document.h" ++ + #ifdef _WIN32 + #ifndef WIN32_LEAN_AND_MEAN + #define WIN32_LEAN_AND_MEAN +@@ -35,32 +38,37 @@ + + namespace kernel_selector { + ++class TuningCache::Impl { ++public: ++ rapidjson::Document cache; ++}; ++ + TuningCache::TuningCache(const std::string& cacheFilePath) +- : cache() { ++ : impl(new Impl()) { + // Read cache file + std::ifstream tuningFile(cacheFilePath); + + if (tuningFile && tuningFile.good()) { + std::stringstream buffer; + buffer << tuningFile.rdbuf(); +- cache.Parse(buffer.str().c_str()); ++ impl->cache.Parse(buffer.str().c_str()); + } else { + throw std::runtime_error("Tuning file: " + cacheFilePath + " could not be read! Must provide a valid cache file in USE_CACHE mode."); + } + +- if (cache.IsNull()) { +- cache.SetObject(); +- } else if (!cache.IsObject()) { ++ if (impl->cache.IsNull()) { ++ impl->cache.SetObject(); ++ } else if (!impl->cache.IsObject()) { + throw std::runtime_error("Tuning file: " + cacheFilePath + " has incorrect format."); + } + +- auto cacheObj = cache.GetObject(); ++ auto cacheObj = impl->cache.GetObject(); + + // Update to new format with version markers + if (!cacheObj.HasMember(version2Marker)) { +- auto newName = rapidjson::Value(version2Marker, cache.GetAllocator()); ++ auto newName = rapidjson::Value(version2Marker, impl->cache.GetAllocator()); + auto newObj = rapidjson::Value(rapidjson::Type::kObjectType); +- cacheObj.AddMember(newName, newObj, cache.GetAllocator()); ++ cacheObj.AddMember(newName, newObj, impl->cache.GetAllocator()); + } + + bool needsV1 = false; +@@ -73,9 +81,9 @@ TuningCache::TuningCache(const std::string& cacheFilePath) + + if (needsV1) { + if (!cacheObj.HasMember(version1Marker)) { +- auto newName = rapidjson::Value(version1Marker, cache.GetAllocator()); ++ auto newName = rapidjson::Value(version1Marker, impl->cache.GetAllocator()); + auto newObj = rapidjson::Value(rapidjson::Type::kObjectType); +- cacheObj.AddMember(newName, newObj, cache.GetAllocator()); ++ cacheObj.AddMember(newName, newObj, impl->cache.GetAllocator()); + } + + for (auto it = cacheObj.begin(); it != cacheObj.end();) { +@@ -86,7 +94,7 @@ TuningCache::TuningCache(const std::string& cacheFilePath) + auto newValue = rapidjson::Value(rapidjson::Type::kObjectType); + newName.Swap(member.name); + newValue.Swap(member.value); +- cache[version1Marker].AddMember(newName, newValue, cache.GetAllocator()); ++ impl->cache[version1Marker].AddMember(newName, newValue, impl->cache.GetAllocator()); + it = cacheObj.EraseMember(it); + } else { + it++; +@@ -96,11 +104,11 @@ TuningCache::TuningCache(const std::string& cacheFilePath) + } + + TuningCache::TuningCache() +- : cache() { +- cache.SetObject(); +- auto v2Name = rapidjson::Value(version2Marker, cache.GetAllocator()); ++ : impl(new Impl()) { ++ impl->cache.SetObject(); ++ auto v2Name = rapidjson::Value(version2Marker, impl->cache.GetAllocator()); + auto v2Obj = rapidjson::Value(rapidjson::Type::kObjectType); +- cache.AddMember(v2Name, v2Obj, cache.GetAllocator()); ++ impl->cache.AddMember(v2Name, v2Obj, impl->cache.GetAllocator()); + } + + TuningCache::Entry TuningCache::LoadKernel(const Params& params) { +@@ -129,8 +137,8 @@ TuningCache::Entry TuningCache::LoadKernel_v1(const Params& params, uint32_t com + auto hashStr = std::to_string(create_hash(params.to_string())); + auto computeUnitsStr = std::to_string(computeUnitsCount); + +- auto v1It = cache.FindMember(version1Marker); +- if (v1It == cache.MemberEnd()) ++ auto v1It = impl->cache.FindMember(version1Marker); ++ if (v1It == impl->cache.MemberEnd()) + return result; + + auto computeUnitsIt = v1It->value.FindMember(computeUnitsStr.c_str()); +@@ -152,8 +160,8 @@ TuningCache::Entry TuningCache::LoadKernel_v2(const Params& params, uint32_t com + auto paramStr = params.to_cache_string_v2(); + auto computeUnitsStr = std::to_string(computeUnitsCount); + +- auto v2It = cache.FindMember(version2Marker); +- if (v2It == cache.MemberEnd()) ++ auto v2It = impl->cache.FindMember(version2Marker); ++ if (v2It == impl->cache.MemberEnd()) + return result; + + auto computeUnitsIt = v2It->value.FindMember(computeUnitsStr.c_str()); +diff --git a/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.h b/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.h +index 1a875b7d4d..8a9da81354 100644 +--- a/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.h ++++ b/src/plugins/intel_gpu/src/kernel_selector/auto_tuner.h +@@ -8,12 +8,12 @@ + #include + #include + #include +-#include "kernel_selector_common.h" +-#include "kernel_selector_params.h" +-#include "document.h" + #include + #include + ++#include "kernel_selector_common.h" ++#include "kernel_selector_params.h" ++ + namespace kernel_selector { + + class TuningCache { +@@ -42,7 +42,8 @@ private: + Entry LoadKernel_v1(const Params& params, uint32_t computeUnitsCount); + Entry LoadKernel_v2(const Params& params, uint32_t computeUnitsCount); + +- rapidjson::Document cache; ++ class Impl; ++ std::shared_ptr impl; + + static constexpr const char* version1Marker = "version_1"; + static constexpr const char* version2Marker = "version_2"; +diff --git a/src/plugins/intel_gpu/src/kernel_selector/jitter.cpp b/src/plugins/intel_gpu/src/kernel_selector/jitter.cpp +index fe6ffe8008..106560f5f1 100644 +--- a/src/plugins/intel_gpu/src/kernel_selector/jitter.cpp ++++ b/src/plugins/intel_gpu/src/kernel_selector/jitter.cpp +@@ -1540,11 +1540,11 @@ JitConstants MakeActivationJitConstants(std::vector(SCHAR_MIN))); +- nl_n = toCodeString(std::min(params[i].n, static_cast(SCHAR_MAX))); ++ nl_m = toCodeString(std::max(params[i].m, std::numeric_limits::min())); ++ nl_n = toCodeString(std::min(params[i].n, std::numeric_limits::max())); + } else if (out_dt == Datatype::UINT8) { + nl_m = toCodeString(std::max(params[i].m, 0.0f)); +- nl_n = toCodeString(std::min(params[i].n, static_cast(UCHAR_MAX))); ++ nl_n = toCodeString(std::min(params[i].n, std::numeric_limits::max())); + } + } + auto jitConstants = JitConstants{MakeJitConstant("NL_M" + activation_suffix, nl_m), +@@ -1949,11 +1949,11 @@ JitConstants FusedOpsCodeGenerator::MakeOpJitConstants(const FusedOpsConfigurati + + if (activation_p.function == ActivationFunction::CLAMP) { + if (out_type == Datatype::INT8) { +- nl_m = toCodeString(std::max(activation_p.m, static_cast(SCHAR_MIN))); +- nl_n = toCodeString(std::min(activation_p.n, static_cast(SCHAR_MAX))); ++ nl_m = toCodeString(std::max(activation_p.m, std::numeric_limits::min())); ++ nl_n = toCodeString(std::min(activation_p.n, std::numeric_limits::max())); + } else if (out_type == Datatype::UINT8) { + nl_m = toCodeString(std::max(activation_p.m, 0.0f)); +- nl_n = toCodeString(std::min(activation_p.n, static_cast(UCHAR_MAX))); ++ nl_n = toCodeString(std::min(activation_p.n, std::numeric_limits::max())); + } + } + +diff --git a/src/plugins/intel_gpu/src/kernel_selector/kernel_selector_params.h b/src/plugins/intel_gpu/src/kernel_selector/kernel_selector_params.h +index 5c71c907b7..76e84e558b 100644 +--- a/src/plugins/intel_gpu/src/kernel_selector/kernel_selector_params.h ++++ b/src/plugins/intel_gpu/src/kernel_selector/kernel_selector_params.h +@@ -10,7 +10,6 @@ + #include + #include "common_types.h" + #include "tensor_type.h" +-#include "document.h" + #include + #include + #include +diff --git a/src/plugins/intel_gpu/src/runtime/CMakeLists.txt b/src/plugins/intel_gpu/src/runtime/CMakeLists.txt +index c442f65575..321fc2f1b2 100644 +--- a/src/plugins/intel_gpu/src/runtime/CMakeLists.txt ++++ b/src/plugins/intel_gpu/src/runtime/CMakeLists.txt +@@ -64,4 +64,4 @@ elseif((NOT ANDROID) AND (UNIX)) + target_link_libraries(${TARGET_NAME} PRIVATE pthread) + endif() + +-ov_install_static_lib(${TARGET_NAME} gpu) ++ov_install_static_lib(${TARGET_NAME} ${OV_CPACK_COMP_CORE}) diff --git a/src/plugins/intel_gpu/thirdparty/CMakeLists.txt b/src/plugins/intel_gpu/thirdparty/CMakeLists.txt -index c7c616d0df..63eeade1f1 100644 +index c7c616d0df..b7cc810a75 100644 --- a/src/plugins/intel_gpu/thirdparty/CMakeLists.txt +++ b/src/plugins/intel_gpu/thirdparty/CMakeLists.txt -@@ -88,17 +88,12 @@ if(ENABLE_ONEDNN_FOR_GPU) +@@ -2,14 +2,6 @@ + # SPDX-License-Identifier: Apache-2.0 + # + +-add_library(rapidjson INTERFACE) +- +-set_target_properties(rapidjson PROPERTIES +- INTERFACE_INCLUDE_DIRECTORIES $ +-) +- +-ov_install_static_lib(rapidjson gpu) +- + # + # oneDNN for GPU plugin + # +@@ -17,11 +9,12 @@ ov_install_static_lib(rapidjson gpu) + if(ENABLE_ONEDNN_FOR_GPU) + function(build_onednn_gpu) + include(ExternalProject) +- set(ONEDNN_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/onednn_gpu_build/") +- set(ONEDNN_INSTALL_DIR "${CMAKE_CURRENT_BINARY_DIR}/onednn_gpu_install/") ++ set(ONEDNN_BUILD_DIR "${CMAKE_CURRENT_BINARY_DIR}/onednn_gpu_build") ++ set(ONEDNN_INSTALL_DIR "${CMAKE_CURRENT_BINARY_DIR}/onednn_gpu_install" CACHE PATH "Installation path for oneDNN GPU library") + set(ONEDNN_PREFIX_DIR "${CMAKE_CURRENT_BINARY_DIR}/onednn_gpu_root") + set(ONEDNN_ENABLED_PRIMITIVES "CONCAT;CONVOLUTION;DECONVOLUTION;INNER_PRODUCT;MATMUL;REORDER;POOLING;REDUCTION") + set(ONEDNN_ENABLED_ISA "XEHP;XEHPG;XEHPC") ++ set(DNNL_GPU_LIBRARY_NAME "openvino_onednn_gpu" CACHE STRING "Name of oneDNN library for Intel GPU Plugin") + + if(X86_64) + set(ONEDNN_TARGET_ARCH "X64" CACHE STRING "" FORCE) +@@ -87,18 +80,16 @@ if(ENABLE_ONEDNN_FOR_GPU) + list(APPEND cmake_extra_args "-DOpenCL_INCLUDE_DIR=${OpenCL_INCLUDE_DIR}") endif() ++ set(onednn_gpu_lib "${CMAKE_STATIC_LIBRARY_PREFIX}${DNNL_GPU_LIBRARY_NAME}${CMAKE_STATIC_LIBRARY_SUFFIX}") ++ set(ONEDNN_GPU_LIB_PATH ${ONEDNN_INSTALL_DIR}/lib/${onednn_gpu_lib} CACHE FILEPATH "Path to oneDNN GPU library") ++ ExternalProject_Add(onednn_gpu_build + # Directory Options: + PREFIX "${ONEDNN_PREFIX_DIR}" @@ -23,15 +561,18 @@ index c7c616d0df..63eeade1f1 100644 CMAKE_ARGS ${cmake_extra_args} "-DCMAKE_CXX_COMPILER=${CMAKE_CXX_COMPILER}" -@@ -114,7 +109,6 @@ if(ENABLE_ONEDNN_FOR_GPU) +@@ -112,9 +103,8 @@ if(ENABLE_ONEDNN_FOR_GPU) + "-DDNNL_TARGET_ARCH=${ONEDNN_TARGET_ARCH}" + "-DDNNL_CPU_RUNTIME=NONE" "-DDNNL_GPU_RUNTIME=OCL" - "-DDNNL_LIBRARY_NAME=openvino_onednn_gpu" +- "-DDNNL_LIBRARY_NAME=openvino_onednn_gpu" ++ "-DDNNL_LIBRARY_NAME=${DNNL_GPU_LIBRARY_NAME}" "-DCMAKE_INSTALL_PREFIX=${ONEDNN_INSTALL_DIR}" - "-DCMAKE_INSTALL_LIBDIR=lib/$" "-DDNNL_ENABLE_CONCURRENT_EXEC=ON" "-DDNNL_ENABLE_PRIMITIVE_CACHE=OFF" "-DDNNL_ENABLE_WORKLOAD=INFERENCE" -@@ -129,10 +123,21 @@ if(ENABLE_ONEDNN_FOR_GPU) +@@ -129,16 +119,38 @@ if(ENABLE_ONEDNN_FOR_GPU) # specifically for Conan, because it overrides CMAKE_PREFIX_PATH and oneDNN's FindOpenCL.cmake is ignored # Conan's FindOpenCL.cmake module does not set OpenCL_INCLUDE_DIRS, so we need to set it manually "-DOpenCL_INCLUDE_DIRS=$" @@ -44,13 +585,100 @@ index c7c616d0df..63eeade1f1 100644 + # Thus we pass it via CMAKE_CACHE_ARGS + "-DDNNL_ENABLE_PRIMITIVE:STRING=${ONEDNN_ENABLED_PRIMITIVES}" + "-DDNNL_ENABLE_PRIMITIVE_GPU_ISA:STRING=${ONEDNN_ENABLED_ISA}" ++ # Build Step Options: ++ BUILD_BYPRODUCTS ${ONEDNN_GPU_LIB_PATH} + # Target Options: + EXCLUDE_FROM_ALL ON ) ++ add_library(onednn_gpu_tgt INTERFACE) set_target_properties(onednn_gpu_tgt PROPERTIES - INTERFACE_LINK_DIRECTORIES "${ONEDNN_INSTALL_DIR}/lib/$" -+ INTERFACE_LINK_DIRECTORIES "${ONEDNN_INSTALL_DIR}/lib" - INTERFACE_LINK_LIBRARIES "openvino_onednn_gpu" - INTERFACE_INCLUDE_DIRECTORIES "${ONEDNN_INSTALL_DIR}/include" +- INTERFACE_LINK_LIBRARIES "openvino_onednn_gpu" +- INTERFACE_INCLUDE_DIRECTORIES "${ONEDNN_INSTALL_DIR}/include" ++ INTERFACE_LINK_LIBRARIES $ ++ INTERFACE_INCLUDE_DIRECTORIES $ INTERFACE_COMPILE_DEFINITIONS ENABLE_ONEDNN_FOR_GPU + ) + add_dependencies(onednn_gpu_tgt onednn_gpu_build) +- # TODO: install onednn_gpu in static builds ++ ++ if(NOT BUILD_SHARED_LIBS) ++ ov_install_static_lib(onednn_gpu_tgt ${OV_CPACK_COMP_CORE}) ++ ++ # we need to install library explicitly and set_target_properties in OpenVINOConfig.cmake for 'onednn_gpu_tgt' ++ # to point to installation location of this file ++ install(FILES "${ONEDNN_GPU_LIB_PATH}" ++ DESTINATION ${OV_CPACK_ARCHIVEDIR} ++ COMPONENT ${OV_CPACK_COMP_CORE}) ++ endif() + endfunction() + build_onednn_gpu() + endif() +diff --git a/src/plugins/intel_gpu/thirdparty/cmake/rapidjson.cmake b/src/plugins/intel_gpu/thirdparty/cmake/rapidjson.cmake +new file mode 100644 +index 0000000000..655224dbc1 +--- /dev/null ++++ b/src/plugins/intel_gpu/thirdparty/cmake/rapidjson.cmake +@@ -0,0 +1,22 @@ ++# Copyright (C) 2018-2023 Intel Corporation ++# SPDX-License-Identifier: Apache-2.0 ++# ++ ++find_package(RapidJSON QUIET) ++ ++if(NOT TARGET rapidjson) ++ # sometimes RapidJSONConfig.cmake defines only RAPIDJSON_INCLUDE_DIRS ++ add_library(rapidjson INTERFACE) ++ ++ if(RapidJSON_FOUND) ++ if(TARGET RapidJSON) ++ target_link_libraries(rapidjson INTERFACE RapidJSON) ++ elseif(DEFINED RAPIDJSON_INCLUDE_DIRS) ++ target_include_directories(rapidjson INTERFACE $) ++ else() ++ message(FATAL_ERROR "RapidJSON does not define RAPIDJSON_INCLUDE_DIRS nor RapidJSON / rapidjson targets") ++ endif() ++ else() ++ target_include_directories(rapidjson INTERFACE $) ++ endif() ++endif() +diff --git a/src/plugins/template/backend/CMakeLists.txt b/src/plugins/template/backend/CMakeLists.txt +index 7530dd1688..a451fea900 100644 +--- a/src/plugins/template/backend/CMakeLists.txt ++++ b/src/plugins/template/backend/CMakeLists.txt +@@ -52,4 +52,4 @@ openvino_developer_export_targets(COMPONENT core TARGETS interpreter_backend) + + # install + +-ov_install_static_lib(interpreter_backend template) ++ov_install_static_lib(interpreter_backend ${OV_CPACK_COMP_CORE}) +diff --git a/src/plugins/template/src/CMakeLists.txt b/src/plugins/template/src/CMakeLists.txt +index 2409bb10e0..f382f90d11 100644 +--- a/src/plugins/template/src/CMakeLists.txt ++++ b/src/plugins/template/src/CMakeLists.txt +@@ -28,7 +28,7 @@ target_include_directories(${TARGET_NAME} PRIVATE + "${CMAKE_CURRENT_SOURCE_DIR}" + "${TEMPLATE_PLUGIN_SOURCE_DIR}/include") + +-# link common Inference Engine libraries ++# link common OpenVINO Runtime libraries + target_link_libraries(${TARGET_NAME} PRIVATE + openvino::interpreter_backend + openvino::reference) +@@ -42,4 +42,4 @@ endif() + # [cmake:plugin] + + install(TARGETS ${TARGET_NAME} +- LIBRARY DESTINATION tests COMPONENT tests EXCLUDE_FROM_ALL) ++ LIBRARY DESTINATION tests COMPONENT tests EXCLUDE_FROM_ALL) +diff --git a/thirdparty/ocl/CMakeLists.txt b/thirdparty/ocl/CMakeLists.txt +index f31519467f..0ebe3fd6d1 100644 +--- a/thirdparty/ocl/CMakeLists.txt ++++ b/thirdparty/ocl/CMakeLists.txt +@@ -58,4 +58,4 @@ set(opencl_root_hints "${OpenCL_INCLUDE_DIR}" PARENT_SCOPE) + + # installation + +-ov_install_static_lib(OpenCL gpu) ++ov_install_static_lib(OpenCL ${OV_CPACK_COMP_CORE}) diff --git a/recipes/openvino/all/patches/2023.1.0/0004-fixed-gpu-plugin-with-clang.patch b/recipes/openvino/all/patches/2023.1.0/0004-fixed-gpu-plugin-with-clang.patch new file mode 100644 index 00000000000000..7659f10e22501b --- /dev/null +++ b/recipes/openvino/all/patches/2023.1.0/0004-fixed-gpu-plugin-with-clang.patch @@ -0,0 +1,2836 @@ +diff --git a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/binary_buffer.hpp b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/binary_buffer.hpp +index 9386e52400..05972d7a97 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/binary_buffer.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/binary_buffer.hpp +@@ -104,12 +104,10 @@ public: + + #define ASSIGN_TYPE_NAME(cls_name) \ + namespace cldnn { \ +- const std::string cls_name::type_for_serialization = #cls_name; \ + } + + #define BIND_BINARY_BUFFER_WITH_TYPE(cls_name) \ + namespace cldnn { \ +- const std::string cls_name::type_for_serialization = #cls_name; \ + BIND_TO_BUFFER(BinaryOutputBuffer, cls_name) \ + BIND_TO_BUFFER(BinaryInputBuffer, cls_name) \ + } +diff --git a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/bind.hpp b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/bind.hpp +index 85ed3fa803..e2a673f0ba 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/bind.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/bind.hpp +@@ -11,9 +11,12 @@ + #include "buffer.hpp" + #include "static_instance.hpp" + +-#define DECLARE_OBJECT_TYPE_SERIALIZATION \ +- static const std::string type_for_serialization; \ +- std::string get_type() const override { return type_for_serialization; } ++#define DECLARE_OBJECT_TYPE_SERIALIZATION(cls_name) \ ++ static const std::string& get_type_info_s() { \ ++ static const std::string type_name = #cls_name; \ ++ return type_name; \ ++ } \ ++ const std::string& get_type_info() const override { return get_type_info_s(); } + + #define BIND_TO_BUFFER(buffer, type) \ + template <> \ +@@ -101,7 +104,7 @@ public: + + private: + buffer_binder() { +- saver_storage::instance().set_save_function({T::type_for_serialization, save}); ++ saver_storage::instance().set_save_function({T::get_type_info_s(), save}); + } + + buffer_binder(const buffer_binder&) = delete; +@@ -130,7 +133,7 @@ public: + private: + buffer_binder() { + def::instance().set_load_function( +- {T::type_for_serialization, [](BufferType& buffer, std::unique_ptr>& result_ptr) { ++ {T::get_type_info_s(), [](BufferType& buffer, std::unique_ptr>& result_ptr) { + std::unique_ptr derived_ptr = std::unique_ptr(new T()); + derived_ptr->load(buffer); + result_ptr.reset(derived_ptr.release()); +@@ -153,7 +156,7 @@ public: + private: + buffer_binder() { + dif::instance().set_load_function( +- {T::type_for_serialization, [](BufferType& buffer, std::unique_ptr>& result_ptr, engine& engine) { ++ {T::get_type_info_s(), [](BufferType& buffer, std::unique_ptr>& result_ptr, engine& engine) { + std::unique_ptr derived_ptr = std::unique_ptr(new T(engine)); + derived_ptr->load(buffer); + result_ptr.reset(derived_ptr.release()); +diff --git a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/polymorphic_serializer.hpp b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/polymorphic_serializer.hpp +index 023045b9bd..1792f5489c 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/polymorphic_serializer.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/graph/serialization/polymorphic_serializer.hpp +@@ -18,7 +18,7 @@ template + class Serializer, typename std::enable_if, BufferType>::value>::type> { + public: + static void save(BufferType& buffer, const std::unique_ptr& ptr) { +- const auto& type = ptr->get_type(); ++ const auto& type = ptr->get_type_info(); + buffer << type; + const auto save_func = saver_storage::instance().get_save_function(type); + save_func(buffer, ptr.get()); +@@ -51,7 +51,7 @@ template + class Serializer, typename std::enable_if, BufferType>::value>::type> { + public: + static void save(BufferType& buffer, const std::shared_ptr& ptr) { +- const std::string& type = ptr->get_type(); ++ const std::string& type = ptr->get_type_info(); + buffer << type; + if (type.compare("NONE") != 0) { + const auto save_func = saver_storage::instance().get_save_function(type); +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/activation.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/activation.hpp +index 09a3f96a98..771f1b9191 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/activation.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/activation.hpp +@@ -82,8 +82,6 @@ struct activation : public primitive_base { + activation_function(activation_func::none), + additional_params({0.f, 0.f}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs Relu primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/adaptive_pooling.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/adaptive_pooling.hpp +index e54b055312..f80d7b3c62 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/adaptive_pooling.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/adaptive_pooling.hpp +@@ -20,8 +20,6 @@ struct adaptive_pooling : public primitive_base { + mode{adaptive_pooling_mode::average}, + output_size{} {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs AdaptiveAvgPooling primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/arg_max_min.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/arg_max_min.hpp +index 16ca38e746..418f8df90d 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/arg_max_min.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/arg_max_min.hpp +@@ -27,8 +27,6 @@ struct arg_max_min : public primitive_base { + values_first(false), + stable(false) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs arg_max_min primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/assign.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/assign.hpp +index 1c4021a77d..4134614504 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/assign.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/assign.hpp +@@ -17,8 +17,6 @@ struct assign : public primitive_base { + + assign() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs Assign primitive. + /// @param id This primitive id + /// @param inputs Input parameters ids +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/batch_to_space.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/batch_to_space.hpp +index fab49940fb..246853a5f3 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/batch_to_space.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/batch_to_space.hpp +@@ -42,8 +42,6 @@ struct batch_to_space : public primitive_base { + + batch_to_space() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs batch_to_space primitive. + /// @param id This primitive id. + /// @param input Input data primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/binary_convolution.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/binary_convolution.hpp +index 268f78e73a..5ba028bda7 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/binary_convolution.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/binary_convolution.hpp +@@ -16,8 +16,6 @@ struct binary_convolution : public primitive_base { + + binary_convolution() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs binary_convolution primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/border.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/border.hpp +index def9b956ff..81ad97a196 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/border.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/border.hpp +@@ -26,8 +26,6 @@ struct border : public primitive_base { + + border() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief whether the input is const or not + enum PAD_NON_CONST_INPUT { + BEGIN = 0x1, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/broadcast.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/broadcast.hpp +index 3b210c7b94..d3b17919a4 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/broadcast.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/broadcast.hpp +@@ -56,8 +56,6 @@ struct broadcast : public primitive_base { + + broadcast() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs broadcast primitive / layer. + /// + /// @param id An identifier of new primitive. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/bucketize.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/bucketize.hpp +index 11e7f8752e..dd5b8f3d93 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/bucketize.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/bucketize.hpp +@@ -13,8 +13,6 @@ struct bucketize : primitive_base { + + bucketize() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs bucketize primitive. + /// @param id This primitive id. + /// @param inputs Input primitives ids. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/concatenation.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/concatenation.hpp +index 184dbf9ceb..5f187c7422 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/concatenation.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/concatenation.hpp +@@ -35,8 +35,6 @@ struct concatenation : public primitive_base { + + concatenation() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @li Constructs concatenation primitive. + /// @param id This primitive id. + /// @param input Vector of input primitives ids. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/convert_color.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/convert_color.hpp +index f1cd6e1934..f71e73310a 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/convert_color.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/convert_color.hpp +@@ -14,8 +14,6 @@ struct convert_color : public primitive_base { + + convert_color() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + enum color_format : uint32_t { + RGB, ///< RGB color format + BGR, ///< BGR color format, default in OpenVINO +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/convolution.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/convolution.hpp +index 01291816b1..0a15e6a146 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/convolution.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/convolution.hpp +@@ -15,8 +15,6 @@ struct convolution : public primitive_base { + + convolution() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs convolution primitive + /// @param id This primitive id. + /// @param input Input primitive id. +@@ -313,8 +311,6 @@ struct deformable_interp : public primitive_base { + + deformable_interp() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + deformable_interp(const primitive_id& id, + const std::vector& inputs, + uint32_t groups, +@@ -430,8 +426,6 @@ struct deformable_conv : public primitive_base { + + deformable_conv() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + deformable_conv(const primitive_id& id, + const input_info& input, + const std::vector& weights, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/crop.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/crop.hpp +index 5c944b75d1..b8935695b2 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/crop.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/crop.hpp +@@ -46,8 +46,6 @@ struct crop : public primitive_base { + + crop() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs crop primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_greedy_decoder.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_greedy_decoder.hpp +index 9c911243d5..2cf19ca58c 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_greedy_decoder.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_greedy_decoder.hpp +@@ -13,8 +13,6 @@ struct ctc_greedy_decoder : public primitive_base { + + ctc_greedy_decoder() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs ctc_greedy_decoder primitive. + /// @param id This primitive id. + /// @param input Input primitive id (input, sequence_indicators, second_output(optional)). +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_loss.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_loss.hpp +index 0d63027cf7..55cc934195 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_loss.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/ctc_loss.hpp +@@ -15,8 +15,6 @@ struct ctc_loss : primitive_base { + + ctc_loss() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs ctc_loss primitive. + /// @param id This primitive id. + /// @param inputs Input primitives ids. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/cum_sum.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/cum_sum.hpp +index 4a038714d7..11bd653d4c 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/cum_sum.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/cum_sum.hpp +@@ -6,15 +6,11 @@ + #include "primitive.hpp" + + namespace cldnn { +- +- + struct cum_sum : public primitive_base { + CLDNN_DECLARE_PRIMITIVE(cum_sum) + + cum_sum() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs cum_sum primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/custom_gpu_primitive.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/custom_gpu_primitive.hpp +index a938e2c0ff..62dafc4ce4 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/custom_gpu_primitive.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/custom_gpu_primitive.hpp +@@ -18,8 +18,6 @@ struct custom_gpu_primitive : public primitive_base { + + custom_gpu_primitive() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Custom primitive kernel argument type + enum arg_type { + arg_input, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/data.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/data.hpp +index 8a89005102..177fbf99b7 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/data.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/data.hpp +@@ -17,8 +17,6 @@ struct data : public primitive_base { + + data() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs data primitive. + /// @param id This primitive id. + /// @param mem @ref memory object which contains data. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/deconvolution.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/deconvolution.hpp +index b149539bb6..5c507a2360 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/deconvolution.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/deconvolution.hpp +@@ -20,8 +20,6 @@ struct deconvolution : public primitive_base { + + deconvolution() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs deconvolution primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/depth_to_space.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/depth_to_space.hpp +index 6d1c430d91..577be63765 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/depth_to_space.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/depth_to_space.hpp +@@ -22,8 +22,6 @@ struct depth_to_space : public primitive_base { + + depth_to_space() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs depth_to_space primitive. + /// @param id This primitive id. + /// @param input Input dictionary primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/detection_output.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/detection_output.hpp +index 7437106428..3c39a83963 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/detection_output.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/detection_output.hpp +@@ -42,8 +42,6 @@ struct detection_output : public primitive_base { + clip_after_nms(false), + objectness_score(0.0f) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs detection output primitive. + /// @param id This primitive id. + /// @param inputs Inputs for primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/dft.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/dft.hpp +index 45042ad94b..329794e088 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/dft.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/dft.hpp +@@ -29,8 +29,6 @@ struct dft : public primitive_base { + + dft() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs DFT primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/eltwise.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/eltwise.hpp +index de1e4138c3..b4b9e8932d 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/eltwise.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/eltwise.hpp +@@ -71,8 +71,6 @@ struct eltwise : public primitive_base { + + eltwise() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs eltwise primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/embedding_bag.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/embedding_bag.hpp +index c749c3b5e2..29b3259b50 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/embedding_bag.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/embedding_bag.hpp +@@ -14,8 +14,6 @@ struct embedding_bag : public primitive_base { + + embedding_bag() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Select type of embedding_bag operation + enum embedding_bag_type { + packed_sum, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_detection_output.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_detection_output.hpp +index cb47ec86f5..f87b161e48 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_detection_output.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_detection_output.hpp +@@ -16,8 +16,6 @@ struct experimental_detectron_detection_output : public primitive_base { +@@ -17,8 +15,6 @@ struct experimental_detectron_prior_grid_generator + + experimental_detectron_prior_grid_generator() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + experimental_detectron_prior_grid_generator(const primitive_id& id, + const std::vector& inputs, + bool flatten, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_roi_feature_extractor.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_roi_feature_extractor.hpp +index a9b27fd16f..3a1e229171 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_roi_feature_extractor.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/experimental_detectron_roi_feature_extractor.hpp +@@ -14,8 +14,6 @@ struct experimental_detectron_roi_feature_extractor : public primitive_base { +@@ -19,8 +17,6 @@ struct experimental_detectron_topk_rois : public primitive_base { + + extract_image_patches() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs select primitive. + /// @param id This primitive id. + /// @param input Input primitive id containing input 4-D tensor. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/eye.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/eye.hpp +index 4137aaa2ec..9cc2c9e083 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/eye.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/eye.hpp +@@ -14,8 +14,6 @@ struct eye : public primitive_base { + + eye() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs eye primitive. + /// @param id This primitive id. + /// @param inputs List of primitive ids. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/fully_connected.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/fully_connected.hpp +index d71afd76f1..ba05829539 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/fully_connected.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/fully_connected.hpp +@@ -35,8 +35,6 @@ struct fully_connected : public primitive_base { + + fully_connected() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs fully connected layer. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather.hpp +index f754d47667..2a7dad7fe4 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather.hpp +@@ -16,8 +16,6 @@ struct gather : public primitive_base { + + gather() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gather primitive. + /// @param id This primitive id. + /// @param dict Input dictionary primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_elements.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_elements.hpp +index 0287a76877..455a40a9ea 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_elements.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_elements.hpp +@@ -14,8 +14,6 @@ struct gather_elements : public primitive_base { + + gather_elements() : primitive_base("", {}), output_format({}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gather_elements primitive. + /// @param id This primitive id. + /// @param data Input data primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_nd.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_nd.hpp +index 932fe0b167..a2c26b0545 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_nd.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_nd.hpp +@@ -14,8 +14,6 @@ struct gather_nd : public primitive_base { + + gather_nd() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gather_nd primitive. + /// + /// @param id This primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_tree.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_tree.hpp +index 5ec3339801..082b4113ab 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_tree.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/gather_tree.hpp +@@ -15,8 +15,6 @@ struct gather_tree : public primitive_base { + + gather_tree() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gather tree primitive / layer. + /// + /// @param id An identifier of new primitive. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/gemm.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/gemm.hpp +index 104b92571c..cef11bbb0b 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/gemm.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/gemm.hpp +@@ -27,8 +27,6 @@ struct gemm : public primitive_base { + + gemm() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gemm layer. + /// @brief Primitive id containing first matrix + /// @brief Primitive id containing second matrix +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/generate_proposals.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/generate_proposals.hpp +index ab57e07d0d..3524c104fd 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/generate_proposals.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/generate_proposals.hpp +@@ -15,8 +15,6 @@ struct generate_proposals + + generate_proposals() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs generate_proposals primitive + /// @param id This primitive id + /// @param input_im_info image size info +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/grid_sample.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/grid_sample.hpp +index 700140c9d2..20e308e4aa 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/grid_sample.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/grid_sample.hpp +@@ -10,8 +10,6 @@ + #include "primitive.hpp" + + namespace cldnn { +- +- + using GridSampleOp = ov::op::v9::GridSample; + + /// @brief GridSample-9 primitive. +@@ -20,8 +18,6 @@ struct grid_sample : primitive_base { + + grid_sample() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs grid_sample primitive. + /// @param id This primitive id. + /// @param inputs Input primitives ids. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/grn.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/grn.hpp +index cda1ebe160..3b629bad91 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/grn.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/grn.hpp +@@ -13,8 +13,6 @@ struct grn : public primitive_base { + + grn() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs grn primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/input_layout.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/input_layout.hpp +index c13e89a3a5..5cbba06ca4 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/input_layout.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/input_layout.hpp +@@ -20,8 +20,6 @@ struct input_layout : public primitive_base { + + input_layout() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs input layout primitive. + /// @param id This primitive id. + /// @param layout Defines layout for the data will be passed to network. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/loop.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/loop.hpp +index 49af132862..c27a88e197 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/loop.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/loop.hpp +@@ -55,8 +55,6 @@ struct loop : public primitive_base { + loop() : primitive_base("", {}), + max_iteration(0) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + struct io_primitive_map { + /// @brief Constructs a mapping from external input/output primitive to input/output primitive in body topology + /// +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/lrn.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/lrn.hpp +index 28bcf69147..f8cc1672e7 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/lrn.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/lrn.hpp +@@ -6,8 +6,6 @@ + #include "primitive.hpp" + + namespace cldnn { +- +- + typedef enum { /*:int32_t*/ + lrn_norm_region_across_channel, + lrn_norm_region_within_channel +@@ -29,8 +27,6 @@ struct lrn : public primitive_base { + + lrn() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs LRN primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm.hpp +index 7c601158d8..71922acd21 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm.hpp +@@ -53,8 +53,6 @@ struct lstm : public primitive_base { + + lstm() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs lstm layer. + /// @param id This primitive id. + /// @param input Vector of primitive id. +@@ -230,8 +228,6 @@ struct lstm_gemm : public primitive_base { + lstm_gemm() : primitive_base("", {}), + direction(0) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs lstm layer. + /// @param id This primitive id. + /// @param input input primitive id. +@@ -319,8 +315,6 @@ struct lstm_elt : public primitive_base { + + lstm_elt() : primitive_base("", {}), clip(0), input_forget(0), offset_order(lstm_weights_order::iofz), direction(0) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + using vec_activation = std::vector; + using vec_activation_param = std::vector; + +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic.hpp +index fd7e7c4a26..d459754ebc 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic.hpp +@@ -22,8 +22,6 @@ struct lstm_dynamic : public primitive_base { + + lstm_dynamic() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs lstm_dynamic layer. + /// @param id This primitive id. + /// @param input Primitive id of input layer. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_input.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_input.hpp +index bf0ddb2d43..6a8e90d9a4 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_input.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_input.hpp +@@ -22,8 +22,6 @@ struct lstm_dynamic_input : public primitive_base { + + lstm_dynamic_input() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs lstm_dynamic layer. + /// @param id This primitive id. + /// @param input Primitive id of input layer. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_timeloop.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_timeloop.hpp +index e5b5ea7661..ef184707f9 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_timeloop.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/lstm_dynamic_timeloop.hpp +@@ -23,8 +23,6 @@ struct lstm_dynamic_timeloop + + lstm_dynamic_timeloop() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs lstm_dynamic layer. + /// @param id This primitive id. + /// @param input Primitive id of input layer. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/matrix_nms.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/matrix_nms.hpp +index 72c95cae70..d4efea1d59 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/matrix_nms.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/matrix_nms.hpp +@@ -16,8 +16,6 @@ struct matrix_nms : public primitive_base { + + matrix_nms() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + enum decay_function { gaussian, linear }; + + enum sort_result_type { +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/multiclass_nms.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/multiclass_nms.hpp +index 5218488f1b..92ea0d371b 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/multiclass_nms.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/multiclass_nms.hpp +@@ -18,8 +18,6 @@ struct multiclass_nms : public primitive_base { + + multiclass_nms() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + enum class sort_result_type : int32_t { + classid, // sort selected boxes by class id (ascending) in each batch element + score, // sort selected boxes by score (descending) in each batch element +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/mutable_data.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/mutable_data.hpp +index 54c46bf785..105711b58d 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/mutable_data.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/mutable_data.hpp +@@ -18,8 +18,6 @@ struct mutable_data : public primitive_base { + + mutable_data() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Enum type to specify function for data filling. + enum filler_type { no_fill, zero, one, xavier }; + +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/mvn.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/mvn.hpp +index 72daa005b6..72e5cd67d9 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/mvn.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/mvn.hpp +@@ -14,8 +14,6 @@ struct mvn : public primitive_base { + + mvn() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs mvn primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/non_max_suppression.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/non_max_suppression.hpp +index b7aafffb55..b9614cd472 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/non_max_suppression.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/non_max_suppression.hpp +@@ -22,8 +22,6 @@ struct non_max_suppression : public primitive_base { + center_point_box(false), + sort_result_descending(false) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Creates non max suppression primitive. + /// @param id This primitive id. + /// @param boxes_positions Id of primitive with bounding boxes. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/non_zero.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/non_zero.hpp +index d243058bad..0fa4b35ff7 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/non_zero.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/non_zero.hpp +@@ -13,8 +13,6 @@ struct count_nonzero : public primitive_base { + + count_nonzero() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs count_nonzero primitive. + /// @param id This primitive id. + /// @param data Input data primitive id. +@@ -33,8 +31,6 @@ struct gather_nonzero : public primitive_base { + + gather_nonzero() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs gather_nonzero primitive. + /// @param id This primitive id. + /// @param data Input data primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/normalize.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/normalize.hpp +index b17c659d76..0f25272bce 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/normalize.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/normalize.hpp +@@ -29,8 +29,6 @@ struct normalize : public primitive_base { + + normalize() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs normalize primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/one_hot.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/one_hot.hpp +index 3a2958a0fb..b94e069fc2 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/one_hot.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/one_hot.hpp +@@ -35,8 +35,6 @@ struct one_hot : public primitive_base { + + one_hot() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs one-hot primitive layer. + /// @param id An identifier of new primitive. + /// @param input An identifier of primitive which is an input for newly created one-hot primitive. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/permute.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/permute.hpp +index 587427e6a8..91bc12df87 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/permute.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/permute.hpp +@@ -21,8 +21,6 @@ struct permute : public primitive_base { + + permute() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs permute primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/pooling.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/pooling.hpp +index 0db15d2278..df49ba46a9 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/pooling.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/pooling.hpp +@@ -34,8 +34,6 @@ struct pooling : public primitive_base { + + pooling() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs pooling primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/primitive.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/primitive.hpp +index f68aa5f6c3..0bbf589b0d 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/primitive.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/primitive.hpp +@@ -203,7 +203,7 @@ public: + + size_t num_outputs; + +- virtual std::string get_type() const { return "NONE"; } ++ virtual const std::string& get_type_info() const = 0; + virtual void save(BinaryOutputBuffer& ob) const { + ob << type_string(); + ob << id; +@@ -313,6 +313,7 @@ struct primitive_info { + } + + #define CLDNN_DECLARE_PRIMITIVE(PType) \ ++ DECLARE_OBJECT_TYPE_SERIALIZATION(PType) \ + CLDNN_DEFINE_TYPE_ID(PType) \ + CLDNN_DEFINE_TYPE_STRING(PType) + +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/prior_box.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/prior_box.hpp +index 959e6b14f0..3f78605f49 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/prior_box.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/prior_box.hpp +@@ -23,8 +23,6 @@ struct prior_box : public primitive_base { + + prior_box() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + using PriorBoxV0Op = ov::op::v0::PriorBox; + using PriorBoxV8Op = ov::op::v8::PriorBox; + using PriorBoxClusteredOp = ov::op::v0::PriorBoxClustered; +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/proposal.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/proposal.hpp +index 1278d4ff6f..a1e6768276 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/proposal.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/proposal.hpp +@@ -10,8 +10,6 @@ + #include "intel_gpu/graph/serialization/vector_serializer.hpp" + + namespace cldnn { +- +- + #define CLDNN_ROI_VECTOR_SIZE 5 + + struct proposal : public primitive_base { +@@ -37,8 +35,6 @@ struct proposal : public primitive_base { + shift_anchors(false), + normalize(false) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + proposal(const primitive_id& id, + const input_info& cls_scores, + const input_info& bbox_pred, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/pyramid_roi_align.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/pyramid_roi_align.hpp +index 6d9842227a..123faf83f2 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/pyramid_roi_align.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/pyramid_roi_align.hpp +@@ -26,8 +26,6 @@ struct pyramid_roi_align : public primitive_base { + + pyramid_roi_align() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @param id This primitive id. + /// @param rois Input RoI boxes as tuple [x1, y1, x2, y2] describing two opposite corners of the region. + /// @param P2 First level of the image pyramid. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/quantize.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/quantize.hpp +index bb5de80742..a2bb5ae3cf 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/quantize.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/quantize.hpp +@@ -38,8 +38,6 @@ struct quantize : public primitive_base { + + quantize() : primitive_base("", {}), levels(0) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief levels The number of quantization levels. + int levels; + +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/random_uniform.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/random_uniform.hpp +index 02c86cb80d..598d8171b5 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/random_uniform.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/random_uniform.hpp +@@ -10,8 +10,6 @@ + + namespace cldnn { + +- +- + /// @brief RandomUniform-8 primitive + /// @details + struct random_uniform : public primitive_base { +@@ -22,8 +20,6 @@ struct random_uniform : public primitive_base { + op_seed(0), + output_shape{} {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /** + * Construct Random Uniform privitive. + * @param id primitive id +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/range.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/range.hpp +index 005d74a6c8..3d68fd2815 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/range.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/range.hpp +@@ -12,8 +12,6 @@ struct range: public primitive_base { + + range() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs range primitive. + /// @param id This primitive id. + /// @param inputs Input primitive id vector. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/read_value.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/read_value.hpp +index 9523b416cd..095c845d07 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/read_value.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/read_value.hpp +@@ -17,8 +17,6 @@ struct read_value : public primitive_base { + + read_value() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs ReadValue primitive. + /// @param id This primitive id + /// @param inputs Input parameters ids +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reduce.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reduce.hpp +index 7af0ad1dd9..c1f687e48a 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reduce.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reduce.hpp +@@ -44,8 +44,6 @@ struct reduce : public primitive_base { + + reduce() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs reduce primitive + /// @param id This primitive id + /// @param input Input primitive id +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/region_yolo.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/region_yolo.hpp +index 7efddc3fb4..d9040d1dc2 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/region_yolo.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/region_yolo.hpp +@@ -16,8 +16,6 @@ struct region_yolo : public primitive_base { + + region_yolo() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs region_yolo primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reorder.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reorder.hpp +index 1c59eebe65..7b2ada5d77 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reorder.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reorder.hpp +@@ -69,8 +69,6 @@ struct reorder : public primitive_base { + output_format(format::any), + mean_mode(reorder_mean_mode::subtract) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief reorder memory types + enum class memory_type { + buffer, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reorg_yolo.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reorg_yolo.hpp +index b5d76e9353..96eff0012e 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reorg_yolo.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reorg_yolo.hpp +@@ -16,8 +16,6 @@ struct reorg_yolo : public primitive_base { + + reorg_yolo() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs region_yolo primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/resample.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/resample.hpp +index b95ce3c5e0..59f58c986b 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/resample.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/resample.hpp +@@ -17,8 +17,6 @@ struct resample : public primitive_base { + + resample() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + using InterpolateOp = ov::op::util::InterpolateBase; + + /// @brief Constructs Resample primitive. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reshape.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reshape.hpp +index 0f9869a2f7..00e8d9a093 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reshape.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reshape.hpp +@@ -17,8 +17,6 @@ struct reshape : public primitive_base { + + reshape() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + enum reshape_mode : uint32_t { + base, + squeeze, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse.hpp +index 0ecb598550..70864a9f1e 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse.hpp +@@ -15,8 +15,6 @@ struct reverse : public primitive_base { + + reverse() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs reverse primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse_sequence.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse_sequence.hpp +index 8058bd3a45..714e0f4a49 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse_sequence.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/reverse_sequence.hpp +@@ -15,8 +15,6 @@ struct reverse_sequence : public primitive_base { + + reverse_sequence() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs reverse_sequence primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_align.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_align.hpp +index 14b031d87f..0813c960f0 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_align.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_align.hpp +@@ -15,8 +15,6 @@ struct roi_align : public primitive_base { + + roi_align() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Pooling mode for the @ref roi_align + enum PoolingMode { max, avg }; + +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_pooling.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_pooling.hpp +index ef7fc25664..2dd22e52d3 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_pooling.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/roi_pooling.hpp +@@ -8,8 +8,6 @@ + #include + + namespace cldnn { +- +- + struct roi_pooling : public primitive_base { + CLDNN_DECLARE_PRIMITIVE(roi_pooling) + +@@ -27,8 +25,6 @@ struct roi_pooling : public primitive_base { + spatial_bins_x(1), + spatial_bins_y(1) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + roi_pooling(const primitive_id& id, + const input_info& input_data, + const input_info& input_rois, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/roll.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/roll.hpp +index 3ae8fc634e..3db154bf47 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/roll.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/roll.hpp +@@ -15,8 +15,6 @@ struct roll : primitive_base { + + roll() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs roll primitive. + /// @param id This primitive id. + /// @param input Input primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_elements_update.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_elements_update.hpp +index fa2cd6e07b..4b823a165c 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_elements_update.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_elements_update.hpp +@@ -14,8 +14,6 @@ struct scatter_elements_update : public primitive_base + + scatter_elements_update() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs scatter_elements_update primitive. + /// @param id This primitive id. + /// @param dict Input data primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_nd_update.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_nd_update.hpp +index f21691c3c7..1cc8746e9e 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_nd_update.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_nd_update.hpp +@@ -14,8 +14,6 @@ struct scatter_nd_update : public primitive_base { + + scatter_nd_update() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + /// @brief Constructs scatter_nd_update primitive. + /// @param id This primitive id. + /// @param dict Input data primitive id. +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_update.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_update.hpp +index 9563fe079e..17c09a8d8e 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_update.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/scatter_update.hpp +@@ -14,8 +14,6 @@ struct scatter_update : public primitive_base { + + scatter_update() : primitive_base("", {}) {} + +- DECLARE_OBJECT_TYPE_SERIALIZATION +- + enum scatter_update_axis { + along_b, + along_f, +diff --git a/src/plugins/intel_gpu/include/intel_gpu/primitives/select.hpp b/src/plugins/intel_gpu/include/intel_gpu/primitives/select.hpp +index 310c5ff2cb..0959fa2709 100644 +--- a/src/plugins/intel_gpu/include/intel_gpu/primitives/select.hpp ++++ b/src/plugins/intel_gpu/include/intel_gpu/primitives/select.hpp +@@ -22,8 +22,6 @@ struct select : public primitive_base { + using kernel_selector_t = kernel_selector::select_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::select_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/shape_of.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/shape_of.cpp +index 02efeee00f..b2efd25f67 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/shape_of.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/shape_of.cpp +@@ -17,7 +17,7 @@ struct shape_of_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::shape_of_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::shape_of_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/shuffle_channels.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/shuffle_channels.cpp +index 57ac2437f4..e40b1b99b8 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/shuffle_channels.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/shuffle_channels.cpp +@@ -17,7 +17,7 @@ struct shuffle_channels_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::shuffle_channels_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::shuffle_channels_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/slice.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/slice.cpp +index 07ea912d06..d7f7f9ba74 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/slice.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/slice.cpp +@@ -72,7 +72,7 @@ struct slice_impl : typed_primitive_impl_ocl { + kInputsNum + }; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::slice_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/softmax.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/softmax.cpp +index b4029ac3b3..6ad4e1d087 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/softmax.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/softmax.cpp +@@ -39,7 +39,7 @@ struct softmax_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::softmax_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::softmax_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_batch.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_batch.cpp +index 141116e04b..c9db851175 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_batch.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_batch.cpp +@@ -16,7 +16,7 @@ struct space_to_batch_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::space_to_batch_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::space_to_batch_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_depth.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_depth.cpp +index ec87100f89..5b72a5572c 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_depth.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/space_to_depth.cpp +@@ -16,7 +16,7 @@ struct space_to_depth_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::space_to_depth_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::space_to_depth_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/strided_slice.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/strided_slice.cpp +index f06ae1b72d..e64498f73f 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/strided_slice.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/strided_slice.cpp +@@ -46,7 +46,7 @@ struct strided_slice_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::strided_slice_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::strided_slice_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/tile.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/tile.cpp +index 16d2dd91cb..bc95a18f54 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/tile.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/tile.cpp +@@ -17,7 +17,7 @@ struct tile_impl : typed_primitive_impl_ocl { + using kernel_selector_t = kernel_selector::tile_kernel_selector; + using kernel_params_t = std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::tile_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/ocl/unique.cpp b/src/plugins/intel_gpu/src/graph/impls/ocl/unique.cpp +index 7018ae66a2..604619c30b 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/ocl/unique.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/ocl/unique.cpp +@@ -17,7 +17,7 @@ struct unique_count_impl : typed_primitive_impl_ocl { + using kernel_params_t = + std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::unique_count_impl) + + std::unique_ptr clone() const override { + return make_unique(*this); +@@ -88,7 +88,7 @@ struct unique_gather_impl : typed_primitive_impl_ocl { + using kernel_params_t = + std::pair; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::ocl::unique_gather) + + std::unique_ptr clone() const override { + return make_unique(*this); +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/concatenation_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/concatenation_onednn.cpp +index ed5565504f..325afd5f3c 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/concatenation_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/concatenation_onednn.cpp +@@ -21,7 +21,7 @@ struct concatenation_onednn : typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::concatenation_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/convolution_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/convolution_onednn.cpp +index 1a27f3ae29..f1d1ab0a6c 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/convolution_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/convolution_onednn.cpp +@@ -26,7 +26,7 @@ struct convolution_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::convolution_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/deconvolution_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/deconvolution_onednn.cpp +index 439b74feff..1702738598 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/deconvolution_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/deconvolution_onednn.cpp +@@ -22,7 +22,7 @@ struct deconvolution_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::deconvolution_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/fully_connected_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/fully_connected_onednn.cpp +index 4aacb2ebd5..8ee6979dec 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/fully_connected_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/fully_connected_onednn.cpp +@@ -19,7 +19,7 @@ struct fully_connected_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::fully_connected_onednn) + + private: + static std::vector reshape_to_2d(const ov::PartialShape& shape, int64_t feature) { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/gemm_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/gemm_onednn.cpp +index 7410f79961..87e7decb34 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/gemm_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/gemm_onednn.cpp +@@ -19,7 +19,7 @@ struct gemm_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::gemm_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/pooling_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/pooling_onednn.cpp +index 52f0edc797..1dc686331b 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/pooling_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/pooling_onednn.cpp +@@ -19,7 +19,7 @@ struct pooling_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::pooling_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/reduction_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/reduction_onednn.cpp +index 581c37c015..635d465fc5 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/reduction_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/reduction_onednn.cpp +@@ -41,7 +41,7 @@ struct reduction_onednn : typed_primitive_onednn_impl { + using parent = typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::reduction_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/impls/onednn/reorder_onednn.cpp b/src/plugins/intel_gpu/src/graph/impls/onednn/reorder_onednn.cpp +index 284dd8b166..433e043067 100644 +--- a/src/plugins/intel_gpu/src/graph/impls/onednn/reorder_onednn.cpp ++++ b/src/plugins/intel_gpu/src/graph/impls/onednn/reorder_onednn.cpp +@@ -19,7 +19,7 @@ struct reorder_onednn : typed_primitive_onednn_impl; + using parent::parent; + +- DECLARE_OBJECT_TYPE_SERIALIZATION ++ DECLARE_OBJECT_TYPE_SERIALIZATION(cldnn::onednn::reorder_onednn) + + protected: + std::unique_ptr clone() const override { +diff --git a/src/plugins/intel_gpu/src/graph/include/primitive_inst.h b/src/plugins/intel_gpu/src/graph/include/primitive_inst.h +index 3244ad20b4..454c92ac97 100644 +--- a/src/plugins/intel_gpu/src/graph/include/primitive_inst.h ++++ b/src/plugins/intel_gpu/src/graph/include/primitive_inst.h +@@ -54,7 +54,7 @@ struct primitive_impl { + + virtual std::vector get_internal_buffer_layouts() const = 0; + virtual void set_node_params(const program_node&) {} +- virtual std::string get_type() const = 0; ++ virtual const std::string& get_type_info() const = 0; + virtual void set_arguments(primitive_inst& instance) = 0; + virtual void set_arguments(primitive_inst& instance, kernel_arguments_data& args) = 0; + virtual kernel_arguments_data get_arguments(const primitive_inst& instance) const = 0; From 870938039c7e0a39ea56b0dc4e5eb8fa9a0d7b32 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 9 Oct 2023 21:11:52 +0300 Subject: [PATCH 1021/1140] (#20361) platform.exceptions: bump versions --- recipes/platform.exceptions/all/conandata.yml | 12 ++++++------ recipes/platform.exceptions/config.yml | 4 ++-- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/recipes/platform.exceptions/all/conandata.yml b/recipes/platform.exceptions/all/conandata.yml index 9459ce54f6fdc4..cf054ea78bcab7 100644 --- a/recipes/platform.exceptions/all/conandata.yml +++ b/recipes/platform.exceptions/all/conandata.yml @@ -2,9 +2,9 @@ sources: "0.5.0": url: "https://github.com/linksplatform/Exceptions/archive/csharp_0.5.0.tar.gz" sha256: "5fbdd49adf7840431a581d0bfe61a5d247398a1fe622101b3985714d11d411f4" - "0.3.0": - url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/cpp_0.3.0.zip" - sha256: "08506f334098e8c9106ff357efd7f68b83a3c1f4dc03b6b97b6229b14737d0ce" - "0.2.0": - url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/0.4.0_0.2.0.zip" - sha256: "9e4513da667e41f0bbe776123747ac63958972edb00eaee300c495ae3b39eb9b" + "0.3.2": + url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/cpp_0.3.2.tar.gz" + sha256: "f2d3af59fd66ef47f93557a2b64d0c8e7a1a0cd033f0e3ae2f09153f81117f71" + "0.2.1": + url: "https://github.com/linksplatform/Exceptions/archive/refs/tags/cpp_0.2.1.tar.gz" + sha256: "9e31f6162cd226a4be3eb0e263b8c1c00e5de1fb41575d4d19207e9ff55f2687" diff --git a/recipes/platform.exceptions/config.yml b/recipes/platform.exceptions/config.yml index 918726b6e05300..7914985fc71b1f 100644 --- a/recipes/platform.exceptions/config.yml +++ b/recipes/platform.exceptions/config.yml @@ -1,7 +1,7 @@ versions: "0.5.0": folder: all - "0.3.0": + "0.3.2": folder: all - "0.2.0": + "0.2.1": folder: all From 4b291f4854fd0556529e32fdc4861b3e486a87af Mon Sep 17 00:00:00 2001 From: Frank Schoenmann Date: Mon, 9 Oct 2023 21:11:56 +0200 Subject: [PATCH 1022/1140] (#20390) mbits-mstch: Compile for GCC 10 --- recipes/mbits-mstch/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/mbits-mstch/all/conanfile.py b/recipes/mbits-mstch/all/conanfile.py index a06f83e964b39b..a8cfe1d7dd5a71 100644 --- a/recipes/mbits-mstch/all/conanfile.py +++ b/recipes/mbits-mstch/all/conanfile.py @@ -33,7 +33,7 @@ def _min_cppstd(self): @property def _compilers_minimum_version(self): return { - "gcc": "11", + "gcc": "10", "clang": "12", "msvc": "192", "apple-clang": "11.0.3", From 3402358391a577d535ff1ce30bec60af4a58043c Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 22:11:27 +0200 Subject: [PATCH 1023/1140] (#20396) cpr/all: bump libcurl, remove old versions * cpr: bump libcurl, remove old versions * remove old patches & versions --- recipes/cpr/all/conandata.yml | 51 ------------------- recipes/cpr/all/conanfile.py | 2 +- .../patches/002-1.4.0-create-install.patch | 14 ----- .../patches/003-1.4.0-curl-use-target.patch | 15 ------ .../patches/004-1.4.0-curl-global-scope.patch | 14 ----- .../005-1.5.2-fix-curl-components.patch | 21 -------- .../005-1.6.2-fix-curl-components.patch | 36 ------------- .../005-1.9.0-fix-curl-components.patch | 21 -------- recipes/cpr/config.yml | 12 ----- 9 files changed, 1 insertion(+), 185 deletions(-) delete mode 100644 recipes/cpr/all/patches/002-1.4.0-create-install.patch delete mode 100644 recipes/cpr/all/patches/003-1.4.0-curl-use-target.patch delete mode 100644 recipes/cpr/all/patches/004-1.4.0-curl-global-scope.patch delete mode 100644 recipes/cpr/all/patches/005-1.5.2-fix-curl-components.patch delete mode 100644 recipes/cpr/all/patches/005-1.6.2-fix-curl-components.patch delete mode 100644 recipes/cpr/all/patches/005-1.9.0-fix-curl-components.patch diff --git a/recipes/cpr/all/conandata.yml b/recipes/cpr/all/conandata.yml index 21c7cc656ba73b..fcfeb5ab978f4d 100644 --- a/recipes/cpr/all/conandata.yml +++ b/recipes/cpr/all/conandata.yml @@ -2,46 +2,20 @@ sources: "1.10.4": url: "https://github.com/libcpr/cpr/archive/refs/tags/1.10.3.tar.gz" sha256: "7b9d3504ffdaf7ce3189f1b91d135888776b6a1b26ea1bf2c3c4986b8a5af06f" - "1.10.1": - url: "https://github.com/libcpr/cpr/archive/refs/tags/1.10.1.tar.gz" - sha256: "dc22ab9d34e6013e024e2c4a64e665b126573c0f125f0e02e6a7291cb7e04c4b" - "1.10.0": - url: "https://github.com/libcpr/cpr/archive/refs/tags/1.10.0.tar.gz" - sha256: "d669c028bd63a1c8827c32b348ecc85e46747bb33be3b00ce59b77717b91aee8" "1.9.3": url: "https://github.com/libcpr/cpr/archive/refs/tags/1.9.3.tar.gz" sha256: "df53e7213d80fdc24583528521f7d3349099f5bb4ed05ab05206091a678cc53c" - "1.9.0": - url: "https://github.com/libcpr/cpr/archive/refs/tags/1.9.0.tar.gz" - sha256: "67023cde8979e8371f5ee7d6e586d6d0761af4a3a3a3be6270256353c9bf411f" "1.8.1": url: "https://github.com/libcpr/cpr/archive/refs/tags/1.8.1.tar.gz" sha256: "9155ec36fcafe8cf8d61c98cde8dc6bd27c146740002069bf990855eecb2b95f" "1.7.2": url: "https://github.com/libcpr/cpr/archive/refs/tags/1.7.2.tar.gz" sha256: "aa38a414fe2ffc49af13a08b6ab34df825fdd2e7a1213d032d835a779e14176f" - "1.6.2": - url: "https://github.com/libcpr/cpr/archive/1.6.2.tar.gz" - sha256: "c45f9c55797380c6ba44060f0c73713fbd7989eeb1147aedb8723aa14f3afaa3" - "1.5.2": - url: "https://github.com/libcpr/cpr/archive/1.5.2.tar.gz" - sha256: "6fc9102dd63b549912d7af1ec95ee41ece1a2fe27f759864306b07f6fcf24fe1" - "1.4.0": - url: "https://github.com/libcpr/cpr/archive/1.4.0.tar.gz" - sha256: "13baffba95445e02291684e31906b04df41d8c6a3020a1a55253047c6756a004" patches: "1.10.4": - patch_file: "patches/008-1.10.0-remove-warning-flags.patch" patch_description: "disable warning flags and warning as error" patch_type: "portability" - "1.10.1": - - patch_file: "patches/008-1.10.0-remove-warning-flags.patch" - patch_description: "disable warning flags and warning as error" - patch_type: "portability" - "1.10.0": - - patch_file: "patches/008-1.10.0-remove-warning-flags.patch" - patch_description: "disable warning flags and warning as error" - patch_type: "portability" "1.9.3": - patch_file: "patches/005-1.9.3-fix-curl-components.patch" patch_description: "use cci package" @@ -49,13 +23,6 @@ patches: - patch_file: "patches/008-1.9.3-remove-warning-flags.patch" patch_description: "disable warning flags and warning as error" patch_type: "portability" - "1.9.0": - - patch_file: "patches/005-1.9.0-fix-curl-components.patch" - patch_description: "use cci package" - patch_type: "conan" - - patch_file: "patches/008-1.8.1-remove-warning-flags.patch" - patch_description: "disable warning flags and warning as error" - patch_type: "portability" "1.8.1": - patch_file: "patches/005-1.8.1-fix-curl-components.patch" patch_description: "use cci package" @@ -76,21 +43,3 @@ patches: - patch_file: "patches/008-1.7.2-remove-warning-flags.patch" patch_description: "disable warning flags and warning as error" patch_type: "portability" - "1.6.2": - - patch_file: "patches/005-1.6.2-fix-curl-components.patch" - patch_description: "use cci package" - patch_type: "conan" - "1.5.2": - - patch_file: "patches/005-1.5.2-fix-curl-components.patch" - patch_description: "use cci package" - patch_type: "conan" - "1.4.0": - - patch_file: "patches/002-1.4.0-create-install.patch" - patch_description: "add install definition" - patch_type: "conan" - - patch_file: "patches/003-1.4.0-curl-use-target.patch" - patch_description: "link curl library as target name" - patch_type: "portability" - - patch_file: "patches/004-1.4.0-curl-global-scope.patch" - patch_description: "use cci package" - patch_type: "conan" diff --git a/recipes/cpr/all/conanfile.py b/recipes/cpr/all/conanfile.py index 811d7ddeeebd74..dc8630b8a6eddf 100644 --- a/recipes/cpr/all/conanfile.py +++ b/recipes/cpr/all/conanfile.py @@ -123,7 +123,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("libcurl/8.0.1", transitive_headers=True, transitive_libs=True) + self.requires("libcurl/8.2.1", transitive_headers=True, transitive_libs=True) # FIXME: This is a very dirty hack. # with_ssl == _AUTO_SSL, cpr needs the openssl header to compile. But Conan recipe does not know which SSL library to use. # because cpr's CMakeLists.txt automatically detects SSL libraries with CPR_ENABLE_SSL == ON. diff --git a/recipes/cpr/all/patches/002-1.4.0-create-install.patch b/recipes/cpr/all/patches/002-1.4.0-create-install.patch deleted file mode 100644 index 42f7f34ab13fe9..00000000000000 --- a/recipes/cpr/all/patches/002-1.4.0-create-install.patch +++ /dev/null @@ -1,14 +0,0 @@ ---- cpr/CMakeLists.txt -+++ cpr/CMakeLists.txt -@@ -46,3 +46,11 @@ - message(STATUS "Using CURL_LIBRARIES: ${CURL_LIBRARIES}.") - target_link_libraries(${CPR_LIBRARIES} - ${CURL_LIBRARIES}) -+ -+include(GNUInstallDirs) -+install(TARGETS cpr -+ RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}" -+ ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}" -+ LIBRARY DESTINATION "${CMAKE_INSTALL_LIBDIR}" -+) -+install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/cpr" DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}") diff --git a/recipes/cpr/all/patches/003-1.4.0-curl-use-target.patch b/recipes/cpr/all/patches/003-1.4.0-curl-use-target.patch deleted file mode 100644 index 61ba93886b977b..00000000000000 --- a/recipes/cpr/all/patches/003-1.4.0-curl-use-target.patch +++ /dev/null @@ -1,15 +0,0 @@ -diff --git a/cpr/CMakeLists.txt b/cpr/CMakeLists.txt -diff --git a/a/cpr/CMakeLists.txt b/b/cpr/CMakeLists.txt -index c4f9b5b..7e2279d 100644 ---- a/a/cpr/CMakeLists.txt -+++ b/b/cpr/CMakeLists.txt -@@ -44,8 +44,7 @@ add_library(${CPR_LIBRARIES} - "${CPR_INCLUDE_DIRS}/cpr/unix_socket.h") - - message(STATUS "Using CURL_LIBRARIES: ${CURL_LIBRARIES}.") --target_link_libraries(${CPR_LIBRARIES} -- ${CURL_LIBRARIES}) -+target_link_libraries(cpr PUBLIC CURL::libcurl) - - include(GNUInstallDirs) - install(TARGETS cpr diff --git a/recipes/cpr/all/patches/004-1.4.0-curl-global-scope.patch b/recipes/cpr/all/patches/004-1.4.0-curl-global-scope.patch deleted file mode 100644 index b4fe11b69536a6..00000000000000 --- a/recipes/cpr/all/patches/004-1.4.0-curl-global-scope.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff --git a/a/CMakeLists.txt b/b/CMakeLists.txt -index aa9f35d..86500d9 100644 ---- a/a/CMakeLists.txt -+++ b/b/CMakeLists.txt -@@ -86,7 +86,8 @@ if(BUILD_CPR_TESTS) - enable_testing() - endif() - --add_subdirectory(opt) -+# add_subdirectory(opt) # With Conan, none of this is used -+find_package(CURL) - add_subdirectory(cpr) - if(BUILD_CPR_TESTS) - add_subdirectory(test) diff --git a/recipes/cpr/all/patches/005-1.5.2-fix-curl-components.patch b/recipes/cpr/all/patches/005-1.5.2-fix-curl-components.patch deleted file mode 100644 index fda5c28eafd1d8..00000000000000 --- a/recipes/cpr/all/patches/005-1.5.2-fix-curl-components.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index c065227d..c1c19155 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -55,15 +55,7 @@ include(cmake/code_coverage.cmake) - - # Curl configuration - if(USE_SYSTEM_CURL) -- find_package(CURL COMPONENTS PROTOCOLS HTTP HTTPS FEATURES SSL) -- if (CURL_FOUND) -- set(SSL_ENABLED ON CACHE INTERNAL "" FORCE) -- else() -- find_package(CURL COMPONENTS PROTOCOLS HTTP) -- if(CURL_FOUND) -- set(SSL_ENABLED OFF CACHE INTERNAL "" FORCE) -- endif() -- endif() -+ find_package(CURL) - endif() - if(NOT USE_SYSTEM_CURL OR NOT CURL_FOUND) - message(STATUS "Not using system Curl, using built-in curl project instead.") diff --git a/recipes/cpr/all/patches/005-1.6.2-fix-curl-components.patch b/recipes/cpr/all/patches/005-1.6.2-fix-curl-components.patch deleted file mode 100644 index 04da489547e84b..00000000000000 --- a/recipes/cpr/all/patches/005-1.6.2-fix-curl-components.patch +++ /dev/null @@ -1,36 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -120,29 +120,11 @@ endif() - - # Curl configuration - if(CPR_FORCE_USE_SYSTEM_CURL) -- if(CPR_ENABLE_SSL) -- find_package(CURL COMPONENTS HTTP HTTPS SSL) -- if(CURL_FOUND) -- message(STATUS "Curl ${CURL_VERSION_STRING} found on this system.") -- # To be able to load certificates under Windows when using OpenSSL: -- if(CMAKE_USE_OPENSSL AND WIN32 AND (NOT (CURL_VERSION_STRING VERSION_GREATER_EQUAL "7.71.0"))) -- message(FATAL_ERROR "Your system curl version (${CURL_VERSION_STRING}) is too old to support OpenSSL on Windows which requires curl >= 7.71.0. Update your curl version, use WinSSL, disable SSL or use the build in version of curl.") -- endif() -- else() -- find_package(CURL COMPONENTS HTTP) -- if(CURL_FOUND) -- message(FATAL_ERROR "Curl found on this system but WITHOUT HTTPS/SSL support. Either disable SSL by setting CPR_ENABLE_SSL to OFF or use the build in version of curl by setting CPR_FORCE_USE_SYSTEM_CURL to OFF.") -- else() -- message(FATAL_ERROR "Curl not found on this system. To use the build in version set CPR_FORCE_USE_SYSTEM_CURL to OFF.") -- endif() -- endif() -+ find_package(CURL REQUIRED) -+ if(CURL_FOUND) -+ message(STATUS "Curl found on this system.") - else() -- find_package(CURL COMPONENTS HTTP) -- if(CURL_FOUND) -- message(STATUS "Curl found on this system.") -- else() -- message(FATAL_ERROR "Curl not found on this system. To use the build in version set CPR_FORCE_USE_SYSTEM_CURL to OFF.") -- endif() -+ message(FATAL_ERROR "Curl not found on this system. To use the build in version set CPR_FORCE_USE_SYSTEM_CURL to OFF.") - endif() - else() - message(STATUS "Configuring build in curl...") diff --git a/recipes/cpr/all/patches/005-1.9.0-fix-curl-components.patch b/recipes/cpr/all/patches/005-1.9.0-fix-curl-components.patch deleted file mode 100644 index f20781e9ef90e8..00000000000000 --- a/recipes/cpr/all/patches/005-1.9.0-fix-curl-components.patch +++ /dev/null @@ -1,21 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index cb7c5f0..c6c19e4 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -162,6 +162,8 @@ endif() - - # Curl configuration - if(CPR_FORCE_USE_SYSTEM_CURL) -+ find_package(CURL REQUIRED) -+ if(0) - if(CPR_ENABLE_SSL) - find_package(CURL COMPONENTS HTTP HTTPS) - if(CURL_FOUND) -@@ -186,6 +188,7 @@ if(CPR_FORCE_USE_SYSTEM_CURL) - message(FATAL_ERROR "Curl not found on this system. To use the build in version set CPR_FORCE_USE_SYSTEM_CURL to OFF.") - endif() - endif() -+ endif() - else() - message(STATUS "Configuring build in curl...") - diff --git a/recipes/cpr/config.yml b/recipes/cpr/config.yml index 66e2467c8e5312..235f485f4ee68a 100644 --- a/recipes/cpr/config.yml +++ b/recipes/cpr/config.yml @@ -1,21 +1,9 @@ versions: "1.10.4": folder: all - "1.10.1": - folder: all - "1.10.0": - folder: all "1.9.3": folder: all - "1.9.0": - folder: all "1.8.1": folder: all "1.7.2": folder: all - "1.6.2": - folder: all - "1.5.2": - folder: all - "1.4.0": - folder: all From ecf654beabbed9a32182ecfa4c8f740f03dbe789 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Mon, 9 Oct 2023 23:13:00 +0200 Subject: [PATCH 1024/1140] (#20401) librdkafka/all: bump deps, remove old versions --- recipes/librdkafka/all/conandata.yml | 70 ------------------- recipes/librdkafka/all/conanfile.py | 8 +-- .../0001-Change-library-names-1-5-2.patch | 31 -------- .../0001-Change-library-names-1-7-0.patch | 35 ---------- ...y-targets-and-result-variables-1-5-2.patch | 23 ------ ...y-targets-and-result-variables-1-6-0.patch | 23 ------ ...y-targets-and-result-variables-1-6-1.patch | 23 ------ ...y-targets-and-result-variables-1-7-0.patch | 37 ---------- recipes/librdkafka/config.yml | 14 ---- 9 files changed, 3 insertions(+), 261 deletions(-) delete mode 100644 recipes/librdkafka/all/patches/0001-Change-library-names-1-5-2.patch delete mode 100644 recipes/librdkafka/all/patches/0001-Change-library-names-1-7-0.patch delete mode 100644 recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-5-2.patch delete mode 100644 recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-0.patch delete mode 100644 recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-1.patch delete mode 100644 recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-7-0.patch diff --git a/recipes/librdkafka/all/conandata.yml b/recipes/librdkafka/all/conandata.yml index 81ba31cdfb277b..a03c452b453607 100644 --- a/recipes/librdkafka/all/conandata.yml +++ b/recipes/librdkafka/all/conandata.yml @@ -8,27 +8,6 @@ sources: "1.9.2": url: "https://github.com/edenhill/librdkafka/archive/v1.9.2.tar.gz" sha256: "3fba157a9f80a0889c982acdd44608be8a46142270a389008b22d921be1198ad" - "1.9.1": - url: "https://github.com/edenhill/librdkafka/archive/v1.9.1.tar.gz" - sha256: "3a54cf375218977b7af4716ed9738378e37fe400a6c5ddb9d622354ca31fdc79" - "1.8.2": - url: "https://github.com/edenhill/librdkafka/archive/v1.8.2.tar.gz" - sha256: "6a747d293a7a4613bd2897e28e8791476fbe1ae7361f2530a876e0fd483482a6" - "1.8.0": - url: "https://github.com/edenhill/librdkafka/archive/v1.8.0.tar.gz" - sha256: "93b12f554fa1c8393ce49ab52812a5f63e264d9af6a50fd6e6c318c481838b7f" - "1.7.0": - url: "https://github.com/edenhill/librdkafka/archive/v1.7.0.tar.gz" - sha256: "c71b8c5ff419da80c31bb8d3036a408c87ad523e0c7588e7660ee5f3c8973057" - "1.6.1": - url: "https://github.com/edenhill/librdkafka/archive/v1.6.1.tar.gz" - sha256: "689028b5fdfdce026f396fc2f3bfe9e38947210d9bd22be28c3159cc8c41b57e" - "1.6.0": - url: "https://github.com/edenhill/librdkafka/archive/v1.6.0.tar.gz" - sha256: "3130cbd391ef683dc9acf9f83fe82ff93b8730a1a34d0518e93c250929be9f6b" - "1.5.3": - url: "https://github.com/edenhill/librdkafka/archive/v1.5.3.tar.gz" - sha256: "2105ca01fef5beca10c9f010bc50342b15d5ce6b73b2489b012e6d09a008b7bf" patches: "2.2.0": - patch_file: patches/0001-Change-library-names-1-9-1.patch @@ -51,52 +30,3 @@ patches: - patch_file: patches/0002-Change-library-targets-and-result-variables-1-9-1.patch patch_description: "refer conan package names" patch_type: "conan" - "1.9.1": - - patch_file: patches/0001-Change-library-names-1-9-1.patch - patch_description: "find_package conan packages" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-9-1.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.8.2": - - patch_file: patches/0001-Change-library-names-1-7-0.patch - patch_description: "find_package conan packages" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-7-0.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.8.0": - - patch_file: patches/0001-Change-library-names-1-7-0.patch - patch_description: "find_package conan packages" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-7-0.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.7.0": - - patch_file: patches/0001-Change-library-names-1-7-0.patch - patch_description: "find_package conan packages" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-7-0.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.6.1": - - patch_file: patches/0001-Change-library-names-1-5-2.patch - patch_description: "find_package conan packages, link sasl libraries" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-6-1.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.6.0": - - patch_file: patches/0001-Change-library-names-1-5-2.patch - patch_description: "find_package conan packages, link sasl libraries" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-6-0.patch - patch_description: "refer conan package names" - patch_type: "conan" - "1.5.3": - - patch_file: patches/0001-Change-library-names-1-5-2.patch - patch_description: "find_package conan packages, link sasl libraries" - patch_type: "conan" - - patch_file: patches/0002-Change-library-targets-and-result-variables-1-5-2.patch - patch_description: "refer conan package names" - patch_type: "conan" diff --git a/recipes/librdkafka/all/conanfile.py b/recipes/librdkafka/all/conanfile.py index a26ad90b5400db..a3942c7cffef19 100644 --- a/recipes/librdkafka/all/conanfile.py +++ b/recipes/librdkafka/all/conanfile.py @@ -52,8 +52,6 @@ def export_sources(self): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC - if Version(self.version) < "1.9.0": - del self.options.curl def configure(self): if self.options.shared: @@ -72,12 +70,12 @@ def requirements(self): self.requires("openssl/[>=1.1 <4]") if self._depends_on_cyrus_sasl: self.requires("cyrus-sasl/2.1.27") - if self.options.get_safe("curl", False): - self.requires("libcurl/8.0.1") + if self.options.curl: + self.requires("libcurl/8.2.1") def build_requirements(self): if self._depends_on_cyrus_sasl: - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) diff --git a/recipes/librdkafka/all/patches/0001-Change-library-names-1-5-2.patch b/recipes/librdkafka/all/patches/0001-Change-library-names-1-5-2.patch deleted file mode 100644 index 63c4787d111f34..00000000000000 --- a/recipes/librdkafka/all/patches/0001-Change-library-names-1-5-2.patch +++ /dev/null @@ -1,31 +0,0 @@ ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -54,7 +54,7 @@ endif() - # } - - # ZSTD { --find_package(ZSTD QUIET) -+find_package(zstd QUIET CONFIG) - if(ZSTD_FOUND) - set(with_zstd_default ON) - else() -@@ -133,6 +133,9 @@ else() - endif() - option(WITH_SASL "With SASL" ${with_sasl_default}) - if(WITH_SASL) -+ if(SASL_FOUND) -+ link_directories(${SASL_LIBRARY_DIRS}) -+ endif() - if(WITH_SSL) - set(WITH_SASL_SCRAM ON) - set(WITH_SASL_OAUTHBEARER ON) -@@ -149,7 +152,8 @@ endif() - option(ENABLE_LZ4_EXT "Enable external LZ4 library support" ON) - set(WITH_LZ4_EXT OFF) - if(ENABLE_LZ4_EXT) -- find_package(LZ4) -+ find_package(lz4 REQUIRED CONFIG) -+ set(LZ4_FOUND ON) - if(LZ4_FOUND) - set(WITH_LZ4_EXT ON) - list(APPEND BUILT_WITH "LZ4_EXT") diff --git a/recipes/librdkafka/all/patches/0001-Change-library-names-1-7-0.patch b/recipes/librdkafka/all/patches/0001-Change-library-names-1-7-0.patch deleted file mode 100644 index 966ba38247ca44..00000000000000 --- a/recipes/librdkafka/all/patches/0001-Change-library-names-1-7-0.patch +++ /dev/null @@ -1,35 +0,0 @@ -From 07bd30c67a532be3c1f31aa383a1061c832a034d Mon Sep 17 00:00:00 2001 -From: Alejandro Colomar -Date: Sun, 30 May 2021 11:02:57 +0200 -Subject: [PATCH] Change library names - ---- - CMakeLists.txt | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/CMakeLists.txt b/CMakeLists.txt -index d1129bce..14d9e7f0 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -54,7 +54,7 @@ endif() - # } - - # ZSTD { --find_package(ZSTD QUIET) -+find_package(zstd QUIET CONFIG) - if(ZSTD_FOUND) - set(with_zstd_default ON) - else() -@@ -152,7 +152,8 @@ endif() - option(ENABLE_LZ4_EXT "Enable external LZ4 library support" ON) - set(WITH_LZ4_EXT OFF) - if(ENABLE_LZ4_EXT) -- find_package(LZ4) -+ find_package(lz4 REQUIRED CONFIG) -+ set(LZ4_FOUND ON) - if(LZ4_FOUND) - set(WITH_LZ4_EXT ON) - list(APPEND BUILT_WITH "LZ4_EXT") --- -2.32.0.rc0 - diff --git a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-5-2.patch b/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-5-2.patch deleted file mode 100644 index 2c6f62c68a4789..00000000000000 --- a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-5-2.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -209,9 +209,7 @@ if(WITH_ZLIB) - endif() - - if(WITH_ZSTD) -- target_link_libraries(rdkafka PUBLIC ${ZSTD_LIBRARY}) -- target_include_directories(rdkafka PUBLIC ${ZSTD_INCLUDE_DIR}) -- message(STATUS "Found ZSTD: ${ZSTD_LIBRARY}") -+ target_link_libraries(rdkafka PUBLIC $,zstd::libzstd_shared,zstd::libzstd_static>) - endif() - - if(WITH_SSL) -@@ -246,8 +244,7 @@ if(WITH_LIBDL) - endif() - - if(WITH_LZ4_EXT) -- target_include_directories(rdkafka PUBLIC ${LZ4_INCLUDE_DIRS}) -- target_link_libraries(rdkafka PUBLIC LZ4::LZ4) -+ target_link_libraries(rdkafka PUBLIC lz4::lz4) - endif() - - # Set up path to these sources for other sub-projects (tests, examples) diff --git a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-0.patch b/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-0.patch deleted file mode 100644 index 71155e468786f8..00000000000000 --- a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-0.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -212,9 +212,7 @@ if(WITH_ZLIB) - endif() - - if(WITH_ZSTD) -- target_link_libraries(rdkafka PUBLIC ${ZSTD_LIBRARY}) -- target_include_directories(rdkafka PUBLIC ${ZSTD_INCLUDE_DIR}) -- message(STATUS "Found ZSTD: ${ZSTD_LIBRARY}") -+ target_link_libraries(rdkafka PUBLIC $,zstd::libzstd_shared,zstd::libzstd_static>) - endif() - - if(WITH_SSL) -@@ -249,8 +247,7 @@ if(WITH_LIBDL) - endif() - - if(WITH_LZ4_EXT) -- target_include_directories(rdkafka PUBLIC ${LZ4_INCLUDE_DIRS}) -- target_link_libraries(rdkafka PUBLIC LZ4::LZ4) -+ target_link_libraries(rdkafka PUBLIC lz4::lz4) - endif() - - # Set up path to these sources for other sub-projects (tests, examples) diff --git a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-1.patch b/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-1.patch deleted file mode 100644 index 0a478997b23736..00000000000000 --- a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-6-1.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -212,9 +212,7 @@ if(WITH_ZLIB) - endif() - - if(WITH_ZSTD) -- target_link_libraries(rdkafka PUBLIC ${ZSTD_LIBRARY}) -- target_include_directories(rdkafka PUBLIC ${ZSTD_INCLUDE_DIR}) -- message(STATUS "Found ZSTD: ${ZSTD_LIBRARY}") -+ target_link_libraries(rdkafka PUBLIC $,zstd::libzstd_shared,zstd::libzstd_static>) - endif() - - if(WITH_SSL) -@@ -253,8 +251,7 @@ if(WITH_LIBDL) - endif() - - if(WITH_LZ4_EXT) -- target_include_directories(rdkafka PUBLIC ${LZ4_INCLUDE_DIRS}) -- target_link_libraries(rdkafka PUBLIC LZ4::LZ4) -+ target_link_libraries(rdkafka PUBLIC lz4::lz4) - endif() - - # Set up path to these sources for other sub-projects (tests, examples) diff --git a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-7-0.patch b/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-7-0.patch deleted file mode 100644 index 377bc8af8e4378..00000000000000 --- a/recipes/librdkafka/all/patches/0002-Change-library-targets-and-result-variables-1-7-0.patch +++ /dev/null @@ -1,37 +0,0 @@ -From 994ad21e1a136e11d1dc5870d991b034e41e6a4c Mon Sep 17 00:00:00 2001 -From: Alejandro Colomar -Date: Sun, 30 May 2021 11:08:36 +0200 -Subject: [PATCH] Change library targets and result variables - ---- - src/CMakeLists.txt | 7 ++----- - 1 file changed, 2 insertions(+), 5 deletions(-) - -diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt -index 6e24a238..4379c060 100644 ---- a/src/CMakeLists.txt -+++ b/src/CMakeLists.txt -@@ -198,9 +198,7 @@ if(WITH_ZLIB) - endif() - - if(WITH_ZSTD) -- target_link_libraries(rdkafka PRIVATE ${ZSTD_LIBRARY}) -- target_include_directories(rdkafka PRIVATE ${ZSTD_INCLUDE_DIR}) -- message(STATUS "Found ZSTD: ${ZSTD_LIBRARY}") -+ target_link_libraries(rdkafka PRIVATE $,zstd::libzstd_shared,zstd::libzstd_static>) - endif() - - if(WITH_SSL) -@@ -239,8 +237,7 @@ if(WITH_LIBDL) - endif() - - if(WITH_LZ4_EXT) -- target_include_directories(rdkafka PRIVATE ${LZ4_INCLUDE_DIRS}) -- target_link_libraries(rdkafka PUBLIC LZ4::LZ4) -+ target_link_libraries(rdkafka PUBLIC lz4::lz4) - endif() - - if(WIN32) --- -2.32.0.rc0 - diff --git a/recipes/librdkafka/config.yml b/recipes/librdkafka/config.yml index 6e80eff9af8852..6b21185a713a77 100644 --- a/recipes/librdkafka/config.yml +++ b/recipes/librdkafka/config.yml @@ -5,17 +5,3 @@ versions: folder: all "1.9.2": folder: all - "1.9.1": - folder: all - "1.8.2": - folder: all - "1.8.0": - folder: all - "1.7.0": - folder: all - "1.6.1": - folder: all - "1.6.0": - folder: all - "1.5.3": - folder: all From c6fdc3389f4522e85169ed953357242bbccaf4cb Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 00:17:14 +0200 Subject: [PATCH 1025/1140] (#20410) libucl/all: bump deps, use version range for OpenSSL --- recipes/libucl/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libucl/all/conanfile.py b/recipes/libucl/all/conanfile.py index 99131d4e958635..5962211b5f08ac 100644 --- a/recipes/libucl/all/conanfile.py +++ b/recipes/libucl/all/conanfile.py @@ -46,11 +46,11 @@ def layout(self): def requirements(self): if self.options.enable_url_include: - self.requires("libcurl/7.86.0") + self.requires("libcurl/8.2.1") if self.options.enable_url_sign: - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") if self.options.with_lua == "lua": - self.requires("lua/5.4.4") + self.requires("lua/5.4.6") elif self.options.with_lua == "luajit": self.requires("luajit/2.0.5") From c9615cd3ca3bfb7eaf3b50862afed8202e591d37 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 01:12:44 +0200 Subject: [PATCH 1026/1140] (#20435) hazelcast-cpp-client/all: use OpenSSL range, bump boost, remove old versions * hazelcast-cpp-client/all: use OpenSSL range, bump boost, remove old versions * revert boost update, add missing system library --- .../hazelcast-cpp-client/all/conandata.yml | 16 ---- recipes/hazelcast-cpp-client/all/conanfile.py | 4 +- .../all/patches/gcc_4.9_5_fix.patch | 79 ------------------- recipes/hazelcast-cpp-client/config.yml | 8 -- 4 files changed, 2 insertions(+), 105 deletions(-) delete mode 100644 recipes/hazelcast-cpp-client/all/patches/gcc_4.9_5_fix.patch diff --git a/recipes/hazelcast-cpp-client/all/conandata.yml b/recipes/hazelcast-cpp-client/all/conandata.yml index b475516774d720..132cdd0f76ad63 100644 --- a/recipes/hazelcast-cpp-client/all/conandata.yml +++ b/recipes/hazelcast-cpp-client/all/conandata.yml @@ -8,27 +8,11 @@ sources: "5.1.0": url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v5.1.0.tar.gz" sha256: "de22ddf2c99079ed2385baa554a997b15ae17b039d6d108f68e25e1b3bbf76b6" - "5.0.0": - url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v5.0.0.tar.gz" - sha256: "0df7948bc6f4d219c60f51179355599938cab5b713335c2ea48d1d38be1b69dc" "4.2.0": url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v4.2.0.zip" sha256: "18aeb755a875015a2e182d4c575cc46a041bdfb699937c5174d94534517e4708" - "4.1.1": - url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v4.1.1.zip" - sha256: "ca425c97eb871400de4bd2307ddaf3c557c9c1bae50d6a0db6507d72f435830c" - "4.1.0": - url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v4.1.0.zip" - sha256: "8356bc76077fea354e83ffcd506096797137af10b292809c6b7843a8fbd084e3" - "4.0.1": - url: "https://github.com/hazelcast/hazelcast-cpp-client/archive/v4.0.1.zip" - sha256: "4b3c6a876ebca2a4dcf23a556d3c3d4da2284e4ce1d2bbdf335df7f86b03fd28" patches: "5.1.0": - patch_file: "patches/gcc_11_1_0.patch" patch_description: "Fix for GCC-111" patch_type: "portability" - "4.1.0": - - patch_file: "patches/gcc_4.9_5_fix.patch" - patch_description: "Fix for GCC-495" - patch_type: "portability" diff --git a/recipes/hazelcast-cpp-client/all/conanfile.py b/recipes/hazelcast-cpp-client/all/conanfile.py index ccfd70e209aa39..a46e46f6fda67f 100644 --- a/recipes/hazelcast-cpp-client/all/conanfile.py +++ b/recipes/hazelcast-cpp-client/all/conanfile.py @@ -46,7 +46,7 @@ def layout(self): def requirements(self): self.requires("boost/1.79.0", transitive_headers=True, transitive_libs=True) if self.options.with_openssl: - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1.1 <4]") def validate(self): if self.settings.compiler.get_safe("cppstd"): @@ -84,6 +84,6 @@ def package_info(self): self.cpp_info.libs = ["hazelcast-cpp-client"] self.cpp_info.defines = ["BOOST_THREAD_VERSION=5"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs.append("pthread") + self.cpp_info.system_libs.extend(["pthread", "m"]) if self.settings.os == "Windows": self.cpp_info.system_libs.append("ws2_32") diff --git a/recipes/hazelcast-cpp-client/all/patches/gcc_4.9_5_fix.patch b/recipes/hazelcast-cpp-client/all/patches/gcc_4.9_5_fix.patch deleted file mode 100644 index f5655c00c6f251..00000000000000 --- a/recipes/hazelcast-cpp-client/all/patches/gcc_4.9_5_fix.patch +++ /dev/null @@ -1,79 +0,0 @@ -diff --git a/hazelcast/include/hazelcast/client/spi/impl/ClientPartitionServiceImpl.h b/hazelcast/include/hazelcast/client/spi/impl/ClientPartitionServiceImpl.h -index 41b437a80..6bef9e28b 100644 ---- a/hazelcast/include/hazelcast/client/spi/impl/ClientPartitionServiceImpl.h -+++ b/hazelcast/include/hazelcast/client/spi/impl/ClientPartitionServiceImpl.h -@@ -64,10 +64,7 @@ namespace hazelcast { - void reset(); - private: - struct partition_table { -- partition_table(int32_t connectionId = 0, int32_t version = -1, -- const std::unordered_map &partitions = {}); -- -- int32_t connection_id{0}; -+ int32_t connection_id; - int32_t version; - std::unordered_map partitions; - }; -diff --git a/hazelcast/src/hazelcast/client/config.cpp b/hazelcast/src/hazelcast/client/config.cpp -index 88cad1ec5..5da63b36a 100644 ---- a/hazelcast/src/hazelcast/client/config.cpp -+++ b/hazelcast/src/hazelcast/client/config.cpp -@@ -856,7 +856,7 @@ namespace hazelcast { - return it->second; - } - -- return reliable_topic_config_map_.emplace(name, name).first->second; -+ return reliable_topic_config_map_.emplace(name, config::reliable_topic_config{name}).first->second; - } - - const config::reliable_topic_config *client_config::lookup_reliable_topic_config(const std::string &name) const { -diff --git a/hazelcast/src/hazelcast/client/discovery.cpp b/hazelcast/src/hazelcast/client/discovery.cpp -index cdc10a906..51279b446 100644 ---- a/hazelcast/src/hazelcast/client/discovery.cpp -+++ b/hazelcast/src/hazelcast/client/discovery.cpp -@@ -588,7 +588,7 @@ namespace hazelcast { - - std::unordered_map aws_client::get_addresses() { - util::Preconditions::check_ssl("aws_client::get_addresses"); -- return {}; -+ return std::unordered_map(); - } - } - } -diff --git a/hazelcast/src/hazelcast/client/spi.cpp b/hazelcast/src/hazelcast/client/spi.cpp -index ada4e665c..206aecb9e 100644 ---- a/hazelcast/src/hazelcast/client/spi.cpp -+++ b/hazelcast/src/hazelcast/client/spi.cpp -@@ -788,9 +788,10 @@ namespace hazelcast { - auto previous_list = member_list_snapshot_.load()->members; - - member_list_snapshot_.store( -- boost::shared_ptr(new member_list_snapshot{0, {}})); -+ boost::shared_ptr(new member_list_snapshot{0})); - -- return detect_membership_events(previous_list, {}); -+ return detect_membership_events(previous_list, -+ std::unordered_map>()); - } - - void ClientClusterServiceImpl::clear_member_list() { -@@ -2357,7 +2358,7 @@ namespace hazelcast { - } - #else - util::Preconditions::check_ssl("cloud_discovery::get_addresses"); -- return {}; -+ return std::unordered_map(); - #endif - } - -@@ -2388,10 +2389,6 @@ namespace hazelcast { - return address(std::move(scoped_hostname), address_holder.get_port()); - } - } -- -- ClientPartitionServiceImpl::partition_table::partition_table(int32_t connectionId, int32_t version, -- const std::unordered_map &partitions) -- : connection_id(connectionId), version(version), partitions(partitions) {} - } - } - } diff --git a/recipes/hazelcast-cpp-client/config.yml b/recipes/hazelcast-cpp-client/config.yml index 7e4b5ade252501..5dd47e8b5a4e08 100644 --- a/recipes/hazelcast-cpp-client/config.yml +++ b/recipes/hazelcast-cpp-client/config.yml @@ -5,13 +5,5 @@ versions: folder: all "5.1.0": folder: all - "5.0.0": - folder: all "4.2.0": folder: all - "4.1.1": - folder: all - "4.1.0": - folder: all - "4.0.1": - folder: all From 3d86a04873170599541cde079f24d6ec707a26b8 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 02:12:26 +0200 Subject: [PATCH 1027/1140] (#20436) cpp-jwt/all: use OpenSSL version range --- recipes/cpp-jwt/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cpp-jwt/all/conanfile.py b/recipes/cpp-jwt/all/conanfile.py index a9da0afcb17e47..71a7e1defc3e47 100644 --- a/recipes/cpp-jwt/all/conanfile.py +++ b/recipes/cpp-jwt/all/conanfile.py @@ -40,7 +40,7 @@ def layout(self): def requirements(self): self.requires("nlohmann_json/3.11.2") - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") def package_id(self): self.info.clear() From 7b75422d877c9bbadf161d035a901b2d3978d690 Mon Sep 17 00:00:00 2001 From: Andrei Malashkin Date: Tue, 10 Oct 2023 03:24:23 +0200 Subject: [PATCH 1028/1140] (#20393) bump dependencies of pkgconf --- recipes/pkgconf/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/pkgconf/all/conanfile.py b/recipes/pkgconf/all/conanfile.py index 18f5f79fa547c2..673b980405e75c 100644 --- a/recipes/pkgconf/all/conanfile.py +++ b/recipes/pkgconf/all/conanfile.py @@ -56,7 +56,7 @@ def package_id(self): del self.info.settings.compiler def build_requirements(self): - self.tool_requires("meson/1.2.1") + self.tool_requires("meson/1.2.2") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From a6be6f71adc9cfa6628bdf7c1767273e1320997a Mon Sep 17 00:00:00 2001 From: Pat Mancuso <46453397+patmantru@users.noreply.github.com> Date: Mon, 9 Oct 2023 22:10:51 -0400 Subject: [PATCH 1029/1140] (#19949) opentdf-client release 1.5.3 & 1.5.4 * Add entry for 1.5.3 * Add version 1.5.4 also --------- Co-authored-by: Carlos Zoido --- recipes/opentdf-client/all/conandata.yml | 6 ++++++ recipes/opentdf-client/config.yml | 4 ++++ 2 files changed, 10 insertions(+) diff --git a/recipes/opentdf-client/all/conandata.yml b/recipes/opentdf-client/all/conandata.yml index 74961dd8639fd5..1c8d39123b6c58 100644 --- a/recipes/opentdf-client/all/conandata.yml +++ b/recipes/opentdf-client/all/conandata.yml @@ -1,4 +1,10 @@ sources: + "1.5.4": + url: "https://github.com/opentdf/client-cpp/archive/1.5.4.tar.gz" + sha256: "7902d3f09b632ac3827f3c9c8fd1a1f7c8fdff82eeed2157385278b91a7f515f" + "1.5.3": + url: "https://github.com/opentdf/client-cpp/archive/1.5.3.tar.gz" + sha256: "43812a99b8942cd8f600f7ea284118e8af7d000705b2602991f889fe49dd3455" "1.5.0": url: "https://github.com/opentdf/client-cpp/archive/1.5.0.tar.gz" sha256: "0d6134634c0c6fde5e8457361332242259e1ef238e5254ccbed2f94549998c48" diff --git a/recipes/opentdf-client/config.yml b/recipes/opentdf-client/config.yml index 99d76618997f83..fd92109485e2dc 100644 --- a/recipes/opentdf-client/config.yml +++ b/recipes/opentdf-client/config.yml @@ -1,4 +1,8 @@ versions: + "1.5.4": + folder: all + "1.5.3": + folder: all "1.5.0": folder: all "1.4.0": From f9af80625bfc0784f021771bc8e8b04c04dcf54c Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 05:12:06 +0200 Subject: [PATCH 1030/1140] (#20437) c-client/all: bump OpenSSL --- recipes/c-client/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/c-client/all/conanfile.py b/recipes/c-client/all/conanfile.py index 45fc29f13df14b..795f25ff9b207d 100644 --- a/recipes/c-client/all/conanfile.py +++ b/recipes/c-client/all/conanfile.py @@ -43,7 +43,7 @@ def layout(self): def requirements(self): if not is_msvc(self): - self.requires("openssl/1.1.1s") + self.requires("openssl/[>=1.1 <4]") def validate(self): if self.settings.os == "Windows" and not is_msvc(self): From bcba984ab51bdcb93ca281ccba7db14fdbbcc85a Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 06:16:13 +0200 Subject: [PATCH 1031/1140] (#20439) simple-websocket-server/all: bump deps, use OpenSSL version range --- recipes/simple-websocket-server/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/simple-websocket-server/all/conanfile.py b/recipes/simple-websocket-server/all/conanfile.py index 65dfdeec4ffb5b..c4f98b42cbc3dd 100644 --- a/recipes/simple-websocket-server/all/conanfile.py +++ b/recipes/simple-websocket-server/all/conanfile.py @@ -31,7 +31,7 @@ def layout(self): basic_layout(self, src_folder="src") def requirements(self): - self.requires("openssl/1.1.1q") + self.requires("openssl/[>=1.1 <4]") # only version 2.0.2 upwards is able to build against asio 1.18.0 or higher if Version(self.version) <= "2.0.1": if self.options.use_asio_standalone: @@ -40,9 +40,9 @@ def requirements(self): self.requires("boost/1.73.0") else: if self.options.use_asio_standalone: - self.requires("asio/1.28.0") + self.requires("asio/1.28.1") else: - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") def package_id(self): self.info.clear() From bdb741fd708b7371023b343ff20390bd96407d97 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 07:11:27 +0200 Subject: [PATCH 1032/1140] (#20440) cmake: add version 3.27.7 --- recipes/cmake/binary/conandata.yml | 19 +++++++++++++++++++ recipes/cmake/config.yml | 2 ++ 2 files changed, 21 insertions(+) diff --git a/recipes/cmake/binary/conandata.yml b/recipes/cmake/binary/conandata.yml index e31c9995f80312..9c2494ef70ebb8 100644 --- a/recipes/cmake/binary/conandata.yml +++ b/recipes/cmake/binary/conandata.yml @@ -1,4 +1,23 @@ sources: + "3.27.7": + Linux: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.7-linux-aarch64.tar.gz" + sha256: "f40ec1b7d41e94efd6c79cf0b7fc45ed6068543af0fea47b0c9fbf2b1b1b3fbc" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.7-linux-x86_64.tar.gz" + sha256: "a8c92ecb139bcc7a1f92a8108179bd1d021bdb158a5ee759cba6d60010b83ae9" + Macos: + universal: + url: "https://cmake.org/files/v3.27/cmake-3.27.7-macos10.10-universal.tar.gz" + sha256: "4a366d07fbe0be7e1efcf0dbd743d09a5dc6609da79035e4036b12296ec679cf" + Windows: + armv8: + url: "https://cmake.org/files/v3.27/cmake-3.27.7-windows-arm64.zip" + sha256: "d9b19fd6830510022156621042759af2374111dc4f431b58c8828a17a68633dc" + x86_64: + url: "https://cmake.org/files/v3.27/cmake-3.27.7-windows-x86_64.zip" + sha256: "5588e50030cda3e6fa96724444d8539916ac808d78d608cda6ae6ff7c4c4c9c8" "3.27.6": Linux: armv8: diff --git a/recipes/cmake/config.yml b/recipes/cmake/config.yml index 88d76a326d17c4..7c56e333cf6664 100644 --- a/recipes/cmake/config.yml +++ b/recipes/cmake/config.yml @@ -1,4 +1,6 @@ versions: + "3.27.7": + folder: "binary" "3.27.6": folder: "binary" "3.27.5": From 700373824a9964d1d6524d1269d8cb5a0fdede10 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 09:13:21 +0200 Subject: [PATCH 1033/1140] (#20447) mosquitto/1.x: bump OpenSSL --- recipes/mosquitto/1.x/conanfile.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/recipes/mosquitto/1.x/conanfile.py b/recipes/mosquitto/1.x/conanfile.py index c9cd7eb5586db7..030bc9686278b0 100644 --- a/recipes/mosquitto/1.x/conanfile.py +++ b/recipes/mosquitto/1.x/conanfile.py @@ -45,7 +45,8 @@ def layout(self): def requirements(self): if self.options.with_tls: - self.requires("openssl/1.1.1s") + # uses deprecated functions in openssl/3.0.0 + self.requires("openssl/1.1.1w") if self.options.with_websockets: self.requires("libwebsockets/4.3.2") From 83cbcc0c864b74c7ab04106432f23fe20e4e9d17 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Tue, 10 Oct 2023 10:42:56 +0200 Subject: [PATCH 1034/1140] (#20455) xkbcommon 1.6.0 --- recipes/xkbcommon/all/conandata.yml | 3 +++ recipes/xkbcommon/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/xkbcommon/all/conandata.yml b/recipes/xkbcommon/all/conandata.yml index 1c21a5c826ba01..35dd4985bdd4e6 100644 --- a/recipes/xkbcommon/all/conandata.yml +++ b/recipes/xkbcommon/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.6.0": + url: "https://xkbcommon.org/download/libxkbcommon-1.6.0.tar.xz" + sha256: "0edc14eccdd391514458bc5f5a4b99863ed2d651e4dd761a90abf4f46ef99c2b" "1.5.0": url: "https://xkbcommon.org/download/libxkbcommon-1.5.0.tar.xz" sha256: "560f11c4bbbca10f495f3ef7d3a6aa4ca62b4f8fb0b52e7d459d18a26e46e017" diff --git a/recipes/xkbcommon/config.yml b/recipes/xkbcommon/config.yml index aa62b1dc6f7812..dc3bda303f68e9 100644 --- a/recipes/xkbcommon/config.yml +++ b/recipes/xkbcommon/config.yml @@ -1,4 +1,6 @@ versions: + "1.6.0": + folder: all "1.5.0": folder: all "1.4.1": From d27d76e493caa35fd5e8bfba3af785fd76a2e69b Mon Sep 17 00:00:00 2001 From: Ivo Hedtke Date: Tue, 10 Oct 2023 12:50:31 +0200 Subject: [PATCH 1035/1140] (#19773) [SCIP] bump version to 8.0.4 * [scip] Bump version of gmp dependency * [scip] drop dependency zlib (as this is included by soplex) * [scip] Add new version 8.0.4 * Re-add zlib but use ranges --- recipes/scip/all/conandata.yml | 3 +++ recipes/scip/all/conanfile.py | 10 +++++++--- recipes/scip/config.yml | 2 ++ 3 files changed, 12 insertions(+), 3 deletions(-) diff --git a/recipes/scip/all/conandata.yml b/recipes/scip/all/conandata.yml index 8e5c45d17a6da6..b92bf4dedd66ae 100644 --- a/recipes/scip/all/conandata.yml +++ b/recipes/scip/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "8.0.4": + url: "https://github.com/scipopt/scip/archive/refs/tags/v804.tar.gz" + sha256: "48be3f568763e3fc209803e9426389df107491371cfcce38f73dcc99ede69a51" "8.0.3": url: "https://github.com/scipopt/scip/archive/refs/tags/v803.tar.gz" sha256: "fe7636f8165a8c9298ff55ed3220d084d4ea31ba9b69d2733beec53e0e4335d6" diff --git a/recipes/scip/all/conanfile.py b/recipes/scip/all/conanfile.py index 1afdaf21774a7c..127afee9dd22bd 100644 --- a/recipes/scip/all/conanfile.py +++ b/recipes/scip/all/conanfile.py @@ -34,6 +34,10 @@ class SCIPConan(ConanFile): "with_tpi": False, "with_sym": "bliss", } + soplex_version_belonging_to_me = { + "8.0.4": "6.0.4", + "8.0.3": "6.0.3" + } @property def _min_cppstd(self): @@ -76,11 +80,11 @@ def config_options(self): def requirements(self): if self.options.with_gmp: - self.requires("gmp/6.2.1") + self.requires("gmp/6.3.0") if self.options.with_sym == "bliss": self.requires("bliss/0.77") - self.requires("soplex/6.0.3") - self.requires("zlib/1.2.13") + self.requires(f"soplex/{self.soplex_version_belonging_to_me[self.version]}") + self.requires("zlib/[>=1.2.11 <2]") def configure(self): self.options["soplex"].with_gmp = self.options.with_gmp diff --git a/recipes/scip/config.yml b/recipes/scip/config.yml index 5a689d128f61a0..131c324cfccd59 100644 --- a/recipes/scip/config.yml +++ b/recipes/scip/config.yml @@ -1,3 +1,5 @@ versions: + "8.0.4": + folder: all "8.0.3": folder: all From ba281efde64545dc25f2621bd76f0a49a7cd6ff0 Mon Sep 17 00:00:00 2001 From: seladb Date: Tue, 10 Oct 2023 05:51:10 -0700 Subject: [PATCH 1036/1140] (#20399) npcap 1.70: migrate to Conan 2.0 * Fix test * Don't check the output (it's not needed) * Remove import * Fix compatibility with Conan 1.x * Address PR comment --- recipes/npcap/all/test_package/conanfile.py | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/recipes/npcap/all/test_package/conanfile.py b/recipes/npcap/all/test_package/conanfile.py index 88fb844b5824b7..3f5bd28111ec18 100644 --- a/recipes/npcap/all/test_package/conanfile.py +++ b/recipes/npcap/all/test_package/conanfile.py @@ -2,7 +2,6 @@ from conan.tools import files from conan.tools.build import can_run from conan.tools.cmake import cmake_layout, CMake -from io import StringIO import os @@ -24,6 +23,9 @@ def configure(self): def layout(self): cmake_layout(self) + def generate(self): + files.save(self, os.path.join(self.build_folder, "libpcap_bin_path"), self.dependencies["libpcap"].cpp_info.bindirs[0]) + def build(self): cmake = CMake(self) cmake.configure() @@ -31,17 +33,13 @@ def build(self): def test(self): if can_run(self): - bindir = self.cpp.build.bindirs[0] + bindir = self.cpp.build.bindir # Use libpcap DLL as a replacement for npcap DLL # It will not provide all the functions # but it will cover enough to check that what we compiled is correct files.rm(self, "wpcap.dll", bindir) - files.copy(self, "pcap.dll", src=self.deps_cpp_info['libpcap'].bin_paths[0], dst=bindir) + libpcap_bin_path = files.load(self, os.path.join(self.build_folder, "libpcap_bin_path")) + files.copy(self, "pcap.dll", src=libpcap_bin_path, dst=os.path.join(str(self.build_path), bindir)) files.rename(self, os.path.join(bindir, "pcap.dll"), os.path.join(bindir, "wpcap.dll")) - bin_path = os.path.join(bindir, "test_package") - output = StringIO() - self.run(bin_path, env="conanrun", output=output) - test_output = output.getvalue() - print(test_output) - assert "libpcap version 1.10.1" in test_output + self.run(os.path.join(bindir, "test_package"), env="conanrun") From 0bbe08f9988dcbe9925ffc6a29bae1131c3b8229 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Tue, 10 Oct 2023 16:31:24 +0200 Subject: [PATCH 1037/1140] (#20212) ffmpeg: add versions 4.4.4, 5.0.3 & 5.1.3 --- recipes/ffmpeg/all/conandata.yml | 9 +++++++++ recipes/ffmpeg/config.yml | 6 ++++++ 2 files changed, 15 insertions(+) diff --git a/recipes/ffmpeg/all/conandata.yml b/recipes/ffmpeg/all/conandata.yml index d7a1adb10f829d..668b92e9cff670 100644 --- a/recipes/ffmpeg/all/conandata.yml +++ b/recipes/ffmpeg/all/conandata.yml @@ -2,12 +2,21 @@ sources: "6.0": url: "https://ffmpeg.org/releases/ffmpeg-6.0.tar.bz2" sha256: "47d062731c9f66a78380e35a19aac77cebceccd1c7cc309b9c82343ffc430c3d" + "5.1.3": + url: "https://ffmpeg.org/releases/ffmpeg-5.1.3.tar.bz2" + sha256: "5d5bef6a11f0c500588f9870ec965a30acc0d54d8b1e535da6554a32902d236d" "5.1": url: "https://ffmpeg.org/releases/ffmpeg-5.1.tar.bz2" sha256: "32b56fb01ce90d452958ae25e91c9564abf49ed5453c127bec23c63e530aa8fa" + "5.0.3": + url: "https://ffmpeg.org/releases/ffmpeg-5.0.3.tar.bz2" + sha256: "664e8fa8ac4cc5dce03277f022798461998d9bb8d96b9e1859b24e74511229fd" "5.0": url: "https://ffmpeg.org/releases/ffmpeg-5.0.tar.bz2" sha256: "c0130b8db2c763430fd1c6905288d61bc44ee0548ad5fcd2dfd650b88432bed9" + "4.4.4": + url: "https://ffmpeg.org/releases/ffmpeg-4.4.4.tar.bz2" + sha256: "47b1fbf70a2c090d9c0fae5910da11c6406ca92408bb69d8c935cd46c622c7ce" "4.4.3": url: "https://ffmpeg.org/releases/ffmpeg-4.4.3.tar.bz2" sha256: "33b8c2dbcd530fe1db5710415345609b4ca227bd0da1e3a9332dbb0f11fd273a" diff --git a/recipes/ffmpeg/config.yml b/recipes/ffmpeg/config.yml index 5596a0ba4cf844..5ba65ef918e0d9 100644 --- a/recipes/ffmpeg/config.yml +++ b/recipes/ffmpeg/config.yml @@ -1,10 +1,16 @@ versions: "6.0": folder: "all" + "5.1.3": + folder: "all" "5.1": folder: "all" + "5.0.3": + folder: "all" "5.0": folder: "all" + "4.4.4": + folder: "all" "4.4.3": folder: "all" "4.4": From af14545440d2dbf4701f8f25669ebc7eddba6454 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rub=C3=A9n=20Rinc=C3=B3n=20Blanco?= Date: Tue, 10 Oct 2023 18:03:50 +0200 Subject: [PATCH 1038/1140] (#20222) microprofiles: Fix license * Fix microprofiles license * Add missing import * Fix source_folder usage Signed-off-by: Uilian Ries * Add missing libm as system library Signed-off-by: Uilian Ries --------- Signed-off-by: Uilian Ries Co-authored-by: Uilian Ries --- recipes/microprofile/all/conandata.yml | 2 -- recipes/microprofile/all/conanfile.py | 13 ++++++++----- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/recipes/microprofile/all/conandata.yml b/recipes/microprofile/all/conandata.yml index 440ae9ec0e9eda..144d6e5120836b 100644 --- a/recipes/microprofile/all/conandata.yml +++ b/recipes/microprofile/all/conandata.yml @@ -2,8 +2,6 @@ sources: "3.1": - url: "https://github.com/jonasmr/microprofile/archive/refs/tags/v3.1.tar.gz" sha256: "300e1d0d21e4c13ad1de72c5309ba02fbdb3bcbbe26e5ad9ff8b798380781527" - - url: "https://raw.githubusercontent.com/jonasmr/microprofile/v4.0/LICENSE" - sha256: "7e12e5df4bae12cb21581ba157ced20e1986a0508dd10d0e8a4ab9a4cf94e85c" patches: "3.1": - patch_file: "patches/sources_fix.patch" diff --git a/recipes/microprofile/all/conanfile.py b/recipes/microprofile/all/conanfile.py index abbded97a0b174..3779e90691c298 100644 --- a/recipes/microprofile/all/conanfile.py +++ b/recipes/microprofile/all/conanfile.py @@ -5,15 +5,15 @@ from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import apply_conandata_patches, collect_libs, copy, download, export_conandata_patches, get, save +from conan.tools.files import apply_conandata_patches, collect_libs, copy, download, export_conandata_patches, get, save, load required_conan_version = ">=1.53.0" class MicroprofileConan(ConanFile): name = "microprofile" + license = "DocumentRef-README.md:LicenseRef-Unlicense" description = "Microprofile is a embeddable profiler in a few files, written in C++" - license = "Unlicense" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/jonasmr/microprofile" topics = ("profiler", "embedded", "timer") @@ -135,7 +135,6 @@ def validate(self): def source(self): get(self, **self.conan_data["sources"][self.version][0], strip_root=True) - download(self, filename="LICENSE", **self.conan_data["sources"][self.version][1]) def generate(self): tc = CMakeToolchain(self) @@ -152,8 +151,12 @@ def build(self): cmake.configure() cmake.build() + def _extract_license(self): + readme = load(self, os.path.join(self.source_folder, "README.md"),) + return readme[readme.find("# License"):] + def package(self): - copy(self, "LICENSE", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + save(self, os.path.join(self.package_folder, "licenses", "LICENSE"), self._extract_license()) cmake = CMake(self) cmake.install() @@ -203,5 +206,5 @@ def package_info(self): if self.settings.os == "Windows": self.cpp_info.system_libs = ["ws2_32"] elif self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs = ["pthread"] + self.cpp_info.system_libs = ["pthread", "m"] self.cpp_info.defines.append("MICROPROFILE_USE_CONFIG") From 50359b96acc8d7e1b671174c1115a00d9bdb8b80 Mon Sep 17 00:00:00 2001 From: James Date: Tue, 10 Oct 2023 19:04:50 +0200 Subject: [PATCH 1039/1140] (#20448) fix openssl 3.X for MinGW --- recipes/openssl/3.x.x/conanfile.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/recipes/openssl/3.x.x/conanfile.py b/recipes/openssl/3.x.x/conanfile.py index bd2227abc9b73e..35f6fcf1604db3 100644 --- a/recipes/openssl/3.x.x/conanfile.py +++ b/recipes/openssl/3.x.x/conanfile.py @@ -481,7 +481,8 @@ def _create_targets(self, cflags, cxxflags, defines, ldflags): def _run_make(self, targets=None, parallel=True, install=False): command = [self._make_program] if install: - command.append(f"DESTDIR={self.package_folder}") + package_folder = self.package_folder.replace("\\", "/") # needed for MinGW build + command.append(f"DESTDIR={package_folder}") if targets: command.extend(targets) if not self._use_nmake: @@ -517,7 +518,8 @@ def _make_install(self): def build(self): self._make() - self.run(f"{self._perl} {self.source_folder}/configdata.pm --dump") + source_folder = self.source_folder.replace("\\", "/") # Necessary for MinGW build + self.run(f"{self._perl} {source_folder}/configdata.pm --dump") @property def _make_program(self): From 0190f7bd7c894716de145abe9d6858126d8b68a9 Mon Sep 17 00:00:00 2001 From: Andrei Malashkin Date: Tue, 10 Oct 2023 20:15:11 +0200 Subject: [PATCH 1040/1140] (#19596) add test for c_subscripts MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add test for c_subscripts * fix SETUP_C_SUBSCRIPTS * Fix URL, get default back to False --------- Co-authored-by: Rubén Rincón Blanco --- recipes/newmat/all/conanfile.py | 4 ++-- recipes/newmat/all/test_package/test_package.cpp | 10 +++++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/recipes/newmat/all/conanfile.py b/recipes/newmat/all/conanfile.py index 1e8f73c3d75fc7..e73dffca97d70d 100644 --- a/recipes/newmat/all/conanfile.py +++ b/recipes/newmat/all/conanfile.py @@ -12,7 +12,7 @@ class NewmatConan(ConanFile): name = "newmat" description = "Manipulate a variety of types of matrices using standard matrix operations." url = "https://github.com/conan-io/conan-center-index" - homepage = "https://newmat.net" + homepage = "http://www.robertnz.net/nm11.htm" topics = ("matrix") license = "LicenseRef-newmat" package_type = "library" @@ -83,5 +83,5 @@ def package_info(self): self.cpp_info.includedirs.append(os.path.join("include", "newmat")) if self.options.with_c_subscripts: - self.cpp_info.defines = ["SETUP_C_SUBSCRIPTS"] + self.cpp_info.defines.append("SETUP_C_SUBSCRIPTS") diff --git a/recipes/newmat/all/test_package/test_package.cpp b/recipes/newmat/all/test_package/test_package.cpp index bcd358b815b251..bd314f10d88fc9 100644 --- a/recipes/newmat/all/test_package/test_package.cpp +++ b/recipes/newmat/all/test_package/test_package.cpp @@ -2,6 +2,14 @@ int main() { - Matrix A(2,3); + Matrix matrix(4,4); + + matrix + << 1 << 2 << 3 << 4 + << 21 << 22 << 23 << 24 + << 31 << 32 << 33 << 34 + << 41 << 42 << 43 << 44 + ; + return 0; } From 29d0e1d7af1ab735ddc1a8bfbfa274b21417ec5f Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Tue, 10 Oct 2023 21:21:57 +0200 Subject: [PATCH 1041/1140] (#20186) qt 6.5.3 * qt 6.5.3 generated with: ``` conan config install https://github.com/conan-io/conan-extensions.git conan cci:upgrade-qt-recipe 6.5.3 ``` * fix conflicts * disable vcpkg * Update conanfile.py --- recipes/qt/6.x.x/conandata.yml | 24 ++ recipes/qt/6.x.x/conanfile.py | 13 +- recipes/qt/6.x.x/qtmodules6.5.3.conf | 332 +++++++++++++++++++++++++++ recipes/qt/config.yml | 2 + 4 files changed, 367 insertions(+), 4 deletions(-) create mode 100644 recipes/qt/6.x.x/qtmodules6.5.3.conf diff --git a/recipes/qt/6.x.x/conandata.yml b/recipes/qt/6.x.x/conandata.yml index ed9afdd80458b9..a0c2a35fafbd7a 100644 --- a/recipes/qt/6.x.x/conandata.yml +++ b/recipes/qt/6.x.x/conandata.yml @@ -1,4 +1,24 @@ sources: + "6.5.3": + url: + - "https://download.qt.io/official_releases/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://download.qt.io/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirrors.20i.com/pub/qt.io/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirrors.ukfast.co.uk/sites/qt.io/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://ftp.nluug.nl/languages/qt/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirror.netcologne.de/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://qt-mirror.dannhauer.de/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://ftp.fau.de/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirrors.dotsrc.org/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://ftp.acc.umu.se/mirror/qt.io/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirror.web4africa.ng/qt/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://qtproject.mirror.liquidtelecom.com/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://qt.mirror.constant.com/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirrors.cloud.tencent.com/qt/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://mirrors.sjtug.sjtu.edu.cn/qt/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://ftp.jaist.ac.jp/pub/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + - "https://ftp.yz.yamagata-u.ac.jp/pub/qtproject/archive/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" + sha256: "7cda4d119aad27a3887329cfc285f2aba5da85601212bcb0aea27bd6b7b544cb" "6.5.2": url: - "https://download.qt.io/official_releases/qt/6.5/6.5.2/single/qt-everywhere-src-6.5.2.tar.xz" @@ -64,6 +84,10 @@ sources: - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/6.3/6.3.2/single/qt-everywhere-src-6.3.2.tar.xz" sha256: "b90524f686224a0e5a945c1d65307e16a375348dbe275c9ac11de171fe31374a" patches: + "6.5.3": + - "base_path": "qtwebengine" + "patch_description": "Workaround for too long .rps file name" + "patch_file": "patches/c72097e.diff" "6.5.2": - "base_path": "qtwebengine" "patch_description": "Workaround for too long .rps file name" diff --git a/recipes/qt/6.x.x/conanfile.py b/recipes/qt/6.x.x/conanfile.py index 3edb49f690ce44..c00b4d63c6bfe7 100644 --- a/recipes/qt/6.x.x/conanfile.py +++ b/recipes/qt/6.x.x/conanfile.py @@ -301,7 +301,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.openssl: self.requires("openssl/[>=1.1 <4]") if self.options.with_pcre2: @@ -321,7 +321,7 @@ def requirements(self): if self.options.get_safe("with_icu", False): self.requires("icu/73.2") if self.options.get_safe("with_harfbuzz", False) and not self.options.multiconfiguration: - self.requires("harfbuzz/8.0.1") + self.requires("harfbuzz/8.2.1") if self.options.get_safe("with_libjpeg", False) and not self.options.multiconfiguration: if self.options.with_libjpeg == "libjpeg-turbo": self.requires("libjpeg-turbo/2.1.5") @@ -353,7 +353,7 @@ def requirements(self): self.requires("xkbcommon/1.5.0") self.requires("wayland/1.22.0") if self.options.with_brotli: - self.requires("brotli/1.0.9") + self.requires("brotli/1.1.0") if self.options.get_safe("qtwebengine") and self.settings.os == "Linux": self.requires("expat/2.5.0") self.requires("opus/1.3.1") @@ -376,7 +376,7 @@ def build_requirements(self): self.tool_requires("cmake/[>=3.21.1 <4]") self.tool_requires("ninja/1.11.1") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.2") if self.settings.os == "Windows": self.tool_requires('strawberryperl/5.32.1.1') @@ -424,6 +424,7 @@ def generate(self): vre.generate(scope="build") # TODO: to remove when properly handled by conan (see https://github.com/conan-io/conan/issues/11962) env = Environment() + env.unset("VCPKG_ROOT") env.prepend_path("PKG_CONFIG_PATH", self.generators_folder) env.vars(self).save_script("conanbuildenv_pkg_config_path") if self._settings_build.os == "Macos": @@ -582,6 +583,8 @@ def generate(self): cpp_std_map["23"] = "FEATURE_cxx2b" tc.variables[cpp_std_map.get(current_cpp_std, "FEATURE_cxx17")] = "ON" + tc.variables["QT_USE_VCPKG"] = False + tc.cache_variables["QT_USE_VCPKG"] = False tc.generate() @@ -633,6 +636,8 @@ def source(self): # use official variable name https://cmake.org/cmake/help/latest/module/FindFontconfig.html replace_in_file(self, os.path.join(self.source_folder, "qtbase", "src", "gui", "configure.cmake"), "FONTCONFIG_FOUND", "Fontconfig_FOUND") + replace_in_file(self, os.path.join(self.source_folder, "qtbase", "cmake", "QtAutoDetect.cmake") , "qt_auto_detect_vcpkg()", "# qt_auto_detect_vcpkg()") + def _xplatform(self): if self.settings.os == "Linux": if self.settings.compiler == "gcc": diff --git a/recipes/qt/6.x.x/qtmodules6.5.3.conf b/recipes/qt/6.x.x/qtmodules6.5.3.conf new file mode 100644 index 00000000000000..aee8d5684dcece --- /dev/null +++ b/recipes/qt/6.x.x/qtmodules6.5.3.conf @@ -0,0 +1,332 @@ +[submodule "qtbase"] + path = qtbase + url = ../qtbase.git + branch = 6.5.3 + status = essential +[submodule "qtsvg"] + depends = qtbase + path = qtsvg + url = ../qtsvg.git + branch = 6.5.3 + status = addon +[submodule "qtdeclarative"] + depends = qtbase + recommends = qtimageformats qtshadertools qtsvg qtlanguageserver + path = qtdeclarative + url = ../qtdeclarative.git + branch = 6.5.3 + status = essential +[submodule "qtactiveqt"] + depends = qtbase + path = qtactiveqt + url = ../qtactiveqt.git + branch = 6.5.3 + status = addon +[submodule "qtmultimedia"] + depends = qtbase qtshadertools + recommends = qtdeclarative qtquick3d + path = qtmultimedia + url = ../qtmultimedia.git + branch = 6.5.3 + status = addon +[submodule "qttools"] + depends = qtbase + recommends = qtdeclarative qtactiveqt + path = qttools + url = ../qttools.git + branch = 6.5.3 + status = essential +[submodule "qtxmlpatterns"] + depends = qtbase + recommends = qtdeclarative + path = qtxmlpatterns + url = ../qtxmlpatterns.git + branch = dev + status = ignore +[submodule "qttranslations"] + depends = qttools + path = qttranslations + url = ../qttranslations.git + branch = 6.5.3 + status = essential + priority = 30 +[submodule "qtdoc"] + depends = qtdeclarative qttools + recommends = qtmultimedia qtshadertools qtwebengine + path = qtdoc + url = ../qtdoc.git + branch = 6.5.3 + status = essential + priority = 40 +[submodule "qtrepotools"] + path = qtrepotools + url = ../qtrepotools.git + branch = master + status = essential + project = - +[submodule "qtqa"] + depends = qtbase + path = qtqa + url = ../qtqa.git + branch = dev + status = essential + priority = 50 +[submodule "qtlocation"] + depends = qtbase qtpositioning + recommends = qtdeclarative + path = qtlocation + url = ../qtlocation.git + branch = 6.5.3 + status = preview +[submodule "qtpositioning"] + depends = qtbase + recommends = qtdeclarative qtserialport + path = qtpositioning + url = ../qtpositioning.git + branch = 6.5.3 + status = addon +[submodule "qtsensors"] + depends = qtbase + recommends = qtdeclarative + path = qtsensors + url = ../qtsensors.git + branch = 6.5.3 + status = addon +[submodule "qtsystems"] + depends = qtbase + recommends = qtdeclarative + path = qtsystems + url = ../qtsystems.git + branch = dev + status = ignore +[submodule "qtfeedback"] + depends = qtdeclarative + recommends = qtmultimedia + path = qtfeedback + url = ../qtfeedback.git + branch = master + status = ignore +[submodule "qtpim"] + depends = qtdeclarative + path = qtpim + url = ../qtpim.git + branch = dev + status = ignore +[submodule "qtconnectivity"] + depends = qtbase + recommends = qtdeclarative + path = qtconnectivity + url = ../qtconnectivity.git + branch = 6.5.3 + status = addon +[submodule "qtwayland"] + depends = qtbase + recommends = qtdeclarative + path = qtwayland + url = ../qtwayland.git + branch = 6.5.3 + status = addon +[submodule "qt3d"] + depends = qtbase + recommends = qtdeclarative qtshadertools + path = qt3d + url = ../qt3d.git + branch = 6.5.3 + status = addon +[submodule "qtimageformats"] + depends = qtbase + path = qtimageformats + url = ../qtimageformats.git + branch = 6.5.3 + status = addon +[submodule "qtserialbus"] + depends = qtbase + recommends = qtserialport + path = qtserialbus + url = ../qtserialbus.git + branch = 6.5.3 + status = addon +[submodule "qtserialport"] + depends = qtbase + path = qtserialport + url = ../qtserialport.git + branch = 6.5.3 + status = addon +[submodule "qtwebsockets"] + depends = qtbase + recommends = qtdeclarative + path = qtwebsockets + url = ../qtwebsockets.git + branch = 6.5.3 + status = addon +[submodule "qtwebchannel"] + depends = qtbase + recommends = qtdeclarative qtwebsockets + path = qtwebchannel + url = ../qtwebchannel.git + branch = 6.5.3 + status = addon +[submodule "qtwebengine"] + depends = qtdeclarative + recommends = qtwebchannel qttools qtpositioning + path = qtwebengine + url = ../qtwebengine.git + branch = 6.5.3 + status = addon + priority = 10 +[submodule "qtcanvas3d"] + depends = qtdeclarative + path = qtcanvas3d + url = ../qtcanvas3d.git + branch = dev + status = ignore +[submodule "qtwebview"] + depends = qtdeclarative + recommends = qtwebengine + path = qtwebview + url = ../qtwebview.git + branch = 6.5.3 + status = addon +[submodule "qtcharts"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtcharts + url = ../qtcharts.git + branch = 6.5.3 + status = addon +[submodule "qtdatavis3d"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtdatavis3d + url = ../qtdatavis3d.git + branch = 6.5.3 + status = addon +[submodule "qtvirtualkeyboard"] + depends = qtbase qtdeclarative qtsvg + recommends = qtmultimedia + path = qtvirtualkeyboard + url = ../qtvirtualkeyboard.git + branch = 6.5.3 + status = addon +[submodule "qtgamepad"] + depends = qtbase + recommends = qtdeclarative + path = qtgamepad + url = ../qtgamepad.git + branch = dev + status = ignore +[submodule "qtscxml"] + depends = qtbase qtdeclarative + path = qtscxml + url = ../qtscxml.git + branch = 6.5.3 + status = addon +[submodule "qtspeech"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtspeech + url = ../qtspeech.git + branch = 6.5.3 + status = addon +[submodule "qtnetworkauth"] + depends = qtbase + path = qtnetworkauth + url = ../qtnetworkauth.git + branch = 6.5.3 + status = addon +[submodule "qtremoteobjects"] + depends = qtbase + recommends = qtdeclarative + path = qtremoteobjects + url = ../qtremoteobjects.git + branch = 6.5.3 + status = addon +[submodule "qtwebglplugin"] + depends = qtbase qtwebsockets + recommends = qtdeclarative + path = qtwebglplugin + url = ../qtwebglplugin.git + branch = dev + status = ignore +[submodule "qtlottie"] + depends = qtbase qtdeclarative + path = qtlottie + url = ../qtlottie.git + branch = 6.5.3 + status = addon +[submodule "qtquicktimeline"] + depends = qtbase qtdeclarative + path = qtquicktimeline + url = ../qtquicktimeline + branch = 6.5.3 + status = addon +[submodule "qtquick3d"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquicktimeline + path = qtquick3d + url = ../qtquick3d.git + branch = 6.5.3 + status = addon +[submodule "qtshadertools"] + depends = qtbase + path = qtshadertools + url = ../qtshadertools.git + branch = 6.5.3 + status = addon +[submodule "qt5compat"] + depends = qtbase qtdeclarative + path = qt5compat + url = ../qt5compat.git + branch = 6.5.3 + status = deprecated +[submodule "qtcoap"] + depends = qtbase + path = qtcoap + url = ../qtcoap.git + branch = 6.5.3 + status = addon +[submodule "qtmqtt"] + depends = qtbase qtdeclarative + path = qtmqtt + url = ../qtmqtt.git + branch = 6.5.3 + status = addon +[submodule "qtopcua"] + depends = qtbase qtdeclarative + path = qtopcua + url = ../qtopcua.git + branch = 6.5.3 + status = addon +[submodule "qtlanguageserver"] + depends = qtbase + path = qtlanguageserver + url = ../qtlanguageserver.git + branch = 6.5.3 + status = preview +[submodule "qthttpserver"] + depends = qtbase + recommends = qtwebsockets + path = qthttpserver + url = ../qthttpserver.git + branch = 6.5.3 + status = preview +[submodule "qtquick3dphysics"] + depends = qtbase qtdeclarative qtquick3d qtshadertools + path = qtquick3dphysics + url = ../qtquick3dphysics.git + branch = 6.5.3 + status = addon +[submodule "qtgrpc"] + depends = qtbase + recommends = qtdeclarative + path = qtgrpc + url = ../qtgrpc.git + branch = 6.5.3 + status = preview +[submodule "qtquickeffectmaker"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquick3d + path = qtquickeffectmaker + url = ../qtquickeffectmaker.git + branch = 6.5.3 + status = addon diff --git a/recipes/qt/config.yml b/recipes/qt/config.yml index 1ccfd2e7da0a7f..6df0033404d92c 100644 --- a/recipes/qt/config.yml +++ b/recipes/qt/config.yml @@ -1,4 +1,6 @@ versions: + "6.5.3": + folder: 6.x.x "6.5.2": folder: 6.x.x "6.5.1": From 26882413211e650eead97cf8ad13de3a0139fafc Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Tue, 10 Oct 2023 16:15:26 -0500 Subject: [PATCH 1042/1140] (#20265) libglvnd: Fix incorrect license and update recipe * Update topics * Add package_type * Fix license * Update Conan recipe and test package * Set src_folder in layout --- recipes/libglvnd/all/conanfile.py | 40 +++++++++---------- .../libglvnd/all/test_package/CMakeLists.txt | 11 ++--- .../libglvnd/all/test_package/conanfile.py | 21 ++++++---- 3 files changed, 38 insertions(+), 34 deletions(-) diff --git a/recipes/libglvnd/all/conanfile.py b/recipes/libglvnd/all/conanfile.py index 7d1919c184d04a..9503a3cd195eb2 100644 --- a/recipes/libglvnd/all/conanfile.py +++ b/recipes/libglvnd/all/conanfile.py @@ -1,8 +1,10 @@ from conan import ConanFile -from conan.tools.meson import Meson, MesonToolchain -from conan.tools.files import get, rmdir, save from conan.errors import ConanInvalidConfiguration +from conan.tools.files import get, rmdir, save +from conan.tools.env import VirtualBuildEnv +from conan.tools.gnu import PkgConfigDeps from conan.tools.layout import basic_layout +from conan.tools.meson import Meson, MesonToolchain import os import textwrap @@ -11,11 +13,12 @@ class LibGlvndConan(ConanFile): name = "libglvnd" description = "The GL Vendor-Neutral Dispatch library" - license = "LicenseRef-LICENSE" + license = "MIT" url = "https://github.com/conan-io/conan-center-index" homepage = "https://gitlab.freedesktop.org/glvnd/libglvnd" - topics = ("gl", "vendor-neutral", "dispatch") + topics = ("dispatch", "egl", "gl", "gles", "glx", "glvnd", "opengl", "vendor-neutral") settings = "os", "arch", "compiler", "build_type" + package_type = "shared-library" options = { "asm": [True, False], "x11": [True, False], @@ -41,21 +44,9 @@ class LibGlvndConan(ConanFile): "entrypoint_patching": True, } - generators = "PkgConfigDeps" - - # don't use self.settings_build - @property - def _settings_build(self): - return getattr(self, "settings_build", self.settings) - - # don't use self.user_info_build - @property - def _user_info_build(self): - return getattr(self, "user_info_build", self.deps_user_info) - def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def requirements(self): if self.options.x11: @@ -65,20 +56,25 @@ def requirements(self): def validate(self): if self.settings.os not in ['Linux', 'FreeBSD']: - raise ConanInvalidConfiguration("libglvnd is only compatible with Linux and FreeBSD") + raise ConanInvalidConfiguration(f"{self.name} is only compatible with Linux and FreeBSD") def build_requirements(self): - self.build_requires("meson/0.63.2") - self.build_requires("pkgconf/1.9.3") + self.tool_requires("meson/1.2.2") + if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): + self.tool_requires("pkgconf/2.0.3") def layout(self): - basic_layout(self) + basic_layout(self, src_folder="src") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): + virtual_build_env = VirtualBuildEnv(self) + virtual_build_env.generate() + pkg_config_deps = PkgConfigDeps(self) + pkg_config_deps.generate() tc = MesonToolchain(self) tc.project_options["asm"] = "enabled" if self.options.asm else "disabled" tc.project_options["x11"] = "enabled" if self.options.x11 else "disabled" diff --git a/recipes/libglvnd/all/test_package/CMakeLists.txt b/recipes/libglvnd/all/test_package/CMakeLists.txt index 34af13462f44f8..60cf6714783e83 100644 --- a/recipes/libglvnd/all/test_package/CMakeLists.txt +++ b/recipes/libglvnd/all/test_package/CMakeLists.txt @@ -1,8 +1,9 @@ -cmake_minimum_required(VERSION 3.1) -project(test_package) +cmake_minimum_required(VERSION 3.15) -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup() +project(test_package LANGUAGES C) + +find_package(libglvnd REQUIRED CONFIG) add_executable(${PROJECT_NAME} test_package.c) -target_link_libraries(${PROJECT_NAME} ${CONAN_LIBS}) +target_link_libraries(${PROJECT_NAME} PRIVATE libglvnd::libglvnd) + diff --git a/recipes/libglvnd/all/test_package/conanfile.py b/recipes/libglvnd/all/test_package/conanfile.py index 8b7f471a280d57..ef5d7042163ecc 100644 --- a/recipes/libglvnd/all/test_package/conanfile.py +++ b/recipes/libglvnd/all/test_package/conanfile.py @@ -1,12 +1,19 @@ from conan import ConanFile -from conan.tools.build import cross_building -from conans import CMake +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake" + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) def build(self): cmake = CMake(self) @@ -14,6 +21,6 @@ def build(self): cmake.build() def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "test_package") - self.run(bin_path, run_environment=True) + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") From e3004c2531cb33568fe3dbc41248eb3b1fa5c73c Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Wed, 11 Oct 2023 00:02:29 +0200 Subject: [PATCH 1043/1140] (#20473) [bot] Update list of references (prod-v2/ListPackages) --- .c3i/conan_v2_ready_references.yml | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) diff --git a/.c3i/conan_v2_ready_references.yml b/.c3i/conan_v2_ready_references.yml index fc3d9282a9ef72..ced5ee37a897a1 100644 --- a/.c3i/conan_v2_ready_references.yml +++ b/.c3i/conan_v2_ready_references.yml @@ -146,6 +146,7 @@ required_for_references: - cfitsio - cgal - cgif +- cgltf - cgns - chaiscript - charls @@ -249,6 +250,7 @@ required_for_references: - dbcppp - dbg-macro - dbus +- dcmtk - debug_assert - decimal_for_cpp - deco @@ -280,6 +282,7 @@ required_for_references: - easy_profiler - easyhttpcpp - easyloggingpp +- easylzma - ecos - editline - edlib @@ -510,6 +513,7 @@ required_for_references: - khrplatform - kickcat - kissfft +- kitten - kmod - ktx - kuba-zip @@ -536,6 +540,7 @@ required_for_references: - libavif - libb2 - libbacktrace +- libbasisu - libbigwig - libbpf - libbsd @@ -557,12 +562,15 @@ required_for_references: - libdivide - libdmtx - libdrawille +- libdrm - libdwarf - libdxfrw - libe57format - libelf +- libenvpp - libepoxy - libev +- libevdev - libevent - libexif - libfdk_aac @@ -588,6 +596,7 @@ required_for_references: - libjpeg - libjpeg-turbo - libkml +- libliftoff - liblsl - libltc - liblzf @@ -609,6 +618,7 @@ required_for_references: - libmysqlclient - libnabo - libnet +- libnetfilter_conntrack - libnetfilter_queue - libnfnetlink - libnfs @@ -620,6 +630,7 @@ required_for_references: - libnova - libnpy - libnuma +- liboping - libpcap - libpciaccess - libpfm4 @@ -684,6 +695,8 @@ required_for_references: - libxls - libxlsxwriter - libxml2 +- libxpm +- libxshmfence - libxslt - libyaml - libyuv @@ -702,6 +715,7 @@ required_for_references: - lodepng - log.c - log4cplus +- log4cxx - logr - loguru - ls-qpack @@ -751,7 +765,9 @@ required_for_references: - meson - metall - metis +- mfast - mgs +- microprofile - microservice-essentials - microtar - mikelankamp-fpm @@ -788,6 +804,7 @@ required_for_references: - msgpack-c - msgpack-cxx - msys2 +- mtdev - mujs - muparser - muparserx @@ -922,6 +939,7 @@ required_for_references: - platform.exceptions - platform.hashing - platform.interfaces +- playrho - plf_colony - plf_indiesort - plf_list @@ -940,6 +958,7 @@ required_for_references: - poppler-data - popt - portable-file-dialogs +- poshlib - pprint - pranav-csv2 - pretty-name @@ -1003,6 +1022,7 @@ required_for_references: - redis-plus-plus - refl-cpp - replxx +- resource_pool - restbed - restinio - rg-etc1 @@ -1021,6 +1041,7 @@ required_for_references: - ruy - rvo2 - rxcpp +- s2geometry - s2n - safeint - sail @@ -1049,6 +1070,7 @@ required_for_references: - seqan3 - serd - serdepp +- serial - sfml - shapelib - shield @@ -1064,6 +1086,7 @@ required_for_references: - sml - snappy - snowhouse +- so5extra - sobjectizer - soci - sofa @@ -1125,6 +1148,7 @@ required_for_references: - tcb-span - tcl - tclap +- tcp-wrappers - tensorflow-lite - tensorpipe - termcap @@ -1184,6 +1208,8 @@ required_for_references: - tsl-sparse-map - tuplet - turtle +- tweetnacl +- twitch-native-ipc - type_safe - tz - ua-nodeset @@ -1257,6 +1283,7 @@ required_for_references: - wyhash - xapian-core - xbyak +- xege - xerces-c - xkbcommon - xkeyboard-config @@ -1288,6 +1315,7 @@ required_for_references: - yas - yasm - yder +- yoga - yyjson - z3 - zbar From d822d18513087e803cefe1d17658b56df61e3fed Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 11 Oct 2023 08:10:27 +0900 Subject: [PATCH 1044/1140] (#20327) immer: add version 0.8.1, rename example MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Francisco Ramírez --- recipes/immer/all/conandata.yml | 3 +++ recipes/immer/all/conanfile.py | 6 +++--- recipes/immer/all/test_package/CMakeLists.txt | 8 ++++---- recipes/immer/all/test_package/conanfile.py | 2 +- .../all/test_package/{example.cpp => test_package.cpp} | 0 recipes/immer/all/test_v1_package/conanfile.py | 2 +- recipes/immer/config.yml | 2 ++ 7 files changed, 14 insertions(+), 9 deletions(-) rename recipes/immer/all/test_package/{example.cpp => test_package.cpp} (100%) diff --git a/recipes/immer/all/conandata.yml b/recipes/immer/all/conandata.yml index 6d029402576cc8..dcc90952900823 100644 --- a/recipes/immer/all/conandata.yml +++ b/recipes/immer/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.8.1": + url: "https://github.com/arximboldi/immer/archive/v0.8.1.tar.gz" + sha256: "de8411c84830864604bb685dc8f2e3c0dbdc40b95b2f6726092f7dcc85e75209" "0.8.0": url: "https://github.com/arximboldi/immer/archive/v0.8.0.tar.gz" sha256: "4ed9e86a525f293e0ba053107b937d88b032674ec6e5db958816f2e412677fde" diff --git a/recipes/immer/all/conanfile.py b/recipes/immer/all/conanfile.py index b605235f935530..dadfcc5005ec64 100644 --- a/recipes/immer/all/conanfile.py +++ b/recipes/immer/all/conanfile.py @@ -24,7 +24,7 @@ class ImmerConan(ConanFile): no_copy_source = True @property - def _minimum_cpp_standard(self): + def _min_cppstd(self): return 14 @property @@ -47,14 +47,14 @@ def package_id(self): def validate(self): if self.settings.compiler.get_safe("cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) + check_min_cppstd(self, self._min_cppstd) min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) if not min_version: self.output.warning(f"{self.name} recipe lacks information about the {self.settings.compiler} compiler support.") else: if Version(self.settings.compiler.version) < min_version: raise ConanInvalidConfiguration( - f"{self.name} requires C++{self._minimum_cpp_standard} support. The current compiler" + f"{self.name} requires C++{self._min_cppstd} support. The current compiler" f" {self.settings.compiler} {self.settings.compiler.version} does not support it." ) diff --git a/recipes/immer/all/test_package/CMakeLists.txt b/recipes/immer/all/test_package/CMakeLists.txt index c9d3024076801f..3e9a18f3dcd2f6 100644 --- a/recipes/immer/all/test_package/CMakeLists.txt +++ b/recipes/immer/all/test_package/CMakeLists.txt @@ -1,8 +1,8 @@ cmake_minimum_required(VERSION 3.15) -project(PackageTest CXX) +project(PackageTest LANGUAGES CXX) find_package(immer REQUIRED CONFIG) -add_executable(example example.cpp) -target_link_libraries(example immer::immer) -target_compile_features(example PUBLIC cxx_std_14) +add_executable(test_package test_package.cpp) +target_link_libraries(test_package PRIVATE immer::immer) +target_compile_features(test_package PRIVATE cxx_std_14) diff --git a/recipes/immer/all/test_package/conanfile.py b/recipes/immer/all/test_package/conanfile.py index 8d52b7021efe14..ef5d7042163ecc 100644 --- a/recipes/immer/all/test_package/conanfile.py +++ b/recipes/immer/all/test_package/conanfile.py @@ -22,5 +22,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindir, "example") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") self.run(bin_path, env="conanrun") diff --git a/recipes/immer/all/test_package/example.cpp b/recipes/immer/all/test_package/test_package.cpp similarity index 100% rename from recipes/immer/all/test_package/example.cpp rename to recipes/immer/all/test_package/test_package.cpp diff --git a/recipes/immer/all/test_v1_package/conanfile.py b/recipes/immer/all/test_v1_package/conanfile.py index 0242d96a644cae..90eb89e3f2f46b 100644 --- a/recipes/immer/all/test_v1_package/conanfile.py +++ b/recipes/immer/all/test_v1_package/conanfile.py @@ -13,5 +13,5 @@ def build(self): def test(self): if not tools.cross_building(self): - bin_path = os.path.join("bin", "example") + bin_path = os.path.join("bin", "test_package") self.run(bin_path, run_environment=True) diff --git a/recipes/immer/config.yml b/recipes/immer/config.yml index 7090494339fd49..249b90e4014bae 100644 --- a/recipes/immer/config.yml +++ b/recipes/immer/config.yml @@ -1,4 +1,6 @@ versions: + "0.8.1": + folder: all "0.8.0": folder: all "0.7.0": From bb64e8446e3ee74115064cae08756f759a7c9aa2 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Tue, 10 Oct 2023 19:11:09 -0500 Subject: [PATCH 1045/1140] (#20353) util-linux-libuuid/2.39: Remove usr directory from package folder For some reason, it tries to install a systemd directory and bash completions in the usr directory. --- recipes/util-linux-libuuid/all/conanfile.py | 1 + 1 file changed, 1 insertion(+) diff --git a/recipes/util-linux-libuuid/all/conanfile.py b/recipes/util-linux-libuuid/all/conanfile.py index 71265d08f5124f..e5c35fe2c862ba 100644 --- a/recipes/util-linux-libuuid/all/conanfile.py +++ b/recipes/util-linux-libuuid/all/conanfile.py @@ -105,6 +105,7 @@ def package(self): rmdir(self, os.path.join(self.package_folder, "bin")) rmdir(self, os.path.join(self.package_folder, "sbin")) rmdir(self, os.path.join(self.package_folder, "share")) + rmdir(self, os.path.join(self.package_folder, "usr")) fix_apple_shared_install_name(self) def package_info(self): From 4710b9a36c35556b63895bc91baf6b32a05c0182 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Tue, 10 Oct 2023 20:11:12 -0500 Subject: [PATCH 1046/1140] (#20379) boost-ext-ut: Add version 2.0.0 * boost-ext-ut: Add version 2.0.0 * Use a newer version of CMake for version 2.0.0 * Use VirtualBuildEnv * Update minimum required versions of Clang and GCC * Use a newer version of apple-clang * Fix typo * Bump minimum apple-clang version to 14 for 2.0.0 --- recipes/boost-ext-ut/all/conandata.yml | 13 ++++++++----- recipes/boost-ext-ut/all/conanfile.py | 25 +++++++++++++++++++------ recipes/boost-ext-ut/config.yml | 2 ++ 3 files changed, 29 insertions(+), 11 deletions(-) diff --git a/recipes/boost-ext-ut/all/conandata.yml b/recipes/boost-ext-ut/all/conandata.yml index 81ce02efd2b42d..f123657f3fbe37 100644 --- a/recipes/boost-ext-ut/all/conandata.yml +++ b/recipes/boost-ext-ut/all/conandata.yml @@ -1,12 +1,15 @@ sources: - "1.1.8": - url: "https://github.com/boost-ext/ut/archive/v1.1.8.tar.gz" - sha256: "3cc426dcf38397637e889efd9567b06d55dd23fb4e65cc0381eb8103a411d104" + "2.0.0": + url: "https://github.com/boost-ext/ut/archive/v2.0.0.tar.gz" + sha256: "8b5b11197d1308dfc1fe20efd6a656e0c833dbec2807e2292967f6e2f7c0420f" "1.1.9": url: "https://github.com/boost-ext/ut/archive/v1.1.9.tar.gz" sha256: "1a666513157905aa0e53a13fac602b5673dcafb04a869100a85cd3f000c2ed0d" -patches: "1.1.8": - - patch_file: "patches/license.patch" + url: "https://github.com/boost-ext/ut/archive/v1.1.8.tar.gz" + sha256: "3cc426dcf38397637e889efd9567b06d55dd23fb4e65cc0381eb8103a411d104" +patches: "1.1.9": - patch_file: "patches/1.1.9_cmake_project_version.patch" + "1.1.8": + - patch_file: "patches/license.patch" diff --git a/recipes/boost-ext-ut/all/conanfile.py b/recipes/boost-ext-ut/all/conanfile.py index bce6579a06de79..a73d7aef01853d 100644 --- a/recipes/boost-ext-ut/all/conanfile.py +++ b/recipes/boost-ext-ut/all/conanfile.py @@ -3,8 +3,9 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, cmake_layout, CMakeToolchain +from conan.tools.env import VirtualBuildEnv from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rmdir -from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.microsoft import is_msvc from conan.tools.scm import Version from conan.errors import ConanInvalidConfiguration @@ -31,9 +32,11 @@ def _minimum_cpp_standard(self): @property def _minimum_compilers_version(self): return { - "apple-clang": "11" if Version(self.version) < "1.1.8" else "12", - "clang": "9", - "gcc": "9", + "apple-clang": "12" if Version(self.version) < "2.0.0" else "14", + "clang": "9" if Version(self.version) < "2.0.0" else "10", + "gcc": "9" if Version(self.version) < "2.0.0" else "10", + "msvc": "192", + "Visual Studio": "14", } def export_sources(self): @@ -54,9 +57,13 @@ def validate(self): if Version(self.version) <= "1.1.8" and is_msvc(self): raise ConanInvalidConfiguration(f"{self.ref} may not be built with MSVC. " "Please use at least version 1.1.9 with MSVC.") + minimum_version = self._minimum_compilers_version.get(str(self.settings.compiler), False) + if minimum_version and Version(self.settings.compiler.version) < minimum_version: + raise ConanInvalidConfiguration( + f"{self.ref} requires at least version {minimum_version} of the {self.settings.compiler} compiler." + ) if is_msvc(self): - check_min_vs(self, "192") if not self.options.get_safe("disable_module", True): self.output.warn("The 'disable_module' option must be enabled when using MSVC.") if not is_msvc(self): @@ -71,6 +78,10 @@ def validate(self): f"{self.ref} requires C++{self._minimum_cpp_standard} support. " f"The current compiler {self.settings.compiler} {self.settings.compiler.version} does not support it.") + def build_requirements(self): + if Version(self.version) >= "2.0.0": + self.tool_requires("cmake/[>=3.21 <4]") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -84,7 +95,9 @@ def generate(self): if disable_module: tc.cache_variables["BOOST_UT_DISABLE_MODULE"] = disable_module tc.generate() - + virtual_build_env = VirtualBuildEnv(self) + virtual_build_env.generate() + def build(self): apply_conandata_patches(self) cmake = CMake(self) diff --git a/recipes/boost-ext-ut/config.yml b/recipes/boost-ext-ut/config.yml index 968159344a038f..483296a860daad 100644 --- a/recipes/boost-ext-ut/config.yml +++ b/recipes/boost-ext-ut/config.yml @@ -1,4 +1,6 @@ versions: + "2.0.0": + folder: "all" "1.1.8": folder: "all" "1.1.9": From ba922b9037457fc9db168fc9359dbbb211f96287 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 11 Oct 2023 04:11:37 +0200 Subject: [PATCH 1047/1140] (#20397) sentry-native/all: bump deps --- recipes/sentry-native/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/sentry-native/all/conanfile.py b/recipes/sentry-native/all/conanfile.py index faa6d8ed510e7d..64c0a526c8730e 100644 --- a/recipes/sentry-native/all/conanfile.py +++ b/recipes/sentry-native/all/conanfile.py @@ -103,7 +103,7 @@ def layout(self): def requirements(self): if self.options.transport == "curl": - self.requires("libcurl/8.0.1") + self.requires("libcurl/8.2.1") if self.options.backend == "crashpad": if self.options.with_crashpad == "sentry": self.requires(f"sentry-crashpad/{self.version}") @@ -115,7 +115,7 @@ def requirements(self): if self.options.with_breakpad == "google": self.requires("breakpad/cci.20210521") if self.options.get_safe("qt"): - self.requires("qt/5.15.9") + self.requires("qt/5.15.11") self.requires("openssl/[>=1.1 <4]") def validate(self): @@ -137,7 +137,7 @@ def build_requirements(self): self.tool_requires("cmake/[>=3.16.4 <4]") if self.options.backend == "breakpad": if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version]) From 51393d52a645b4db23895979b2e9a8087a1b4bdd Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 11 Oct 2023 05:10:28 +0200 Subject: [PATCH 1048/1140] (#20405) libsixel/all: bump deps --- recipes/libsixel/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libsixel/all/conanfile.py b/recipes/libsixel/all/conanfile.py index 5b731a76e5de89..182d8500c1d8ab 100644 --- a/recipes/libsixel/all/conanfile.py +++ b/recipes/libsixel/all/conanfile.py @@ -58,7 +58,7 @@ def layout(self): def requirements(self): if self.options.with_curl: - self.requires("libcurl/8.2.0") + self.requires("libcurl/8.2.1") if self.options.with_gd: self.requires("libgd/2.3.3") if self.options.with_gdk_pixbuf2: @@ -75,9 +75,9 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} does not support Visual Studio") def build_requirements(self): - self.tool_requires("meson/1.2.0") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.5") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From fe6f997c3cb962a1bcf447df4a35dfaf5a487608 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Wed, 11 Oct 2023 06:10:21 +0200 Subject: [PATCH 1049/1140] (#20425) libmetalink/all: bump deps --- recipes/libmetalink/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/libmetalink/all/conanfile.py b/recipes/libmetalink/all/conanfile.py index 26b6f8a3d96558..a17aa7f18af8a0 100644 --- a/recipes/libmetalink/all/conanfile.py +++ b/recipes/libmetalink/all/conanfile.py @@ -53,9 +53,9 @@ def layout(self): def requirements(self): if self.options.xml_backend == "expat": - self.requires("expat/2.4.9") + self.requires("expat/2.5.0") elif self.options.xml_backend == "libxml2": - self.requires("libxml2/2.9.14") + self.requires("libxml2/2.11.4") def validate(self): if is_msvc(self): @@ -63,7 +63,7 @@ def validate(self): def build_requirements(self): self.tool_requires("gnu-config/cci.20210814") - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From c5533fc98d707f43a80f160215173b9f1541d176 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 11 Oct 2023 07:11:24 +0200 Subject: [PATCH 1050/1140] (#20462) libtasn1: use winflexbison instead of bison if build machine is Windows bison raises if Windows --- recipes/libtasn1/all/conanfile.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/recipes/libtasn1/all/conanfile.py b/recipes/libtasn1/all/conanfile.py index 069830d3c9f365..d1eea1562324a8 100644 --- a/recipes/libtasn1/all/conanfile.py +++ b/recipes/libtasn1/all/conanfile.py @@ -55,7 +55,11 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} doesn't support Visual Studio") def build_requirements(self): - self.tool_requires("bison/3.8.2") + if self._settings_build.os == "Windows": + self.tool_requires("winflexbison/2.5.25") + else: + self.tool_requires("bison/3.8.2") + if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From 3c082ddef25fea486db677df4f5f2672a8a64ceb Mon Sep 17 00:00:00 2001 From: Gregor Jasny Date: Wed, 11 Oct 2023 08:11:14 +0200 Subject: [PATCH 1051/1140] (#20466) c-ares: add version 1.20.1 --- recipes/c-ares/all/conandata.yml | 3 +++ recipes/c-ares/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/c-ares/all/conandata.yml b/recipes/c-ares/all/conandata.yml index e6549888363362..5fa919d9fff6b4 100644 --- a/recipes/c-ares/all/conandata.yml +++ b/recipes/c-ares/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.20.1": + url: "https://github.com/c-ares/c-ares/releases/download/cares-1_20_1/c-ares-1.20.1.tar.gz" + sha256: "de24a314844cb157909730828560628704f4f896d167dd7da0fa2fb93ea18b10" "1.19.1": url: "https://github.com/c-ares/c-ares/releases/download/cares-1_19_1/c-ares-1.19.1.tar.gz" sha256: "321700399b72ed0e037d0074c629e7741f6b2ec2dda92956abe3e9671d3e268e" diff --git a/recipes/c-ares/config.yml b/recipes/c-ares/config.yml index 402bb147b757b9..e429742ce15f71 100644 --- a/recipes/c-ares/config.yml +++ b/recipes/c-ares/config.yml @@ -1,4 +1,6 @@ versions: + "1.20.1": + folder: all "1.19.1": folder: all "1.19.0": From 0124cb3f0763a883b424c241b30706e012b384b0 Mon Sep 17 00:00:00 2001 From: Carlos Zoido Date: Wed, 11 Oct 2023 09:03:50 +0200 Subject: [PATCH 1052/1140] (#20454) Bump deps in sdl to avoid conflicts --- recipes/sdl/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/sdl/all/conanfile.py b/recipes/sdl/all/conanfile.py index 6d8d882403cbd1..f04c1dfd85b9b3 100644 --- a/recipes/sdl/all/conanfile.py +++ b/recipes/sdl/all/conanfile.py @@ -144,7 +144,7 @@ def requirements(self): self.requires("libiconv/1.17") if self.settings.os == "Linux": if self.options.alsa: - self.requires("libalsa/1.2.7.2") + self.requires("libalsa/1.2.10") if self.options.pulse: self.requires("pulseaudio/14.2") if self.options.opengl: @@ -152,7 +152,7 @@ def requirements(self): if self.options.nas: self.requires("nas/1.9.5") if self.options.wayland: - self.requires("wayland/1.21.0") + self.requires("wayland/1.22.0") self.requires("xkbcommon/1.4.1") self.requires("egl/system") if self.options.libunwind: @@ -188,7 +188,7 @@ def build_requirements(self): if self.settings.os == "Linux" and not self.conf.get("tools.gnu:pkg_config", check_type=str): self.tool_requires("pkgconf/1.9.3") if hasattr(self, "settings_build") and self.options.get_safe("wayland"): - self.build_requires("wayland/1.21.0") # Provides wayland-scanner + self.build_requires("wayland/1.22.0") # Provides wayland-scanner def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True, From 2815efc941e467b842d04d296ea2848870323d57 Mon Sep 17 00:00:00 2001 From: toge Date: Wed, 11 Oct 2023 17:12:47 +0900 Subject: [PATCH 1053/1140] (#20468) commata: add version 0.2.6 --- recipes/commata/all/conandata.yml | 3 +++ recipes/commata/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/commata/all/conandata.yml b/recipes/commata/all/conandata.yml index f3b0e9f61cd278..e7ea4a174774d9 100644 --- a/recipes/commata/all/conandata.yml +++ b/recipes/commata/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.2.6": + url: "https://github.com/furfurylic/commata/archive/refs/tags/v0.2.6.tar.gz" + sha256: "bc91f496cb261e5627fb39d8e79d1aaa924975332d9957de4cb4097db6957815" "0.2.5": url: "https://github.com/furfurylic/commata/archive/refs/tags/v0.2.5.tar.gz" sha256: "d1be1f366267af6c466c29f846f5968f57626a8a6635a2ea9a3de3f6fb88e53b" diff --git a/recipes/commata/config.yml b/recipes/commata/config.yml index 5000ff084e2004..571d6667fb3bed 100644 --- a/recipes/commata/config.yml +++ b/recipes/commata/config.yml @@ -1,4 +1,6 @@ versions: + "0.2.6": + folder: all "0.2.5": folder: all "0.2.4-bug1": From 4abd9f713e8b724da8fed88146f1d49f801a6ab6 Mon Sep 17 00:00:00 2001 From: rconde01 Date: Wed, 11 Oct 2023 04:47:19 -0400 Subject: [PATCH 1054/1140] (#20475) gh-20467 Fix linker errors when building cspice utilities on windows The cmake logic depended on removing a matching file name, but the list contained relative paths, while the file to match had absolute paths. Now they both use absolute paths. --- recipes/cspice/all/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/cspice/all/CMakeLists.txt b/recipes/cspice/all/CMakeLists.txt index 3812708448a9a5..4e032190639fa8 100644 --- a/recipes/cspice/all/CMakeLists.txt +++ b/recipes/cspice/all/CMakeLists.txt @@ -65,7 +65,7 @@ if(CSPICE_BUILD_UTILITIES) file(GLOB CSPICE_UTILITIES_SUBDIRS RELATIVE ${SRC_DIR} "${SRC_DIR}/*_c") list(REMOVE_ITEM CSPICE_UTILITIES_SUBDIRS "cook_c") foreach(CSPICE_SUBDIR ${CSPICE_UTILITIES_SUBDIRS}) - set(UTILITY_SRC_DIR "${SRC_DIR}/${CSPICE_SUBDIR}") + get_filename_component(UTILITY_SRC_DIR "${SRC_DIR}/${CSPICE_SUBDIR}" ABSOLUTE) # Each .pgm file is the entry point of an executable file(GLOB PGM_FILES "${UTILITY_SRC_DIR}/*.pgm") From d3ce11c85b42073d93aec27a1a82ebb0f61550ae Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 11:01:22 +0200 Subject: [PATCH 1055/1140] (#20479) xorg-gccmakedep/all: bump deps * xorg-gccmakedep/all/: bump deps * xorg-gccmakedep/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-gccmakedep/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-gccmakedep/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/xorg-gccmakedep/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/xorg-gccmakedep/all/conanfile.py b/recipes/xorg-gccmakedep/all/conanfile.py index 813811cb7758d4..1aafda519a4705 100644 --- a/recipes/xorg-gccmakedep/all/conanfile.py +++ b/recipes/xorg-gccmakedep/all/conanfile.py @@ -29,7 +29,7 @@ def requirements(self): self.requires("xorg-macros/1.19.3") def build_requirements(self): - self.tool_requires("pkgconf/1.7.4") + self.tool_requires("pkgconf/2.0.3") def validate(self): if self.settings.os == "Windows": From bb3c48a1387214cc92ed4a11f23340ed9e9aa6af Mon Sep 17 00:00:00 2001 From: Ahajha <44127594+Ahajha@users.noreply.github.com> Date: Wed, 11 Oct 2023 05:03:31 -0400 Subject: [PATCH 1056/1140] (#20499) stduuid: fix conditional dependency on ms-gsl * stduuid: use std::span only when available * stduuid: only check for c++20 * stduuid: fixes * Add src folder to layout * Fix for Conan 1.x --------- Co-authored-by: Luis Caro Campos <3535649+jcar87@users.noreply.github.com> --- recipes/stduuid/all/conandata.yml | 9 +++++ recipes/stduuid/all/conanfile.py | 39 ++++++++++++------- .../patches/1.2.2-handle-span-header.patch | 26 +++++++++++++ .../patches/1.2.3-handle-span-header.patch | 29 ++++++++++++++ 4 files changed, 89 insertions(+), 14 deletions(-) create mode 100644 recipes/stduuid/all/patches/1.2.2-handle-span-header.patch create mode 100644 recipes/stduuid/all/patches/1.2.3-handle-span-header.patch diff --git a/recipes/stduuid/all/conandata.yml b/recipes/stduuid/all/conandata.yml index cb02ec2f291486..106008491388a0 100644 --- a/recipes/stduuid/all/conandata.yml +++ b/recipes/stduuid/all/conandata.yml @@ -8,3 +8,12 @@ sources: "1.0": url: "https://github.com/mariusbancila/stduuid/archive/v1.0.tar.gz" sha256: "e96f2ac7c950c3c24d7e2e44a84236277b7774ee346dcc620edf400d9eda0a3c" +patches: + "1.2.2": + - patch_file: "patches/1.2.2-handle-span-header.patch" + patch_description: "Conditionally include span header based on compiler definition" + patch_type: "conan" + "1.2.3": + - patch_file: "patches/1.2.3-handle-span-header.patch" + patch_description: "Conditionally include span header based on compiler definition" + patch_type: "conan" diff --git a/recipes/stduuid/all/conanfile.py b/recipes/stduuid/all/conanfile.py index 0ca3e6b2dcb08d..740dfa380f1ad7 100644 --- a/recipes/stduuid/all/conanfile.py +++ b/recipes/stduuid/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.build import check_min_cppstd -from conan.tools.files import copy, get +from conan.tools.build import check_min_cppstd, valid_min_cppstd +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.layout import basic_layout from conan.tools.scm import Version import os @@ -18,16 +18,14 @@ class StduuidConan(ConanFile): homepage = "https://github.com/mariusbancila/stduuid" settings = "os", "arch", "compiler", "build_type" options = { + # True: Use std::span + # False: Use gsl::span "with_cxx20_span": [True, False], } - default_options = { - "with_cxx20_span": False, - } - no_copy_source = True @property def _min_cppstd(self): - return "20" if self.options.with_cxx20_span else "17" + return "20" if self.options.get_safe("with_cxx20_span") else "17" @property def _compilers_minimum_version(self): @@ -38,13 +36,26 @@ def _compilers_minimum_version(self): "msvc": "191", "Visual Studio": "15", } + + def export_sources(self): + export_conandata_patches(self) def layout(self): basic_layout(self, src_folder="src") + def config_options(self): + if Version(self.version) == "1.0": + # Version 1.0 unconditionally depends on gsl span + del self.options.with_cxx20_span + else: + # Conditionally set the default value of with_cxx20_span + # if cppstd is set and is 20 or greater + self.options.with_cxx20_span = (self.settings.compiler.get_safe("cppstd", False) + and valid_min_cppstd(self, 20)) + def requirements(self): - if not self.options.with_cxx20_span: - self.requires("ms-gsl/3.1.0", transitive_headers=True) + if not self.options.get_safe("with_cxx20_span") or Version(self.version) == "1.0": + self.requires("ms-gsl/4.0.0", transitive_headers=True) if self.settings.os == "Linux" and Version(self.version) <= "1.0": self.requires("util-linux-libuuid/2.39", transitive_headers=True, transitive_libs=True) @@ -52,7 +63,7 @@ def package_id(self): self.info.clear() def validate(self): - if self.settings.compiler.get_safe("cppsd"): + if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) minimum_version = self._compilers_minimum_version.get(str(self.settings.compiler), False) @@ -62,8 +73,8 @@ def validate(self): ) def source(self): - get(self, **self.conan_data["sources"][self.version], - destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) + apply_conandata_patches(self) def build(self): pass @@ -75,5 +86,5 @@ def package(self): def package_info(self): self.cpp_info.bindirs = [] self.cpp_info.libdirs = [] - if not self.options.with_cxx20_span: - self.cpp_info.includedirs.append(os.path.join(self.dependencies["ms-gsl"].cpp_info.includedirs[0], "gsl")) + if self.options.get_safe("with_cxx20_span"): + self.cpp_info.defines = ["LIBUUID_CPP20_OR_GREATER"] diff --git a/recipes/stduuid/all/patches/1.2.2-handle-span-header.patch b/recipes/stduuid/all/patches/1.2.2-handle-span-header.patch new file mode 100644 index 00000000000000..840c78174c7724 --- /dev/null +++ b/recipes/stduuid/all/patches/1.2.2-handle-span-header.patch @@ -0,0 +1,26 @@ +diff --git a/include/uuid.h b/include/uuid.h +index 600846f..5f00a49 100644 +--- a/include/uuid.h ++++ b/include/uuid.h +@@ -15,7 +15,11 @@ + #include + #include + #include +-#include ++#if defined(LIBUUID_CPP20_OR_GREATER) ++# include ++#else ++# include ++#endif + + #ifdef _WIN32 + +@@ -51,7 +55,7 @@ + + namespace uuids + { +-#ifdef __cpp_lib_span ++#if defined(LIBUUID_CPP20_OR_GREATER) + template + using span = std::span; + #else diff --git a/recipes/stduuid/all/patches/1.2.3-handle-span-header.patch b/recipes/stduuid/all/patches/1.2.3-handle-span-header.patch new file mode 100644 index 00000000000000..fae5f65b66c25c --- /dev/null +++ b/recipes/stduuid/all/patches/1.2.3-handle-span-header.patch @@ -0,0 +1,29 @@ +diff --git a/include/uuid.h b/include/uuid.h +index d48059d..4d14e4d 100644 +--- a/include/uuid.h ++++ b/include/uuid.h +@@ -17,15 +17,6 @@ + #include + #include + +-#ifdef __cplusplus +- +-# if (__cplusplus >= 202002L) || (defined(_MSVC_LANG) && _MSVC_LANG >= 202002L) +-# define LIBUUID_CPP20_OR_GREATER +-# endif +- +-#endif +- +- + #ifdef LIBUUID_CPP20_OR_GREATER + #include + #else +@@ -66,7 +57,7 @@ + + namespace uuids + { +-#ifdef __cpp_lib_span ++#if defined(LIBUUID_CPP20_OR_GREATER) + template + using span = std::span; + #else From 656ed53b37e0cc03742a674605d8466f5feee791 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 11:26:43 +0200 Subject: [PATCH 1057/1140] (#20480) xorg-makedepend/all: bump deps * xorg-makedepend/all/: bump deps * xorg-makedepend/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-makedepend/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-makedepend/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/xorg-makedepend/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/xorg-makedepend/all/conanfile.py b/recipes/xorg-makedepend/all/conanfile.py index 6656dcd889cfff..a0024be22451a8 100644 --- a/recipes/xorg-makedepend/all/conanfile.py +++ b/recipes/xorg-makedepend/all/conanfile.py @@ -30,7 +30,7 @@ def requirements(self): self.requires("xorg-proto/2022.2") def build_requirements(self): - self.build_requires("pkgconf/1.7.4") + self.build_requires("pkgconf/2.0.3") def validate(self): if self.settings.os == "Windows": From 1f99f877841f8120d8c25adc8555a2ed3c4f195d Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 11:59:26 +0200 Subject: [PATCH 1058/1140] (#20481) simde/all: bump deps * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * simde/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/simde/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/simde/all/conanfile.py b/recipes/simde/all/conanfile.py index 9ede298cf49ed4..492893a0540fba 100644 --- a/recipes/simde/all/conanfile.py +++ b/recipes/simde/all/conanfile.py @@ -26,9 +26,9 @@ def package_id(self): self.info.clear() def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From bf5a0a97bae18cd3a0f1c8b0332a454cf64b2ee8 Mon Sep 17 00:00:00 2001 From: Daniel Date: Wed, 11 Oct 2023 12:17:59 +0200 Subject: [PATCH 1059/1140] (#20498) [config] Update conan version to 2.0.12 and 1.61.0 --- .c3i/config_v1.yml | 2 +- .c3i/config_v2.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index 9a047a70fde584..0d6518b391c5e2 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -3,7 +3,7 @@ id: 'conan-io/conan-center-index' conan: - version: 1.60.2 + version: 1.61.0 artifactory: url: "https://c3i.jfrog.io/c3i" diff --git a/.c3i/config_v2.yml b/.c3i/config_v2.yml index dae018bdc79517..7cb248b22318fb 100644 --- a/.c3i/config_v2.yml +++ b/.c3i/config_v2.yml @@ -3,7 +3,7 @@ id: 'conan-io/conan-center-index' conan: - version: 2.0.9 + version: 2.0.12 backup_sources: upload_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/" download_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/" From 124eee9a851a33cdc678b9ac89510735686fb923 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 12:45:12 +0200 Subject: [PATCH 1060/1140] (#20482) wayland-protocols/all: bump deps * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * wayland-protocols/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/wayland-protocols/all/conanfile.py | 2 +- recipes/wayland-protocols/all/test_package/conanfile.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/wayland-protocols/all/conanfile.py b/recipes/wayland-protocols/all/conanfile.py index 04a7ce005ea56e..5888f7b0c3ad17 100644 --- a/recipes/wayland-protocols/all/conanfile.py +++ b/recipes/wayland-protocols/all/conanfile.py @@ -27,7 +27,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} only supports Linux") def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.2") def layout(self): basic_layout(self, src_folder="src") diff --git a/recipes/wayland-protocols/all/test_package/conanfile.py b/recipes/wayland-protocols/all/test_package/conanfile.py index 06a3d74d242191..6004f71f932671 100644 --- a/recipes/wayland-protocols/all/test_package/conanfile.py +++ b/recipes/wayland-protocols/all/test_package/conanfile.py @@ -20,9 +20,9 @@ def requirements(self): self.requires("wayland/1.22.0") def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", default=False, check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") self.tool_requires("wayland/1.22.0") def layout(self): From 5d797555111d1c83a3d97b25ffb67c4c2d2aec07 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 12:57:13 +0200 Subject: [PATCH 1061/1140] (#20488) opusfile/all: bump deps * opusfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * opusfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * opusfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * opusfile/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/opusfile/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/opusfile/all/conanfile.py b/recipes/opusfile/all/conanfile.py index ec4750c742092b..e9cced5a0a16c1 100644 --- a/recipes/opusfile/all/conanfile.py +++ b/recipes/opusfile/all/conanfile.py @@ -57,7 +57,7 @@ def layout(self): def requirements(self): self.requires("ogg/1.3.5", transitive_headers=True) - self.requires("opus/1.3.1", transitive_headers=True) + self.requires("opus/1.4", transitive_headers=True) if self.options.http: self.requires("openssl/[>=1.1 <4]") @@ -69,7 +69,7 @@ def build_requirements(self): if not is_msvc(self): self.tool_requires("libtool/2.4.7") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From f405d4812cc06a5222eccd0790a92cce79d4b3e9 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 14:03:06 +0200 Subject: [PATCH 1062/1140] (#20489) cairo/meson: bump deps * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * cairo/meson: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * Update conanfile.py --- recipes/cairo/meson/conanfile.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/recipes/cairo/meson/conanfile.py b/recipes/cairo/meson/conanfile.py index f45ccd7290ad42..84d1dc2823d84c 100644 --- a/recipes/cairo/meson/conanfile.py +++ b/recipes/cairo/meson/conanfile.py @@ -99,7 +99,7 @@ def requirements(self): if self.options.with_lzo: self.requires("lzo/2.10") if self.options.with_zlib: - self.requires("zlib/1.2.13") + self.requires("zlib/[>=1.2.11 <2]") if self.options.with_freetype: self.requires("freetype/2.13.0") if self.options.with_fontconfig: @@ -107,7 +107,7 @@ def requirements(self): if self.options.with_png: self.requires("libpng/1.6.40") if self.options.with_glib: - self.requires("glib/2.77.0") + self.requires("glib/2.78.0") if self.settings.os == "Linux": if self.options.with_xlib or self.options.with_xlib_xrender or self.options.with_xcb: self.requires("xorg/system") @@ -135,9 +135,9 @@ def validate(self): ) def build_requirements(self): - self.tool_requires("meson/1.1.1") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", check_type=str): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) From a78e7ddbf52f2de2a9122922328d7e8dc8714a54 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Wed, 11 Oct 2023 15:34:01 +0200 Subject: [PATCH 1063/1140] (#20490) xorg-proto/all: bump deps * xorg-proto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-proto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * xorg-proto/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/xorg-proto/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/xorg-proto/all/conanfile.py b/recipes/xorg-proto/all/conanfile.py index b53e7215a23385..f20cc54f7acb5e 100644 --- a/recipes/xorg-proto/all/conanfile.py +++ b/recipes/xorg-proto/all/conanfile.py @@ -34,7 +34,7 @@ def _settings_build(self): def build_requirements(self): self.tool_requires("automake/1.16.5") self.tool_requires("xorg-macros/1.19.3") - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self._settings_build.os == "Windows": self.win_bash = True if not self.conf.get("tools.microsoft.bash:path", check_type=str): From 53d6979d3ca7ffef9dc2871fdbc3d24cc96a9ed6 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Wed, 11 Oct 2023 17:10:31 +0200 Subject: [PATCH 1064/1140] (#20517) [config] Uses CCI Bot as ower of Conan 1.x scheduled export results Signed-off-by: Uilian Ries --- .c3i/config_v1.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.c3i/config_v1.yml b/.c3i/config_v1.yml index 0d6518b391c5e2..802becc2d32bbc 100644 --- a/.c3i/config_v1.yml +++ b/.c3i/config_v1.yml @@ -59,7 +59,7 @@ tasks: timeout_seconds: 600 # Maximum time to wait for the multibranch job merge_messages: true # Merge messages from the multibranch job waited for scheduled_export_check: - report_issue_url: https://github.com/conan-io/conan-center-index/issues/2232 + report_issue_url: https://github.com/conan-io/conan-center-index/issues/20516 report_issue_append: false validate_infrastructure: macos_executors: 2 From 7930b650e7e5bdba9ad341ddb8eb6e76f0d7f91d Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Wed, 11 Oct 2023 19:08:25 +0200 Subject: [PATCH 1065/1140] (#20518) [docs] Add changelog for new conan versions Signed-off-by: Uilian Ries --- docs/changelog.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/changelog.md b/docs/changelog.md index e1a988f3032537..07a058bc923e10 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -1,5 +1,10 @@ # Changelog +### 11-Oct-2023 - 12:17 CEST + +- [feature] Update Conan 2.x to the version 2.0.12 in the CI +- [feature] Update Conan 1.x to the version 1.61.0 in the CI + ### 06-Oct-2023 - 10:15 CEST - [feature] Label PRs with version conflict properly From bf50294d71d06d1b696fb3cb370f0f9ece222efb Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 11 Oct 2023 19:39:10 +0200 Subject: [PATCH 1066/1140] (#19929) btyacc: conan v2 support * conan v2 support * typo * move cmake file under bin/cmake * and don't forget to change relative path * workaround in test package * Revert "workaround in test package" This reverts commit ba102b0e0eb88b5a3f9e41d66272258bfa239b4c. * improve test with conan v2 client * small change to regenerate binaries --- recipes/btyacc/all/CMakeLists.txt | 8 -- recipes/btyacc/all/conanfile.py | 74 +++++++++---------- .../btyacc/all/test_package/CMakeLists.txt | 9 +-- recipes/btyacc/all/test_package/conanfile.py | 53 +++++++++---- .../btyacc/all/test_v1_package/CMakeLists.txt | 10 +++ .../btyacc/all/test_v1_package/conanfile.py | 16 ++++ 6 files changed, 103 insertions(+), 67 deletions(-) delete mode 100644 recipes/btyacc/all/CMakeLists.txt create mode 100644 recipes/btyacc/all/test_v1_package/CMakeLists.txt create mode 100644 recipes/btyacc/all/test_v1_package/conanfile.py diff --git a/recipes/btyacc/all/CMakeLists.txt b/recipes/btyacc/all/CMakeLists.txt deleted file mode 100644 index b598faf845d1a3..00000000000000 --- a/recipes/btyacc/all/CMakeLists.txt +++ /dev/null @@ -1,8 +0,0 @@ -cmake_minimum_required(VERSION 3.2) - -project(btyacc_wrapper C) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS KEEP_RPATHS) - -add_subdirectory(source_subfolder) diff --git a/recipes/btyacc/all/conanfile.py b/recipes/btyacc/all/conanfile.py index 392605b08cf53b..d34d04d75a89b5 100644 --- a/recipes/btyacc/all/conanfile.py +++ b/recipes/btyacc/all/conanfile.py @@ -1,10 +1,11 @@ -import functools import os import textwrap -from conans import CMake, ConanFile, tools +from conan import ConanFile +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir, save -required_conan_version = ">=1.43.0" +required_conan_version = ">=1.53.0" class BtyaccConan(ConanFile): @@ -14,6 +15,7 @@ class BtyaccConan(ConanFile): description = "Backtracking yacc" topics = "yacc", "parser" license = "Unlicense" + package_type = "application" settings = "os", "arch", "compiler", "build_type" options = { "fPIC": [True, False], @@ -21,60 +23,54 @@ class BtyaccConan(ConanFile): default_options = { "fPIC": True, } - generators = "cmake" - exports_sources = "CMakeLists.txt" - no_copy_source = True - - @property - def _source_subfolder(self): - return "source_subfolder" def config_options(self): if self.settings.os == "Windows": del self.options.fPIC def configure(self): - del self.settings.compiler.libcxx - del self.settings.compiler.cppstd + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") + + def layout(self): + cmake_layout(self, src_folder="src") def source(self): - root = self._source_subfolder - get_args = self.conan_data["sources"][self.version] - tools.get(**get_args, destination=root, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def generate(self): + tc = CMakeToolchain(self) + tc.generate() def build(self): - self._configure_cmake().build() + cmake = CMake(self) + cmake.configure() + cmake.build() @property - def _variables(self): - return os.path.join("bin", "conan-official-btyacc-variables.cmake") + def _cmake_variables(self): + return os.path.join("bin", "cmake", f"conan-official-{self.name}-variables.cmake") def package(self): - self.copy("README", "licenses", self._source_subfolder) - self.copy("README.BYACC", "licenses", self._source_subfolder) - self._configure_cmake().install() - tools.rmdir(os.path.join(self.package_folder, "share")) - variables = os.path.join(self.package_folder, self._variables) + copy(self, "README*", src=self.source_folder, dst=os.path.join(self.package_folder, "licenses")) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "share")) content = textwrap.dedent("""\ - set(BTYACC_EXECUTABLE "${CMAKE_CURRENT_LIST_DIR}/btyacc") + set(BTYACC_EXECUTABLE "${CMAKE_CURRENT_LIST_DIR}/../btyacc") if(NOT EXISTS "${BTYACC_EXECUTABLE}") - set(BTYACC_EXECUTABLE "${BTYACC_EXECUTABLE}.exe") + set(BTYACC_EXECUTABLE "${BTYACC_EXECUTABLE}.exe") endif() """) - tools.save(variables, content) + save(self, os.path.join(self.package_folder, self._cmake_variables), content) def package_info(self): - bindir = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bindir}") - self.env_info.PATH.append(bindir) - self.cpp_info.build_modules["cmake"] = [self._variables] - self.cpp_info.build_modules["cmake_find_package"] = [self._variables] - self.cpp_info.build_modules["cmake_find_package_multi"] = \ - [self._variables] - self.cpp_info.builddirs = ["bin"] + self.cpp_info.includedirs = [] + self.cpp_info.libdirs = [] + self.cpp_info.set_property("cmake_build_modules", [self._cmake_variables]) + + # TODO: to remove after conan v2 + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) + self.cpp_info.build_modules["cmake"] = [self._cmake_variables] + self.cpp_info.build_modules["cmake_find_package"] = [self._cmake_variables] + self.cpp_info.build_modules["cmake_find_package_multi"] = [self._cmake_variables] diff --git a/recipes/btyacc/all/test_package/CMakeLists.txt b/recipes/btyacc/all/test_package/CMakeLists.txt index 80f7ff14861ac7..d2daa6eb3e6527 100644 --- a/recipes/btyacc/all/test_package/CMakeLists.txt +++ b/recipes/btyacc/all/test_package/CMakeLists.txt @@ -1,13 +1,11 @@ cmake_minimum_required(VERSION 3.1) +project(test_package LANGUAGES C) -project(test_package C) - -include("${CMAKE_BINARY_DIR}/conanbuildinfo.cmake") -conan_basic_setup(TARGETS KEEP_RPATHS) +enable_testing() find_package(btyacc REQUIRED CONFIG) if(NOT DEFINED BTYACC_EXECUTABLE) - message(FATAL_ERROR "BTYACC_EXECUTABLE is not defined") + message(FATAL_ERROR "BTYACC_EXECUTABLE is not defined") endif() set(bin "${PROJECT_BINARY_DIR}") @@ -24,7 +22,6 @@ add_custom_command( add_executable(test_package "${bin}/main.c") -enable_testing() add_test( NAME main COMMAND "${CMAKE_COMMAND}" -E echo "(())()(())" | test_package diff --git a/recipes/btyacc/all/test_package/conanfile.py b/recipes/btyacc/all/test_package/conanfile.py index 84bba6ad911d3b..fe825a55c4c797 100644 --- a/recipes/btyacc/all/test_package/conanfile.py +++ b/recipes/btyacc/all/test_package/conanfile.py @@ -1,23 +1,48 @@ -import functools -import os - -from conans import ConanFile, CMake, tools +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, CMakeDeps, cmake_layout +from conan.tools.env import VirtualBuildEnv, VirtualRunEnv class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" - generators = "cmake", "cmake_find_package_multi" + generators = "CMakeToolchain" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + # TODO: Only keep logic under if hasattr(self, "settings_build") after conan v2. + # Indeed, v1 pipeline of c3i uses 1 profile, which can't work with + # build_context_activated & build_context_build_modules of CMakeDeps + + def requirements(self): + if not hasattr(self, "settings_build"): + self.requires(self.tested_reference_str) + + def build_requirements(self): + if hasattr(self, "settings_build"): + self.tool_requires(self.tested_reference_str) - @functools.lru_cache(1) - def _configure_cmake(self): - cmake = CMake(self) - cmake.configure() - return cmake + def generate(self): + if hasattr(self, "settings_build"): + VirtualBuildEnv(self).generate() + deps = CMakeDeps(self) + deps.build_context_activated = ["btyacc"] + deps.build_context_build_modules = ["btyacc"] + deps.generate() + else: + if can_run(self): + VirtualRunEnv(self).generate(scope="build") + deps = CMakeDeps(self) + deps.generate() def build(self): - if not tools.cross_building(self): - self._configure_cmake().build() + if hasattr(self, "settings_build") or can_run(self): + cmake = CMake(self) + cmake.configure() + cmake.build() def test(self): - if not tools.cross_building(self): - self._configure_cmake().test() + if can_run(self): + self.run(f"ctest --output-on-failure -C {self.settings.build_type}", env="conanrun") diff --git a/recipes/btyacc/all/test_v1_package/CMakeLists.txt b/recipes/btyacc/all/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..c23ed5cfe6d983 --- /dev/null +++ b/recipes/btyacc/all/test_v1_package/CMakeLists.txt @@ -0,0 +1,10 @@ +cmake_minimum_required(VERSION 3.1) +project(test_v1_package) + +enable_testing() + +include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) +conan_basic_setup(TARGETS) + +add_subdirectory(${CMAKE_CURRENT_SOURCE_DIR}/../test_package + ${CMAKE_CURRENT_BINARY_DIR}/test_package) diff --git a/recipes/btyacc/all/test_v1_package/conanfile.py b/recipes/btyacc/all/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..1b50aeffd40ff3 --- /dev/null +++ b/recipes/btyacc/all/test_v1_package/conanfile.py @@ -0,0 +1,16 @@ +from conans import ConanFile, CMake, tools + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "cmake", "cmake_find_package_multi" + + def build(self): + if not tools.cross_building(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if not tools.cross_building(self): + self.run(f"ctest --output-on-failure -C {self.settings.build_type}", run_environment=True) From 1417143f09747364d42ce195846915a2fcafaec8 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 12 Oct 2023 02:57:52 +0900 Subject: [PATCH 1067/1140] (#19987) pdf-writer: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * pdf-writer: add recipe * update 4.5.12 * disable cpack --------- Co-authored-by: Rubén Rincón Blanco --- recipes/pdf-writer/all/conandata.yml | 9 ++ recipes/pdf-writer/all/conanfile.py | 101 ++++++++++++++++++ .../all/patches/4.5.12-0001-fix-cmake.patch | 42 ++++++++ .../all/test_package/CMakeLists.txt | 8 ++ .../pdf-writer/all/test_package/conanfile.py | 26 +++++ .../all/test_package/test_package.cpp | 26 +++++ recipes/pdf-writer/config.yml | 3 + 7 files changed, 215 insertions(+) create mode 100644 recipes/pdf-writer/all/conandata.yml create mode 100644 recipes/pdf-writer/all/conanfile.py create mode 100644 recipes/pdf-writer/all/patches/4.5.12-0001-fix-cmake.patch create mode 100644 recipes/pdf-writer/all/test_package/CMakeLists.txt create mode 100644 recipes/pdf-writer/all/test_package/conanfile.py create mode 100644 recipes/pdf-writer/all/test_package/test_package.cpp create mode 100644 recipes/pdf-writer/config.yml diff --git a/recipes/pdf-writer/all/conandata.yml b/recipes/pdf-writer/all/conandata.yml new file mode 100644 index 00000000000000..4775a5371af8ee --- /dev/null +++ b/recipes/pdf-writer/all/conandata.yml @@ -0,0 +1,9 @@ +sources: + "4.5.12": + url: "https://github.com/galkahana/PDF-Writer/archive/refs/tags/v4.5.12.tar.gz" + sha256: "40fcbaa66fc46fcb588ceda119ba8839ff6d2c886191ac5e68ed702475c7336e" +patches: + "4.5.12": + - patch_file: "patches/4.5.12-0001-fix-cmake.patch" + patch_description: "disable test/cpack, use cci package" + patch_type: "conan" diff --git a/recipes/pdf-writer/all/conanfile.py b/recipes/pdf-writer/all/conanfile.py new file mode 100644 index 00000000000000..976af4f35f8250 --- /dev/null +++ b/recipes/pdf-writer/all/conanfile.py @@ -0,0 +1,101 @@ +from conan import ConanFile +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.gnu import PkgConfigDeps +import os + +required_conan_version = ">=1.53.0" + +class PDFWriterConan(ConanFile): + name = "pdf-writer" + description = "High performance library for creating, modiyfing and parsing PDF files in C++" + license = "Apache-2.0" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/galkahana/PDF-Writer" + topics = ("pdf", "writer") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + "with_png": [True, False], + "with_jpeg": [True, False], + "with_tiff": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + "with_png": True, + "with_jpeg": True, + "with_tiff": True, + } + + @property + def _min_cppstd(self): + return 11 + + def export_sources(self): + export_conandata_patches(self) + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def requirements(self): + self.requires("freetype/2.13.0") + self.requires("libaesgm/2013.1.1") + self.requires("zlib/[>=1.2.11 <2]") + if self.options.with_png: + self.requires("libjpeg/9e") + if self.options.with_jpeg: + self.requires("libpng/1.6.40") + if self.options.with_tiff: + self.requires("libtiff/4.6.0") + + def validate(self): + if self.settings.compiler.cppstd: + check_min_cppstd(self, self._min_cppstd) + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["USE_BUNDLED"] = False + tc.generate() + deps = PkgConfigDeps(self) + deps.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + apply_conandata_patches(self) + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + self.cpp_info.set_property("cmake_file_name", "PDFHummus") + self.cpp_info.set_property("cmake_target_name", "PDFHummus::PDFWriter") + self.cpp_info.libs = ["PDFWriter"] + self.cpp_info.requires = ["freetype::freetype", "zlib::zlib", "libaesgm::libaesgm"] + if self.options.with_png: + self.cpp_info.requires.append("libjpeg::libjpeg") + if self.options.with_jpeg: + self.cpp_info.requires.append("libpng::libpng") + if self.options.with_tiff: + self.cpp_info.requires.append("libtiff::libtiff") diff --git a/recipes/pdf-writer/all/patches/4.5.12-0001-fix-cmake.patch b/recipes/pdf-writer/all/patches/4.5.12-0001-fix-cmake.patch new file mode 100644 index 00000000000000..02aec77b37c06b --- /dev/null +++ b/recipes/pdf-writer/all/patches/4.5.12-0001-fix-cmake.patch @@ -0,0 +1,42 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 8dcb27d..ca69cdf 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -153,21 +153,21 @@ endif(NOT USE_BUNDLED) + + ADD_SUBDIRECTORY(PDFWriter) + +-if(PROJECT_IS_TOP_LEVEL) ++if(0) + # avoid installing the testing lib altogether when included in another project. + # it's annoying when in parent all, and more annoying to then get the tests added + # to the parent project ctest. + enable_testing() + ADD_SUBDIRECTORY(PDFWriterTesting) +-endif(PROJECT_IS_TOP_LEVEL) ++endif() + +-include(InstallRequiredSystemLibraries) +-set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE") +-set(CPACK_PACKAGE_VERSION_MAJOR "${PDFHummus_VERSION_MAJOR}") +-set(CPACK_PACKAGE_VERSION_MINOR "${PDFHummus_VERSION_MINOR}") +-set(CPACK_SOURCE_GENERATOR "ZIP") +-set(CPACK_GENERATOR "ZIP") +-include(CPack) ++# include(InstallRequiredSystemLibraries) ++# set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/LICENSE") ++# set(CPACK_PACKAGE_VERSION_MAJOR "${PDFHummus_VERSION_MAJOR}") ++# set(CPACK_PACKAGE_VERSION_MINOR "${PDFHummus_VERSION_MINOR}") ++# set(CPACK_SOURCE_GENERATOR "ZIP") ++# set(CPACK_GENERATOR "ZIP") ++# include(CPack) + + install(EXPORT PDFHummusTargets + FILE PDFHummusTargets.cmake +@@ -196,4 +196,4 @@ install(FILES + export(EXPORT PDFHummusTargets + FILE "${CMAKE_CURRENT_BINARY_DIR}/PDFHummusTargets.cmake" + NAMESPACE PDFHummus:: +-) +\ No newline at end of file ++) diff --git a/recipes/pdf-writer/all/test_package/CMakeLists.txt b/recipes/pdf-writer/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..079a134d31c95f --- /dev/null +++ b/recipes/pdf-writer/all/test_package/CMakeLists.txt @@ -0,0 +1,8 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(PDFHummus REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE PDFHummus::PDFWriter) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) diff --git a/recipes/pdf-writer/all/test_package/conanfile.py b/recipes/pdf-writer/all/test_package/conanfile.py new file mode 100644 index 00000000000000..a9fb96656f2039 --- /dev/null +++ b/recipes/pdf-writer/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/pdf-writer/all/test_package/test_package.cpp b/recipes/pdf-writer/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..aa251ff45f3855 --- /dev/null +++ b/recipes/pdf-writer/all/test_package/test_package.cpp @@ -0,0 +1,26 @@ +#include +#include "PDFWriter/PDFWriter.h" + +int main(void) { + PDFWriter pdfWriter; + + auto status = pdfWriter.StartPDF( + "test_package.pdf", + ePDFVersion13, + LogConfiguration(true, true, "AppendPagesTestLog.txt") + ); + + if (status != PDFHummus::eSuccess) { + std::cerr << "failed to create pdf" << std::endl; + return 1; + } + + status = pdfWriter.EndPDF(); + + if (status != PDFHummus::eSuccess) { + std::cerr << "failed to close pdf" << std::endl; + return 1; + } + + return 0; +} diff --git a/recipes/pdf-writer/config.yml b/recipes/pdf-writer/config.yml new file mode 100644 index 00000000000000..f15bafabcf2283 --- /dev/null +++ b/recipes/pdf-writer/config.yml @@ -0,0 +1,3 @@ +versions: + "4.5.12": + folder: all From 07e21797c5b143ab567522f00e7cb7f8ed259a80 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 11 Oct 2023 21:55:34 +0300 Subject: [PATCH 1068/1140] (#20317) cub: fix project URL --- recipes/cub/all/conanfile.py | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) diff --git a/recipes/cub/all/conanfile.py b/recipes/cub/all/conanfile.py index 0576f4a61be0df..c19b0eb6a89020 100644 --- a/recipes/cub/all/conanfile.py +++ b/recipes/cub/all/conanfile.py @@ -7,7 +7,7 @@ from conan.tools.layout import basic_layout from conan.tools.scm import Version -required_conan_version = ">=1.50.0" +required_conan_version = ">=1.52.0" class CubConan(ConanFile): @@ -15,8 +15,9 @@ class CubConan(ConanFile): description = "Cooperative primitives for CUDA C++" license = "BSD 3-Clause" url = "https://github.com/conan-io/conan-center-index" - homepage = "https://github.com/project/cub" - topics = ("algorithms", "cuda", "gpu", "nvidia", "nvidia-hpc-sdk") + homepage = "https://github.com/NVIDIA/cub" + topics = ("algorithms", "cuda", "gpu", "nvidia", "nvidia-hpc-sdk", "header-only") + package_type = "header-library" settings = "os", "arch", "compiler", "build_type" no_copy_source = True @@ -54,22 +55,18 @@ def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): - copy( - self, - pattern="LICENSE.TXT", - dst=os.path.join(self.package_folder, "licenses"), - src=self.source_folder, - ) - copy( - self, - pattern="*.cuh", - dst=os.path.join(self.package_folder, "include", "cub"), - src=os.path.join(self.source_folder, "cub"), - ) + copy(self, "LICENSE.TXT", + dst=os.path.join(self.package_folder, "licenses"), + src=self.source_folder) + copy(self, "*.cuh", + dst=os.path.join(self.package_folder, "include", "cub"), + src=os.path.join(self.source_folder, "cub")) def package_info(self): self.cpp_info.bindirs = [] + self.cpp_info.frameworkdirs = [] self.cpp_info.libdirs = [] + self.cpp_info.resdirs = [] # Follows the naming conventions of the official CMake config file: # https://github.com/NVIDIA/cub/blob/main/cub/cmake/cub-config.cmake From ccaedd5038058ba2e09ccfaf19d2cd5c9a54dcb1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Wed, 11 Oct 2023 23:14:02 +0300 Subject: [PATCH 1069/1140] (#20321) libsgp4: add v1.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/libsgp4/all/conandata.yml | 11 +++++--- .../all/patches/1.0-fix-cmake-files.patch | 27 +++++++++++++++++++ ...s.patch => 20191207-fix-cmake-files.patch} | 2 +- recipes/libsgp4/config.yml | 2 ++ 4 files changed, 38 insertions(+), 4 deletions(-) create mode 100644 recipes/libsgp4/all/patches/1.0-fix-cmake-files.patch rename recipes/libsgp4/all/patches/{fix-cmake-files.patch => 20191207-fix-cmake-files.patch} (97%) diff --git a/recipes/libsgp4/all/conandata.yml b/recipes/libsgp4/all/conandata.yml index acdc9ee85a4536..427372b5ece502 100644 --- a/recipes/libsgp4/all/conandata.yml +++ b/recipes/libsgp4/all/conandata.yml @@ -1,7 +1,12 @@ sources: + "1.0": + url: "https://github.com/dnwrnr/sgp4/archive/refs/tags/v1.0.tar.gz" + sha256: "34cdcce25adbe25234b5113b06537bec9d6e6c2a74f70919c9d71710dc3773f4" "20191207": - url: "https://github.com/dnwrnr/sgp4/archive/f5cb54b382a5b4787432ab5b9a1e83de1a224610.zip" - sha256: "e8ce05b5e62ffe81e2e07020ac693cb5f3eb7dd90587e9c2203639564c030495" + url: "https://github.com/dnwrnr/sgp4/archive/f5cb54b382a5b4787432ab5b9a1e83de1a224610.tar.gz" + sha256: "260f3524ead05c191bdf19c2f018376394b4856d2fbcc1ed63bcdd475b81c338" patches: + "1.0": + - patch_file: "patches/1.0-fix-cmake-files.patch" "20191207": - - patch_file: "patches/fix-cmake-files.patch" + - patch_file: "patches/20191207-fix-cmake-files.patch" diff --git a/recipes/libsgp4/all/patches/1.0-fix-cmake-files.patch b/recipes/libsgp4/all/patches/1.0-fix-cmake-files.patch new file mode 100644 index 00000000000000..0b0946d73305a1 --- /dev/null +++ b/recipes/libsgp4/all/patches/1.0-fix-cmake-files.patch @@ -0,0 +1,27 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -27,8 +27,3 @@ + include_directories(libsgp4) + + add_subdirectory(libsgp4) +-add_subdirectory(sattrack) +-add_subdirectory(runtest) +-add_subdirectory(passpredict) +- +-file(COPY SGP4-VER.TLE DESTINATION ${PROJECT_BINARY_DIR}) +--- a/libsgp4/CMakeLists.txt ++++ b/libsgp4/CMakeLists.txt +@@ -35,7 +35,10 @@ + Vector.h + ) + +-add_library(sgp4 STATIC ${SRCS} ${INCS}) +-add_library(sgp4s SHARED ${SRCS} ${INCS}) +-install( TARGETS sgp4s LIBRARY DESTINATION lib ) ++add_library(sgp4 ${SRCS}) ++if(BUILD_SHARED_LIBS) ++ set_target_properties(sgp4 PROPERTIES OUTPUT_NAME sgp4s) ++endif() ++include(GNUInstallDirs) ++install(TARGETS sgp4) + install( FILES ${INCS} DESTINATION include/SGP4 ) diff --git a/recipes/libsgp4/all/patches/fix-cmake-files.patch b/recipes/libsgp4/all/patches/20191207-fix-cmake-files.patch similarity index 97% rename from recipes/libsgp4/all/patches/fix-cmake-files.patch rename to recipes/libsgp4/all/patches/20191207-fix-cmake-files.patch index c465c328534391..7874f13bef92ac 100644 --- a/recipes/libsgp4/all/patches/fix-cmake-files.patch +++ b/recipes/libsgp4/all/patches/20191207-fix-cmake-files.patch @@ -2,7 +2,7 @@ +++ b/CMakeLists.txt @@ -1,16 +1,7 @@ -CMAKE_MINIMUM_REQUIRED(VERSION 2.8) -+CMAKE_MINIMUM_REQUIRED(VERSION 3.8) ++CMAKE_MINIMUM_REQUIRED(VERSION 3.15) PROJECT(SGP4) -include(CheckCXXCompilerFlag) diff --git a/recipes/libsgp4/config.yml b/recipes/libsgp4/config.yml index 72af20020d59f6..323fde5efbec23 100644 --- a/recipes/libsgp4/config.yml +++ b/recipes/libsgp4/config.yml @@ -1,3 +1,5 @@ versions: + "1.0": + folder: all "20191207": folder: all From 2d85bae60f1cf52984241286edc2468d88df910c Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Wed, 11 Oct 2023 23:38:54 +0200 Subject: [PATCH 1070/1140] (#20351) s2geometry: do not suggest unofficial CMake imported target + cleanup a little bit recipe * honor C++ standard from profile * default CMake target defined by conan and few minor recipe cleanup - do not define custom CMake target since upstream doesn't install a CMake config file - cleanup topics - bump required_conan_version to 1.54.0 because upstream defines BUILD_SHARED_LIBS as an option in its CMakeLists - prefer to not scatter min compiler version logic * prefer tar.gz tarball --- recipes/s2geometry/all/conandata.yml | 8 ++--- recipes/s2geometry/all/conanfile.py | 29 +++++++++---------- .../all/patches/bump_cmake_cxx_standard.patch | 2 +- .../all/test_package/CMakeLists.txt | 28 +++++++++--------- .../s2geometry/all/test_package/conanfile.py | 7 ++--- 5 files changed, 34 insertions(+), 40 deletions(-) diff --git a/recipes/s2geometry/all/conandata.yml b/recipes/s2geometry/all/conandata.yml index 811d215efcb5e6..2320f21a27e4cf 100644 --- a/recipes/s2geometry/all/conandata.yml +++ b/recipes/s2geometry/all/conandata.yml @@ -1,9 +1,9 @@ sources: - 0.10.0: - url: https://github.com/google/s2geometry/archive/refs/tags/v0.10.0.zip - sha256: d03ae5566e9957c5b3bc6e0e62603370d1450feaf093d204d27b7af9e4d14909 + "0.10.0": + url: "https://github.com/google/s2geometry/archive/refs/tags/v0.10.0.tar.gz" + sha256: "1c17b04f1ea20ed09a67a83151ddd5d8529716f509dde49a8190618d70532a3d" patches: - 0.10.0: + "0.10.0": - patch_description: "Bump CMAKE_CXX_STANDARD to 14" patch_file: "patches/bump_cmake_cxx_standard.patch" patch_source: "https://github.com/google/s2geometry/issues/317" diff --git a/recipes/s2geometry/all/conanfile.py b/recipes/s2geometry/all/conanfile.py index 7a3ed3284ec7c9..31e07fd7e0dc37 100644 --- a/recipes/s2geometry/all/conanfile.py +++ b/recipes/s2geometry/all/conanfile.py @@ -5,10 +5,10 @@ from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import get, copy, export_conandata_patches, apply_conandata_patches -from conan.tools.microsoft import check_min_vs, is_msvc +from conan.tools.microsoft import is_msvc from conan.tools.scm import Version -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.54.0" class S2GeometryConan(ConanFile): @@ -17,7 +17,7 @@ class S2GeometryConan(ConanFile): license = "Apache-2.0" url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/google/s2geometry" - topics = ("geometry", "s2", "spherical-geometry", "spatial-indexing") + topics = ("geometry", "spherical-geometry", "spatial-indexing") package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { @@ -39,6 +39,8 @@ def _compilers_minimum_version(self): "gcc": "5", "clang": "7", "apple-clang": "10", + "Visual Studio": "15", + "msvc": "191", } def export_sources(self): @@ -62,15 +64,15 @@ def requirements(self): def validate(self): if self.settings.compiler.cppstd: check_min_cppstd(self, self._min_cppstd) - check_min_vs(self, 191) - if not is_msvc(self): - 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." - ) + + 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." + ) + if is_msvc(self) and self.options.shared: - raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared on Visual Studio and msvc.") + raise ConanInvalidConfiguration(f"{self.ref} can not be built as shared with Visual Studio") def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -96,8 +98,3 @@ def package(self): def package_info(self): self.cpp_info.libs = ["s2"] - self.cpp_info.set_property("cmake_target_name", "s2") - - # TODO: to remove in conan v2 once cmake_find_package_* generators removed - self.cpp_info.names["cmake_find_package"] = "s2" - self.cpp_info.names["cmake_find_package_multi"] = "s2" diff --git a/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch b/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch index 50b168d636d588..4bb8e07c259085 100644 --- a/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch +++ b/recipes/s2geometry/all/patches/bump_cmake_cxx_standard.patch @@ -7,7 +7,7 @@ index f080b4b..b2699ee 100644 # end up defined differently. There is probably a better way to achieve # this than assuming what absl used. -set(CMAKE_CXX_STANDARD 11) -+set(CMAKE_CXX_STANDARD 14) ++set(CMAKE_CXX_STANDARD 14 CACHE STRING "The C++ standard to build with") set(CMAKE_CXX_STANDARD_REQUIRED ON) # No compiler-specific extensions, i.e. -std=c++11, not -std=gnu++11. set(CMAKE_CXX_EXTENSIONS OFF) diff --git a/recipes/s2geometry/all/test_package/CMakeLists.txt b/recipes/s2geometry/all/test_package/CMakeLists.txt index 6727aedf56df7a..cc8c0e21436028 100644 --- a/recipes/s2geometry/all/test_package/CMakeLists.txt +++ b/recipes/s2geometry/all/test_package/CMakeLists.txt @@ -1,20 +1,18 @@ cmake_minimum_required(VERSION 3.15) - -project(test_package CXX) - -set(CMAKE_CXX_STANDARD 14) -set(CMAKE_CXX_STANDARD_REQUIRED ON) +project(test_package LANGUAGES CXX) find_package(s2geometry REQUIRED CONFIG) -if (MSVC) - # Use unsigned characters - add_definitions(-J) - # Make sure cmath header defines things like M_PI - add_definitions(-D_USE_MATH_DEFINES) - # Make sure Windows doesn't define min/max macros that interfere with STL - add_definitions(-DNOMINMAX) -endif () - add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE s2) +target_link_libraries(${PROJECT_NAME} PRIVATE s2geometry::s2geometry) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_14) +if(MSVC) + # Use unsigned characters + target_compile_options(${PROJECT_NAME} PRIVATE "-J") + target_compile_definitions(${PROJECT_NAME} PRIVATE + # Make sure cmath header defines things like M_PI + "_USE_MATH_DEFINES" + # Make sure Windows doesn't define min/max macros that interfere with STL + "NOMINMAX" + ) +endif() diff --git a/recipes/s2geometry/all/test_package/conanfile.py b/recipes/s2geometry/all/test_package/conanfile.py index 02eb5ce439fb40..3a91c9439218e3 100644 --- a/recipes/s2geometry/all/test_package/conanfile.py +++ b/recipes/s2geometry/all/test_package/conanfile.py @@ -4,18 +4,17 @@ import os -# It will become the standard on Conan 2.x class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" test_type = "explicit" - def requirements(self): - self.requires(self.tested_reference_str) - def layout(self): cmake_layout(self) + def requirements(self): + self.requires(self.tested_reference_str) + def build(self): cmake = CMake(self) cmake.configure() From c3861134d10f3ecc2dad63d00739317ad17280cd Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 12 Oct 2023 00:16:09 +0200 Subject: [PATCH 1071/1140] (#20412) tixi3/all: bump deps, fix test package * tixi3/all: bump deps, fix test package * fix lint issues --- recipes/tixi3/all/conanfile.py | 22 +++++-------------- recipes/tixi3/all/test_package/CMakeLists.txt | 8 +++---- recipes/tixi3/all/test_package/conanfile.py | 9 +++++--- .../tixi3/all/test_v1_package/CMakeLists.txt | 10 --------- .../tixi3/all/test_v1_package/conanfile.py | 19 ---------------- 5 files changed, 16 insertions(+), 52 deletions(-) delete mode 100644 recipes/tixi3/all/test_v1_package/CMakeLists.txt delete mode 100644 recipes/tixi3/all/test_v1_package/conanfile.py diff --git a/recipes/tixi3/all/conanfile.py b/recipes/tixi3/all/conanfile.py index b8124c51186f67..f552a4f54ec24a 100644 --- a/recipes/tixi3/all/conanfile.py +++ b/recipes/tixi3/all/conanfile.py @@ -33,12 +33,12 @@ def generate(self): deps.generate() def requirements(self): - self.requires("libxml2/2.9.14") + self.requires("libxml2/2.11.4") self.requires("libxslt/1.1.34") - self.requires("libcurl/7.84.0") + self.requires("libcurl/8.2.1") def layout(self): - cmake_layout(self) + cmake_layout(self, src_folder="src") def config_options(self): if self.settings.os == "Windows": @@ -46,20 +46,10 @@ def config_options(self): def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass - + self.options.rm_safe("fPIC") # tixi is a c library - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def export_sources(self): for patch in self.conan_data.get("patches", {}).get(self.version, []): diff --git a/recipes/tixi3/all/test_package/CMakeLists.txt b/recipes/tixi3/all/test_package/CMakeLists.txt index c9358ca94ac503..9d54bfb6f94d4c 100644 --- a/recipes/tixi3/all/test_package/CMakeLists.txt +++ b/recipes/tixi3/all/test_package/CMakeLists.txt @@ -1,7 +1,7 @@ -cmake_minimum_required(VERSION 3.12) -project(Tixi-Conan-TestPackage CXX) +cmake_minimum_required(VERSION 3.15) +project(test_package CXX) find_package(tixi3 REQUIRED) -add_executable(tixi3_conan_test main.cpp) -target_link_libraries(tixi3_conan_test PRIVATE tixi3) +add_executable(${PROJECT_NAME} main.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE tixi3) diff --git a/recipes/tixi3/all/test_package/conanfile.py b/recipes/tixi3/all/test_package/conanfile.py index 0e104e3f9a6621..ef5d7042163ecc 100644 --- a/recipes/tixi3/all/test_package/conanfile.py +++ b/recipes/tixi3/all/test_package/conanfile.py @@ -1,13 +1,16 @@ - from conan import ConanFile -from conan.tools.cmake import CMake, cmake_layout from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake import os class TestPackageConan(ConanFile): settings = "os", "arch", "compiler", "build_type" generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) def layout(self): cmake_layout(self) @@ -19,5 +22,5 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindirs[0], "tixi3_conan_test") + bin_path = os.path.join(self.cpp.build.bindir, "test_package") self.run(bin_path, env="conanrun") diff --git a/recipes/tixi3/all/test_v1_package/CMakeLists.txt b/recipes/tixi3/all/test_v1_package/CMakeLists.txt deleted file mode 100644 index 80f9071294122b..00000000000000 --- a/recipes/tixi3/all/test_v1_package/CMakeLists.txt +++ /dev/null @@ -1,10 +0,0 @@ -cmake_minimum_required(VERSION 3.1.2) -project(tixi3_conan_test CXX) - -include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake) -conan_basic_setup(TARGETS) - -find_package(tixi3 REQUIRED CONFIG) - -add_executable(tixi3_conan_test ../test_package/main.cpp) -target_link_libraries(tixi3_conan_test tixi3) diff --git a/recipes/tixi3/all/test_v1_package/conanfile.py b/recipes/tixi3/all/test_v1_package/conanfile.py deleted file mode 100644 index d620b7c8ee1ca6..00000000000000 --- a/recipes/tixi3/all/test_v1_package/conanfile.py +++ /dev/null @@ -1,19 +0,0 @@ -import os - -from conan.tools.build import cross_building -from conans import ConanFile, CMake - - -class TestPackageConan(ConanFile): - settings = "os", "compiler", "build_type", "arch" - generators = "cmake", "cmake_find_package_multi" - - def build(self): - cmake = CMake(self) - cmake.configure() - cmake.build() - - def test(self): - if not cross_building(self): - bin_path = os.path.join("bin", "tixi3_conan_test") - self.run(bin_path, run_environment=True) From db98450aa9dc549e70d8f357da5afe18e95f4035 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 12 Oct 2023 00:31:22 +0200 Subject: [PATCH 1072/1140] (#20414) yder: fix macOS build, bump libsystemd MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * yder: fix macOS build, bump libsystemd * Further fixes --------- Co-authored-by: Rubén Rincón Blanco --- recipes/yder/all/conanfile.py | 22 ++++++++-------------- 1 file changed, 8 insertions(+), 14 deletions(-) diff --git a/recipes/yder/all/conanfile.py b/recipes/yder/all/conanfile.py index d027f053ed062e..ffe23774e69d2f 100644 --- a/recipes/yder/all/conanfile.py +++ b/recipes/yder/all/conanfile.py @@ -5,7 +5,7 @@ import os import textwrap -required_conan_version = ">=1.52.0" +required_conan_version = ">=1.53.0" class YderConan(ConanFile): @@ -15,6 +15,8 @@ class YderConan(ConanFile): topics = ("logging", "stdout", "file", "journald", "systemd") license = "LGPL-2.1-or-later" url = "https://github.com/conan-io/conan-center-index" + + package_type = "library" settings = "os", "arch", "compiler", "build_type" options = { "shared": [True, False], @@ -30,27 +32,19 @@ class YderConan(ConanFile): def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + if self.settings.os != "Linux": del self.options.with_libsystemd def configure(self): if self.options.shared: - try: - del self.options.fPIC - except Exception: - pass - try: - del self.settings.compiler.libcxx - except Exception: - pass - try: - del self.settings.compiler.cppstd - except Exception: - pass + self.options.rm_safe("fPIC") + self.settings.rm_safe("compiler.cppstd") + self.settings.rm_safe("compiler.libcxx") def requirements(self): self.requires("orcania/2.3.1") if self.options.get_safe("with_libsystemd"): - self.requires("libsystemd/251.4") + self.requires("libsystemd/253.10") def source(self): get(self, **self.conan_data["sources"][self.version], From 1524fda944120bbca8411cac0b7a430db466ba09 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 12 Oct 2023 07:43:40 +0900 Subject: [PATCH 1073/1140] (#20416) fastnoise2: add recipe * fastnoise2: add recipe * fix debug build * remove pdb files * rm pdb files in bin folder * link math lib --- recipes/fastnoise2/all/conandata.yml | 4 + recipes/fastnoise2/all/conanfile.py | 92 +++++++++++++++++++ .../all/test_package/CMakeLists.txt | 9 ++ .../fastnoise2/all/test_package/conanfile.py | 25 +++++ .../all/test_package/test_package.cpp | 11 +++ recipes/fastnoise2/config.yml | 3 + 6 files changed, 144 insertions(+) create mode 100644 recipes/fastnoise2/all/conandata.yml create mode 100644 recipes/fastnoise2/all/conanfile.py create mode 100644 recipes/fastnoise2/all/test_package/CMakeLists.txt create mode 100644 recipes/fastnoise2/all/test_package/conanfile.py create mode 100644 recipes/fastnoise2/all/test_package/test_package.cpp create mode 100644 recipes/fastnoise2/config.yml diff --git a/recipes/fastnoise2/all/conandata.yml b/recipes/fastnoise2/all/conandata.yml new file mode 100644 index 00000000000000..63afd14b046743 --- /dev/null +++ b/recipes/fastnoise2/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "0.10.0-alpha": + url: "https://github.com/Auburn/FastNoise2/archive/v0.10.0-alpha.tar.gz" + sha256: "8e1331425d6372e65e73775e13fedd367ae5999ec5616036b99df33434e3b527" diff --git a/recipes/fastnoise2/all/conanfile.py b/recipes/fastnoise2/all/conanfile.py new file mode 100644 index 00000000000000..15602b9b084997 --- /dev/null +++ b/recipes/fastnoise2/all/conanfile.py @@ -0,0 +1,92 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import get, copy, rmdir, rm +from conan.tools.build import check_min_cppstd +from conan.tools.scm import Version +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout +import os + +required_conan_version = ">=1.53.0" + +class Fastnoise2Conan(ConanFile): + name = "fastnoise2" + description = "Modular node graph based noise generation library using SIMD, C++17 and templates" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/Auburn/FastNoise2" + topics = ("procedural-generation", "terrain-generation", "noise") + package_type = "library" + settings = "os", "arch", "compiler", "build_type" + options = { + "shared": [True, False], + "fPIC": [True, False], + } + default_options = { + "shared": False, + "fPIC": True, + } + + @property + def _min_cppstd(self): + return 17 + + @property + def _compilers_minimum_version(self): + return { + "gcc": "8", + "clang": "7", + "apple-clang": "12", + "Visual Studio": "16", + "msvc": "192", + } + + def config_options(self): + if self.settings.os == "Windows": + del self.options.fPIC + + def configure(self): + if self.options.shared: + self.options.rm_safe("fPIC") + + def layout(self): + cmake_layout(self, src_folder="src") + + def validate(self): + if self.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) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["FASTNOISE2_NOISETOOL"] = False + tc.generate() + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def package(self): + copy(self, pattern="LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + rm(self, "*.pdb", os.path.join(self.package_folder, "bin")) + rm(self, "*.pdb", os.path.join(self.package_folder, "lib")) + + def package_info(self): + lib_suffix = "D" if self.settings.build_type == "Debug" else "" + self.cpp_info.libs = [f"FastNoise{lib_suffix}"] + + self.cpp_info.set_property("cmake_file_name", "FastNoise2") + self.cpp_info.set_property("cmake_target_name", "FastNoise2::FastNoise") + + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") diff --git a/recipes/fastnoise2/all/test_package/CMakeLists.txt b/recipes/fastnoise2/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..4c5f6ffc5d5fee --- /dev/null +++ b/recipes/fastnoise2/all/test_package/CMakeLists.txt @@ -0,0 +1,9 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package LANGUAGES CXX) + +find_package(FastNoise2 REQUIRED CONFIG) + +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE FastNoise2::FastNoise) +target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_17) + diff --git a/recipes/fastnoise2/all/test_package/conanfile.py b/recipes/fastnoise2/all/test_package/conanfile.py new file mode 100644 index 00000000000000..f5cf204295e195 --- /dev/null +++ b/recipes/fastnoise2/all/test_package/conanfile.py @@ -0,0 +1,25 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/fastnoise2/all/test_package/test_package.cpp b/recipes/fastnoise2/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..0dd8b950d971d8 --- /dev/null +++ b/recipes/fastnoise2/all/test_package/test_package.cpp @@ -0,0 +1,11 @@ +#include "FastNoise/FastNoise.h" + +int main() { + auto fnSimplex = FastNoise::New(); + auto fnFractal = FastNoise::New(); + + fnFractal->SetSource( fnSimplex ); + fnFractal->SetOctaveCount( 5 ); + + return 0; +} diff --git a/recipes/fastnoise2/config.yml b/recipes/fastnoise2/config.yml new file mode 100644 index 00000000000000..a75277535cb78a --- /dev/null +++ b/recipes/fastnoise2/config.yml @@ -0,0 +1,3 @@ +versions: + "0.10.0-alpha": + folder: all From b28e0f691232d6a44c275cb40825548188839fe5 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 01:11:45 +0200 Subject: [PATCH 1074/1140] (#20426) tcp-wrappers: relocatable shared lib on macOS + handle windows build machine + raise in validate() instead of configure() * move checks to validate() * add msys2 to build requirements if build machine is Windows * relocatable shared lib on macOS --- recipes/tcp-wrappers/all/conanfile.py | 22 ++++++++++++++++------ 1 file changed, 16 insertions(+), 6 deletions(-) diff --git a/recipes/tcp-wrappers/all/conanfile.py b/recipes/tcp-wrappers/all/conanfile.py index 43c0049890c3cc..654c207b466b2a 100644 --- a/recipes/tcp-wrappers/all/conanfile.py +++ b/recipes/tcp-wrappers/all/conanfile.py @@ -2,7 +2,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.apple import is_apple_os +from conan.tools.apple import fix_apple_shared_install_name, is_apple_os from conan.tools.build import cross_building from conan.tools.files import apply_conandata_patches, chdir, copy, export_conandata_patches, get from conan.tools.gnu import Autotools, AutotoolsToolchain @@ -31,6 +31,10 @@ class TcpWrappersConan(ConanFile): "fPIC": True, } + @property + def _settings_build(self): + return getattr(self, "settings_build", self.settings) + def export_sources(self): export_conandata_patches(self) @@ -39,8 +43,6 @@ def config_options(self): del self.options.fPIC def configure(self): - if is_msvc(self): - raise ConanInvalidConfiguration("Visual Studio is not supported") if self.options.shared: self.options.rm_safe("fPIC") self.settings.rm_safe("compiler.libcxx") @@ -50,9 +52,17 @@ def layout(self): basic_layout(self, src_folder="src") def validate(self): + if is_msvc(self): + raise ConanInvalidConfiguration("Visual Studio is not supported") if cross_building(self): raise ConanInvalidConfiguration("Cross-building is not current supported.") + def build_requirements(self): + if self._settings_build.os == "Windows": + self.win_bash = True + if not self.conf.get("tools.microsoft.bash:subsystem", check_type=str): + self.tool_requires("msys2/cci.latest") + def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) @@ -101,10 +111,10 @@ def package(self): src=self.source_folder, dst=os.path.join(self.package_folder, "lib"), keep_path=False) + fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["wrap"] - bin_path = os.path.join(self.package_folder, "bin") - self.output.info(f"Appending PATH environment variable: {bin_path}") - self.env_info.PATH.append(bin_path) + # TODO: to remove once conan v1 not supported anymore + self.env_info.PATH.append(os.path.join(self.package_folder, "bin")) From ed0dc672c0e97a796cb8e9732370b45ec24128cd Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 01:42:12 +0200 Subject: [PATCH 1075/1140] (#20430) twitch-native-ipc: move checks to validate() --- recipes/twitch-native-ipc/all/conanfile.py | 28 ++++++++++++---------- 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/recipes/twitch-native-ipc/all/conanfile.py b/recipes/twitch-native-ipc/all/conanfile.py index 72b9b555dec987..3f478da041a705 100644 --- a/recipes/twitch-native-ipc/all/conanfile.py +++ b/recipes/twitch-native-ipc/all/conanfile.py @@ -5,7 +5,7 @@ from conan.tools.build import check_min_cppstd, stdcpp_library from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, rm -from conan.tools.microsoft import is_msvc_static_runtime +from conan.tools.microsoft import is_msvc, is_msvc_static_runtime from conan.tools.scm import Version required_conan_version = ">=1.53.0" @@ -30,6 +30,10 @@ class TwitchNativeIpcConan(ConanFile): "fPIC": True, } + @property + def _min_cppstd(self): + return "17" + @property def _compilers_min_version(self): return { @@ -48,16 +52,6 @@ def config_options(self): del self.options.fPIC def configure(self): - if self.settings.compiler.cppstd: - check_min_cppstd(self, 17) - - min_version = self._compilers_min_version.get(str(self.settings.compiler), False) - if min_version: - if Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration("twitch-native-ipc requires C++17") - else: - self.output.warning("unknown compiler, assuming C++17 support") - if self.options.shared: self.options.rm_safe("fPIC") @@ -67,6 +61,16 @@ def layout(self): def requirements(self): self.requires("libuv/1.46.0") + def validate(self): + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + minimum_version = self._compilers_min_version.get(str(self.settings.compiler)) + 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) @@ -74,7 +78,7 @@ def generate(self): tc = CMakeToolchain(self) tc.variables["ENABLE_CODE_FORMATTING"] = False tc.variables["BUILD_TESTING"] = False - if self.settings.os == "Windows": + if is_msvc(self): tc.variables["MSVC_DYNAMIC_RUNTIME"] = not is_msvc_static_runtime(self) tc.generate() tc = CMakeDeps(self) From 508a3b1732bc65142888de1ad34d201846b8536f Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 12 Oct 2023 02:11:09 +0200 Subject: [PATCH 1076/1140] (#20491) sdbus-cpp/all: bump deps * sdbus-cpp/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * sdbus-cpp/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * sdbus-cpp/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * sdbus-cpp/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) * sdbus-cpp/all: bump deps Generated and committed by [Conan Center Bump Deps](https://github.com/ericLemanissier/conan-center-index-bump-deps) Find more updatable recipes in the [GitHub Pages](https://ericlemanissier.github.io/conan-center-index-bump-deps/) --- recipes/sdbus-cpp/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/sdbus-cpp/all/conanfile.py b/recipes/sdbus-cpp/all/conanfile.py index b93c27ec1b9185..1f8bc66668fefb 100644 --- a/recipes/sdbus-cpp/all/conanfile.py +++ b/recipes/sdbus-cpp/all/conanfile.py @@ -56,7 +56,7 @@ def configure(self): del self.options.fPIC def requirements(self): - self.requires("libsystemd/253.3") + self.requires("libsystemd/253.10") def validate(self): if self.info.settings.os != "Linux": @@ -74,7 +74,7 @@ def validate(self): self.name, self._minimum_cpp_standard, self.info.settings.compiler, self.info.settings.compiler.version)) def build_requirements(self): - self.tool_requires("pkgconf/1.9.3") + self.tool_requires("pkgconf/2.0.3") if self.options.with_code_gen: self.tool_requires("expat/2.5.0") From cccc5c7abdb45d90b9cfbd8f4dc320fa8d25de30 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 02:44:34 +0200 Subject: [PATCH 1077/1140] (#20493) amqp-cpp: fix build with MinGW and remove old versions several existing patches have been submitted upstream, so they have been split accordingly --- recipes/amqp-cpp/all/conandata.yml | 60 +++++++++---------- recipes/amqp-cpp/all/conanfile.py | 1 - ...01-cmake-openssl-install-directories.patch | 23 ------- .../4.1.7-0001-cmake-link-openssl.patch | 9 +++ ...7-0002-cmake-install-dll-export-msvc.patch | 20 +++++++ .../4.1.7-0003-cmake-link-ws2_32.patch | 12 ++++ .../4.3.24-0001-cmake-link-openssl.patch | 8 +++ ...01-cmake-openssl-install-directories.patch | 25 -------- ...4-0002-cmake-install-dll-export-msvc.patch | 20 +++++++ .../4.3.24-0003-cmake-link-ws2_32.patch | 12 ++++ recipes/amqp-cpp/config.yml | 12 ---- 11 files changed, 108 insertions(+), 94 deletions(-) delete mode 100644 recipes/amqp-cpp/all/patches/0001-cmake-openssl-install-directories.patch create mode 100644 recipes/amqp-cpp/all/patches/4.1.7-0001-cmake-link-openssl.patch create mode 100644 recipes/amqp-cpp/all/patches/4.1.7-0002-cmake-install-dll-export-msvc.patch create mode 100644 recipes/amqp-cpp/all/patches/4.1.7-0003-cmake-link-ws2_32.patch create mode 100644 recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-link-openssl.patch delete mode 100644 recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-openssl-install-directories.patch create mode 100644 recipes/amqp-cpp/all/patches/4.3.24-0002-cmake-install-dll-export-msvc.patch create mode 100644 recipes/amqp-cpp/all/patches/4.3.24-0003-cmake-link-ws2_32.patch diff --git a/recipes/amqp-cpp/all/conandata.yml b/recipes/amqp-cpp/all/conandata.yml index d5f7ffbc385d2f..e4916e22784e38 100644 --- a/recipes/amqp-cpp/all/conandata.yml +++ b/recipes/amqp-cpp/all/conandata.yml @@ -2,46 +2,40 @@ sources: "4.3.24": url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.3.24.tar.gz" sha256: "c3312f8af813cacabf6c257dfaf41bf9e66606bbf7d62d085a9b7da695355245" - "4.3.18": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.3.18.tar.gz" - sha256: "cc2c1fc5da00a1778c2804306e06bdedc782a5f74762b9d9b442d3a498dd0c4f" - "4.3.16": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.3.16.tar.gz" - sha256: "66c96e0db1efec9e7ddcf7240ff59a073d68c09752bd3e94b8bc4c506441fbf7" - "4.3.11": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.3.11.tar.gz" - sha256: "be2b11ada1020f77b859857310be54bd073c3a4f579d99a5e251a738576ca28c" - "4.3.10": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.3.10.tar.gz" - sha256: "4fa1e9650f7a08ae7217899431a3b3f0a173ad826dd819f0b8c760e4e2a65298" "4.2.1": url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.2.1.tar.gz" sha256: "33306d6cdb60554998afb304cdc3e3120a71ea539b4be187812065b1b9e59c2f" "4.1.7": url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.1.7.tar.gz" sha256: "71b504f21f62b69c76b371fe7044e0dfc6d42650a15c267431c5084badb0ade7" - "4.1.6": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.1.6.tar.gz" - sha256: "48832068dc1e25a5313dd9e96fb33ba954c19f9dc04eeca8f7b2c6cecde3afc9" - "4.1.5": - url: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/archive/v4.1.5.tar.gz" - sha256: "9840c7fb17bb0c0b601d269e528b7f9cac5ec008dcf8d66bef22434423b468aa" patches: "4.3.24": - - patch_file: "patches/4.3.24-0001-cmake-openssl-install-directories.patch" - "4.3.18": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" - "4.3.16": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" - "4.3.11": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" - "4.3.10": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" + - patch_file: "patches/4.3.24-0001-cmake-link-openssl.patch" + - patch_file: "patches/4.3.24-0002-cmake-install-dll-export-msvc.patch" + patch_description: "windows: Fix install directory of DLL and export symbols if msvc" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/515" + - patch_file: "patches/4.3.24-0003-cmake-link-ws2_32.patch" + patch_description: "Link to ws2_32 if windows" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/514" "4.2.1": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" + - patch_file: "patches/4.1.7-0001-cmake-link-openssl.patch" + - patch_file: "patches/4.1.7-0002-cmake-install-dll-export-msvc.patch" + patch_description: "windows: Fix install directory of DLL and export symbols if msvc" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/515" + - patch_file: "patches/4.1.7-0003-cmake-link-ws2_32.patch" + patch_description: "Link to ws2_32 if windows" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/514" "4.1.7": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" - "4.1.6": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" - "4.1.5": - - patch_file: "patches/0001-cmake-openssl-install-directories.patch" + - patch_file: "patches/4.1.7-0001-cmake-link-openssl.patch" + - patch_file: "patches/4.1.7-0002-cmake-install-dll-export-msvc.patch" + patch_description: "windows: Fix install directory of DLL and export symbols if msvc" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/515" + - patch_file: "patches/4.1.7-0003-cmake-link-ws2_32.patch" + patch_description: "windows: Link to ws2_32" + patch_type: "portability" + patch_source: "https://github.com/CopernicaMarketingSoftware/AMQP-CPP/pull/514" diff --git a/recipes/amqp-cpp/all/conanfile.py b/recipes/amqp-cpp/all/conanfile.py index c1e0ec3696e4e9..3e26ef28cb2618 100644 --- a/recipes/amqp-cpp/all/conanfile.py +++ b/recipes/amqp-cpp/all/conanfile.py @@ -89,7 +89,6 @@ def generate(self): tc.variables["AMQP-CPP_BUILD_SHARED"] = self.options.shared tc.variables["AMQP-CPP_BUILD_EXAMPLES"] = False tc.variables["AMQP-CPP_LINUX_TCP"] = self.options.get_safe("linux_tcp_module", False) - tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True tc.generate() deps = CMakeDeps(self) deps.generate() diff --git a/recipes/amqp-cpp/all/patches/0001-cmake-openssl-install-directories.patch b/recipes/amqp-cpp/all/patches/0001-cmake-openssl-install-directories.patch deleted file mode 100644 index f47d6bd4b19df0..00000000000000 --- a/recipes/amqp-cpp/all/patches/0001-cmake-openssl-install-directories.patch +++ /dev/null @@ -1,23 +0,0 @@ ---- CMakeLists.txt -+++ CMakeLists.txt -@@ -88,7 +88,10 @@ - #add_library(${PROJECT_NAME} STATIC ${SRCS}) - add_library(${PROJECT_NAME} STATIC ${src_MAIN} ${src_LINUX_TCP}) - endif() -- -+if(AMQP-CPP_LINUX_TCP) -+find_package(OpenSSL REQUIRED) -+target_link_libraries(${PROJECT_NAME} OpenSSL::SSL OpenSSL::Crypto) -+endif() - # install rules - # ------------------------------------------------------------------------------------------------------ - -@@ -97,7 +99,7 @@ - install(TARGETS ${PROJECT_NAME} EXPORT ${PROJECT_NAME}Config - ARCHIVE DESTINATION lib - LIBRARY DESTINATION lib -- RUNTIME DESTINATION lib -+ RUNTIME DESTINATION bin - ) - else() - # copy static lib diff --git a/recipes/amqp-cpp/all/patches/4.1.7-0001-cmake-link-openssl.patch b/recipes/amqp-cpp/all/patches/4.1.7-0001-cmake-link-openssl.patch new file mode 100644 index 00000000000000..4fd90bf502649e --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.1.7-0001-cmake-link-openssl.patch @@ -0,0 +1,9 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -129,4 +129,6 @@ target_include_directories(${PROJECT_NAME} SYSTEM PUBLIC + + if(AMQP-CPP_LINUX_TCP) + target_link_libraries(${PROJECT_NAME} ${CMAKE_DL_LIBS}) ++ find_package(OpenSSL REQUIRED) ++ target_link_libraries(${PROJECT_NAME} OpenSSL::SSL) + endif() diff --git a/recipes/amqp-cpp/all/patches/4.1.7-0002-cmake-install-dll-export-msvc.patch b/recipes/amqp-cpp/all/patches/4.1.7-0002-cmake-install-dll-export-msvc.patch new file mode 100644 index 00000000000000..a27f553a66fa51 --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.1.7-0002-cmake-install-dll-export-msvc.patch @@ -0,0 +1,20 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -82,7 +82,7 @@ if(AMQP-CPP_BUILD_SHARED) + #add_library(${PROJECT_NAME} SHARED ${SRCS}) + add_library(${PROJECT_NAME} SHARED ${src_MAIN} ${src_LINUX_TCP}) + # set shared lib version +- set_target_properties(${PROJECT_NAME} PROPERTIES SOVERSION ${SO_VERSION}) ++ set_target_properties(${PROJECT_NAME} PROPERTIES SOVERSION ${SO_VERSION} WINDOWS_EXPORT_ALL_SYMBOLS ON) + else() + # create static lib + #add_library(${PROJECT_NAME} STATIC ${SRCS}) +@@ -97,7 +97,7 @@ if(AMQP-CPP_BUILD_SHARED) + install(TARGETS ${PROJECT_NAME} EXPORT ${PROJECT_NAME}Config + ARCHIVE DESTINATION lib + LIBRARY DESTINATION lib +- RUNTIME DESTINATION lib ++ RUNTIME DESTINATION bin + ) + else() + # copy static lib diff --git a/recipes/amqp-cpp/all/patches/4.1.7-0003-cmake-link-ws2_32.patch b/recipes/amqp-cpp/all/patches/4.1.7-0003-cmake-link-ws2_32.patch new file mode 100644 index 00000000000000..935f6704ae4e79 --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.1.7-0003-cmake-link-ws2_32.patch @@ -0,0 +1,12 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -88,6 +88,9 @@ else() + #add_library(${PROJECT_NAME} STATIC ${SRCS}) + add_library(${PROJECT_NAME} STATIC ${src_MAIN} ${src_LINUX_TCP}) + endif() ++if(WIN32) ++ target_link_libraries(${PROJECT_NAME} PUBLIC ws2_32) ++endif() + + # install rules + # ------------------------------------------------------------------------------------------------------ diff --git a/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-link-openssl.patch b/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-link-openssl.patch new file mode 100644 index 00000000000000..69dd45f821f963 --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-link-openssl.patch @@ -0,0 +1,8 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -135,4 +135,5 @@ if(AMQP-CPP_LINUX_TCP) + # Find OpenSSL and provide include dirs + find_package(OpenSSL REQUIRED) + target_include_directories(${PROJECT_NAME} PRIVATE ${OPENSSL_INCLUDE_DIR}) ++ target_link_libraries(${PROJECT_NAME} OpenSSL::SSL) + endif() diff --git a/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-openssl-install-directories.patch b/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-openssl-install-directories.patch deleted file mode 100644 index 3ab0f791141189..00000000000000 --- a/recipes/amqp-cpp/all/patches/4.3.24-0001-cmake-openssl-install-directories.patch +++ /dev/null @@ -1,25 +0,0 @@ -diff --git a/CMakeLists.txt b/CMakeLists.txt -index 69deeaf..4623ab2 100644 ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -91,7 +91,10 @@ else() - #add_library(${PROJECT_NAME} STATIC ${SRCS}) - add_library(${PROJECT_NAME} STATIC ${src_MAIN} ${src_LINUX_TCP}) - endif() -- -+if(AMQP-CPP_LINUX_TCP) -+find_package(OpenSSL REQUIRED) -+target_link_libraries(${PROJECT_NAME} OpenSSL::SSL OpenSSL::Crypto) -+endif() - # install rules - # ------------------------------------------------------------------------------------------------------ - -@@ -100,7 +103,7 @@ if(AMQP-CPP_BUILD_SHARED) - install(TARGETS ${PROJECT_NAME} EXPORT ${PROJECT_NAME}Config - ARCHIVE DESTINATION lib - LIBRARY DESTINATION lib -- RUNTIME DESTINATION lib -+ RUNTIME DESTINATION bin - ) - else() - # copy static lib diff --git a/recipes/amqp-cpp/all/patches/4.3.24-0002-cmake-install-dll-export-msvc.patch b/recipes/amqp-cpp/all/patches/4.3.24-0002-cmake-install-dll-export-msvc.patch new file mode 100644 index 00000000000000..1e75ea7e91ac06 --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.3.24-0002-cmake-install-dll-export-msvc.patch @@ -0,0 +1,20 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -85,7 +85,7 @@ if(AMQP-CPP_BUILD_SHARED) + #add_library(${PROJECT_NAME} SHARED ${SRCS}) + add_library(${PROJECT_NAME} SHARED ${src_MAIN} ${src_LINUX_TCP}) + # set shared lib version +- set_target_properties(${PROJECT_NAME} PROPERTIES SOVERSION ${SO_VERSION}) ++ set_target_properties(${PROJECT_NAME} PROPERTIES SOVERSION ${SO_VERSION} WINDOWS_EXPORT_ALL_SYMBOLS ON) + else() + # create static lib + #add_library(${PROJECT_NAME} STATIC ${SRCS}) +@@ -100,7 +100,7 @@ if(AMQP-CPP_BUILD_SHARED) + install(TARGETS ${PROJECT_NAME} EXPORT ${PROJECT_NAME}Config + ARCHIVE DESTINATION lib + LIBRARY DESTINATION lib +- RUNTIME DESTINATION lib ++ RUNTIME DESTINATION bin + ) + else() + # copy static lib diff --git a/recipes/amqp-cpp/all/patches/4.3.24-0003-cmake-link-ws2_32.patch b/recipes/amqp-cpp/all/patches/4.3.24-0003-cmake-link-ws2_32.patch new file mode 100644 index 00000000000000..98c5524cc4932f --- /dev/null +++ b/recipes/amqp-cpp/all/patches/4.3.24-0003-cmake-link-ws2_32.patch @@ -0,0 +1,12 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -91,6 +91,9 @@ else() + #add_library(${PROJECT_NAME} STATIC ${SRCS}) + add_library(${PROJECT_NAME} STATIC ${src_MAIN} ${src_LINUX_TCP}) + endif() ++if(WIN32) ++ target_link_libraries(${PROJECT_NAME} PUBLIC ws2_32) ++endif() + + # install rules + # ------------------------------------------------------------------------------------------------------ diff --git a/recipes/amqp-cpp/config.yml b/recipes/amqp-cpp/config.yml index 31f91dc40c9199..4b9ef0a6cfcced 100644 --- a/recipes/amqp-cpp/config.yml +++ b/recipes/amqp-cpp/config.yml @@ -1,19 +1,7 @@ versions: "4.3.24": folder: all - "4.3.18": - folder: all - "4.3.16": - folder: all - "4.3.11": - folder: all - "4.3.10": - folder: all "4.2.1": folder: all "4.1.7": folder: all - "4.1.6": - folder: all - "4.1.5": - folder: all From 04b4641c9899f1b76964d72cbda23635c0056a88 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 02:58:14 +0200 Subject: [PATCH 1078/1140] (#20496) poly2tri: fix MinGW by injecting `_USE_MATH_DEFINES` to avoid `M_PI` not defined * inject _USE_MATH_DEFINES to avoid M_PI not defined for several compilers * add libm to system libs --- recipes/poly2tri/all/CMakeLists.txt | 5 +++++ recipes/poly2tri/all/conanfile.py | 2 ++ 2 files changed, 7 insertions(+) diff --git a/recipes/poly2tri/all/CMakeLists.txt b/recipes/poly2tri/all/CMakeLists.txt index 584d7ebc98cae7..f72581637fe532 100644 --- a/recipes/poly2tri/all/CMakeLists.txt +++ b/recipes/poly2tri/all/CMakeLists.txt @@ -11,6 +11,11 @@ add_library(poly2tri ${POLY2TRI_SRC_DIR}/sweep/sweep_context.cc ) +# _USE_MATH_DEFINES is defined in utils.h where M_PI is used, but it can break because math.h or cmath +# may have already been included indirectly by other headers included by sweep.cc before inclusion of utils.h +# Therefore we ensure that _USE_MATH_DEFINES is defined before any inclusion of headers. +target_compile_definitions(poly2tri PRIVATE _USE_MATH_DEFINES) + if(MSVC AND BUILD_SHARED_LIBS) set_property(TARGET poly2tri PROPERTY WINDOWS_EXPORT_ALL_SYMBOLS ON) endif() diff --git a/recipes/poly2tri/all/conanfile.py b/recipes/poly2tri/all/conanfile.py index d43ae54e6e9c64..8890a1140dca4d 100644 --- a/recipes/poly2tri/all/conanfile.py +++ b/recipes/poly2tri/all/conanfile.py @@ -58,3 +58,5 @@ def package(self): def package_info(self): self.cpp_info.libs = ["poly2tri"] + if self.settings.os in ["Linux", "FreeBSD"]: + self.cpp_info.system_libs.append("m") From 71b4adbb95d86fe2acaf244dfff620348d5dc1b0 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 12 Oct 2023 10:26:02 +0900 Subject: [PATCH 1079/1140] (#20500) sqlite3: add version 3.43.2 --- recipes/sqlite3/all/conandata.yml | 3 +++ recipes/sqlite3/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sqlite3/all/conandata.yml b/recipes/sqlite3/all/conandata.yml index 464fb1e4a09242..a1adb1f83b8a68 100644 --- a/recipes/sqlite3/all/conandata.yml +++ b/recipes/sqlite3/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.43.2": + url: "https://sqlite.org/2023/sqlite-amalgamation-3430200.zip" + sha256: "a17ac8792f57266847d57651c5259001d1e4e4b46be96ec0d985c953925b2a1c" "3.43.1": url: "https://sqlite.org/2023/sqlite-amalgamation-3430100.zip" sha256: "7e634bbd4b2870a83dc7c1e3cc02e4d30b8555cd7db7b332f24e0c447fd0dd16" diff --git a/recipes/sqlite3/config.yml b/recipes/sqlite3/config.yml index fcd4427a99ec3c..cf7ef48f1e6002 100644 --- a/recipes/sqlite3/config.yml +++ b/recipes/sqlite3/config.yml @@ -1,4 +1,6 @@ versions: + "3.43.2": + folder: all "3.43.1": folder: all "3.43.0": From eb5de6274c401834ae1534cf1f8e61467fd26e94 Mon Sep 17 00:00:00 2001 From: toge Date: Thu, 12 Oct 2023 10:56:04 +0900 Subject: [PATCH 1080/1140] (#20501) libnghttp2: add version 1.57.0 (fix CVE-2023-44487) --- recipes/libnghttp2/all/conandata.yml | 3 +++ recipes/libnghttp2/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libnghttp2/all/conandata.yml b/recipes/libnghttp2/all/conandata.yml index 241b93e58b1d36..da61b35ff41f8a 100644 --- a/recipes/libnghttp2/all/conandata.yml +++ b/recipes/libnghttp2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.57.0": + url: "https://github.com/nghttp2/nghttp2/archive/v1.57.0.tar.gz" + sha256: "3c0b4e023dddf2afa087aa4409f7dbe03c099b4c63655e7545a607035085848a" "1.56.0": url: "https://github.com/nghttp2/nghttp2/archive/v1.56.0.tar.gz" sha256: "63dd705b524eec3c843b8e4e24914600a30c2804a113e8e5baeeb9695d09590a" diff --git a/recipes/libnghttp2/config.yml b/recipes/libnghttp2/config.yml index 1bcc72d765fd28..4a36922d02f025 100644 --- a/recipes/libnghttp2/config.yml +++ b/recipes/libnghttp2/config.yml @@ -1,4 +1,6 @@ versions: + "1.57.0": + folder: all "1.56.0": folder: all "1.55.1": From e7182f4ed01463d000d29423a7567c9172918ad9 Mon Sep 17 00:00:00 2001 From: igormironchik Date: Thu, 12 Oct 2023 05:29:51 +0300 Subject: [PATCH 1081/1140] (#20503) md4qt: bump version --- recipes/md4qt/all/conandata.yml | 3 +++ recipes/md4qt/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/md4qt/all/conandata.yml b/recipes/md4qt/all/conandata.yml index 89f9c14aa5d1b9..92019f4f1b80b2 100644 --- a/recipes/md4qt/all/conandata.yml +++ b/recipes/md4qt/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.1.1": + url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.1.1.tar.gz" + sha256: "76f4cb2919cae393ef52788a63853aa52e429f8ff218f5eff9d38f4ebb4b3b1e" "2.1.0": url: "https://github.com/igormironchik/md4qt/archive/refs/tags/2.1.0.tar.gz" sha256: "cfbf515adecd798a3f1a4f2e007021b4b31742dd0b36805c273b3b8316fd820d" diff --git a/recipes/md4qt/config.yml b/recipes/md4qt/config.yml index 6e3494f0799608..c2325184a99517 100644 --- a/recipes/md4qt/config.yml +++ b/recipes/md4qt/config.yml @@ -1,4 +1,6 @@ versions: + "2.1.1": + folder: all "2.1.0": folder: all "2.0.18": From 3c0221b247c6677104367b02e475c069279a6aa4 Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Wed, 11 Oct 2023 21:43:10 -0500 Subject: [PATCH 1082/1140] (#20506) libdrm: Fix nouveau include directories MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The pkg-config file libdrm_nouveau.pc adds an additional include directory. This include directory is `libdrm/nouveau`. This PR just adds this include directory to the component. Co-authored-by: Rubén Rincón Blanco --- recipes/libdrm/all/conanfile.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/recipes/libdrm/all/conanfile.py b/recipes/libdrm/all/conanfile.py index 4947d9528c7e3e..9fc352be868112 100644 --- a/recipes/libdrm/all/conanfile.py +++ b/recipes/libdrm/all/conanfile.py @@ -168,7 +168,7 @@ def package_info(self): if self.options.nouveau: self.cpp_info.components["libdrm_nouveau"].libs = ["drm_nouveau"] - self.cpp_info.components["libdrm_nouveau"].includedirs.append(os.path.join("include", "libdrm")) + self.cpp_info.components["libdrm_nouveau"].includedirs.extend([os.path.join("include", "libdrm"), os.path.join("include", "libdrm", "nouveau")]) self.cpp_info.components["libdrm_nouveau"].requires = ["libdrm_libdrm"] self.cpp_info.components["libdrm_nouveau"].set_property("pkg_config_name", "libdrm_nouveau") if self.settings.os in ["Linux", "FreeBSD"]: From a4cbf821406e458031cfe6c8a37e421dda12c0a0 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 05:12:48 +0200 Subject: [PATCH 1083/1140] (#20509) nmslib: better way to create relocatable shared lib on macOS --- recipes/nmslib/all/conanfile.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes/nmslib/all/conanfile.py b/recipes/nmslib/all/conanfile.py index 0aeec8ba9e93f9..91ad2d35e900e2 100644 --- a/recipes/nmslib/all/conanfile.py +++ b/recipes/nmslib/all/conanfile.py @@ -2,8 +2,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration -from conan.tools.apple import fix_apple_shared_install_name -from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get from conan.tools.microsoft import is_msvc, check_min_vs @@ -59,6 +58,8 @@ def source(self): def generate(self): tc = CMakeToolchain(self) tc.variables["WITHOUT_TESTS"] = True + # Relocatable shared libs on macOS + tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0042"] = "NEW" tc.generate() def build(self): @@ -73,7 +74,6 @@ def package(self): src=self.source_folder) cmake = CMake(self) cmake.install() - fix_apple_shared_install_name(self) def package_info(self): self.cpp_info.libs = ["NonMetricSpaceLib"] From 707acfa584632e186b0ee6be85a6aa7f5289c829 Mon Sep 17 00:00:00 2001 From: choll Date: Thu, 12 Oct 2023 04:43:27 +0100 Subject: [PATCH 1084/1140] (#20250) sokol: add version 20230925 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * sokol: add version 20230925 * sokol: order project versions with newest first --------- Co-authored-by: Rubén Rincón Blanco --- recipes/sokol/all/conandata.yml | 3 +++ recipes/sokol/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sokol/all/conandata.yml b/recipes/sokol/all/conandata.yml index 28862f21946275..dd1a5b69303284 100644 --- a/recipes/sokol/all/conandata.yml +++ b/recipes/sokol/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "cci.20230925": + url: "https://github.com/floooh/sokol/archive/5633a0f91bf3354320837ce0c7b4748a953a1401.zip" + sha256: 9c854bc7e6f73024a99554e8e1c8850fddfc325bb2b1ece2c59502c0e3cef68d "cci.20210304": url: "https://github.com/floooh/sokol/archive/c5d55faa1036af9919bd28400e97d37548bb3789.zip" sha256: e61c782e287543ffb8077ac24a7bfee05e867ee27f6c3e9487a2dbfa1ca2b466 diff --git a/recipes/sokol/config.yml b/recipes/sokol/config.yml index 25320f6c19961f..d5b10b1bcb9c11 100644 --- a/recipes/sokol/config.yml +++ b/recipes/sokol/config.yml @@ -1,3 +1,5 @@ versions: + "cci.20230925": + folder: "all" "cci.20210304": folder: "all" From ad0bd9aee236d0d4ab9f15f49f8983f0ed67c3e8 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 12 Oct 2023 06:10:25 +0200 Subject: [PATCH 1085/1140] (#20224) sdl_image/all: bump deps --- recipes/sdl_image/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/sdl_image/all/conanfile.py b/recipes/sdl_image/all/conanfile.py index 6543a9f1cf3506..44c33234c8ec44 100644 --- a/recipes/sdl_image/all/conanfile.py +++ b/recipes/sdl_image/all/conanfile.py @@ -81,13 +81,13 @@ def requirements(self): # Headers are exposed https://github.com/conan-io/conan-center-index/pull/16167#issuecomment-1508347351 self.requires("sdl/2.26.5", transitive_headers=True) if self.options.with_libtiff: - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") if self.options.with_libjpeg: self.requires("libjpeg/9e") if self.options.with_libpng: self.requires("libpng/1.6.40") if self.options.with_libwebp: - self.requires("libwebp/1.3.1") + self.requires("libwebp/1.3.2") def validate(self): if self.options.shared and not self.dependencies["sdl"].options.shared: From 5f7822f7f746e3c05dfd036bc42a0f7f665e3737 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 06:40:59 +0200 Subject: [PATCH 1086/1140] (#20510) yaclib: fix `YACLIB_CXX_STANDARD` + add package_type * fix injection of YACLIB_CXX_STANDARD * add package_type --- recipes/yaclib/all/conanfile.py | 38 +++++++++++++++++---------------- 1 file changed, 20 insertions(+), 18 deletions(-) diff --git a/recipes/yaclib/all/conanfile.py b/recipes/yaclib/all/conanfile.py index 5cd68c33e8af5c..49364fbee5eedf 100644 --- a/recipes/yaclib/all/conanfile.py +++ b/recipes/yaclib/all/conanfile.py @@ -16,6 +16,7 @@ class YACLibConan(ConanFile): homepage = "https://github.com/YACLib/YACLib" license = "MIT" topics = ("async", "parallel", "concurrency") + package_type = "static-library" settings = "os", "arch", "compiler", "build_type" _yaclib_flags = { @@ -62,28 +63,13 @@ def _compilers_minimum_version(self): def export_sources(self): export_conandata_patches(self) - def layout(self): - cmake_layout(self, src_folder="src") - - def generate(self): - tc = CMakeToolchain(self) - tc.variables['YACLIB_INSTALL'] = True - if self.settings.compiler.get_safe("cppstd"): - tc.variables["YACLIB_CXX_STANDARD"] = self.settings.compiler.cppstd - - flags = [] - for flag in self._yaclib_flags: - if self.options.get_safe(flag): - flags.append(flag.upper()) - if flags: - tc.variables["YACLIB_FLAGS"] = ";".join(flags) - - tc.generate() - def config_options(self): if self.settings.os == "Windows": del self.options.fPIC + def layout(self): + cmake_layout(self, src_folder="src") + def validate(self): if self.settings.compiler.get_safe("cppstd"): check_min_cppstd(self, self._min_cppstd) @@ -103,6 +89,22 @@ def loose_lt_semver(v1, v2): def source(self): get(self, **self.conan_data["sources"][self.version], strip_root=True) + def generate(self): + tc = CMakeToolchain(self) + tc.variables["YACLIB_INSTALL"] = True + cppstd = self.settings.compiler.get_safe("cppstd") + if cppstd: + tc.variables["YACLIB_CXX_STANDARD"] = str(cppstd).replace("gnu", "") + + flags = [] + for flag in self._yaclib_flags: + if self.options.get_safe(flag): + flags.append(flag.upper()) + if flags: + tc.variables["YACLIB_FLAGS"] = ";".join(flags) + + tc.generate() + def build(self): apply_conandata_patches(self) cmake = CMake(self) From 3574c94e2cf9ae11521b4501889b8155847534bf Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 12 Oct 2023 07:11:29 +0200 Subject: [PATCH 1087/1140] (#20445) arrow/all: bump deps, use version range for OpenSSL --- recipes/arrow/all/conanfile.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/recipes/arrow/all/conanfile.py b/recipes/arrow/all/conanfile.py index 00c6c39a561ae8..dcd80308b7b011 100644 --- a/recipes/arrow/all/conanfile.py +++ b/recipes/arrow/all/conanfile.py @@ -301,7 +301,7 @@ def requirements(self): if self.options.with_mimalloc: self.requires("mimalloc/1.7.6") if self.options.with_boost: - self.requires("boost/1.82.0") + self.requires("boost/1.83.0") if self.options.with_gflags: self.requires("gflags/2.2.2") if self.options.with_glog: @@ -317,15 +317,15 @@ def requirements(self): if self.options.with_openssl: # aws-sdk-cpp requires openssl/1.1.1. it uses deprecated functions in openssl/3.0.0 if self.options.with_s3: - self.requires("openssl/1.1.1t") + self.requires("openssl/1.1.1w") else: - self.requires("openssl/1.1.1t") + self.requires("openssl/[>=1.1 <4]") if self.options.get_safe("with_opentelemetry"): self.requires("opentelemetry-cpp/1.7.0") if self.options.with_s3: self.requires("aws-sdk-cpp/1.9.234") if self.options.with_brotli: - self.requires("brotli/1.0.9") + self.requires("brotli/1.1.0") if self.options.with_bz2: self.requires("bzip2/1.0.8") if self.options.with_lz4: @@ -339,9 +339,9 @@ def requirements(self): if self.options.with_zlib: self.requires("zlib/[>=1.2.11 <2]") if self.options.with_zstd: - self.requires("zstd/1.5.2") + self.requires("zstd/1.5.5") if self.options.with_re2: - self.requires("re2/20220601") + self.requires("re2/20230301") if self.options.with_utf8proc: self.requires("utf8proc/2.8.0") if self.options.with_backtrace: From e11069005c0878279a76b11791f22e82b72f8a67 Mon Sep 17 00:00:00 2001 From: Andrei Malashkin Date: Thu, 12 Oct 2023 08:14:25 +0200 Subject: [PATCH 1088/1140] (#20522) bump glib dependencies * bump glib dependencies * fix review notes --- recipes/glib/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/glib/all/conanfile.py b/recipes/glib/all/conanfile.py index fa5bd0a44e4c3f..6ccdcc81fb42ae 100644 --- a/recipes/glib/all/conanfile.py +++ b/recipes/glib/all/conanfile.py @@ -72,7 +72,7 @@ def requirements(self): if self.options.get_safe("with_mount"): self.requires("libmount/2.39") if self.options.get_safe("with_selinux"): - self.requires("libselinux/3.3") + self.requires("libselinux/3.5") if self.settings.os != "Linux": # for Linux, gettext is provided by libc self.requires("libgettext/0.22", transitive_headers=True, transitive_libs=True) @@ -81,7 +81,7 @@ def requirements(self): self.requires("libiconv/1.17") def build_requirements(self): - self.tool_requires("meson/1.2.1") + self.tool_requires("meson/1.2.2") if not self.conf.get("tools.gnu:pkg_config", check_type=str): self.tool_requires("pkgconf/2.0.3") From 7011e36d31de1cc017d0793af0d1983a0048e4d7 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Thu, 12 Oct 2023 08:26:23 +0200 Subject: [PATCH 1089/1140] (#20527) onnxruntime: add version 1.16.1 --- recipes/onnxruntime/all/conandata.yml | 10 ++++++++++ recipes/onnxruntime/config.yml | 2 ++ 2 files changed, 12 insertions(+) diff --git a/recipes/onnxruntime/all/conandata.yml b/recipes/onnxruntime/all/conandata.yml index 978433ed6b132c..abfa25a1b938ff 100644 --- a/recipes/onnxruntime/all/conandata.yml +++ b/recipes/onnxruntime/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.16.1": + url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.16.1.tar.gz" + sha256: "197c6ce4f2de9176402fb8a634c390e757b729ff48a30e8038a0f7d71ff1f1ae" "1.16.0": url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.16.0.tar.gz" sha256: "3a4e57d454bce4349e11e2262fc47728a78b86ef1e0754514bbbc7d709e0a80d" @@ -9,6 +12,13 @@ sources: url: "https://github.com/microsoft/onnxruntime/archive/refs/tags/v1.14.1.tar.gz" sha256: "f998352b131bb89fa7dd1f1d87ddbafe647dfaddd11929b6b5168b3f4ef857de" patches: + "1.16.1": + - patch_file: "patches/1.16.0-0001-cmake-dependencies.patch" + patch_description: "CMake: ensure conan dependencies are used" + patch_type: "conan" + - patch_file: "patches/1.14.1-0004-abseil-no-string-view.patch" + patch_description: "allow to build with abseil built without c++17 support" + patch_type: "portability" "1.16.0": - patch_file: "patches/1.16.0-0001-cmake-dependencies.patch" patch_description: "CMake: ensure conan dependencies are used" diff --git a/recipes/onnxruntime/config.yml b/recipes/onnxruntime/config.yml index af60133f50aa30..55662a19a7296c 100644 --- a/recipes/onnxruntime/config.yml +++ b/recipes/onnxruntime/config.yml @@ -1,4 +1,6 @@ versions: + "1.16.1": + folder: all "1.16.0": folder: all "1.15.1": From 8b1e0650d6902c1ceaa6ac5edc7ff136ef154ff6 Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Thu, 12 Oct 2023 08:56:35 +0200 Subject: [PATCH 1090/1140] (#20515) wayland-protocols: add version 1.32 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/wayland-protocols/all/conandata.yml | 3 +++ recipes/wayland-protocols/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/wayland-protocols/all/conandata.yml b/recipes/wayland-protocols/all/conandata.yml index f5d4a91464dd2f..9574e69bcf1e98 100644 --- a/recipes/wayland-protocols/all/conandata.yml +++ b/recipes/wayland-protocols/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.32": + url: "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/1.32/downloads/wayland-protocols-1.32.tar.xz" + sha256: "7459799d340c8296b695ef857c07ddef24c5a09b09ab6a74f7b92640d2b1ba11" "1.31": url: "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/releases/1.31/downloads/wayland-protocols-1.31.tar.xz" sha256: "a07fa722ed87676ec020d867714bc9a2f24c464da73912f39706eeef5219e238" diff --git a/recipes/wayland-protocols/config.yml b/recipes/wayland-protocols/config.yml index 81aded41c98221..f707ca2da06d2d 100644 --- a/recipes/wayland-protocols/config.yml +++ b/recipes/wayland-protocols/config.yml @@ -1,4 +1,6 @@ versions: + "1.32": + folder: all "1.31": folder: all "1.27": From ecd1df7d4659d5a8e3ac0ff0aa52dfbae30f89e9 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 12 Oct 2023 12:03:23 +0300 Subject: [PATCH 1091/1140] (#20272) libx265: fix missing glibc symbols on newer systems * libx265: add -fno-finite-math-only to fix issues with glibc >= 2.31 * libx265: add rt to system_libs --- recipes/libx265/all/conanfile.py | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/libx265/all/conanfile.py b/recipes/libx265/all/conanfile.py index 4938bb30119502..677f51dce82b09 100644 --- a/recipes/libx265/all/conanfile.py +++ b/recipes/libx265/all/conanfile.py @@ -108,6 +108,11 @@ def _patch_sources(self): if self.settings.os == "Android": replace_in_file(self, cmakelists, "list(APPEND PLATFORM_LIBS pthread)", "") replace_in_file(self, cmakelists, "list(APPEND PLATFORM_LIBS rt)", "") + # The finite-math-only optimization has no effect and can cause linking errors + # when linked against glibc >= 2.31 + replace_in_file(self, cmakelists, + "add_definitions(-ffast-math)", + "add_definitions(-ffast-math -fno-finite-math-only)") def build(self): self._patch_sources() @@ -145,7 +150,7 @@ def package_info(self): if self.options.shared: self.cpp_info.defines.append("X265_API_IMPORTS") elif self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.system_libs.extend(["dl", "pthread", "m"]) + self.cpp_info.system_libs.extend(["dl", "pthread", "m", "rt"]) if not self.options.shared: self.cpp_info.sharedlinkflags = ["-Wl,-Bsymbolic,-znoexecstack"] elif self.settings.os == "Android": From 9bf5f41dc7cd434f1a91b897a5ae2dead9e04e4e Mon Sep 17 00:00:00 2001 From: Ilya Lavrenov Date: Thu, 12 Oct 2023 16:54:59 +0400 Subject: [PATCH 1092/1140] (#20420) openvino/all: added component for C API --- recipes/openvino/all/conanfile.py | 7 ++- .../openvino/all/test_package/CMakeLists.txt | 55 ++++++++++++------- .../openvino/all/test_package/conanfile.py | 7 ++- .../openvino/all/test_package/test_package.c | 49 +++++++++++++++++ .../all/test_package/test_package.cpp | 36 ------------ 5 files changed, 94 insertions(+), 60 deletions(-) create mode 100644 recipes/openvino/all/test_package/test_package.c diff --git a/recipes/openvino/all/conanfile.py b/recipes/openvino/all/conanfile.py index 60ab6b910442c0..01d98eb2e1f7e2 100644 --- a/recipes/openvino/all/conanfile.py +++ b/recipes/openvino/all/conanfile.py @@ -293,7 +293,7 @@ def package_info(self): openvino_runtime = self.cpp_info.components["Runtime"] openvino_runtime.set_property("cmake_target_name", "openvino::runtime") openvino_runtime.requires = ["onetbb::libtbb", "pugixml::pugixml"] - openvino_runtime.libs = ["openvino_c", "openvino"] + openvino_runtime.libs = ["openvino"] if self._preprocessing_available: openvino_runtime.requires.append("ade::ade") if self._target_x86_64: @@ -364,6 +364,11 @@ def package_info(self): if self.settings.os == "Windows": openvino_runtime.system_libs.append("setupapi") + openvino_runtime_c = self.cpp_info.components["Runtime_C"] + openvino_runtime_c.set_property("cmake_target_name", "openvino::runtime::c") + openvino_runtime_c.libs = ["openvino_c"] + openvino_runtime_c.requires = ["Runtime"] + if self.options.enable_onnx_frontend: openvino_onnx = self.cpp_info.components["ONNX"] openvino_onnx.set_property("cmake_target_name", "openvino::frontend::onnx") diff --git a/recipes/openvino/all/test_package/CMakeLists.txt b/recipes/openvino/all/test_package/CMakeLists.txt index 032463e0d1754a..60799331791bdf 100644 --- a/recipes/openvino/all/test_package/CMakeLists.txt +++ b/recipes/openvino/all/test_package/CMakeLists.txt @@ -1,5 +1,7 @@ cmake_minimum_required(VERSION 3.15) -project(test_package LANGUAGES CXX) +project(test_package LANGUAGES CXX C) + +# Common macro(add_component def comp) if(${def}) @@ -15,34 +17,45 @@ add_component(ENABLE_PYTORCH_FRONTEND PyTroch) find_package(OpenVINO REQUIRED COMPONENTS Runtime ${OpenVINO_COMPONENTS}) -add_executable(${PROJECT_NAME} test_package.cpp) -target_link_libraries(${PROJECT_NAME} PRIVATE openvino::runtime) -target_compile_features(${PROJECT_NAME} PRIVATE cxx_std_11) - -function(add_plugin def) +function(add_plugin_definition target def) if(${def}) - target_compile_definitions(${PROJECT_NAME} PRIVATE ${def}) + target_compile_definitions(${target} PRIVATE ${def}) endif() endfunction() -add_plugin(ENABLE_INTEL_CPU) -add_plugin(ENABLE_INTEL_GPU) -add_plugin(ENABLE_AUTO) -add_plugin(ENABLE_HETERO) -add_plugin(ENABLE_AUTO_BATCH) - -function(add_frontend def frontend) +function(add_frontend_definition target def frontend) if(${def}) - target_compile_definitions(${PROJECT_NAME} PRIVATE ${def}) + target_compile_definitions(${target} PRIVATE ${def}) if(NOT TARGET openvino::frontend::${frontend}) message(FATAL_ERROR "Target for ${frontend} has not been created") endif() endif() endfunction() -add_plugin(ENABLE_IR_FRONTEND) -add_frontend(ENABLE_ONNX_FRONTEND onnx) -add_frontend(ENABLE_PADDLE_FRONTEND paddle) -add_frontend(ENABLE_TF_FRONTEND tensorflow) -add_frontend(ENABLE_TF_LITE_FRONTEND tensorflow_lite) -add_frontend(ENABLE_PYTORCH_FRONTEND pytorch) +# C++ test_package + +set(target ${PROJECT_NAME}_cpp) +add_executable(${target} test_package.cpp) + +add_plugin_definition(${target} ENABLE_IR_FRONTEND) +add_frontend_definition(${target} ENABLE_ONNX_FRONTEND onnx) +add_frontend_definition(${target} ENABLE_PADDLE_FRONTEND paddle) +add_frontend_definition(${target} ENABLE_TF_FRONTEND tensorflow) +add_frontend_definition(${target} ENABLE_TF_LITE_FRONTEND tensorflow_lite) +add_frontend_definition(${target} ENABLE_PYTORCH_FRONTEND pytorch) + +target_link_libraries(${target} PRIVATE openvino::runtime) +target_compile_features(${target} PRIVATE cxx_std_11) + +# C test_package + +set(target ${PROJECT_NAME}_c) +add_executable(${target} test_package.c) + +add_plugin_definition(${target} ENABLE_INTEL_CPU) +add_plugin_definition(${target} ENABLE_INTEL_GPU) +add_plugin_definition(${target} ENABLE_AUTO) +add_plugin_definition(${target} ENABLE_HETERO) +add_plugin_definition(${target} ENABLE_AUTO_BATCH) + +target_link_libraries(${target} PRIVATE openvino::runtime::c) diff --git a/recipes/openvino/all/test_package/conanfile.py b/recipes/openvino/all/test_package/conanfile.py index 2cbd00abf5b8b9..9d90e91b9a9f9a 100644 --- a/recipes/openvino/all/test_package/conanfile.py +++ b/recipes/openvino/all/test_package/conanfile.py @@ -45,5 +45,8 @@ def build(self): def test(self): if can_run(self): - bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") - self.run(bin_path, env="conanrun") + bin_path_c = os.path.join(self.cpp.build.bindirs[0], "test_package_c") + self.run(bin_path_c, env="conanrun") + + bin_path_cpp = os.path.join(self.cpp.build.bindirs[0], "test_package_cpp") + self.run(bin_path_cpp, env="conanrun") diff --git a/recipes/openvino/all/test_package/test_package.c b/recipes/openvino/all/test_package/test_package.c new file mode 100644 index 00000000000000..1cea5771a2dbf7 --- /dev/null +++ b/recipes/openvino/all/test_package/test_package.c @@ -0,0 +1,49 @@ +#include + +#define OV_SUCCESS(statement) \ + if ((statement) != 0) \ + return 1; + +#define OV_FAIL(statement) \ + if ((statement) == 0) \ + return 1; + +int test_available_devices() { + ov_core_t* core = NULL; + char* ret = NULL; + OV_SUCCESS(ov_core_create(&core)); +#ifdef ENABLE_INTEL_CPU + OV_SUCCESS(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); +#endif +#ifdef ENABLE_INTEL_GPU + OV_SUCCESS(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); +#endif +#ifdef ENABLE_AUTO + OV_SUCCESS(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); + OV_SUCCESS(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); + OV_FAIL(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); +#endif +#ifdef ENABLE_HETERO + OV_SUCCESS(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); +#endif +#ifdef ENABLE_AUTO_BATCH + OV_SUCCESS(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); +#else + OV_FAIL(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); +#endif + ov_core_free(core); + return 0; +} + +int main() { + OV_SUCCESS(test_available_devices()); + return 0; +} diff --git a/recipes/openvino/all/test_package/test_package.cpp b/recipes/openvino/all/test_package/test_package.cpp index 4160d5eb98fcc8..baaef66559aa49 100644 --- a/recipes/openvino/all/test_package/test_package.cpp +++ b/recipes/openvino/all/test_package/test_package.cpp @@ -10,41 +10,6 @@ if ((statement) == 0) \ return 1; -int test_available_devices() { - ov_core_t* core = NULL; - char* ret = NULL; - OV_SUCCESS(ov_core_create(&core)); -#ifdef ENABLE_INTEL_CPU - OV_SUCCESS(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); -#else - OV_FAIL(ov_core_get_property(core, "CPU", "AVAILABLE_DEVICES", &ret)); -#endif -#ifdef ENABLE_INTEL_GPU - OV_SUCCESS(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); -#else - OV_FAIL(ov_core_get_property(core, "GPU", "AVAILABLE_DEVICES", &ret)); -#endif -#ifdef ENABLE_AUTO - OV_SUCCESS(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); - OV_SUCCESS(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); -#else - OV_FAIL(ov_core_get_property(core, "AUTO", "SUPPORTED_METRICS", &ret)); - OV_FAIL(ov_core_get_property(core, "MULTI", "SUPPORTED_METRICS", &ret)); -#endif -#ifdef ENABLE_HETERO - OV_SUCCESS(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); -#else - OV_FAIL(ov_core_get_property(core, "HETERO", "SUPPORTED_METRICS", &ret)); -#endif -#ifdef ENABLE_AUTO_BATCH - OV_SUCCESS(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); -#else - OV_FAIL(ov_core_get_property(core, "BATCH", "SUPPORTED_METRICS", &ret)); -#endif - ov_core_free(core); - return 0; -} - int test_available_frontends() { ov::frontend::FrontEndManager manager; auto frontend_found = [&] (const std::string & name) -> int { @@ -90,7 +55,6 @@ int test_available_frontends() { } int main() { - OV_SUCCESS(test_available_devices()); OV_SUCCESS(test_available_frontends()); // Deinitialize OpenVINO. Important for old systems like Ubuntu 16.04 with obsolete glibc, From 8639f5fcc914e57e03de4d00b83dc656484388f2 Mon Sep 17 00:00:00 2001 From: Maksim Petukhov <6967052+maksim-petukhov@users.noreply.github.com> Date: Thu, 12 Oct 2023 15:00:26 +0200 Subject: [PATCH 1093/1140] (#18546) qarchive: add new version, bump deps, fix includedirs * init * specify requires * transitive headers * Update recipes/qarchive/all/conanfile.py --- recipes/qarchive/all/conandata.yml | 3 +++ recipes/qarchive/all/conanfile.py | 5 +++-- recipes/qarchive/config.yml | 2 ++ 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/recipes/qarchive/all/conandata.yml b/recipes/qarchive/all/conandata.yml index da2432b9b6e33b..421701414538ef 100644 --- a/recipes/qarchive/all/conandata.yml +++ b/recipes/qarchive/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.2.6": + url: "https://github.com/antony-jr/QArchive/archive/v2.2.6.tar.gz" + sha256: "c0cad2bc79eeb4ab4180fd97822a967b8a0e3c594387ccf921733449ee5bd3e6" "2.2.4": url: "https://github.com/antony-jr/QArchive/archive/v2.2.4.tar.gz" sha256: "7c7f0e3bf3d6fb5130aa4632201873511944cd98ab16b273da5072198f53ad7b" diff --git a/recipes/qarchive/all/conanfile.py b/recipes/qarchive/all/conanfile.py index b299a0c2ae050d..320e0e4349c527 100644 --- a/recipes/qarchive/all/conanfile.py +++ b/recipes/qarchive/all/conanfile.py @@ -49,7 +49,7 @@ def layout(self): def requirements(self): self.requires("libarchive/3.6.2") - self.requires("qt/5.15.9") + self.requires("qt/5.15.10", transitive_headers=True, transitive_libs=True) def build_requirements(self): self.tool_requires("cmake/[>=3.17 <4]") @@ -104,7 +104,8 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "QArchive") self.cpp_info.set_property("pkg_config_name", "QArchive") self.cpp_info.libs = ["QArchive"] - self.cpp_info.includedirs = [os.path.join("include", "QArchive")] + self.cpp_info.includedirs.append(os.path.join("include", "QArchive")) + self.cpp_info.requires = ["qt::qtCore", "libarchive::libarchive"] # TODO: to remove in conan v2 once cmake_find_package_* & pkg_config generators removed self.cpp_info.names["cmake_find_package"] = "QArchive" diff --git a/recipes/qarchive/config.yml b/recipes/qarchive/config.yml index 3db8c0c3676e91..b9579224638bcf 100644 --- a/recipes/qarchive/config.yml +++ b/recipes/qarchive/config.yml @@ -1,4 +1,6 @@ versions: + "2.2.6": + folder: all "2.2.4": folder: all "2.2.3": From 45f0c5ee5352e11ff001bf5d8c099d8ca921340a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Thu, 12 Oct 2023 17:11:52 +0200 Subject: [PATCH 1094/1140] (#19827) tomplusplus: add package_type & layout MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * add package_type * cleanup * add basic_layout * Fix tests * fix test package * remove logic based on version < 1.3.0 in test package, since those versions are not maintained anymore in conancenter * small change * cleanup * Maybe? * Try not to typo this much Rubén plz --------- Co-authored-by: Rubén Rincón Blanco --- recipes/tomlplusplus/all/conanfile.py | 51 ++++++++++--------- .../all/test_package/conanfile.py | 29 ++++++----- .../all/test_v1_package/conanfile.py | 4 +- 3 files changed, 44 insertions(+), 40 deletions(-) diff --git a/recipes/tomlplusplus/all/conanfile.py b/recipes/tomlplusplus/all/conanfile.py index 44f523638d7139..c7d9d9ea44bf50 100644 --- a/recipes/tomlplusplus/all/conanfile.py +++ b/recipes/tomlplusplus/all/conanfile.py @@ -1,10 +1,12 @@ +import os + from conan import ConanFile -from conan.tools.microsoft import is_msvc +from conan.errors import ConanInvalidConfiguration from conan.tools.build import check_min_cppstd -from conan.tools.scm import Version from conan.tools.files import get, copy -from conan.errors import ConanInvalidConfiguration -import os +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version required_conan_version = ">=1.51.3" @@ -17,12 +19,13 @@ class TomlPlusPlusConan(ConanFile): url = "https://github.com/conan-io/conan-center-index" homepage = "https://github.com/marzer/tomlplusplus" license = "MIT" - settings = ("compiler", "arch", "os", "build_type") + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" no_copy_source = True @property - def _minimum_cpp_standard(self): - return 17 + def _min_cppstd(self): + return "17" @property def _minimum_compilers_version(self): @@ -34,29 +37,30 @@ def _minimum_compilers_version(self): "apple-clang": "10", } + def layout(self): + basic_layout(self, src_folder="src") + def package_id(self): self.info.clear() def validate(self): - if self.info.settings.get_safe("compiler.cppstd"): - check_min_cppstd(self, self._minimum_cpp_standard) - min_version = self._minimum_compilers_version.get(str(self.settings.compiler)) - compiler = f"{self.settings.compiler} {self.settings.compiler.version}" - if not min_version: - self.output.warn(f"{self.ref} recipe lacks information about the {self.settings.compiler} compiler support.") - else: - if Version(self.settings.compiler.version) < min_version: - raise ConanInvalidConfiguration(f"{self.ref} requires c++{self._minimum_cpp_standard} support." - " The current compiler {compiler} does not support it.") + if self.settings.compiler.get_safe("cppstd"): + check_min_cppstd(self, self._min_cppstd) + + minimum_version = self._minimum_compilers_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." + ) if self.settings.compiler == "apple-clang" and Version(self.version) < "2.3.0": - raise ConanInvalidConfiguration(f"The compiler {compiler} is supported in version >= 2.3.0") + raise ConanInvalidConfiguration("apple-clang is not supported in versions < 2.3.0") if is_msvc(self) and Version(self.version) == "2.1.0": - raise ConanInvalidConfiguration(f"The current compiler {compiler} is unable to build version 2.1.0") + raise ConanInvalidConfiguration("msvc is unable to build version 2.1.0") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def package(self): copy(self, "LICENSE", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) @@ -65,10 +69,7 @@ def package(self): copy(self, pattern="toml.hpp", dst=os.path.join(self.package_folder, "include"), src=self.source_folder) def package_info(self): - self.cpp_info.bindirs = [] - self.cpp_info.frameworkdirs = [] - self.cpp_info.libdirs = [] - self.cpp_info.resdirs = [] - self.cpp_info.set_property("cmake_file_name", "tomlplusplus") self.cpp_info.set_property("cmake_target_name", "tomlplusplus::tomlplusplus") + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/tomlplusplus/all/test_package/conanfile.py b/recipes/tomlplusplus/all/test_package/conanfile.py index db279683bd8ccd..57da1f7d0d18bc 100644 --- a/recipes/tomlplusplus/all/test_package/conanfile.py +++ b/recipes/tomlplusplus/all/test_package/conanfile.py @@ -1,36 +1,41 @@ from conan import ConanFile from conan.tools.build import can_run -from conan.tools.cmake import CMake, cmake_layout +from conan.tools.cmake import CMake, CMakeToolchain, cmake_layout from conan.tools.scm import Version import os class TestPackageConan(ConanFile): settings = "os", "compiler", "build_type", "arch" - generators = "CMakeToolchain", "CMakeDeps", "VirtualRunEnv" + generators = "CMakeDeps", "VirtualRunEnv" test_type = "explicit" + def layout(self): + cmake_layout(self) + def requirements(self): self.requires(self.tested_reference_str) + + @property + def _single_header_only(self): + return self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "8" - def layout(self): - cmake_layout(self) + def generate(self): + tc = CMakeToolchain(self) + if self._single_header_only: + tc.variables["TOMLPP_BUILD_SINGLE_ONLY"] = True + tc.generate() def build(self): cmake = CMake(self) - if Version(self.deps_cpp_info["tomlplusplus"].version) < "1.3.0": - self.single_header_only = True - if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "8": - self.single_header_only = True - variables = {"TOMLPP_BUILD_SINGLE_ONLY": True} if hasattr(self, "single_header_only") else None - cmake.configure(variables=variables) + cmake.configure() cmake.build() def test(self): if can_run(self): bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") - conf_path = os.path.join(self.recipe_folder, "configuration.toml") + conf_path = os.path.join(self.source_folder, "configuration.toml") self.run(f"{bin_path} {conf_path}", env="conanrun") - if not hasattr(self, "single_header_only"): + if not self._single_header_only: bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package_multi") self.run(f"{bin_path} {conf_path}", env="conanrun") diff --git a/recipes/tomlplusplus/all/test_v1_package/conanfile.py b/recipes/tomlplusplus/all/test_v1_package/conanfile.py index aba957cc3efa9d..0e8807dfd3ae47 100644 --- a/recipes/tomlplusplus/all/test_v1_package/conanfile.py +++ b/recipes/tomlplusplus/all/test_v1_package/conanfile.py @@ -10,8 +10,6 @@ class TestPackageConan(ConanFile): def build(self): cmake = CMake(self) - if Version(self.deps_cpp_info["tomlplusplus"].version) < "1.3.0": - self.single_header_only = True if self.settings.compiler == "gcc" and Version(self.settings.compiler.version) < "8": self.single_header_only = True if hasattr(self, "single_header_only"): @@ -22,7 +20,7 @@ def build(self): def test(self): if not cross_building(self): bin_path = os.path.join("bin", "test_package") - conf_path = os.path.join(self.recipe_folder, "..", "test_package", "configuration.toml") + conf_path = os.path.join(self.source_folder, os.pardir, "test_package", "configuration.toml") self.run(f"{bin_path} {conf_path}", run_environment=True) if not hasattr(self, "single_header_only"): bin_path = os.path.join("bin", "test_package_multi") From af9658073c1a5b74de7f8a3971637a657206396e Mon Sep 17 00:00:00 2001 From: ashley-b Date: Fri, 13 Oct 2023 02:39:57 +1100 Subject: [PATCH 1095/1140] (#19762) qwt: Fixed transitive requirement of qt * qwt: Removed space from key name. * qwt: Added transitive_headers for Qt dependency * qwt: Fixed topics to match this package * qwt: Added package_type * qwt: Added transitive_libs to fixed shared builds of qt * use host_version of qt in build requirements * no self.info in validate() * qwt: Bump dependencies --------- Co-authored-by: SpaceIm <30052553+SpaceIm@users.noreply.github.com> --- recipes/qwt/all/conanfile.py | 35 ++++++++++++++++++++--------------- 1 file changed, 20 insertions(+), 15 deletions(-) diff --git a/recipes/qwt/all/conanfile.py b/recipes/qwt/all/conanfile.py index 3c7b6925650a86..8cc76b47a4e496 100644 --- a/recipes/qwt/all/conanfile.py +++ b/recipes/qwt/all/conanfile.py @@ -7,7 +7,7 @@ from conan.tools.scm import Version import os -required_conan_version = ">=1.53.0" +required_conan_version = ">=1.60.0 <2.0 || >=2.0.5" class QwtConan(ConanFile): @@ -15,7 +15,8 @@ class QwtConan(ConanFile): license = "LGPL-2.1-or-later" url = "https://github.com/conan-io/conan-center-index" homepage = "https://qwt.sourceforge.io/" - topics = ("archive", "compression") + topics = ("chart", "data-visualization", "graph", "plot", "qt") + package_type = "library" description = ( "The Qwt library contains GUI Components and utility classes which are primarily useful for programs " "with a technical background. Beside a framework for 2D plots it provides scales, sliders, dials, compasses, " @@ -43,6 +44,10 @@ class QwtConan(ConanFile): "polar": True, } + @property + def _is_legacy_one_profile(self): + return not hasattr(self, "settings_build") + def export_sources(self): export_conandata_patches(self) @@ -58,39 +63,39 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("qt/5.15.9") + self.requires("qt/5.15.11", transitive_headers=True, transitive_libs=True) def validate(self): if hasattr(self, "settings_build") and cross_building(self): raise ConanInvalidConfiguration("Qwt recipe does not support cross-compilation yet") qt_options = self.dependencies["qt"].options - if self.info.options.widgets and not qt_options.widgets: + if self.options.widgets and not qt_options.widgets: raise ConanInvalidConfiguration("qwt:widgets=True requires qt:widgets=True") - if self.info.options.svg and not qt_options.qtsvg: + if self.options.svg and not qt_options.qtsvg: raise ConanInvalidConfiguration("qwt:svg=True requires qt:qtsvg=True") - if self.info.options.opengl and qt_options.opengl == "no": + if self.options.opengl and qt_options.opengl == "no": raise ConanInvalidConfiguration("qwt:opengl=True is not compatible with qt:opengl=no") - if self.info.options.designer and not (qt_options.qttools and qt_options.gui and qt_options.widgets): + if self.options.designer and not (qt_options.qttools and qt_options.gui and qt_options.widgets): raise ConanInvalidConfiguration("qwt:designer=True requires qt:qttools=True, qt::gui=True and qt::widgets=True") def build_requirements(self): - if hasattr(self, "settings_build") and cross_building(self): - self.tool_requires("qt/5.15.7") + if not self._is_legacy_one_profile: + self.tool_requires("qt/") def source(self): - get(self, **self.conan_data["sources"][self.version], destination=self.source_folder, strip_root=True) + get(self, **self.conan_data["sources"][self.version], strip_root=True) def generate(self): - if hasattr(self, "settings_build") and cross_building(self): - env = VirtualBuildEnv(self) - env.generate() - else: + if self._is_legacy_one_profile: env = VirtualRunEnv(self) env.generate(scope="build") + else: + env = VirtualBuildEnv(self) + env.generate() tc = CMakeToolchain(self) tc.variables["QWT_DLL"] = self.options.shared - tc.variables["QWT_STATIC "] = not self.options.shared + tc.variables["QWT_STATIC"] = not self.options.shared tc.variables["QWT_PLOT"] = self.options.plot tc.variables["QWT_WIDGETS"] = self.options.widgets tc.variables["QWT_SVG"] = self.options.svg From a395d4ccb8e603d29a4f264c67d8f8e13eb51a1b Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 13 Oct 2023 01:14:46 +0900 Subject: [PATCH 1096/1140] (#20525) ada: add version 2.7.0 --- recipes/ada/all/conandata.yml | 3 +++ recipes/ada/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ada/all/conandata.yml b/recipes/ada/all/conandata.yml index 509473568c35a1..f881ad719a6c1a 100644 --- a/recipes/ada/all/conandata.yml +++ b/recipes/ada/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.7.0": + url: "https://github.com/ada-url/ada/archive/v2.7.0.tar.gz" + sha256: "08646b8a41cd6367b282aab2c87c82e5ce4876078a0cbe0799af7e51e4358591" "2.6.10": url: "https://github.com/ada-url/ada/archive/v2.6.10.tar.gz" sha256: "a43e1ea0bcdd7585edf538afffe1fc3303b936752e18bac545fa11729de088bc" diff --git a/recipes/ada/config.yml b/recipes/ada/config.yml index 417e43596e1945..24235209b6d9f1 100644 --- a/recipes/ada/config.yml +++ b/recipes/ada/config.yml @@ -1,4 +1,6 @@ versions: + "2.7.0": + folder: all "2.6.10": folder: all "2.6.7": From 8d3eb5dcf5fcf29d971892e156781b5e26e1453a Mon Sep 17 00:00:00 2001 From: toge Date: Fri, 13 Oct 2023 01:29:03 +0900 Subject: [PATCH 1097/1140] (#20539) watcher: add version 0.9.5 --- recipes/watcher/all/conandata.yml | 3 +++ recipes/watcher/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/watcher/all/conandata.yml b/recipes/watcher/all/conandata.yml index 61b03ba30a80dc..857cc8ad363672 100644 --- a/recipes/watcher/all/conandata.yml +++ b/recipes/watcher/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.9.5": + url: "https://github.com/e-dant/watcher/archive/release/0.9.5.tar.gz" + sha256: "41b74d138eec106c35a99e7544def599453a8bf4cf4887ad627e1c9e3355287c" "0.9.2": url: "https://github.com/e-dant/watcher/archive/release/0.9.2.tar.gz" sha256: "d728960cbf5cebb05e1e0b7d61482b1cfd10b6bc616f9e494168f7d5d2e689cf" diff --git a/recipes/watcher/config.yml b/recipes/watcher/config.yml index e770c710dc9cfb..2b4b53a7cfb59a 100644 --- a/recipes/watcher/config.yml +++ b/recipes/watcher/config.yml @@ -1,4 +1,6 @@ versions: + "0.9.5": + folder: all "0.9.2": folder: all "0.8.8": From 2d16ab1085f9aad8d8fd63ab3108a8ca250b25c6 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Thu, 12 Oct 2023 22:48:35 +0300 Subject: [PATCH 1098/1140] (#20313) nuklear: add version 4.10.6 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/nuklear/all/conandata.yml | 3 +++ recipes/nuklear/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/nuklear/all/conandata.yml b/recipes/nuklear/all/conandata.yml index 2bff2ae899a2a9..d11d172a2e7ff1 100644 --- a/recipes/nuklear/all/conandata.yml +++ b/recipes/nuklear/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.10.6": + url: "https://github.com/Immediate-Mode-UI/Nuklear/archive/4.10.6.tar.gz" + sha256: "1baa1c9603ef20e6410a931de65d3fe07def5266fa7a61cdf1ffd241b3109a99" "4.10.1": url: "https://github.com/Immediate-Mode-UI/Nuklear/archive/refs/tags/4.10.1.tar.gz" sha256: "a7bd28477e00be6768e9b8cc3a406bc67b2d32d3a023b1e44868e8c566a7eb2f" diff --git a/recipes/nuklear/config.yml b/recipes/nuklear/config.yml index 7f21ae0ba74181..96278eaa477be1 100644 --- a/recipes/nuklear/config.yml +++ b/recipes/nuklear/config.yml @@ -1,4 +1,6 @@ versions: + "4.10.6": + folder: all "4.10.1": folder: all "4.06.1": From a96fdfba237e75d8a42b101100e223572bc42a69 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Fri, 13 Oct 2023 07:55:39 +0200 Subject: [PATCH 1099/1140] (#20418) libxml2: add version 2.11.5 --- recipes/libxml2/all/conandata.yml | 3 +++ recipes/libxml2/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libxml2/all/conandata.yml b/recipes/libxml2/all/conandata.yml index 1056eab90fe205..e2e74158989197 100644 --- a/recipes/libxml2/all/conandata.yml +++ b/recipes/libxml2/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.11.5": + url: "https://download.gnome.org/sources/libxml2/2.11/libxml2-2.11.5.tar.xz" + sha256: "3727b078c360ec69fa869de14bd6f75d7ee8d36987b071e6928d4720a28df3a6" "2.11.4": url: "https://download.gnome.org/sources/libxml2/2.11/libxml2-2.11.4.tar.xz" sha256: "737e1d7f8ab3f139729ca13a2494fd17bf30ddb4b7a427cf336252cab57f57f7" diff --git a/recipes/libxml2/config.yml b/recipes/libxml2/config.yml index a49601ef686b56..7a7b2cea0b90c9 100644 --- a/recipes/libxml2/config.yml +++ b/recipes/libxml2/config.yml @@ -1,4 +1,6 @@ versions: + "2.11.5": + folder: all "2.11.4": folder: all "2.11.3": From 0b4bb72d66bc60e8d8b664bd729a7d92b6ef804c Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 11:48:15 +0300 Subject: [PATCH 1100/1140] (#20301) utfcpp: add version 3.2.5 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot Co-authored-by: Rubén Rincón Blanco --- recipes/utfcpp/all/conandata.yml | 3 +++ recipes/utfcpp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/utfcpp/all/conandata.yml b/recipes/utfcpp/all/conandata.yml index 572f41ae51de7e..c53cea46246825 100644 --- a/recipes/utfcpp/all/conandata.yml +++ b/recipes/utfcpp/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.2.5": + url: "https://github.com/nemtrif/utfcpp/archive/v3.2.5.tar.gz" + sha256: "14fd1b3c466814cb4c40771b7f207b61d2c7a0aa6a5e620ca05c00df27f25afd" "3.2.4": url: "https://github.com/nemtrif/utfcpp/archive/refs/tags/v3.2.4.tar.gz" sha256: "fde21a4c519eed25f095a1cd8490167409cc70d7b5e9c38756142e588ccb7c7e" diff --git a/recipes/utfcpp/config.yml b/recipes/utfcpp/config.yml index b0811297690469..7c9a9e66d30ce6 100644 --- a/recipes/utfcpp/config.yml +++ b/recipes/utfcpp/config.yml @@ -1,4 +1,6 @@ versions: + "3.2.5": + folder: all "3.2.4": folder: all "3.2.3": From 6ea27fab88156d6b6d663b1d81d8b15a8b65bdcf Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 12:04:53 +0300 Subject: [PATCH 1101/1140] (#20310) dbg-macro: add version 0.5.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/dbg-macro/all/conandata.yml | 3 +++ recipes/dbg-macro/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/dbg-macro/all/conandata.yml b/recipes/dbg-macro/all/conandata.yml index 4beffe08cb1f1f..3c855c0c751259 100644 --- a/recipes/dbg-macro/all/conandata.yml +++ b/recipes/dbg-macro/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.5.1": + url: "https://github.com/sharkdp/dbg-macro/archive/v0.5.1.tar.gz" + sha256: "fffea75f067c69995853dc790626887788e2c4c9eb0a5a0014a4501d2b6b9909" "0.5.0": url: "https://github.com/sharkdp/dbg-macro/archive/v0.5.0.tar.gz" sha256: "dac4907aadf39dbd9eac279a214c59ad30af6c0c3d585688242f73cb1a9ce243" diff --git a/recipes/dbg-macro/config.yml b/recipes/dbg-macro/config.yml index 49f293dbf19712..e820923f0c236b 100644 --- a/recipes/dbg-macro/config.yml +++ b/recipes/dbg-macro/config.yml @@ -1,4 +1,6 @@ versions: + "0.5.1": + folder: "all" "0.5.0": folder: "all" "0.4.0": From 56e1681d6e7babc725fa924c15866d2ab016f5af Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 12:18:09 +0300 Subject: [PATCH 1102/1140] (#20298) cpp-peglib: add version 1.8.5 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/cpp-peglib/1.x.x/conandata.yml | 3 +++ recipes/cpp-peglib/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cpp-peglib/1.x.x/conandata.yml b/recipes/cpp-peglib/1.x.x/conandata.yml index cd54a6a1b9b282..22a75880404673 100644 --- a/recipes/cpp-peglib/1.x.x/conandata.yml +++ b/recipes/cpp-peglib/1.x.x/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.5": + url: "https://github.com/yhirose/cpp-peglib/archive/v1.8.5.tar.gz" + sha256: "2813f7ffdeb570959b879ce2bf3921bf4f2edc0d9f1568c4429eceadff9ab114" "1.8.4": url: "https://github.com/yhirose/cpp-peglib/archive/v1.8.4.tar.gz" sha256: "002cec65f659180ba90c0b04ee30a349ca18f0732fbe00e7638f1ead44aeb701" diff --git a/recipes/cpp-peglib/config.yml b/recipes/cpp-peglib/config.yml index a30fecf91ce926..e7a9a93559bfa8 100644 --- a/recipes/cpp-peglib/config.yml +++ b/recipes/cpp-peglib/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.5": + folder: "1.x.x" "1.8.4": folder: "1.x.x" "1.8.3": From 98ebbc541112462b80d959af3613f824b2b6315e Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Fri, 13 Oct 2023 04:29:58 -0500 Subject: [PATCH 1103/1140] (#20524) util-linux-libuuid: Add version 2.39.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Francisco Ramírez Co-authored-by: Daniel --- recipes/util-linux-libuuid/all/conandata.yml | 3 +++ recipes/util-linux-libuuid/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/util-linux-libuuid/all/conandata.yml b/recipes/util-linux-libuuid/all/conandata.yml index 4e1010ee8b94f4..c84795c4daf4e6 100644 --- a/recipes/util-linux-libuuid/all/conandata.yml +++ b/recipes/util-linux-libuuid/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.39.2": + url: "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.39/util-linux-2.39.2.tar.xz" + sha256: "87abdfaa8e490f8be6dde976f7c80b9b5ff9f301e1b67e3899e1f05a59a1531f" "2.39": url: "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.39/util-linux-2.39.tar.xz" sha256: "32b30a336cda903182ed61feb3e9b908b762a5e66fe14e43efb88d37162075cb" diff --git a/recipes/util-linux-libuuid/config.yml b/recipes/util-linux-libuuid/config.yml index 427b3a10b7a7d1..4ab19fceb4d3b4 100644 --- a/recipes/util-linux-libuuid/config.yml +++ b/recipes/util-linux-libuuid/config.yml @@ -1,3 +1,5 @@ versions: + "2.39.2": + folder: all "2.39": folder: all From c04984f8c40ce7ab8993bb2d4e5d18c55c6b9f9f Mon Sep 17 00:00:00 2001 From: Oliver Kuckertz Date: Fri, 13 Oct 2023 11:43:20 +0200 Subject: [PATCH 1104/1140] (#20549) android-ndk: add r26b --- recipes/android-ndk/all/conandata.yml | 13 +++++++++++++ recipes/android-ndk/config.yml | 2 ++ 2 files changed, 15 insertions(+) diff --git a/recipes/android-ndk/all/conandata.yml b/recipes/android-ndk/all/conandata.yml index 91ea41fe322a4d..788c3990884da0 100644 --- a/recipes/android-ndk/all/conandata.yml +++ b/recipes/android-ndk/all/conandata.yml @@ -1,4 +1,17 @@ sources: + "r26b": + "Windows": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26b-windows.zip" + sha256: "a478d43d4a45d0d345cda6be50d79642b92fb175868d9dc0dfc86181d80f691e" + "Linux": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26b-linux.zip" + sha256: "ad73c0370f0b0a87d1671ed2fd5a9ac9acfd1eb5c43a7fbfbd330f85d19dd632" + "Macos": + "x86_64": + url: "https://dl.google.com/android/repository/android-ndk-r26b-darwin.zip" + sha256: "4b0ea6148a9a2337e62a0c0c7ac59ff1edc38d69b81d9c58251897d23f7fa321" "r26": "Windows": "x86_64": diff --git a/recipes/android-ndk/config.yml b/recipes/android-ndk/config.yml index afb825c16b4c6d..a7fa8c97dd42c7 100644 --- a/recipes/android-ndk/config.yml +++ b/recipes/android-ndk/config.yml @@ -1,4 +1,6 @@ versions: + "r26b": + folder: all "r26": folder: all "r25c": From a0a1af9b19987cf5cda4083cae35ac54961a860e Mon Sep 17 00:00:00 2001 From: Martin Delille Date: Fri, 13 Oct 2023 12:08:52 +0200 Subject: [PATCH 1105/1140] (#19138) [quazip] Set zlib transitive headers * [quazip] Set zlib transitive headers * Bump qt to 6.5.2 * Revert "Bump qt to 6.5.2" since it requires cor5compat This reverts commit 06b1f7fd6f547333f2fb48fcd7e494c5d3be102b. * fix requires * Update recipes/quazip/all/conanfile.py --------- Co-authored-by: Carlos Zoido --- recipes/quazip/all/conanfile.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/quazip/all/conanfile.py b/recipes/quazip/all/conanfile.py index 0203b4a63fa9cd..6e40033d8025b7 100644 --- a/recipes/quazip/all/conanfile.py +++ b/recipes/quazip/all/conanfile.py @@ -48,8 +48,8 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("qt/5.15.9") - self.requires("zlib/1.2.13") + self.requires("qt/5.15.9", transitive_headers=True, transitive_libs=True) + self.requires("zlib/[>=1.2.11 <2]", transitive_headers=True) if Version(self.version) >= "1.4": self.requires("bzip2/1.0.8") From da12f0f3ce6af541894e29895141fb0b27785e32 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 13:43:49 +0300 Subject: [PATCH 1106/1140] (#20299) lerc: add version 4.0.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/lerc/all/conandata.yml | 7 +++++++ recipes/lerc/config.yml | 2 ++ 2 files changed, 9 insertions(+) diff --git a/recipes/lerc/all/conandata.yml b/recipes/lerc/all/conandata.yml index f1d58df7a46b7e..73b69372cf8f46 100644 --- a/recipes/lerc/all/conandata.yml +++ b/recipes/lerc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.0.1": + url: "https://github.com/Esri/lerc/archive/js_v4.0.1.tar.gz" + sha256: "d771f45b90dd033187d5fad2b99159d0a98d46878d88d3236147c3df297dd544" "4.0.0": url: "https://github.com/Esri/lerc/archive/refs/tags/v4.0.0.tar.gz" sha256: "91431c2b16d0e3de6cbaea188603359f87caed08259a645fd5a3805784ee30a0" @@ -9,6 +12,10 @@ sources: url: "https://github.com/Esri/lerc/archive/v2.1.tar.gz" sha256: "7c48de40cd5f09319de4b39c417ff4eec4ad4b6aa5d6144f6ffa9b10d18ec94e" patches: + "4.0.1": + - patch_file: "patches/4.0.0-include-algorithm.patch" + patch_description: "include algorithm header for std::min/max" + patch_type: "portability" "4.0.0": - patch_file: "patches/4.0.0-include-algorithm.patch" patch_description: "include algorithm header for std::min/max" diff --git a/recipes/lerc/config.yml b/recipes/lerc/config.yml index 6bcfdf0332e1f2..a09a8d0001ec66 100644 --- a/recipes/lerc/config.yml +++ b/recipes/lerc/config.yml @@ -1,4 +1,6 @@ versions: + "4.0.1": + folder: all "4.0.0": folder: all "2.2": From 01e142ce46c13fb81ed1ceab818cb722788f656e Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 14:12:06 +0300 Subject: [PATCH 1107/1140] (#20309) kangaru: add version 4.3.1 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/kangaru/all/conandata.yml | 3 +++ recipes/kangaru/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/kangaru/all/conandata.yml b/recipes/kangaru/all/conandata.yml index 7cacb93f9b6160..5c977f020a27d6 100644 --- a/recipes/kangaru/all/conandata.yml +++ b/recipes/kangaru/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "4.3.1": + url: "https://github.com/gracicot/kangaru/archive/v4.3.1.tar.gz" + sha256: "3896ea2a13cc1c220b4d83bf598e27e77004170b4a212af8f14264f8a6fb0e45" "4.3.0": url: "https://github.com/gracicot/kangaru/archive/refs/tags/v4.3.0.tar.gz" sha256: "98a0d7f2e5ac65d93fe83615ead1627fab2237b173e18151fb68d50234ed6eaf" diff --git a/recipes/kangaru/config.yml b/recipes/kangaru/config.yml index f77751b7637b42..a57d047923a8af 100644 --- a/recipes/kangaru/config.yml +++ b/recipes/kangaru/config.yml @@ -1,4 +1,6 @@ versions: + "4.3.1": + folder: all "4.3.0": folder: all "4.2.4": From cc4e61698a02fbd150cce06e360797f29160eb3a Mon Sep 17 00:00:00 2001 From: Conan Center Index Bot <54393557+conan-center-bot@users.noreply.github.com> Date: Fri, 13 Oct 2023 13:47:07 +0200 Subject: [PATCH 1108/1140] (#20532) [bot] Update authorized users list (2023-10-12) --- .c3i/authorized_users.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.c3i/authorized_users.yml b/.c3i/authorized_users.yml index 3b442dae2045d4..9a2e9e466b87db 100644 --- a/.c3i/authorized_users.yml +++ b/.c3i/authorized_users.yml @@ -1243,3 +1243,4 @@ authorized_users: - fixstars-sonali - FranzPoize - SoShiny +- tamaskenezlego From 1d4e6da0ec07407efa3214eaad5d1d84eedcf859 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 15:10:52 +0300 Subject: [PATCH 1109/1140] (#20302) libsvtav1: add version 1.7.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot Co-authored-by: Rubén Rincón Blanco --- recipes/libsvtav1/all/conandata.yml | 3 +++ recipes/libsvtav1/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libsvtav1/all/conandata.yml b/recipes/libsvtav1/all/conandata.yml index 116460d8d2500b..54555aa218224f 100644 --- a/recipes/libsvtav1/all/conandata.yml +++ b/recipes/libsvtav1/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.7.0": + url: "https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v1.7.0/SVT-AV1-v1.7.0.tar.gz" + sha256: "ce0973584f1a187aa4abf63f509ff8464397120878e322a3153f87e9c161fc4f" "1.6.0": url: https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v1.6.0/SVT-AV1-v1.6.0.tar.bz2 sha256: c6b49111a2d4c5113f1ada0c2f716d94bd4a8db704623d453066826401ecdab5 diff --git a/recipes/libsvtav1/config.yml b/recipes/libsvtav1/config.yml index e7e07862417048..c8fea3589a745b 100644 --- a/recipes/libsvtav1/config.yml +++ b/recipes/libsvtav1/config.yml @@ -1,4 +1,6 @@ versions: + "1.7.0": + folder: all "1.6.0": folder: all "1.4.1": From 5d016b65867d7662a4641b127ecf04e24b7a00d5 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 15:56:14 +0300 Subject: [PATCH 1110/1140] (#20308) reactiveplusplus: add version 0.2.3 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/reactiveplusplus/all/conandata.yml | 3 +++ recipes/reactiveplusplus/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/reactiveplusplus/all/conandata.yml b/recipes/reactiveplusplus/all/conandata.yml index b01e397208475c..9e638abe5d43ae 100644 --- a/recipes/reactiveplusplus/all/conandata.yml +++ b/recipes/reactiveplusplus/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.2.3": + url: "https://github.com/victimsnino/ReactivePlusPlus/archive/v0.2.3.tar.gz" + sha256: "9542419f8d7da98126ba2c6ae08fab287b4b3798d89cf75ed9bed2a9e3ec1678" "0.2.1": url: "https://github.com/victimsnino/ReactivePlusPlus/archive/refs/tags/v0.2.1.tar.gz" sha256: "c41f9a0b727d5bdbc92390b3f075bfa280fd4f6f2aa7db51428fc30023b518d0" diff --git a/recipes/reactiveplusplus/config.yml b/recipes/reactiveplusplus/config.yml index 4fec465c4ccadf..34b32de1aab118 100644 --- a/recipes/reactiveplusplus/config.yml +++ b/recipes/reactiveplusplus/config.yml @@ -1,4 +1,6 @@ versions: + "0.2.3": + folder: all "0.2.1": folder: all "0.1.2": From 544b02f43aa6bf889edce3df5210ec8db3869353 Mon Sep 17 00:00:00 2001 From: Joris Putcuyps Date: Fri, 13 Oct 2023 15:33:01 +0200 Subject: [PATCH 1111/1140] (#20535) fltk: Fixes undefined reference to `__imp__TrackMouseEvent' on msys2. * Fixes undefined reference to `__imp__TrackMouseEvent' on msys2. * Add suggested opengl32 following the hook warning * Cleanup os library conditions --- recipes/fltk/all/conanfile.py | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/recipes/fltk/all/conanfile.py b/recipes/fltk/all/conanfile.py index f32dd94a48036a..6651e281a97d2d 100644 --- a/recipes/fltk/all/conanfile.py +++ b/recipes/fltk/all/conanfile.py @@ -111,22 +111,24 @@ def package_info(self): self.cpp_info.set_property("cmake_target_name", "fltk::fltk") self.cpp_info.libs = collect_libs(self) - if self.options.shared and self.settings.os == "Windows": - self.cpp_info.defines.append("FL_DLL") if self.settings.os in ("Linux", "FreeBSD"): if self.options.with_threads: self.cpp_info.system_libs.extend(["pthread", "dl"]) if self.options.with_gl: self.cpp_info.system_libs.extend(["GL", "GLU"]) - if is_apple_os(self): + elif is_apple_os(self): self.cpp_info.frameworks = [ "AppKit", "ApplicationServices", "Carbon", "Cocoa", "CoreFoundation", "CoreGraphics", "CoreText", "CoreVideo", "Foundation", "IOKit", "OpenGL", ] - if self.settings.os == "Windows": - self.cpp_info.system_libs = ["gdi32", "imm32", "msimg32", "ole32", "oleaut32", "uuid"] + elif self.settings.os == "Windows": + if self.options.shared: + self.cpp_info.defines.append("FL_DLL") + self.cpp_info.system_libs = ["gdi32", "imm32", "msimg32", "ole32", "oleaut32", "uuid", "comctl32"] if self.options.get_safe("with_gdiplus"): self.cpp_info.system_libs.append("gdiplus") + if self.options.with_gl: + self.cpp_info.system_libs.append("opengl32") # TODO: to remove in conan v2 once legacy generators removed self.cpp_info.names["cmake_find_package"] = "fltk" From c403509b4eabc07cd23ba6d1c70a3bafce697481 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 17:26:03 +0300 Subject: [PATCH 1112/1140] (#20042) gcem: add version 1.17.0 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/gcem/all/conandata.yml | 3 +++ recipes/gcem/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/gcem/all/conandata.yml b/recipes/gcem/all/conandata.yml index 58f1cc5b754a9c..5aa429fe457fd4 100644 --- a/recipes/gcem/all/conandata.yml +++ b/recipes/gcem/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.17.0": + url: "https://github.com/kthohr/gcem/archive/v1.17.0.tar.gz" + sha256: "74cc499e2db247c32f1ce82fc22022d22e0f0a110ecd19281269289a9e78a6f8" "1.16.0": url: "https://github.com/kthohr/gcem/archive/v1.16.0.tar.gz" sha256: "119c742b9371c0adc7d9cd710c3cbc575459a98fb63f6be4c636215dcf8404ce" diff --git a/recipes/gcem/config.yml b/recipes/gcem/config.yml index cc18649bfe195f..f63fe5ab6f0146 100644 --- a/recipes/gcem/config.yml +++ b/recipes/gcem/config.yml @@ -1,4 +1,6 @@ versions: + "1.17.0": + folder: all "1.16.0": folder: all "1.14.1": From 56172550af4f8429e78ebb9b736a4372389a9359 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 17:58:43 +0300 Subject: [PATCH 1113/1140] (#20030) plog: add version 1.1.10 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/plog/all/conandata.yml | 3 +++ recipes/plog/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/plog/all/conandata.yml b/recipes/plog/all/conandata.yml index a2d1cb2b746a69..d1c46d7ff154b1 100644 --- a/recipes/plog/all/conandata.yml +++ b/recipes/plog/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.1.10": + url: "https://github.com/SergiusTheBest/plog/archive/1.1.10.tar.gz" + sha256: "55a090fc2b46ab44d0dde562a91fe5fc15445a3caedfaedda89fe3925da4705a" "1.1.9": url: "https://github.com/SergiusTheBest/plog/archive/1.1.9.tar.gz" sha256: "058315b9ec9611b659337d4333519ab4783fad3f2f23b1cc7bb84d977ea38055" diff --git a/recipes/plog/config.yml b/recipes/plog/config.yml index c3432fc6b2f2ae..5526e402261bcd 100644 --- a/recipes/plog/config.yml +++ b/recipes/plog/config.yml @@ -1,4 +1,6 @@ versions: + "1.1.10": + folder: all "1.1.9": folder: all "1.1.5": From c5e6f48fa1d849e2577df1afa006bca247a0e73b Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 18:42:55 +0300 Subject: [PATCH 1114/1140] (#20020) vc: add version 1.4.3 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/vc/all/conandata.yml | 3 +++ recipes/vc/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/vc/all/conandata.yml b/recipes/vc/all/conandata.yml index b1e2f20f1981dd..ef285ad3397b4d 100644 --- a/recipes/vc/all/conandata.yml +++ b/recipes/vc/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.4.3": + url: "https://github.com/VcDevel/Vc/archive/1.4.3.tar.gz" + sha256: "988ea0053f3fbf17544ca776a2749c097b3139089408b0286fa4e9e8513e037f" "1.4.2": url: "https://github.com/VcDevel/Vc/releases/download/1.4.2/Vc-1.4.2.tar.gz" sha256: "50d3f151e40b0718666935aa71d299d6370fafa67411f0a9e249fbce3e6e3952" diff --git a/recipes/vc/config.yml b/recipes/vc/config.yml index 0ba616ecf92b28..f5a2ce84083be3 100644 --- a/recipes/vc/config.yml +++ b/recipes/vc/config.yml @@ -1,4 +1,6 @@ versions: + "1.4.3": + folder: all "1.4.2": folder: all "1.4.1": From dba6b2c36e6e4a3e92195ca8be9e2a5983d636e1 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 19:10:44 +0300 Subject: [PATCH 1115/1140] (#20023) ezc3d: add version 1.5.4 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/ezc3d/all/conandata.yml | 3 +++ recipes/ezc3d/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ezc3d/all/conandata.yml b/recipes/ezc3d/all/conandata.yml index 7c22e7d8569923..cba9d2eb45320e 100644 --- a/recipes/ezc3d/all/conandata.yml +++ b/recipes/ezc3d/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.4": + url: "https://github.com/pyomeca/ezc3d/archive/Release_1.5.4.tar.gz" + sha256: "d27a1d8ffc5cebf47b53c2d263a1c4dbb4a6dc2f474c6978b3588bbb143e272f" "1.5.0": url: "https://github.com/pyomeca/ezc3d/archive/refs/tags/Release_1.5.0.tar.gz" sha256: "8387857d989f5bbb62869ec930b417e6d0a303eef9b39e8b0e6b35437d5809ce" diff --git a/recipes/ezc3d/config.yml b/recipes/ezc3d/config.yml index 3d5d9b1cd1d496..13db8816b3037b 100644 --- a/recipes/ezc3d/config.yml +++ b/recipes/ezc3d/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.4": + folder: all "1.5.0": folder: all "1.4.8": From a5e7b9eb9cc9f4c04940e5ea0e8e173ea97b2848 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Fri, 13 Oct 2023 19:40:33 +0300 Subject: [PATCH 1116/1140] (#20038) libharu: add version 2.4.4 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/libharu/all/conandata.yml | 3 +++ recipes/libharu/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libharu/all/conandata.yml b/recipes/libharu/all/conandata.yml index 29a286d695d61d..0e549c3a82e1fc 100644 --- a/recipes/libharu/all/conandata.yml +++ b/recipes/libharu/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.4.4": + url: "https://github.com/libharu/libharu/archive/v2.4.4.tar.gz" + sha256: "227ab0ae62979ad65c27a9bc36d85aa77794db3375a0a30af18acdf4d871aee6" "2.4.3": url: "https://github.com/libharu/libharu/archive/refs/tags/v2.4.3.tar.gz" sha256: "a2c3ae4261504a0fda25b09e7babe5df02b21803dd1308fdf105588f7589d255" diff --git a/recipes/libharu/config.yml b/recipes/libharu/config.yml index 39ca57fe00f3bb..be72156e0ef73a 100644 --- a/recipes/libharu/config.yml +++ b/recipes/libharu/config.yml @@ -1,4 +1,6 @@ versions: + "2.4.4": + folder: "all" "2.4.3": folder: "all" "2.3.0": From e79c84ef264b967b21c72a7fa6dfeaf8a4cd2a1c Mon Sep 17 00:00:00 2001 From: Gavin Date: Fri, 13 Oct 2023 13:12:10 -0400 Subject: [PATCH 1117/1140] (#19877) Updated ImGui. Added the imgui_stdlib source and header file * Added the imgui_stdlib source and header file * imgui_stdlib.cpp no longer compiled into library - now included int he include folder so that i can be manually added to a source file by the user * src/h files for stdlib/freetype extensions are included in res folder * imgui src files included in res folder * imgui.cpp added --------- Co-authored-by: Carlos Zoido --- recipes/imgui/all/CMakeLists.txt | 1 + recipes/imgui/all/conanfile.py | 9 +++++++++ 2 files changed, 10 insertions(+) diff --git a/recipes/imgui/all/CMakeLists.txt b/recipes/imgui/all/CMakeLists.txt index 97b98049ec042b..0626bf7008e526 100644 --- a/recipes/imgui/all/CMakeLists.txt +++ b/recipes/imgui/all/CMakeLists.txt @@ -7,6 +7,7 @@ set(IMGUI_EXPORT_HEADERS imgui_export_headers.h) file(GLOB SOURCE_FILES ${IMGUI_SRC_DIR}/*.cpp) file(GLOB HEADER_FILES ${IMGUI_SRC_DIR}/*.h) + file(GLOB EXTRA_FONTS_FILES ${EXTRA_FONTS_DIR}/*.ttf) if (MSVC) file(GLOB EXTRA_NATVIS_FILES ${MISC_DIR}/natvis/*.natvis) diff --git a/recipes/imgui/all/conanfile.py b/recipes/imgui/all/conanfile.py index b71a56e771c7a5..ffe8b2248047c5 100644 --- a/recipes/imgui/all/conanfile.py +++ b/recipes/imgui/all/conanfile.py @@ -77,6 +77,15 @@ def package(self): copy(self, pattern="imgui_impl_*", dst=os.path.join(self.package_folder, "res", "bindings"), src=backends_folder) + copy(self, pattern="imgui*.cpp", + dst=os.path.join(self.package_folder, "res", "src"), + src=os.path.join(self.source_folder)) + copy(self, pattern="*.*", + dst=os.path.join(self.package_folder, "res", "misc", "cpp"), + src=os.path.join(self.source_folder, "misc", "cpp")) + copy(self, pattern="*.*", + dst=os.path.join(self.package_folder, "res", "misc", "freetype"), + src=os.path.join(self.source_folder, "misc", "freetype")) cmake = CMake(self) cmake.install() From 63af0f5ce4cd6f3d28b8429032bafa626883e0a4 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 14 Oct 2023 03:42:32 +0900 Subject: [PATCH 1118/1140] (#20559) luau: add version 0.598 --- recipes/luau/all/conandata.yml | 3 +++ recipes/luau/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/luau/all/conandata.yml b/recipes/luau/all/conandata.yml index 8561d42700a294..a1b979b6920f06 100644 --- a/recipes/luau/all/conandata.yml +++ b/recipes/luau/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.598": + url: "https://github.com/Roblox/luau/archive/0.598.tar.gz" + sha256: "a2bab4b513fe5f2fe174c45de4807846e6ce83420c9ba7a34c81c48b99e01c98" "0.593": url: "https://github.com/Roblox/luau/archive/0.593.tar.gz" sha256: "1cbe4390ef71bb0f2210853978c900974aa02fab73de92b6e18e7bb10dd0e3c1" diff --git a/recipes/luau/config.yml b/recipes/luau/config.yml index ce328e74955788..1b6e2a1736bdbf 100644 --- a/recipes/luau/config.yml +++ b/recipes/luau/config.yml @@ -1,4 +1,6 @@ versions: + "0.598": + folder: all "0.593": folder: all "0.589": From a4572c4bff3415e5f64c14d555877f5ff0a525e7 Mon Sep 17 00:00:00 2001 From: toge Date: Sat, 14 Oct 2023 10:29:28 +0900 Subject: [PATCH 1119/1140] (#20469) embedded_ringbuf_cpp: add recipe MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * embedded_ringbuf_cpp: add recipe * fix license filename * drop msvc * add package_type, add header-only topic Co-authored-by: Rubén Rincón Blanco --------- Co-authored-by: Rubén Rincón Blanco --- .../embedded_ringbuf_cpp/all/conandata.yml | 4 ++ recipes/embedded_ringbuf_cpp/all/conanfile.py | 47 +++++++++++++++++++ .../all/test_package/CMakeLists.txt | 6 +++ .../all/test_package/conanfile.py | 26 ++++++++++ .../all/test_package/test_package.cpp | 15 ++++++ recipes/embedded_ringbuf_cpp/config.yml | 3 ++ 6 files changed, 101 insertions(+) create mode 100644 recipes/embedded_ringbuf_cpp/all/conandata.yml create mode 100644 recipes/embedded_ringbuf_cpp/all/conanfile.py create mode 100644 recipes/embedded_ringbuf_cpp/all/test_package/CMakeLists.txt create mode 100644 recipes/embedded_ringbuf_cpp/all/test_package/conanfile.py create mode 100644 recipes/embedded_ringbuf_cpp/all/test_package/test_package.cpp create mode 100644 recipes/embedded_ringbuf_cpp/config.yml diff --git a/recipes/embedded_ringbuf_cpp/all/conandata.yml b/recipes/embedded_ringbuf_cpp/all/conandata.yml new file mode 100644 index 00000000000000..123dfa02585908 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/all/conandata.yml @@ -0,0 +1,4 @@ +sources: + "1.3": + url: "https://github.com/wizard97/Embedded_RingBuf_CPP/archive/refs/tags/1.3.tar.gz" + sha256: "52340d9762e48b507810458507105c79c57c4d9bff2a9faec6c48bbf65ed2290" diff --git a/recipes/embedded_ringbuf_cpp/all/conanfile.py b/recipes/embedded_ringbuf_cpp/all/conanfile.py new file mode 100644 index 00000000000000..177f5ad4ff7854 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/all/conanfile.py @@ -0,0 +1,47 @@ +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.files import get, copy +from conan.tools.layout import basic_layout +from conan.tools.microsoft import is_msvc +import os + +required_conan_version = ">=1.52.0" + +class EmbeddedRingbufcppConan(ConanFile): + name = "embedded_ringbuf_cpp" + description = "A simple C++ Ring (Circular) Buffer Queuing Library for Programming with Arduino's and other Embedded platforms" + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + homepage = "https://github.com/wizard97/Embedded_RingBuf_CPP/" + topics = ("ring buffer", "circular buffer", "queue", "data-structures", "header-only") + + package_type = "header-library" + settings = "os", "arch", "compiler", "build_type" + no_copy_source = True + + def layout(self): + basic_layout(self, src_folder="src") + + def package_id(self): + self.info.clear() + + def validate(self): + # embedded_ringbuf_cpp uses #warning preprocessor directive + if is_msvc(self): + raise ConanInvalidConfiguration(f"{self.ref} doesn't support Visual Studio and msvc.") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def package(self): + copy(self, pattern="LICENSE.txt", dst=os.path.join(self.package_folder, "licenses"), src=self.source_folder) + copy( + self, + pattern="RingBuf*.h", + dst=os.path.join(self.package_folder, "include"), + src=self.source_folder, + ) + + def package_info(self): + self.cpp_info.bindirs = [] + self.cpp_info.libdirs = [] diff --git a/recipes/embedded_ringbuf_cpp/all/test_package/CMakeLists.txt b/recipes/embedded_ringbuf_cpp/all/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..ac26e4c63d05b1 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/all/test_package/CMakeLists.txt @@ -0,0 +1,6 @@ +cmake_minimum_required(VERSION 3.8) +project(test_package LANGUAGES CXX) + +find_package(embedded_ringbuf_cpp CONFIG REQUIRED) +add_executable(${PROJECT_NAME} test_package.cpp) +target_link_libraries(${PROJECT_NAME} PRIVATE embedded_ringbuf_cpp::embedded_ringbuf_cpp) diff --git a/recipes/embedded_ringbuf_cpp/all/test_package/conanfile.py b/recipes/embedded_ringbuf_cpp/all/test_package/conanfile.py new file mode 100644 index 00000000000000..3a91c9439218e3 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/all/test_package/conanfile.py @@ -0,0 +1,26 @@ +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import cmake_layout, CMake +import os + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def layout(self): + cmake_layout(self) + + def requirements(self): + self.requires(self.tested_reference_str) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindir, "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/embedded_ringbuf_cpp/all/test_package/test_package.cpp b/recipes/embedded_ringbuf_cpp/all/test_package/test_package.cpp new file mode 100644 index 00000000000000..c12de1cdf78c11 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/all/test_package/test_package.cpp @@ -0,0 +1,15 @@ +// size_t is needed for RingBufCPP +#include + +#include + +int main() { + RingBufCPP q; + + q.add(12); + + int tmp; + q.pull(&tmp); + + return 0; +} diff --git a/recipes/embedded_ringbuf_cpp/config.yml b/recipes/embedded_ringbuf_cpp/config.yml new file mode 100644 index 00000000000000..d2eb4ed4a511f9 --- /dev/null +++ b/recipes/embedded_ringbuf_cpp/config.yml @@ -0,0 +1,3 @@ +versions: + "1.3": + folder: all From e02449d45cbe64cdd9c5ba3a531135ca21d10fde Mon Sep 17 00:00:00 2001 From: ericLemanissier Date: Sat, 14 Oct 2023 03:56:08 +0200 Subject: [PATCH 1120/1140] (#20514) qt 6.6.0 * qt 6.6.0 generated with: ``` conan config install https://github.com/conan-io/conan-extensions.git conan cci:upgrade-qt-recipe 6.6.0 ``` * add resolv to network system libs on macos --- recipes/qt/6.x.x/conandata.yml | 25 ++ recipes/qt/6.x.x/conanfile.py | 2 + recipes/qt/6.x.x/patches/c72097e_6.6.0.diff | 42 +++ recipes/qt/6.x.x/qtmodules6.6.0.conf | 338 ++++++++++++++++++++ recipes/qt/config.yml | 2 + 5 files changed, 409 insertions(+) create mode 100644 recipes/qt/6.x.x/patches/c72097e_6.6.0.diff create mode 100644 recipes/qt/6.x.x/qtmodules6.6.0.conf diff --git a/recipes/qt/6.x.x/conandata.yml b/recipes/qt/6.x.x/conandata.yml index a0c2a35fafbd7a..c7703da5dc28f1 100644 --- a/recipes/qt/6.x.x/conandata.yml +++ b/recipes/qt/6.x.x/conandata.yml @@ -1,4 +1,25 @@ sources: + "6.6.0": + url: + - "https://download.qt.io/official_releases/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://download.qt.io/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://qt.mirror.constant.com/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirrors.ukfast.co.uk/sites/qt.io/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirrors.20i.com/pub/qt.io/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.nluug.nl/languages/qt/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirror.netcologne.de/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirror.web4africa.ng/qt/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://qt-mirror.dannhauer.de/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.fau.de/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirrors.dotsrc.org/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.icm.edu.pl/packages/qt/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.acc.umu.se/mirror/qt.io/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://www.nic.funet.fi/pub/mirrors/download.qt-project.org/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://qtproject.mirror.liquidtelecom.com/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://mirrors.sjtug.sjtu.edu.cn/qt/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.jaist.ac.jp/pub/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + - "https://ftp.yz.yamagata-u.ac.jp/pub/qtproject/archive/qt/6.6/6.6.0/single/qt-everywhere-src-6.6.0.tar.xz" + sha256: "652538fcb5d175d8f8176c84c847b79177c87847b7273dccaec1897d80b50002" "6.5.3": url: - "https://download.qt.io/official_releases/qt/6.5/6.5.3/single/qt-everywhere-src-6.5.3.tar.xz" @@ -84,6 +105,10 @@ sources: - "https://mirrors.ustc.edu.cn/qtproject/archive/qt/6.3/6.3.2/single/qt-everywhere-src-6.3.2.tar.xz" sha256: "b90524f686224a0e5a945c1d65307e16a375348dbe275c9ac11de171fe31374a" patches: + "6.6.0": + - "base_path": "qtwebengine" + "patch_description": "Workaround for too long .rps file name" + "patch_file": "patches/c72097e_6.6.0.diff" "6.5.3": - "base_path": "qtwebengine" "patch_description": "Workaround for too long .rps file name" diff --git a/recipes/qt/6.x.x/conanfile.py b/recipes/qt/6.x.x/conanfile.py index c00b4d63c6bfe7..769e317fad83e0 100644 --- a/recipes/qt/6.x.x/conanfile.py +++ b/recipes/qt/6.x.x/conanfile.py @@ -26,6 +26,7 @@ class QtConan(ConanFile): "qtserialport", "qtwebsockets", "qtwebchannel", "qtwebengine", "qtwebview", "qtremoteobjects", "qtpositioning", "qtlanguageserver", "qtspeech", "qthttpserver", "qtquick3dphysics", "qtgrpc", "qtquickeffectmaker"] + _submodules += ["qtgraphs"] # new modules for qt 6.6.0 name = "qt" description = "Qt is a cross-platform framework for graphical user interfaces." @@ -1324,6 +1325,7 @@ def _create_plugin(pluginname, libname, plugintype, requires): self.cpp_info.components["qtCore"].frameworks.append("IOKit") # qtcore requires "_IORegistryEntryCreateCFProperty", "_IOServiceGetMatchingService" and much more which are in "IOKit" framework self.cpp_info.components["qtCore"].frameworks.append("Cocoa") # qtcore requires "_OBJC_CLASS_$_NSApplication" and more, which are in "Cocoa" framework self.cpp_info.components["qtCore"].frameworks.append("Security") # qtcore requires "_SecRequirementCreateWithString" and more, which are in "Security" framework + self.cpp_info.components["qtNetwork"].system_libs.append("resolv") self.cpp_info.components["qtNetwork"].frameworks.append("SystemConfiguration") if self.options.with_gssapi: self.cpp_info.components["qtNetwork"].frameworks.append("GSS") diff --git a/recipes/qt/6.x.x/patches/c72097e_6.6.0.diff b/recipes/qt/6.x.x/patches/c72097e_6.6.0.diff new file mode 100644 index 00000000000000..968f4abf220b6e --- /dev/null +++ b/recipes/qt/6.x.x/patches/c72097e_6.6.0.diff @@ -0,0 +1,42 @@ +From c72097e8790553771daf3231124c3fbe1a438379 Mon Sep 17 00:00:00 2001 +From: Samuli Piippo +Date: Thu, 30 Mar 2017 11:37:24 +0300 +Subject: [PATCH] chromium: workaround for too long .rps file name + +Ninja may fail when the build directory is too long: + +ninja: error: WriteFile(__third_party_WebKit_Source_bindings_modules_\ +interfaces_info_individual_modules__home_qt_work_build_build-nitrogen\ +6x_tmp_work_cortexa9hf-neon-mx6qdl-poky-linux-gnueabi_qtwebengine_5.9\ +.0_gitAUTOINC_29afdb0a34_049134677a-r0_build_src_toolchain_target__ru\ +le.rsp): Unable to create file. File name too long + +Task-number: QTBUG-59769 +Change-Id: I73c5e64ae5174412be2a675e35b0b6047f2bf4c1 +--- + src/3rdparty/gn/src/gn/ninja_action_target_writer.cc | 9 +++++++++ + 1 file changed, 9 insertions(+) + +diff --git a/src/3rdparty/gn/src/gn/ninja_action_target_writer.cc b/src/3rdparty/gn/src/gn/ninja_action_target_writer.cc +index a5bc6cd..5cefbfe 100644 +--- a/src/3rdparty/gn/src/gn/ninja_action_target_writer.cc ++++ b/src/3rdparty/gn/tosrcols/gn/ninja_action_target_writer.cc +@@ -125,9 +125,18 @@ std::string NinjaActionTargetWriter::WriteRuleDefinition() { + // strictly necessary for regular one-shot actions, but it's easier to + // just always define unique_name. + std::string rspfile = custom_rule_name; ++ ++ //quick workaround if filename length > 255 - ".rsp", just cut the dirs starting from the end ++ //please note ".$unique_name" is not used at the moment ++ int pos = 0; ++ std::string delimiter("_"); ++ while (rspfile.length() > 250 && (pos = rspfile.find_last_of(delimiter)) != std::string::npos) ++ rspfile = rspfile.substr(0,pos); ++ + if (!target_->sources().empty()) + rspfile += ".$unique_name"; + rspfile += ".rsp"; ++ + out_ << " rspfile = " << rspfile << std::endl; + + // Response file contents. diff --git a/recipes/qt/6.x.x/qtmodules6.6.0.conf b/recipes/qt/6.x.x/qtmodules6.6.0.conf new file mode 100644 index 00000000000000..e3853727b0712c --- /dev/null +++ b/recipes/qt/6.x.x/qtmodules6.6.0.conf @@ -0,0 +1,338 @@ +[submodule "qtbase"] + path = qtbase + url = ../qtbase.git + branch = 6.6.0 + status = essential +[submodule "qtsvg"] + depends = qtbase + path = qtsvg + url = ../qtsvg.git + branch = 6.6.0 + status = addon +[submodule "qtdeclarative"] + depends = qtbase + recommends = qtimageformats qtshadertools qtsvg qtlanguageserver + path = qtdeclarative + url = ../qtdeclarative.git + branch = 6.6.0 + status = essential +[submodule "qtactiveqt"] + depends = qtbase + path = qtactiveqt + url = ../qtactiveqt.git + branch = 6.6.0 + status = addon +[submodule "qtmultimedia"] + depends = qtbase qtshadertools + recommends = qtdeclarative qtquick3d + path = qtmultimedia + url = ../qtmultimedia.git + branch = 6.6.0 + status = addon +[submodule "qttools"] + depends = qtbase + recommends = qtdeclarative qtactiveqt + path = qttools + url = ../qttools.git + branch = 6.6.0 + status = essential +[submodule "qtxmlpatterns"] + depends = qtbase + recommends = qtdeclarative + path = qtxmlpatterns + url = ../qtxmlpatterns.git + branch = dev + status = ignore +[submodule "qttranslations"] + depends = qttools + path = qttranslations + url = ../qttranslations.git + branch = 6.6.0 + status = essential + priority = 30 +[submodule "qtdoc"] + depends = qtdeclarative qttools + recommends = qtmultimedia qtshadertools qtwebengine + path = qtdoc + url = ../qtdoc.git + branch = 6.6.0 + status = essential + priority = 40 +[submodule "qtrepotools"] + path = qtrepotools + url = ../qtrepotools.git + branch = master + status = essential + project = - +[submodule "qtqa"] + depends = qtbase + path = qtqa + url = ../qtqa.git + branch = dev + status = essential + priority = 50 +[submodule "qtlocation"] + depends = qtbase qtpositioning + recommends = qtdeclarative + path = qtlocation + url = ../qtlocation.git + branch = 6.6.0 + status = preview +[submodule "qtpositioning"] + depends = qtbase + recommends = qtdeclarative qtserialport + path = qtpositioning + url = ../qtpositioning.git + branch = 6.6.0 + status = addon +[submodule "qtsensors"] + depends = qtbase + recommends = qtdeclarative + path = qtsensors + url = ../qtsensors.git + branch = 6.6.0 + status = addon +[submodule "qtsystems"] + depends = qtbase + recommends = qtdeclarative + path = qtsystems + url = ../qtsystems.git + branch = dev + status = ignore +[submodule "qtfeedback"] + depends = qtdeclarative + recommends = qtmultimedia + path = qtfeedback + url = ../qtfeedback.git + branch = master + status = ignore +[submodule "qtpim"] + depends = qtdeclarative + path = qtpim + url = ../qtpim.git + branch = dev + status = ignore +[submodule "qtconnectivity"] + depends = qtbase + recommends = qtdeclarative + path = qtconnectivity + url = ../qtconnectivity.git + branch = 6.6.0 + status = addon +[submodule "qtwayland"] + depends = qtbase + recommends = qtdeclarative + path = qtwayland + url = ../qtwayland.git + branch = 6.6.0 + status = addon +[submodule "qt3d"] + depends = qtbase + recommends = qtdeclarative qtshadertools qtmultimedia + path = qt3d + url = ../qt3d.git + branch = 6.6.0 + status = addon +[submodule "qtimageformats"] + depends = qtbase + path = qtimageformats + url = ../qtimageformats.git + branch = 6.6.0 + status = addon +[submodule "qtserialbus"] + depends = qtbase + recommends = qtserialport + path = qtserialbus + url = ../qtserialbus.git + branch = 6.6.0 + status = addon +[submodule "qtserialport"] + depends = qtbase + path = qtserialport + url = ../qtserialport.git + branch = 6.6.0 + status = addon +[submodule "qtwebsockets"] + depends = qtbase + recommends = qtdeclarative + path = qtwebsockets + url = ../qtwebsockets.git + branch = 6.6.0 + status = addon +[submodule "qtwebchannel"] + depends = qtbase + recommends = qtdeclarative qtwebsockets + path = qtwebchannel + url = ../qtwebchannel.git + branch = 6.6.0 + status = addon +[submodule "qtwebengine"] + depends = qtdeclarative + recommends = qtwebchannel qttools qtpositioning + path = qtwebengine + url = ../qtwebengine.git + branch = 6.6.0 + status = addon + priority = 10 +[submodule "qtcanvas3d"] + depends = qtdeclarative + path = qtcanvas3d + url = ../qtcanvas3d.git + branch = dev + status = ignore +[submodule "qtwebview"] + depends = qtdeclarative + recommends = qtwebengine + path = qtwebview + url = ../qtwebview.git + branch = 6.6.0 + status = addon +[submodule "qtcharts"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtcharts + url = ../qtcharts.git + branch = 6.6.0 + status = addon +[submodule "qtdatavis3d"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtdatavis3d + url = ../qtdatavis3d.git + branch = 6.6.0 + status = addon +[submodule "qtvirtualkeyboard"] + depends = qtbase qtdeclarative qtsvg + recommends = qtmultimedia + path = qtvirtualkeyboard + url = ../qtvirtualkeyboard.git + branch = 6.6.0 + status = addon +[submodule "qtgamepad"] + depends = qtbase + recommends = qtdeclarative + path = qtgamepad + url = ../qtgamepad.git + branch = dev + status = ignore +[submodule "qtscxml"] + depends = qtbase qtdeclarative + path = qtscxml + url = ../qtscxml.git + branch = 6.6.0 + status = addon +[submodule "qtspeech"] + depends = qtbase + recommends = qtdeclarative qtmultimedia + path = qtspeech + url = ../qtspeech.git + branch = 6.6.0 + status = addon +[submodule "qtnetworkauth"] + depends = qtbase + path = qtnetworkauth + url = ../qtnetworkauth.git + branch = 6.6.0 + status = addon +[submodule "qtremoteobjects"] + depends = qtbase + recommends = qtdeclarative + path = qtremoteobjects + url = ../qtremoteobjects.git + branch = 6.6.0 + status = addon +[submodule "qtwebglplugin"] + depends = qtbase qtwebsockets + recommends = qtdeclarative + path = qtwebglplugin + url = ../qtwebglplugin.git + branch = dev + status = ignore +[submodule "qtlottie"] + depends = qtbase qtdeclarative + path = qtlottie + url = ../qtlottie.git + branch = 6.6.0 + status = addon +[submodule "qtquicktimeline"] + depends = qtbase qtdeclarative + path = qtquicktimeline + url = ../qtquicktimeline + branch = 6.6.0 + status = addon +[submodule "qtquick3d"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquicktimeline + path = qtquick3d + url = ../qtquick3d.git + branch = 6.6.0 + status = addon +[submodule "qtshadertools"] + depends = qtbase + path = qtshadertools + url = ../qtshadertools.git + branch = 6.6.0 + status = addon +[submodule "qt5compat"] + depends = qtbase qtdeclarative + path = qt5compat + url = ../qt5compat.git + branch = 6.6.0 + status = deprecated +[submodule "qtcoap"] + depends = qtbase + path = qtcoap + url = ../qtcoap.git + branch = 6.6.0 + status = addon +[submodule "qtmqtt"] + depends = qtbase qtdeclarative + path = qtmqtt + url = ../qtmqtt.git + branch = 6.6.0 + status = addon +[submodule "qtopcua"] + depends = qtbase qtdeclarative + path = qtopcua + url = ../qtopcua.git + branch = 6.6.0 + status = addon +[submodule "qtlanguageserver"] + depends = qtbase + path = qtlanguageserver + url = ../qtlanguageserver.git + branch = 6.6.0 + status = preview +[submodule "qthttpserver"] + depends = qtbase + recommends = qtwebsockets + path = qthttpserver + url = ../qthttpserver.git + branch = 6.6.0 + status = preview +[submodule "qtquick3dphysics"] + depends = qtbase qtdeclarative qtquick3d qtshadertools + path = qtquick3dphysics + url = ../qtquick3dphysics.git + branch = 6.6.0 + status = addon +[submodule "qtgrpc"] + depends = qtbase + recommends = qtdeclarative + path = qtgrpc + url = ../qtgrpc.git + branch = 6.6.0 + status = preview +[submodule "qtquickeffectmaker"] + depends = qtbase qtdeclarative qtshadertools + recommends = qtquick3d + path = qtquickeffectmaker + url = ../qtquickeffectmaker.git + branch = 6.6.0 + status = addon +[submodule "qtgraphs"] + depends = qtbase qtdeclarative qtquick3d + path = qtgraphs + url = ../qtgraphs.git + branch = 6.6.0 + status = preview diff --git a/recipes/qt/config.yml b/recipes/qt/config.yml index 6df0033404d92c..787fe5656bf21c 100644 --- a/recipes/qt/config.yml +++ b/recipes/qt/config.yml @@ -1,4 +1,6 @@ versions: + "6.6.0": + folder: 6.x.x "6.5.3": folder: 6.x.x "6.5.2": From b5c024d59128c56d887a4fdb7986ad2ea340a5fc Mon Sep 17 00:00:00 2001 From: Jordan Williams Date: Fri, 13 Oct 2023 21:25:49 -0500 Subject: [PATCH 1121/1140] (#20523) libmount: Add version 2.39.2 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Rubén Rincón Blanco --- recipes/libmount/all/conandata.yml | 3 +++ recipes/libmount/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/libmount/all/conandata.yml b/recipes/libmount/all/conandata.yml index 18c98b7cab46ce..d36ca36c23c13b 100644 --- a/recipes/libmount/all/conandata.yml +++ b/recipes/libmount/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "2.39.2": + url: "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.39/util-linux-2.39.2.tar.xz" + sha256: "87abdfaa8e490f8be6dde976f7c80b9b5ff9f301e1b67e3899e1f05a59a1531f" "2.39": url: "https://mirrors.edge.kernel.org/pub/linux/utils/util-linux/v2.39/util-linux-2.39.tar.xz" sha256: "32b30a336cda903182ed61feb3e9b908b762a5e66fe14e43efb88d37162075cb" diff --git a/recipes/libmount/config.yml b/recipes/libmount/config.yml index b9150d1aa9e481..867141253ca23f 100644 --- a/recipes/libmount/config.yml +++ b/recipes/libmount/config.yml @@ -1,4 +1,6 @@ versions: + "2.39.2": + folder: all "2.39": folder: all "2.36.2": From 4007834675f8e58aaca43020f8a0dbe25bd57ab4 Mon Sep 17 00:00:00 2001 From: Toni Neubert Date: Sat, 14 Oct 2023 15:10:48 +0200 Subject: [PATCH 1122/1140] (#20567) emio: add version 0.6.0 --- recipes/emio/all/conandata.yml | 3 +++ recipes/emio/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/emio/all/conandata.yml b/recipes/emio/all/conandata.yml index f62ffc65b5b74e..c729fb82ca3f51 100644 --- a/recipes/emio/all/conandata.yml +++ b/recipes/emio/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.6.0": + url: "https://github.com/viatorus/emio/archive/0.6.0.tar.gz" + sha256: "789c0c1b73d2add1caef9ffd90bc2dd0286e31a0f0f5dc12ff206eb32c394a98" "0.5.0": url: "https://github.com/viatorus/emio/archive/0.5.0.tar.gz" sha256: "14cfa81d96db6ef74b8da7b5d2ffbd26535f2930d0d423e4fde7b526ddb3b308" diff --git a/recipes/emio/config.yml b/recipes/emio/config.yml index 9582e7461fbc51..03142756fc88cd 100644 --- a/recipes/emio/config.yml +++ b/recipes/emio/config.yml @@ -1,4 +1,6 @@ versions: + "0.6.0": + folder: all "0.5.0": folder: all "0.4.0": From a3d4283712c788edd438c4d68ec071d3f4437c91 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sat, 14 Oct 2023 17:11:07 +0300 Subject: [PATCH 1123/1140] (#20047) cgif: add version 0.3.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/cgif/all/conandata.yml | 3 +++ recipes/cgif/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/cgif/all/conandata.yml b/recipes/cgif/all/conandata.yml index f6abd559f85fbd..6cfe1b1bc6c905 100644 --- a/recipes/cgif/all/conandata.yml +++ b/recipes/cgif/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.3.2": + url: "https://github.com/dloebl/cgif/archive/V0.3.2.tar.gz" + sha256: "0abf83b7617f4793d9ab3a4d581f4e8d7548b56a29e3f95b0505f842cbfd7f95" "0.3.0": url: "https://github.com/dloebl/cgif/archive/refs/tags/V0.3.0.tar.gz" sha256: "c4f70bbae4c6afee3a524e65be31ae495201fd26687cb8429d7aded8be96306a" diff --git a/recipes/cgif/config.yml b/recipes/cgif/config.yml index d126790212e0c4..be2ba90eb4dc70 100644 --- a/recipes/cgif/config.yml +++ b/recipes/cgif/config.yml @@ -1,3 +1,5 @@ versions: + "0.3.2": + folder: all "0.3.0": folder: all From 991aa227dcddab5f639fc1b632bdab801a46bc71 Mon Sep 17 00:00:00 2001 From: Matthieu Darbois Date: Sat, 14 Oct 2023 16:42:02 +0200 Subject: [PATCH 1124/1140] (#20563) opencv/4.x: bump deps --- recipes/opencv/4.x/conanfile.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/recipes/opencv/4.x/conanfile.py b/recipes/opencv/4.x/conanfile.py index 0f533c33789b50..9a03220f56cd98 100644 --- a/recipes/opencv/4.x/conanfile.py +++ b/recipes/opencv/4.x/conanfile.py @@ -1012,7 +1012,7 @@ def requirements(self): if self.options.with_eigen: self.requires("eigen/3.4.0") if self.options.parallel == "tbb": - self.requires("onetbb/2021.9.0") + self.requires("onetbb/2021.10.0") if self.options.with_ipp == "intel-ipp": self.requires("intel-ipp/2020") # dnn module dependencies @@ -1023,19 +1023,19 @@ def requirements(self): self.requires("vulkan-headers/1.3.250.0") # gapi module dependencies if self.options.gapi: - self.requires("ade/0.1.2a") + self.requires("ade/0.1.2c") # highgui module dependencies if self.options.get_safe("with_gtk"): self.requires("gtk/system") if self.options.get_safe("with_qt"): - self.requires("qt/5.15.10") + self.requires("qt/5.15.11") # imgcodecs module dependencies if self.options.get_safe("with_jpeg") == "libjpeg": self.requires("libjpeg/9e") elif self.options.get_safe("with_jpeg") == "libjpeg-turbo": self.requires("libjpeg-turbo/3.0.0") elif self.options.get_safe("with_jpeg") == "mozjpeg": - self.requires("mozjpeg/4.1.1") + self.requires("mozjpeg/4.1.3") if self.options.get_safe("with_jpeg2000") == "jasper": self.requires("jasper/4.0.0") elif self.options.get_safe("with_jpeg2000") == "openjpeg": @@ -1045,11 +1045,11 @@ def requirements(self): if self.options.get_safe("with_openexr"): self.requires("openexr/3.1.9") if self.options.get_safe("with_tiff"): - self.requires("libtiff/4.5.1") + self.requires("libtiff/4.6.0") if self.options.get_safe("with_webp"): self.requires("libwebp/1.3.2") if self.options.get_safe("with_gdal"): - self.requires("gdal/3.5.2") + self.requires("gdal/3.7.0") if self.options.get_safe("with_gdcm"): self.requires("gdcm/3.0.21") # objdetect module dependencies @@ -1058,11 +1058,11 @@ def requirements(self): # videoio module dependencies if self.options.get_safe("with_ffmpeg"): # opencv doesn't support ffmpeg >= 5.0.0 for the moment (until 4.5.5 at least) - self.requires("ffmpeg/4.4.3") + self.requires("ffmpeg/4.4.4") # freetype module dependencies if self.options.freetype: self.requires("freetype/2.13.0") - self.requires("harfbuzz/8.1.1") + self.requires("harfbuzz/8.2.1") # hdf module dependencies if self.options.hdf: self.requires("hdf5/1.14.1") From 5591c72e3bc3dcc5fd6774acc9c5117c062993f8 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 15 Oct 2023 05:55:39 +0900 Subject: [PATCH 1125/1140] (#20570) ctre: add version 3.8.1 --- recipes/ctre/all/conandata.yml | 3 +++ recipes/ctre/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/ctre/all/conandata.yml b/recipes/ctre/all/conandata.yml index 84177523424ed2..c31706ca559c2e 100644 --- a/recipes/ctre/all/conandata.yml +++ b/recipes/ctre/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.8.1": + url: "https://github.com/hanickadot/compile-time-regular-expressions/archive/v3.8.1.tar.gz" + sha256: "0ce8760d43b3b97b43364cd32ee663e5c8b8b4bfd58e7890042eff6ac52db605" "3.8": url: "https://github.com/hanickadot/compile-time-regular-expressions/archive/v3.8.tar.gz" sha256: "6462ee41fa6aa12075f6b9d13f42358091d32963087443a6669d2c94232eea04" diff --git a/recipes/ctre/config.yml b/recipes/ctre/config.yml index e8d08c6a4805a3..02f3f62c0a4518 100644 --- a/recipes/ctre/config.yml +++ b/recipes/ctre/config.yml @@ -1,4 +1,6 @@ versions: + "3.8.1": + folder: all "3.8": folder: all "3.7.2": From 2992b67c462a76dc40a5f335998588040e5ffb15 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 15 Oct 2023 11:37:39 +0300 Subject: [PATCH 1126/1140] (#20014) pupnp: add version 1.14.18 * pupnp: add version 1.14.18 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * pupnp: fix_apple_shared_install_name() --------- Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/pupnp/all/conandata.yml | 3 +++ recipes/pupnp/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/pupnp/all/conandata.yml b/recipes/pupnp/all/conandata.yml index 388307853302ae..7964480fefad59 100644 --- a/recipes/pupnp/all/conandata.yml +++ b/recipes/pupnp/all/conandata.yml @@ -8,3 +8,6 @@ sources: "1.14.12": url: "https://github.com/pupnp/pupnp/archive/release-1.14.12.tar.gz" sha256: "6a7f26818d5aa3949bc2e68739387a261c564430ba612f793c61d31619dde1e4" + "1.14.18": + url: "https://github.com/pupnp/pupnp/archive/release-1.14.18.tar.gz" + sha256: "8b038be04c04886b6304c0878f7eb502c8f4800524acf44ce8f9cd7f9319df90" diff --git a/recipes/pupnp/config.yml b/recipes/pupnp/config.yml index 700325f13fdc85..1338c7bbcf33f3 100644 --- a/recipes/pupnp/config.yml +++ b/recipes/pupnp/config.yml @@ -5,3 +5,5 @@ versions: folder: all "1.14.12": folder: all + "1.14.18": + folder: all From 34b149f194d4a3e8a141f7cae975bf198654dc3a Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 15 Oct 2023 20:40:49 +0900 Subject: [PATCH 1127/1140] (#20576) mbedtls: add version 3.5.0 --- recipes/mbedtls/all/conandata.yml | 3 +++ recipes/mbedtls/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/mbedtls/all/conandata.yml b/recipes/mbedtls/all/conandata.yml index f923ca0c489a5d..ea482e12f5ff12 100644 --- a/recipes/mbedtls/all/conandata.yml +++ b/recipes/mbedtls/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.5.0": + url: "https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/v3.5.0.tar.gz" + sha256: "bdee0e3e45bbf360541306cac0cc27e00402c7a46b9bdf2d24787d5107f008f2" "3.4.1": url: "https://github.com/Mbed-TLS/mbedtls/archive/refs/tags/v3.4.1.tar.gz" sha256: "a420fcf7103e54e775c383e3751729b8fb2dcd087f6165befd13f28315f754f5" diff --git a/recipes/mbedtls/config.yml b/recipes/mbedtls/config.yml index 6d346411f4a8a4..004f51becf1f56 100644 --- a/recipes/mbedtls/config.yml +++ b/recipes/mbedtls/config.yml @@ -1,4 +1,6 @@ versions: + "3.5.0": + folder: all "3.4.1": folder: all "3.2.1": From 3e1a99d8b04aa00b3c7563801710cd3cdb178e2b Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 15 Oct 2023 14:38:38 +0200 Subject: [PATCH 1128/1140] (#20520) jinja2cpp: fix `JINJA2CPP_CXX_STANDARD` mapping with `compiler.cppstd` when cppstd is `gnu*` * fix JINJA2CPP_CXX_STANDARD mapping with compiler.cppstd when cppstd is `gnu*` * remove unused import --- recipes/jinja2cpp/all/conanfile.py | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/recipes/jinja2cpp/all/conanfile.py b/recipes/jinja2cpp/all/conanfile.py index 8026c45b97a606..7e812e5ef15e35 100644 --- a/recipes/jinja2cpp/all/conanfile.py +++ b/recipes/jinja2cpp/all/conanfile.py @@ -1,7 +1,7 @@ from conan import ConanFile from conan.errors import ConanInvalidConfiguration from conan.tools.microsoft import msvc_runtime_flag, is_msvc -from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rm, rmdir, replace_in_file +from conan.tools.files import apply_conandata_patches, export_conandata_patches, get, copy, rmdir, replace_in_file from conan.tools.build import check_min_cppstd from conan.tools.scm import Version from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout @@ -86,7 +86,9 @@ def generate(self): tc.variables["JINJA2CPP_STRICT_WARNINGS"] = False tc.variables["JINJA2CPP_BUILD_SHARED"] = self.options.shared tc.variables["JINJA2CPP_DEPS_MODE"] = "conan-build" - tc.variables["JINJA2CPP_CXX_STANDARD"] = self.settings.compiler.get_safe("cppstd", 14) + cppstd = self.settings.compiler.get_safe("cppstd") + if cppstd: + tc.cache_variables["JINJA2CPP_CXX_STANDARD"] = str(cppstd).replace("gnu", "") if is_msvc(self): # Runtime type configuration for Jinja2C++ should be strictly '/MT' or '/MD' runtime = "/MD" if "MD" in msvc_runtime_flag(self) else "/MT" From 7198f49baa884750a6b18b2ea6b5e77fa95cbe75 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Sun, 15 Oct 2023 16:06:42 +0300 Subject: [PATCH 1129/1140] (#20035) ssht: add version 1.5.2 * ssht: add version 1.5.2 Generated and committed by [Conan Center Bot](https://github.com/qchateau/conan-center-bot) Find more updatable recipes in the [GitHub Pages](https://qchateau.github.io/conan-center-bot/) * ssht: bump fftw --------- Co-authored-by: Quentin Chateau via Conan Center Bot --- recipes/ssht/all/conandata.yml | 3 +++ recipes/ssht/all/conanfile.py | 2 +- recipes/ssht/config.yml | 2 ++ 3 files changed, 6 insertions(+), 1 deletion(-) diff --git a/recipes/ssht/all/conandata.yml b/recipes/ssht/all/conandata.yml index 077fff5429d558..dab3a69b6f7e96 100644 --- a/recipes/ssht/all/conandata.yml +++ b/recipes/ssht/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.5.2": + url: "https://github.com/astro-informatics/ssht/archive/v1.5.2.tar.gz" + sha256: "6ce3e48d36a4af57cab9d96f5f845f905808dac8ac8b3ec195f6b49d017a890d" "1.4.0": url: "https://github.com/astro-informatics/ssht/archive/v1.4.0.tar.gz" sha256: "b33f1b763a240df773a1900139aad6f6b5c676bb2b64a8c1062077fd95c08769" diff --git a/recipes/ssht/all/conanfile.py b/recipes/ssht/all/conanfile.py index 616e2e41a56b19..aa4695a01d1547 100644 --- a/recipes/ssht/all/conanfile.py +++ b/recipes/ssht/all/conanfile.py @@ -33,7 +33,7 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("fftw/3.3.9") + self.requires("fftw/3.3.10") def validate(self): if is_msvc(self): diff --git a/recipes/ssht/config.yml b/recipes/ssht/config.yml index fc50f8a9c5846a..aca406dbf9f3fc 100644 --- a/recipes/ssht/config.yml +++ b/recipes/ssht/config.yml @@ -1,4 +1,6 @@ versions: + "1.5.2": + folder: all "1.4.0": folder: all "1.3.7": From f55e034586d0c11cab9c7f633b748fc3d95d555c Mon Sep 17 00:00:00 2001 From: Mateusz Pusz Date: Sun, 15 Oct 2023 15:21:09 +0200 Subject: [PATCH 1130/1140] (#20097) Mp-units-2.0 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * mp-units 2.0 added * Homepage updated for mp-units/0.8.0 * Disable msvc and apple-clang for now * Add checks for 2.0.0 branch --------- Co-authored-by: Rubén Rincón Blanco --- recipes/mp-units/0.8.0/conanfile.py | 4 +- recipes/mp-units/2.0.0/conandata.yml | 4 + recipes/mp-units/2.0.0/conanfile.py | 165 ++++++++++++++++++ .../2.0.0/test_package/CMakeLists.txt | 10 ++ .../mp-units/2.0.0/test_package/conanfile.py | 27 +++ .../2.0.0/test_package/test_package.cpp | 16 ++ .../2.0.0/test_v1_package/CMakeLists.txt | 10 ++ .../2.0.0/test_v1_package/conanfile.py | 25 +++ .../2.0.0/test_v1_package/test_package.cpp | 16 ++ recipes/mp-units/config.yml | 2 + 10 files changed, 277 insertions(+), 2 deletions(-) create mode 100644 recipes/mp-units/2.0.0/conandata.yml create mode 100644 recipes/mp-units/2.0.0/conanfile.py create mode 100644 recipes/mp-units/2.0.0/test_package/CMakeLists.txt create mode 100644 recipes/mp-units/2.0.0/test_package/conanfile.py create mode 100644 recipes/mp-units/2.0.0/test_package/test_package.cpp create mode 100644 recipes/mp-units/2.0.0/test_v1_package/CMakeLists.txt create mode 100644 recipes/mp-units/2.0.0/test_v1_package/conanfile.py create mode 100644 recipes/mp-units/2.0.0/test_v1_package/test_package.cpp diff --git a/recipes/mp-units/0.8.0/conanfile.py b/recipes/mp-units/0.8.0/conanfile.py index 360e81be61b3df..c44e1496f2a039 100644 --- a/recipes/mp-units/0.8.0/conanfile.py +++ b/recipes/mp-units/0.8.0/conanfile.py @@ -12,8 +12,8 @@ class MPUnitsConan(ConanFile): name = "mp-units" - homepage = "https://github.com/mpusz/units" - description = "Physical Quantities and Units library for C++" + homepage = "https://github.com/mpusz/mp-units" + description = "A Physical Quantities and Units library for C++" topics = ( "units", "dimensions", diff --git a/recipes/mp-units/2.0.0/conandata.yml b/recipes/mp-units/2.0.0/conandata.yml new file mode 100644 index 00000000000000..79322cc88147b5 --- /dev/null +++ b/recipes/mp-units/2.0.0/conandata.yml @@ -0,0 +1,4 @@ +sources: + "2.0.0": + url: https://github.com/mpusz/units/archive/v2.0.0.tar.gz + sha256: c04cda9fdaeca3ae42886552658e8bde3b608a24a4a921a621a5db41ec416e0e diff --git a/recipes/mp-units/2.0.0/conanfile.py b/recipes/mp-units/2.0.0/conanfile.py new file mode 100644 index 00000000000000..e7312a805414c6 --- /dev/null +++ b/recipes/mp-units/2.0.0/conanfile.py @@ -0,0 +1,165 @@ +import os + +from conan import ConanFile +from conan.errors import ConanInvalidConfiguration +from conan.tools.build import check_min_cppstd +from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout +from conan.tools.files import copy, get, rmdir +from conan.tools.microsoft import is_msvc +from conan.tools.scm import Version + +required_conan_version = ">=1.59.0" + + +class MPUnitsConan(ConanFile): + name = "mp-units" + homepage = "https://github.com/mpusz/mp-units" + description = "A Physical Quantities and Units library for C++" + topics = ( + "units", + "dimensions", + "quantities", + "dimensional-analysis", + "physical-quantities", + "physical-units", + "system-of-units", + "system-of-quantities", + "isq", + "si", + "library", + "quantity-manipulation", + ) + license = "MIT" + url = "https://github.com/conan-io/conan-center-index" + settings = "os", "arch", "compiler", "build_type" + tool_requires = "cmake/[>=3.19 <4]" + package_type = "header-library" + no_copy_source = True + + @property + def _min_cppstd(self): + return "20" + + @property + def _minimum_compilers_version(self): + # Note that apple-clang and msvc are disabled for now, their C++ 20 implementations are not up to speed + return {"gcc": "11", "clang": "16"} + + @property + def _use_libfmt(self): + compiler = self.settings.compiler + version = Version(self.settings.compiler.version) + std_support = compiler == "msvc" and version >= 193 and compiler.cppstd == 23 + return not std_support + + @property + def _use_range_v3(self): + compiler = self.settings.compiler + version = Version(self.settings.compiler.version) + return "clang" in compiler and compiler.libcxx == "libc++" and version < 14 + + def requirements(self): + self.requires("gsl-lite/0.40.0") + if self._use_libfmt: + self.requires("fmt/10.1.0") + if self._use_range_v3: + self.requires("range-v3/0.11.0") + + def validate(self): + if self.settings.get_safe("compiler.cppstd"): + check_min_cppstd(self, self._min_cppstd) + + def loose_lt_semver(v1, v2): + lv1 = [int(v) for v in v1.split(".")] + lv2 = [int(v) for v in v2.split(".")] + min_length = min(len(lv1), len(lv2)) + return lv1[:min_length] < lv2[:min_length] + + compiler = self.settings.compiler + min_version = self._minimum_compilers_version.get(str(compiler)) + if min_version and loose_lt_semver(str(compiler.version), min_version): + raise ConanInvalidConfiguration( + f"{self.ref} requires at least {compiler} {min_version} ({compiler.version} in use)" + ) + + # Note that apple-clang and msvc are disabled for now, their C++ 20 implementations are not up to speed + # Re-enable once newer versions with better support come out + if is_msvc(self) or compiler == "apple-clang": + raise ConanInvalidConfiguration(f"{self.ref} disabled for {compiler} as their C++20 implementation is not up to speed yet") + + def layout(self): + cmake_layout(self, src_folder="src") + + def source(self): + get(self, **self.conan_data["sources"][self.version], strip_root=True) + + def generate(self): + tc = CMakeToolchain(self) + tc.variables["MP_UNITS_USE_LIBFMT"] = self._use_libfmt + tc.generate() + deps = CMakeDeps(self) + deps.generate() + + def build(self): + cmake = CMake(self) + cmake.configure(build_script_folder="src") + cmake.build() + + def package_id(self): + self.info.clear() + + def package(self): + copy( + self, + "LICENSE.md", + self.source_folder, + os.path.join(self.package_folder, "licenses"), + ) + cmake = CMake(self) + cmake.install() + rmdir(self, os.path.join(self.package_folder, "lib", "cmake")) + + def package_info(self): + compiler = self.settings.compiler + + # core + self.cpp_info.components["core"].requires = ["gsl-lite::gsl-lite"] + if compiler == "msvc": + self.cpp_info.components["core"].cxxflags = ["/utf-8"] + if self._use_range_v3: + self.cpp_info.components["core"].requires.append("range-v3::range-v3") + + # rest + self.cpp_info.components["core-io"].requires = ["core"] + self.cpp_info.components["core-fmt"].requires = ["core"] + if self._use_libfmt: + self.cpp_info.components["core-fmt"].requires.append("fmt::fmt") + self.cpp_info.components["utility"].requires = ["core", "isq", "si", "angular"] + self.cpp_info.components["isq"].requires = ["core"] + self.cpp_info.components["angular"].requires = ["isq"] + self.cpp_info.components["isq_angular"].requires = ["isq", "angular"] + self.cpp_info.components["natural"].requires = ["isq"] + self.cpp_info.components["si"].requires = ["isq"] + self.cpp_info.components["cgs"].requires = ["si"] + self.cpp_info.components["hep"].requires = ["si"] + self.cpp_info.components["iau"].requires = ["si"] + self.cpp_info.components["imperial"].requires = ["si"] + self.cpp_info.components["international"].requires = ["si"] + self.cpp_info.components["typographic"].requires = ["usc"] + self.cpp_info.components["usc"].requires = ["international"] + self.cpp_info.components["iec80000"].requires = ["isq", "si"] + self.cpp_info.components["systems"].requires = [ + "isq", + "angular", + "isq_angular", + "natural", + "si", + "cgs", + "hep", + "iau", + "imperial", + "international", + "typographic", + "usc", + "iec80000", + ] diff --git a/recipes/mp-units/2.0.0/test_package/CMakeLists.txt b/recipes/mp-units/2.0.0/test_package/CMakeLists.txt new file mode 100644 index 00000000000000..07f3e7cd91e8a7 --- /dev/null +++ b/recipes/mp-units/2.0.0/test_package/CMakeLists.txt @@ -0,0 +1,10 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package + LANGUAGES CXX +) + +find_package(mp-units CONFIG REQUIRED) + +add_executable(test_package test_package.cpp) +target_link_libraries(test_package PRIVATE mp-units::mp-units) +target_compile_features(test_package PUBLIC cxx_std_20) diff --git a/recipes/mp-units/2.0.0/test_package/conanfile.py b/recipes/mp-units/2.0.0/test_package/conanfile.py new file mode 100644 index 00000000000000..e418ee7701960b --- /dev/null +++ b/recipes/mp-units/2.0.0/test_package/conanfile.py @@ -0,0 +1,27 @@ +import os + +from conan import ConanFile +from conan.tools.build import can_run +from conan.tools.cmake import CMake, cmake_layout + + +class TestPackageConan(ConanFile): + settings = "os", "arch", "compiler", "build_type" + generators = "CMakeDeps", "CMakeToolchain", "VirtualRunEnv" + test_type = "explicit" + + def requirements(self): + self.requires(self.tested_reference_str) + + def layout(self): + cmake_layout(self) + + def build(self): + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if can_run(self): + bin_path = os.path.join(self.cpp.build.bindirs[0], "test_package") + self.run(bin_path, env="conanrun") diff --git a/recipes/mp-units/2.0.0/test_package/test_package.cpp b/recipes/mp-units/2.0.0/test_package/test_package.cpp new file mode 100644 index 00000000000000..f7a82eba1d2def --- /dev/null +++ b/recipes/mp-units/2.0.0/test_package/test_package.cpp @@ -0,0 +1,16 @@ +#include +#include +#include + +using namespace mp_units; + +constexpr auto avg_speed(QuantityOf auto d, QuantityOf auto t) +{ + return d / t; +} + +int main() +{ + using namespace mp_units::si::unit_symbols; + std::cout << "Average speed = " << avg_speed(240 * km, 2 * h) << '\n'; +} diff --git a/recipes/mp-units/2.0.0/test_v1_package/CMakeLists.txt b/recipes/mp-units/2.0.0/test_v1_package/CMakeLists.txt new file mode 100644 index 00000000000000..07f3e7cd91e8a7 --- /dev/null +++ b/recipes/mp-units/2.0.0/test_v1_package/CMakeLists.txt @@ -0,0 +1,10 @@ +cmake_minimum_required(VERSION 3.15) +project(test_package + LANGUAGES CXX +) + +find_package(mp-units CONFIG REQUIRED) + +add_executable(test_package test_package.cpp) +target_link_libraries(test_package PRIVATE mp-units::mp-units) +target_compile_features(test_package PUBLIC cxx_std_20) diff --git a/recipes/mp-units/2.0.0/test_v1_package/conanfile.py b/recipes/mp-units/2.0.0/test_v1_package/conanfile.py new file mode 100644 index 00000000000000..048e0f9557d476 --- /dev/null +++ b/recipes/mp-units/2.0.0/test_v1_package/conanfile.py @@ -0,0 +1,25 @@ +from conans import ConanFile, CMake, tools +from conans.tools import Version +import os + + +class TestPackageConan(ConanFile): + settings = "os", "compiler", "build_type", "arch" + generators = "cmake_find_package_multi" + + # TODO remove when https://github.com/conan-io/conan/issues/7680 is solved (or VS2019 is updated to at least 16.9) + def _skip_check(self): + return self.settings.compiler == "Visual Studio" and Version(self.settings.compiler.version) <= "16" + + def build(self): + if self._skip_check(): + return + cmake = CMake(self) + cmake.configure() + cmake.build() + + def test(self): + if self._skip_check(): + return + if not tools.cross_building(self.settings): + self.run("test_package", run_environment=True) diff --git a/recipes/mp-units/2.0.0/test_v1_package/test_package.cpp b/recipes/mp-units/2.0.0/test_v1_package/test_package.cpp new file mode 100644 index 00000000000000..f7a82eba1d2def --- /dev/null +++ b/recipes/mp-units/2.0.0/test_v1_package/test_package.cpp @@ -0,0 +1,16 @@ +#include +#include +#include + +using namespace mp_units; + +constexpr auto avg_speed(QuantityOf auto d, QuantityOf auto t) +{ + return d / t; +} + +int main() +{ + using namespace mp_units::si::unit_symbols; + std::cout << "Average speed = " << avg_speed(240 * km, 2 * h) << '\n'; +} diff --git a/recipes/mp-units/config.yml b/recipes/mp-units/config.yml index 384108bf7c63a2..80a7d8dff9ed14 100644 --- a/recipes/mp-units/config.yml +++ b/recipes/mp-units/config.yml @@ -1,3 +1,5 @@ versions: "0.8.0": folder: 0.8.0 + "2.0.0": + folder: 2.0.0 From ae5295acacb063a57041a3448707c1da9fa937d7 Mon Sep 17 00:00:00 2001 From: toge Date: Sun, 15 Oct 2023 22:39:15 +0900 Subject: [PATCH 1131/1140] (#20286) drogon: add version 1.8.7, update dependencies --- recipes/drogon/all/conandata.yml | 10 ++++++++++ recipes/drogon/all/conanfile.py | 4 ++-- recipes/drogon/config.yml | 2 ++ 3 files changed, 14 insertions(+), 2 deletions(-) diff --git a/recipes/drogon/all/conandata.yml b/recipes/drogon/all/conandata.yml index d62ebab92171a2..e4ec996a75d857 100644 --- a/recipes/drogon/all/conandata.yml +++ b/recipes/drogon/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "1.8.7": + url: "https://github.com/drogonframework/drogon/archive/v1.8.7.tar.gz" + sha256: "d2d80d35becd69bf80d74bf09b69425193f1b7be3926bd44f3ac7b951e54465d" "1.8.6": url: "https://github.com/drogonframework/drogon/archive/v1.8.6.tar.gz" sha256: "ff02979f28047e97e19e36d1f363b3052b8122975fa8a379305d746dfe5fb004" @@ -21,6 +24,13 @@ sources: url: "https://github.com/drogonframework/drogon/archive/refs/tags/v1.7.5.tar.gz" sha256: "e2af7c55dcabafef16f26f5b3242692f5a2b54c19b7b626840bf9132d24766f6" patches: + "1.8.7": + - patch_file: "patches/1.8.5-0001-remove-shared-libs.patch" + patch_description: "remove shared libs option" + patch_type: "conan" + - patch_file: "patches/1.8.6-0002-find-cci-packages.patch" + patch_description: "Fix jsoncpp cmake target name" + patch_type: "conan" "1.8.6": - patch_file: "patches/1.8.5-0001-remove-shared-libs.patch" patch_description: "remove shared libs option" diff --git a/recipes/drogon/all/conanfile.py b/recipes/drogon/all/conanfile.py index 827f0fd96949d1..d35f8664c1c76e 100644 --- a/recipes/drogon/all/conanfile.py +++ b/recipes/drogon/all/conanfile.py @@ -110,7 +110,7 @@ def validate(self): raise ConanInvalidConfiguration(f"{self.ref} requires boost on C++14") def requirements(self): - self.requires("trantor/1.5.13", transitive_headers=True, transitive_libs=True) + self.requires("trantor/1.5.14", transitive_headers=True, transitive_libs=True) self.requires("jsoncpp/1.9.5", transitive_headers=True, transitive_libs=True) self.requires("openssl/[>=1.1 <4]") self.requires("zlib/[>=1.2.11 <2]") @@ -127,7 +127,7 @@ def requirements(self): if self.options.get_safe("with_mysql"): self.requires("libmysqlclient/8.1.0") if self.options.get_safe("with_sqlite"): - self.requires("sqlite3/3.42.0") + self.requires("sqlite3/3.42.1") if self.options.get_safe("with_redis"): self.requires("hiredis/1.2.0") if self.options.get_safe("with_yaml_cpp", False): diff --git a/recipes/drogon/config.yml b/recipes/drogon/config.yml index 62f17e07b2e955..933b39a309076e 100644 --- a/recipes/drogon/config.yml +++ b/recipes/drogon/config.yml @@ -1,4 +1,6 @@ versions: + "1.8.7": + folder: "all" "1.8.6": folder: "all" "1.8.5": From f282679ce0432272b84626dc67b8b8cdfe4b2720 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 15 Oct 2023 16:22:35 +0200 Subject: [PATCH 1132/1140] (#20531) rpclib: fix MinGW shared --- recipes/rpclib/all/conandata.yml | 6 ++++++ recipes/rpclib/all/conanfile.py | 10 ++++++++-- .../all/patches/2.3.0-0001-win-link-winsock.patch | 12 ++++++++++++ 3 files changed, 26 insertions(+), 2 deletions(-) create mode 100644 recipes/rpclib/all/patches/2.3.0-0001-win-link-winsock.patch diff --git a/recipes/rpclib/all/conandata.yml b/recipes/rpclib/all/conandata.yml index 696b41e86b171b..d7b9eea3bb30c6 100644 --- a/recipes/rpclib/all/conandata.yml +++ b/recipes/rpclib/all/conandata.yml @@ -2,3 +2,9 @@ sources: "2.3.0": url: "https://github.com/rpclib/rpclib/archive/refs/tags/v2.3.0.tar.gz" sha256: "eb9e6fa65e1a79b37097397f60599b93cb443d304fbc0447c50851bc3452fdef" +patches: + "2.3.0": + - patch_file: "patches/2.3.0-0001-win-link-winsock.patch" + patch_description: "Link to mswsock and ws2_32 if windows" + patch_type: "portability" + patch_source: "https://github.com/rpclib/rpclib/pull/287" diff --git a/recipes/rpclib/all/conanfile.py b/recipes/rpclib/all/conanfile.py index 09e7e84ca393f7..111d6614af1bee 100644 --- a/recipes/rpclib/all/conanfile.py +++ b/recipes/rpclib/all/conanfile.py @@ -3,7 +3,7 @@ from conan import ConanFile from conan.tools.build import check_min_cppstd from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout -from conan.tools.files import copy, get, mkdir, rename, rmdir +from conan.tools.files import apply_conandata_patches, copy, export_conandata_patches, get, mkdir, rename, rmdir from conan.tools.microsoft import is_msvc_static_runtime required_conan_version = ">=1.53.0" @@ -32,6 +32,9 @@ class rpclibConan(ConanFile): def _min_cppstd(self): return "11" + def export_sources(self): + export_conandata_patches(self) + def config_options(self): if self.settings.os == "Windows": del self.options.fPIC @@ -60,6 +63,7 @@ def generate(self): tc.generate() def build(self): + apply_conandata_patches(self) cmake = CMake(self) cmake.configure() cmake.build() @@ -85,7 +89,9 @@ def package_info(self): # TODO: back to global scope after Conan 2.0 self.cpp_info.components["_rpc"].libs = ["rpc"] if self.settings.os in ["Linux", "FreeBSD"]: - self.cpp_info.components["_rpc"].system_libs.append("pthread") + self.cpp_info.components["_rpc"].system_libs.extend(["m", "pthread"]) + elif self.settings.os == "Windows": + self.cpp_info.components["_rpc"].system_libs.extend(["mswsock", "ws2_32"]) # TODO: Remove after Conan 2.0 self.cpp_info.components["_rpc"].names["cmake_find_package"] = "rpc" diff --git a/recipes/rpclib/all/patches/2.3.0-0001-win-link-winsock.patch b/recipes/rpclib/all/patches/2.3.0-0001-win-link-winsock.patch new file mode 100644 index 00000000000000..47ffb5454d1b33 --- /dev/null +++ b/recipes/rpclib/all/patches/2.3.0-0001-win-link-winsock.patch @@ -0,0 +1,12 @@ +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -167,6 +167,9 @@ if(RPCLIB_COMPILE_DEFINITIONS) + endif() + + target_link_libraries(${PROJECT_NAME} ${RPCLIB_DEP_LIBRARIES}) ++if (WIN32) ++ target_link_libraries(${PROJECT_NAME} mswsock ws2_32) ++endif() + target_include_directories( + ${PROJECT_NAME} PUBLIC + $ From c4af9f76f4602318733528ba012279f176cc7283 Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 15 Oct 2023 16:36:37 +0200 Subject: [PATCH 1133/1140] (#20554) wslay: fix mingw shared --- recipes/wslay/all/patches/0001-msvc-support.patch | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/recipes/wslay/all/patches/0001-msvc-support.patch b/recipes/wslay/all/patches/0001-msvc-support.patch index a689fc2452be18..b8e26fd0b44afc 100644 --- a/recipes/wslay/all/patches/0001-msvc-support.patch +++ b/recipes/wslay/all/patches/0001-msvc-support.patch @@ -44,14 +44,14 @@ index 4af972e..96b5392 100644 if(WSLAY_STATIC) add_library(wslay STATIC ${SOURCES} ${HEADERS}) list(APPEND WSLAY_TARGETS wslay) -+ if(MSVC) ++ if(WIN32) + target_link_libraries(wslay PUBLIC ws2_32) + endif() endif() if(WSLAY_SHARED) add_library(wslay_shared SHARED ${SOURCES} ${HEADERS}) list(APPEND WSLAY_TARGETS wslay_shared) -+ if(MSVC) ++ if(WIN32) + target_link_libraries(wslay_shared PUBLIC ws2_32) + endif() endif() From d969a988f37eb370925a2b4def1ec473ca890e1a Mon Sep 17 00:00:00 2001 From: SpaceIm <30052553+SpaceIm@users.noreply.github.com> Date: Sun, 15 Oct 2023 16:54:44 +0200 Subject: [PATCH 1134/1140] (#20555) tinkerforge-bindings: fix MinGW shared --- .../tinkerforge-bindings/all/CMakeLists.txt | 31 +++++++++---------- recipes/tinkerforge-bindings/all/conanfile.py | 1 + 2 files changed, 16 insertions(+), 16 deletions(-) diff --git a/recipes/tinkerforge-bindings/all/CMakeLists.txt b/recipes/tinkerforge-bindings/all/CMakeLists.txt index 9c3750e3fa826c..64a0e8e101bed9 100644 --- a/recipes/tinkerforge-bindings/all/CMakeLists.txt +++ b/recipes/tinkerforge-bindings/all/CMakeLists.txt @@ -1,23 +1,22 @@ -cmake_minimum_required(VERSION 3.4) -project(tinkerforge_bindings) +cmake_minimum_required(VERSION 3.15) +project(tinkerforge_bindings LANGUAGES C) -set(SOURCES_DIR ${CMAKE_CURRENT_LIST_DIR}/src) +file(GLOB TINK_SOURCES ${TINKERFORGE_BINDINGS_SRC_DIR}/source/*.c) +file(GLOB TINK_HEADERS ${TINKERFORGE_BINDINGS_SRC_DIR}/source/*.h) -file(GLOB SOURCES ${SOURCES_DIR}/source/*.c) -file(GLOB HEADERS ${SOURCES_DIR}/source/*.h) - -if(WIN32 AND BUILD_SHARED_LIBS) - set(CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS ON) -endif() - -add_library(${PROJECT_NAME} ${SOURCES}) - -if(MSVC) - target_link_libraries(${PROJECT_NAME} PRIVATE ws2_32 advapi32) +add_library(${PROJECT_NAME} ${TINK_SOURCES}) +set_target_properties(${PROJECT_NAME} PROPERTIES + PUBLIC_HEADER "${TINK_HEADERS}" + WINDOWS_EXPORT_ALL_SYMBOLS ON +) +if(WIN32) + target_link_libraries(${PROJECT_NAME} PRIVATE ws2_32 advapi32) endif() include(GNUInstallDirs) -set_target_properties(${PROJECT_NAME} PROPERTIES PUBLIC_HEADER "${HEADERS}") install(TARGETS ${PROJECT_NAME} - PUBLIC_HEADER DESTINATION include + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + PUBLIC_HEADER DESTINATION ${CMAKE_INSTALL_INCLUDEDIR} ) diff --git a/recipes/tinkerforge-bindings/all/conanfile.py b/recipes/tinkerforge-bindings/all/conanfile.py index f287887f2f3ea7..43201b9ca39347 100644 --- a/recipes/tinkerforge-bindings/all/conanfile.py +++ b/recipes/tinkerforge-bindings/all/conanfile.py @@ -53,6 +53,7 @@ def source(self): def generate(self): tc = CMakeToolchain(self) + tc.variables["TINKERFORGE_BINDINGS_SRC_DIR"] = self.source_folder.replace("\\", "/") tc.generate() def build(self): From b0b94d2076a8c929d75cd15153235a69c807565c Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 16 Oct 2023 00:24:16 +0900 Subject: [PATCH 1135/1140] (#20560) thelink2012-any: add version cci.20230118 --- recipes/thelink2012-any/all/conandata.yml | 3 +++ recipes/thelink2012-any/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/thelink2012-any/all/conandata.yml b/recipes/thelink2012-any/all/conandata.yml index 05fc280a1c1002..71bf293016c65c 100644 --- a/recipes/thelink2012-any/all/conandata.yml +++ b/recipes/thelink2012-any/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "cci.20230118": + url: "https://github.com/thelink2012/any/archive/e88b1bfc160fa9b01e6174dd29c812eeeece3be9.tar.gz" + sha256: "4be9b7be551a61730c85c3e08f8513ad217874d0c3f966d8f9eb5e0892424f55" "cci.20200719": url: "https://github.com/thelink2012/any/archive/f67bd5f8bbf7eb628bf38206d4ac5cb22438e6bb.tar.gz" sha256: "1cd121a2fb27936213397ff4ff94fe4d6d4e28cabc13894cc4512eb046d71be8" diff --git a/recipes/thelink2012-any/config.yml b/recipes/thelink2012-any/config.yml index 1eac063d13841a..cdbc38379aaf4d 100644 --- a/recipes/thelink2012-any/config.yml +++ b/recipes/thelink2012-any/config.yml @@ -1,3 +1,5 @@ versions: + "cci.20230118": + folder: all "cci.20200719": folder: all From a80e786407b9e799e987654147236153e591059b Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 16 Oct 2023 00:43:06 +0900 Subject: [PATCH 1136/1140] (#20577) oniguruma: add version 6.9.9 --- recipes/oniguruma/all/conandata.yml | 3 +++ recipes/oniguruma/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/oniguruma/all/conandata.yml b/recipes/oniguruma/all/conandata.yml index 1d4c5ee6c51923..d74493648d9a9c 100644 --- a/recipes/oniguruma/all/conandata.yml +++ b/recipes/oniguruma/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "6.9.9": + url: "https://github.com/kkos/oniguruma/releases/download/v6.9.9/onig-6.9.9.tar.gz" + sha256: "60162bd3b9fc6f4886d4c7a07925ffd374167732f55dce8c491bfd9cd818a6cf" "6.9.8": url: "https://github.com/kkos/oniguruma/releases/download/v6.9.8/onig-6.9.8.tar.gz" sha256: "28cd62c1464623c7910565fb1ccaaa0104b2fe8b12bcd646e81f73b47535213e" diff --git a/recipes/oniguruma/config.yml b/recipes/oniguruma/config.yml index 271aea57020658..9cf31a690977c1 100644 --- a/recipes/oniguruma/config.yml +++ b/recipes/oniguruma/config.yml @@ -1,4 +1,6 @@ versions: + "6.9.9": + folder: all "6.9.8": folder: all "6.9.7.1": From b146d411c909d6efc997715981d6f98b427d54d0 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 16 Oct 2023 06:08:51 +0900 Subject: [PATCH 1137/1140] (#20583) sqlpp11: add version 0.64 --- recipes/sqlpp11/all/conandata.yml | 3 +++ recipes/sqlpp11/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/sqlpp11/all/conandata.yml b/recipes/sqlpp11/all/conandata.yml index 3357310d8ea8c9..6b607672eff4f5 100644 --- a/recipes/sqlpp11/all/conandata.yml +++ b/recipes/sqlpp11/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "0.64": + url: "https://github.com/rbock/sqlpp11/archive/0.64.tar.gz" + sha256: "72e6d37c716cc45b38c3cf4541604f16224aaa3b511d1f1d0be0c49176c3be86" "0.63": url: "https://github.com/rbock/sqlpp11/archive/0.63.tar.gz" sha256: "8e8229501679435e5052c2184d6772e4d6f61e6a9e2ec7231c5fb9a3d3b88d7e" diff --git a/recipes/sqlpp11/config.yml b/recipes/sqlpp11/config.yml index e0a6c05b5e9278..cd4a669a1a8d73 100644 --- a/recipes/sqlpp11/config.yml +++ b/recipes/sqlpp11/config.yml @@ -1,4 +1,6 @@ versions: + "0.64": + folder: "all" "0.63": folder: "all" "0.62": From 2bca4c6737ecd588e5c8f384eeb9cc1212ae2ab7 Mon Sep 17 00:00:00 2001 From: toge Date: Mon, 16 Oct 2023 15:08:23 +0900 Subject: [PATCH 1138/1140] (#20585) tomlplusplus: add version 3.4.0 --- recipes/tomlplusplus/all/conandata.yml | 3 +++ recipes/tomlplusplus/config.yml | 2 ++ 2 files changed, 5 insertions(+) diff --git a/recipes/tomlplusplus/all/conandata.yml b/recipes/tomlplusplus/all/conandata.yml index a459f949569ec9..63de1cac4b075c 100644 --- a/recipes/tomlplusplus/all/conandata.yml +++ b/recipes/tomlplusplus/all/conandata.yml @@ -1,4 +1,7 @@ sources: + "3.4.0": + url: "https://github.com/marzer/tomlplusplus/archive/v3.4.0.tar.gz" + sha256: "8517f65938a4faae9ccf8ebb36631a38c1cadfb5efa85d9a72e15b9e97d25155" "3.3.0": url: "https://github.com/marzer/tomlplusplus/archive/v3.3.0.tar.gz" sha256: "fc1a5eb410f3c67e90e5ad1264a1386d020067cfb01b633cc8c0441789aa6cf2" diff --git a/recipes/tomlplusplus/config.yml b/recipes/tomlplusplus/config.yml index 4cd7ca8687e684..0705075264b761 100644 --- a/recipes/tomlplusplus/config.yml +++ b/recipes/tomlplusplus/config.yml @@ -1,4 +1,6 @@ versions: + "3.4.0": + folder: all "3.3.0": folder: all "3.2.0": From d2f965efde16837df41d0105b241fe59f8af8e45 Mon Sep 17 00:00:00 2001 From: Hans-Joachim Krauch Date: Mon, 16 Oct 2023 08:24:33 +0200 Subject: [PATCH 1139/1140] (#18885) foxglove-websocket: Add version 1.1.0 * foxglove-websocket: Add version 1.1.0 * foxglove-websocket: Add asio option * foxglove-websocket: Remove asio option False * foxglove-websocket: Update tag hash sum * foxglove-websocket: Use transitive headers for websocketpp * Update recipes/foxglove-websocket/all/conanfile.py * Set CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS true for win shared --------- Co-authored-by: Carlos Zoido --- recipes/foxglove-websocket/all/conandata.yml | 3 +++ recipes/foxglove-websocket/all/conanfile.py | 8 ++++++-- recipes/foxglove-websocket/config.yml | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/recipes/foxglove-websocket/all/conandata.yml b/recipes/foxglove-websocket/all/conandata.yml index 30a26f91bb4d64..8f15ef7f494fbe 100644 --- a/recipes/foxglove-websocket/all/conandata.yml +++ b/recipes/foxglove-websocket/all/conandata.yml @@ -1,4 +1,7 @@ sources: + 1.1.0: + url: https://github.com/foxglove/ws-protocol/archive/refs/tags/releases/cpp/v1.1.0.tar.gz + sha256: 3ad1f639e340e878dd638d542e57185b8c7c08fdfcb03d8c43d054957078a81f 1.0.0: url: https://github.com/foxglove/ws-protocol/archive/refs/tags/releases/cpp/v1.0.0.tar.gz sha256: c6106934a47d9d5b53ee3f6a0a6c8ec778ffdb52e9b462136bfc1bc5391ed227 diff --git a/recipes/foxglove-websocket/all/conanfile.py b/recipes/foxglove-websocket/all/conanfile.py index 60557d9c03f137..666816b0d58206 100644 --- a/recipes/foxglove-websocket/all/conanfile.py +++ b/recipes/foxglove-websocket/all/conanfile.py @@ -20,10 +20,12 @@ class FoxgloveWebSocketConan(ConanFile): options = { "shared": [True, False], "fPIC": [True, False], + "asio": ["boost", "standalone"], } default_options = { "shared": False, "fPIC": True, + "asio": "standalone" } settings = "os", "arch", "compiler", "build_type" @@ -65,13 +67,15 @@ def validate(self): def requirements(self): self.requires("nlohmann_json/3.10.5", transitive_headers=True) - self.requires("websocketpp/0.8.2") + self.requires("websocketpp/0.8.2", transitive_headers=True, transitive_libs=True) def layout(self): cmake_layout(self, src_folder="src") def generate(self): tc = CMakeToolchain(self) + if self.settings.os == "Windows" and self.options.shared: + tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = True tc.generate() def config_options(self): @@ -79,7 +83,7 @@ def config_options(self): del self.options.fPIC def configure(self): - self.options["websocketpp"].asio = "standalone" + self.options["websocketpp"].asio = self.options.asio if self.options.shared: self.options.rm_safe("fPIC") diff --git a/recipes/foxglove-websocket/config.yml b/recipes/foxglove-websocket/config.yml index 3e794e52e592a4..29bb1651937f8a 100644 --- a/recipes/foxglove-websocket/config.yml +++ b/recipes/foxglove-websocket/config.yml @@ -1,3 +1,5 @@ versions: + 1.1.0: + folder: all 1.0.0: folder: all From 71b404d85bce95fff5bf03d8a7ffc59fc6b161f3 Mon Sep 17 00:00:00 2001 From: Martin Valgur Date: Mon, 16 Oct 2023 14:13:02 +0300 Subject: [PATCH 1140/1140] (#19582) gtsam: add v4.2, remove v4.2.0a9 pre-release, bump deps * gtsam: add v4.2, remove v4.2.0a9 pre-release, bump deps * gtsam: update config.yml --- recipes/gtsam/all/conandata.yml | 12 ++++-------- recipes/gtsam/all/conanfile.py | 6 +++--- .../patches/4.2.0a9-0001-fix-invalid-include.patch | 12 ------------ recipes/gtsam/config.yml | 2 +- 4 files changed, 8 insertions(+), 24 deletions(-) delete mode 100644 recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch diff --git a/recipes/gtsam/all/conandata.yml b/recipes/gtsam/all/conandata.yml index eecf7c3eb615ed..243d25034c49ec 100644 --- a/recipes/gtsam/all/conandata.yml +++ b/recipes/gtsam/all/conandata.yml @@ -1,7 +1,7 @@ sources: - "4.2.0a9": - url: "https://github.com/borglab/gtsam/archive/refs/tags/4.2a9.tar.gz" - sha256: "a9790e5132bfb2705a5985a1505c3cf9cdf95b711be8352ffa9a9299b279f2f8" + "4.2": + url: "https://github.com/borglab/gtsam/archive/refs/tags/4.2.tar.gz" + sha256: "9ff8846d0a83a245c284cb5760ec2d74535ef9b5885183ccfefd7ff122eba60e" "4.1.1": url: "https://github.com/borglab/gtsam/archive/4.1.1.tar.gz" sha256: "c7b5e6cdad52b141c272778f47baf628975457be3e26ed96a7bc2ae685a00af0" @@ -9,7 +9,7 @@ sources: url: "https://github.com/borglab/gtsam/archive/4.0.3.tar.gz" sha256: "eaa561749edf7a2d402981828253e28aed6c717dae35738301c5ab23e2595f25" patches: - "4.2.0a9": + "4.2": - patch_file: "patches/4.1.1-0001-cmake-boost.patch" patch_description: "Use boost targets" patch_type: "conan" @@ -19,10 +19,6 @@ patches: - patch_file: "patches/4.2.0-0002-eigen3-version.patch" patch_description: "Get Eigen3 version info from Conan" patch_type: "conan" - - patch_file: "patches/4.2.0a9-0001-fix-invalid-include.patch" - patch_description: "Fix an invalid include for pre-C++17 compatibility" - patch_type: "portability" - patch_source: "https://github.com/borglab/gtsam/pull/1545" "4.1.1": - patch_file: "patches/4.1.1-0001-cmake-boost.patch" patch_description: "Use boost targets" diff --git a/recipes/gtsam/all/conanfile.py b/recipes/gtsam/all/conanfile.py index 4320c2bbb7e698..bca7930e912c29 100644 --- a/recipes/gtsam/all/conanfile.py +++ b/recipes/gtsam/all/conanfile.py @@ -138,12 +138,12 @@ def layout(self): cmake_layout(self, src_folder="src") def requirements(self): - self.requires("boost/1.82.0", transitive_headers=True) + self.requires("boost/1.83.0", transitive_headers=True) self.requires("eigen/3.4.0", transitive_headers=True) if self.options.with_TBB: - self.requires("onetbb/2021.9.0", transitive_headers=True) + self.requires("onetbb/2021.10.0", transitive_headers=True) if self.options.default_allocator == "tcmalloc": - self.requires("gperftools/2.10.0") + self.requires("gperftools/2.11.0") # TODO: add use_vendored_metis=False option # if self.options.support_nested_dissection and not self.options.use_vendored_metis: # # Used in a public header here: diff --git a/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch b/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch deleted file mode 100644 index a0431a45e608d0..00000000000000 --- a/recipes/gtsam/all/patches/4.2.0a9-0001-fix-invalid-include.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff --git a/gtsam/sfm/DsfTrackGenerator.h b/gtsam/sfm/DsfTrackGenerator.h ---- a/gtsam/sfm/DsfTrackGenerator.h (revision c57988fe554e7213c77fe379c1d7c483de26ad33) -+++ b/gtsam/sfm/DsfTrackGenerator.h (revision 26a37d62103a9b3b828d36e8b1a76f875ed842e3) -@@ -22,7 +22,7 @@ - - #include - #include --#include -+#include - #include - - namespace gtsam { diff --git a/recipes/gtsam/config.yml b/recipes/gtsam/config.yml index 9c6d4a9be25c5e..92f20f30ab3474 100644 --- a/recipes/gtsam/config.yml +++ b/recipes/gtsam/config.yml @@ -1,5 +1,5 @@ versions: - "4.2.0a9": + "4.2": folder: all "4.1.1": folder: all