Skip to content

Commit

Permalink
Merge branch 'master' into tiledb/new-recipe
Browse files Browse the repository at this point in the history
  • Loading branch information
valgur authored Aug 26, 2023
2 parents fa8ef57 + ae69850 commit 7bd7007
Show file tree
Hide file tree
Showing 52 changed files with 479 additions and 228 deletions.
1 change: 1 addition & 0 deletions .c3i/authorized_users.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1216,3 +1216,4 @@ authorized_users:
- adattatri
- jwfallawuiuc
- tgurriet
- mgfernan
5 changes: 5 additions & 0 deletions .c3i/conan_v2_ready_references.yml
Original file line number Diff line number Diff line change
Expand Up @@ -256,6 +256,7 @@ required_for_references:
- drwav
- dtl
- duckdb
- duktape
- eabase
- earcut
- eastl
Expand Down Expand Up @@ -314,6 +315,7 @@ required_for_references:
- flatbush
- flecs
- flex
- fltk
- fmt
- fmtlog
- fontconfig
Expand Down Expand Up @@ -845,6 +847,7 @@ required_for_references:
- pbtools
- pcapplusplus
- pcg-cpp
- pcl
- pcre
- pcre2
- pdfgen
Expand Down Expand Up @@ -953,6 +956,7 @@ required_for_references:
- rmm
- roaring
- robin-hood-hashing
- rpclib
- rply
- rtklib
- rtm
Expand Down Expand Up @@ -1003,6 +1007,7 @@ required_for_references:
- sml
- snappy
- snowhouse
- sobjectizer
- soci
- sofa
- sokol
Expand Down
3 changes: 3 additions & 0 deletions recipes/arrow/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -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"
Expand Down
236 changes: 114 additions & 122 deletions recipes/arrow/all/conanfile.py

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions recipes/arrow/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"12.0.1":
folder: all
"12.0.0":
folder: all
"11.0.0":
Expand Down
3 changes: 3 additions & 0 deletions recipes/aws-c-event-stream/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -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"
Expand Down
12 changes: 9 additions & 3 deletions recipes/aws-c-event-stream/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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)
Expand Down
2 changes: 2 additions & 0 deletions recipes/aws-c-event-stream/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"0.3.1":
folder: all
"0.2.15":
folder: all
"0.2.12":
Expand Down
3 changes: 0 additions & 3 deletions recipes/aws-c-s3/all/conandata.yml
Original file line number Diff line number Diff line change
Expand Up @@ -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"
83 changes: 44 additions & 39 deletions recipes/aws-c-s3/all/conanfile.py
Original file line number Diff line number Diff line change
@@ -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],
Expand All @@ -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)
Expand All @@ -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]
8 changes: 3 additions & 5 deletions recipes/aws-c-s3/all/test_v1_package/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -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)
2 changes: 0 additions & 2 deletions recipes/aws-c-s3/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,3 @@ versions:
folder: all
"0.1.27":
folder: all
"0.1.19":
folder: all
2 changes: 2 additions & 0 deletions recipes/boost/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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"]
Expand Down
1 change: 1 addition & 0 deletions recipes/expected-lite/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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 = []
6 changes: 3 additions & 3 deletions recipes/glibmm/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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:
Expand All @@ -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)
Expand Down
12 changes: 10 additions & 2 deletions recipes/gmp/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -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"
Expand All @@ -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"
Expand Down
2 changes: 2 additions & 0 deletions recipes/gmp/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"6.3.0":
folder: all
"6.2.1":
folder: all
"6.2.0":
Expand Down
3 changes: 3 additions & 0 deletions recipes/gperftools/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -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"
Expand Down
2 changes: 2 additions & 0 deletions recipes/gperftools/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"2.12.0":
folder: all
"2.11.0":
folder: all
"2.10.0":
Expand Down
6 changes: 3 additions & 3 deletions recipes/keychain/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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")
Expand Down
3 changes: 3 additions & 0 deletions recipes/lexbor/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -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"
Expand Down
2 changes: 2 additions & 0 deletions recipes/lexbor/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"2.3.0":
folder: "all"
"2.2.0":
folder: "all"
"2.1.0":
Expand Down
3 changes: 2 additions & 1 deletion recipes/libmount/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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"))
Expand Down
6 changes: 3 additions & 3 deletions recipes/libsecret/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -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")

Expand All @@ -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/<host_version>")

if self.settings.os == "Macos":
Expand Down
Loading

0 comments on commit 7bd7007

Please sign in to comment.