Skip to content

Commit

Permalink
Merge branch 'leptonica-1.84.0' of https://github.com/toge/conan-cent…
Browse files Browse the repository at this point in the history
…er-index into leptonica-1.84.0
  • Loading branch information
toge committed Feb 2, 2024
2 parents e050e08 + 3787680 commit 9299d49
Show file tree
Hide file tree
Showing 516 changed files with 4,704 additions and 2,311 deletions.
10 changes: 10 additions & 0 deletions .c3i/authorized_users.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1256,3 +1256,13 @@ authorized_users:
- piliugin-anton
- Drllap
- i-curve
- Mi-La
- gureedo
- cbaecker
- ErixenCruz
- OrianeGourdyStilla
- nikitasinys
- pgrossomoreira
- wu-vincent
- Inujel
- keszegrobert
8 changes: 8 additions & 0 deletions .c3i/conan_v2_ready_references.yml
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ required_for_references:
- cargs
- cassandra-cpp-driver
- catch2
- cc65
- ccache
- cccl
- ccfits
Expand Down Expand Up @@ -195,9 +196,11 @@ required_for_references:
- console_bridge
- continuable
- coost
- copypp
- corrade
- cose-c
- cotila
- coz
- cpp-httplib
- cpp-ipc
- cpp-jwt
Expand Down Expand Up @@ -371,6 +374,7 @@ required_for_references:
- flatbush
- flecs
- flex
- flint
- fltk
- fmi1
- fmi2
Expand Down Expand Up @@ -651,6 +655,7 @@ required_for_references:
- libhydrogen
- libiberty
- libiconv
- libid3tag
- libinterpolate
- libipt
- libjpeg
Expand Down Expand Up @@ -748,6 +753,7 @@ required_for_references:
- libuuid
- libuv
- libuvc
- libva
- libvault
- libverto
- libvips
Expand Down Expand Up @@ -778,6 +784,7 @@ required_for_references:
- linux-headers-generic
- linux-syscall-support
- litehtml
- lksctp-tools
- llhttp
- llvm-openmp
- lmdb
Expand Down Expand Up @@ -1116,6 +1123,7 @@ required_for_references:
- redboltz-mqtt_cpp
- redis-plus-plus
- refl-cpp
- reflect-cpp
- replxx
- resource_pool
- restbed
Expand Down
2 changes: 1 addition & 1 deletion .c3i/config_v2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ cppstd:
apple-clang:
"13": ["17", "gnu17", "20", "gnu20"]
gcc:
"11": ["17", "gnu17", "20", "gnu20"]
"11": ["17", "gnu17", "20", "gnu20", "23", "gnu23"]
msvc:
"192": ["14", "17", "20"]
"193": ["14", "17", "20"]
Expand Down
7 changes: 0 additions & 7 deletions recipes/andreasbuhr-cppcoro/all/CMakeLists.txt

This file was deleted.

6 changes: 3 additions & 3 deletions recipes/andreasbuhr-cppcoro/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
sources:
"cci.20210113":
url: "https://github.com/andreasbuhr/cppcoro/archive/7cc9433436fe8f2482138019cfaafce8e1d7a896.zip"
sha256: "5edc72bb19616ae5b794c7d83f9a5d4973f32c966f1966ab81779d3a38b36a2c"
"cci.20230629":
url: "https://github.com/andreasbuhr/cppcoro/archive/a3082f56ba135a659f7386b00ff797ba441207ba.zip"
sha256: "8c3283dd7587cdd18b871b290fda9394f262110140685e6de3760ede3b505736"
139 changes: 83 additions & 56 deletions recipes/andreasbuhr-cppcoro/all/conanfile.py
Original file line number Diff line number Diff line change
@@ -1,21 +1,24 @@
import os
from conans import ConanFile, tools, CMake
from conans.errors import ConanInvalidConfiguration
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 rmdir, get, copy
from conan.tools.microsoft import is_msvc
from conan.tools.scm import Version
from conan.errors import ConanInvalidConfiguration

required_conan_version = ">=1.33.0"
required_conan_version = ">=1.53.0"

class AndreasbuhrCppCoroConan(ConanFile):
name = "andreasbuhr-cppcoro"
description = "A library of C++ coroutine abstractions for the coroutines TS"
topics = ("conan", "cpp", "async", "coroutines")
topics = ("cpp", "async", "coroutines")
url = "https://github.com/conan-io/conan-center-index"
homepage = "https://github.com/andreasbuhr/cppcoro"
license = "MIT"
settings = "os", "compiler", "build_type", "arch"
provides = "cppcoro"

exports_sources = "CMakeLists.txt"
generators = "cmake"
package_type = "library"

options = {
"shared": [True, False],
Expand All @@ -26,87 +29,111 @@ class AndreasbuhrCppCoroConan(ConanFile):
"fPIC": True,
}

_cmake = None

@property
def _source_subfolder(self):
return "source_subfolder"

@property
def _minimum_compilers_version(self):
return {
"Visual Studio": "15",
"msvc": "191",
"gcc": "10",
"clang": "8",
"apple-clang": "10",
}

@property
def _min_cppstd(self):
# Clang with libstdc++ always requires C++20
# Clang 17+ always requires C++20
# Otherwise, require C++17
compiler = self.settings.compiler
requires_cpp20 = compiler == "clang" and ("libstdc++" in compiler.get_safe("libcxx", "") or compiler.version >= Version("17"))
return 20 if requires_cpp20 else 17

def layout(self):
cmake_layout(self, src_folder="src")

def config_options(self):
if self.settings.os == "Windows":
del self.options.fPIC
self.options.rm_safe("fPIC")

def validate(self):
if self.settings.compiler.cppstd:
check_min_cppstd(self, self._min_cppstd)

# We can't simply check for C++20, because clang and MSVC support the coroutine TS despite not having labeled (__cplusplus macro) C++20 support
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 coroutine TS support. The current compiler {} {} does not support it.".format(
self.name, self.settings.compiler, self.settings.compiler.version))

# Currently clang expects coroutine to be implemented in a certain way (under std::experiemental::), while libstdc++ puts them under std::
# There are also other inconsistencies, see https://bugs.llvm.org/show_bug.cgi?id=48172
# This should be removed after both gcc and clang implements the final coroutine TS
if self.settings.compiler == "clang" and self.settings.compiler.get_safe("libcxx") == "libstdc++":
raise ConanInvalidConfiguration("{} does not support clang with libstdc++. Use libc++ instead.".format(self.name))
if Version(self.settings.compiler.version) < min_version:
raise ConanInvalidConfiguration(
f"{self.name} requires coroutine TS support. The current compiler {self.settings.compiler} {self.settings.compiler.version} does not support it."
)

# Older versions of clang expects coroutine to be put under std::experimental::, while libstdc++ puts them under std::,
# See https://bugs.llvm.org/show_bug.cgi?id=48172 for more context.
if self.settings.compiler == "clang" and "libstdc++" in self.settings.compiler.get_safe("libcxx", ""):
if self.settings.compiler.version < Version("14"):
raise ConanInvalidConfiguration("{self.name} does not support clang<14 with libstdc++. Use libc++ or upgrade to clang 14+ instead.")
if self.settings.compiler.version == Version("14"):
self.output.warning("This build may fail if using libstdc++13 or greater")

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)
get(self, **self.conan_data["sources"][self.version], strip_root=True)

def _configure_cmake(self):
if not self._cmake:
self._cmake = CMake(self)
if self.settings.os == "Windows" and self.options.shared:
self._cmake.definitions["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = "ON"
self._cmake.configure()
return self._cmake
def generate(self):
tc = CMakeToolchain(self)
tc.variables["CMAKE_WINDOWS_EXPORT_ALL_SYMBOLS"] = "ON"
tc.generate()

def build(self):
cmake = self._configure_cmake()
cmake = CMake(self)
cmake.configure()
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()
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.filenames["cmake_find_package"] = "cppcoro"
self.cpp_info.filenames["cmake_find_package_multi"] = "cppcoro"
self.cpp_info.names["cmake_find_package"] = "cppcoro"
self.cpp_info.names["cmake_find_package_multi"] = "cppcoro"
@property
def _needs_fcoroutines_ts_flag(self):
version = Version(self.settings.compiler.version)
if self.settings.compiler == "clang":
# clang 5: Coroutines support added
# somewhere between clang 5 and 11: the requirement to add -fcoroutines-ts was dropped, at least in the context of this recipe.
return version < 11
elif self.settings.compiler == "apple-clang":
# At some point before apple-clang 13, in the context of this recipe, the requirement for this flag was dropped.
return version < 13
else:
return False

comp = self.cpp_info.components["cppcoro"]
comp.names["cmake_find_package"] = "cppcoro"
comp.names["cmake_find_package_multi"] = "cppcoro"
comp.libs = ["cppcoro"]
def package_info(self):
self.cpp_info.libs = ["cppcoro"]

if self.settings.os == "Linux" and self.options.shared:
comp.system_libs = ["pthread"]
if self.settings.os in ["Linux", "FreeBSD"] and self.options.shared:
self.cpp_info.system_libs = ["pthread", "m"]
if self.settings.os == "Windows":
comp.system_libs = ["synchronization"]
self.cpp_info.system_libs = ["synchronization", "ws2_32", "mswsock"]

if self.settings.compiler == "Visual Studio":
comp.cxxflags.append("/await")
if is_msvc(self):
self.cpp_info.cxxflags.append("/await")
elif self.settings.compiler == "gcc":
comp.cxxflags.append("-fcoroutines")
comp.defines.append("CPPCORO_COMPILER_SUPPORTS_SYMMETRIC_TRANSFER=1")
elif self.settings.compiler == "clang" or self.settings.compiler == "apple-clang":
comp.cxxflags.append("-fcoroutines-ts")
self.cpp_info.cxxflags.append("-fcoroutines")
self.cpp_info.defines.append("CPPCORO_COMPILER_SUPPORTS_SYMMETRIC_TRANSFER=1")
elif self._needs_fcoroutines_ts_flag:
self.cpp_info.cxxflags.append("-fcoroutines-ts")

self.cpp_info.set_property("cmake_file_name", "cppcoro")
self.cpp_info.set_property("cmake_target_name", "cppcoro::cppcoro")

# TODO: to remove in conan v2 once cmake_find_package_* generators removed
self.cpp_info.filenames["cmake_find_package"] = "cppcoro"
self.cpp_info.filenames["cmake_find_package_multi"] = "cppcoro"
self.cpp_info.names["cmake_find_package"] = "cppcoro"
self.cpp_info.names["cmake_find_package_multi"] = "cppcoro"
5 changes: 1 addition & 4 deletions recipes/andreasbuhr-cppcoro/all/test_package/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
cmake_minimum_required(VERSION 3.1)
cmake_minimum_required(VERSION 3.15)
project(test_package)

include(${CMAKE_BINARY_DIR}/conanbuildinfo.cmake)
conan_basic_setup()

find_package(cppcoro CONFIG REQUIRED)

add_executable(${PROJECT_NAME} test_package.cpp)
Expand Down
22 changes: 16 additions & 6 deletions recipes/andreasbuhr-cppcoro/all/test_package/conanfile.py
Original file line number Diff line number Diff line change
@@ -1,16 +1,26 @@
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", "compiler", "build_type", "arch"
generators = "cmake", "cmake_find_package_multi"
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 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")
2 changes: 1 addition & 1 deletion recipes/andreasbuhr-cppcoro/config.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
versions:
"cci.20210113":
"cci.20230629":
folder: "all"
4 changes: 2 additions & 2 deletions recipes/aravis/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ def layout(self):
def requirements(self):
# glib-object.h and gio/gio.h are used in several public headers
self.requires("glib/2.78.1", transitive_headers=True)
self.requires("libxml2/2.12.2")
self.requires("libxml2/2.12.3")
self.requires("zlib/[>=1.2.11 <2]")

if self.options.usb:
Expand Down Expand Up @@ -104,7 +104,7 @@ def validate(self):

def build_requirements(self):
#windows build: meson/1.2.1 works, meson/1.2.2 breaks for some reason!
self.tool_requires("meson/1.3.0")
self.tool_requires("meson/1.3.1")
self.tool_requires("glib/<host_version>")
if not self.conf.get("tools.gnu:pkg_config", check_type=str):
self.tool_requires("pkgconf/2.1.0")
Expand Down
2 changes: 2 additions & 0 deletions recipes/at-spi2-core/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,5 @@ versions:
folder: new
"2.50.0":
folder: new
"2.51.0":
folder: new
3 changes: 3 additions & 0 deletions recipes/at-spi2-core/new/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
sources:
"2.51.0":
sha256: 8dd07c6160e3115f4f77e2205963449def6822a3dc85d495c5db389f56663037
url: https://ftp.gnome.org/pub/gnome/sources/at-spi2-core/2.51/at-spi2-core-2.51.0.tar.xz
"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
Expand Down
9 changes: 6 additions & 3 deletions recipes/autoconf-archive/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,10 @@
sources:
"2021.02.19":
url: "https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-2021.02.19.tar.xz"
sha256: "e8a6eb9d28ddcba8ffef3fa211653239e9bf239aba6a01a6b7cfc7ceaec69cbd"
"2023.02.20":
url: "https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-2023.02.20.tar.xz"
sha256: "71d4048479ae28f1f5794619c3d72df9c01df49b1c628ef85fde37596dc31a33"
"2022.09.03":
url: "https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-2022.09.03.tar.xz"
sha256: "e07454f00d8cae7907bed42d0747798927809947684d94c37207a4d63a32f423"
"2021.02.19":
url: "https://ftpmirror.gnu.org/autoconf-archive/autoconf-archive-2021.02.19.tar.xz"
sha256: "e8a6eb9d28ddcba8ffef3fa211653239e9bf239aba6a01a6b7cfc7ceaec69cbd"
4 changes: 3 additions & 1 deletion recipes/autoconf-archive/config.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
versions:
"2021.02.19":
"2023.02.20":
folder: all
"2022.09.03":
folder: all
"2021.02.19":
folder: all
Loading

0 comments on commit 9299d49

Please sign in to comment.