Skip to content

Commit

Permalink
Merge branch 'master' into qt_folder
Browse files Browse the repository at this point in the history
  • Loading branch information
ericLemanissier authored May 23, 2024
2 parents 3ecdb90 + 1292b47 commit a136177
Show file tree
Hide file tree
Showing 248 changed files with 3,119 additions and 2,526 deletions.
3 changes: 3 additions & 0 deletions .c3i/authorized_users.yml
Original file line number Diff line number Diff line change
Expand Up @@ -1351,3 +1351,6 @@ authorized_users:
- jmdaly
- inPhraZ
- nikolay-pv
- Julianiolo
- ErikHons
- enzo-pellegrini
12 changes: 12 additions & 0 deletions .c3i/conan_v2_ready_references.yml
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,7 @@ required_for_references:
- autoconf-archive
- automake
- avahi
- avcpp
- avir
- aws-c-auth
- aws-c-cal
Expand Down Expand Up @@ -223,6 +224,7 @@ required_for_references:
- cpp-peglib
- cpp-sort
- cpp-validator
- cpp-yyjson
- cpp_project_framework
- cppbenchmark
- cppcheck
Expand Down Expand Up @@ -272,6 +274,7 @@ required_for_references:
- cute_headers
- cvplot
- cwalk
- cxxgraph
- cxxopts
- cyclonedds
- cyclonedds-cxx
Expand Down Expand Up @@ -303,6 +306,7 @@ required_for_references:
- directx-headers
- dirent
- discount
- dispenso
- djinni-generator
- djinni-support-lib
- djvulibre
Expand Down Expand Up @@ -360,6 +364,7 @@ required_for_references:
- entityx
- entt
- enum-flags
- enumbitmask
- erikzenker-hsm
- erkir
- etc2comp
Expand Down Expand Up @@ -479,6 +484,7 @@ required_for_references:
- glu
- gm2calc
- gmp
- gn
- gnu-config
- gnulib
- gnutls
Expand Down Expand Up @@ -698,6 +704,7 @@ required_for_references:
- libgd
- libgeotiff
- libgettext
- libgit2
- libglvnd
- libgpg-error
- libgphoto2
Expand All @@ -712,6 +719,7 @@ required_for_references:
- libid3tag
- libidn
- libidn2
- libigl
- libinput
- libinterpolate
- libipt
Expand Down Expand Up @@ -762,6 +770,7 @@ required_for_references:
- libpqxx
- libproperties
- libpsl
- libqasm
- libqrencode
- librasterlite
- libraw
Expand Down Expand Up @@ -1224,6 +1233,7 @@ required_for_references:
- refl-cpp
- reflect-cpp
- replxx
- resiprocate
- resource_pool
- restbed
- restinio
Expand Down Expand Up @@ -1401,6 +1411,7 @@ required_for_references:
- tiny-utf8
- tinyalsa
- tinycbor
- tinycolormap
- tinycthread
- tinycthreadpool
- tinydir
Expand Down Expand Up @@ -1570,6 +1581,7 @@ required_for_references:
- yasm
- yder
- yoga
- yomm2
- yyjson
- z3
- zbar
Expand Down
2 changes: 1 addition & 1 deletion .c3i/config_v1.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
id: 'conan-io/conan-center-index'

conan:
version: 1.64.0
version: 1.64.1

artifactory:
url: "https://c3i.jfrog.io/c3i"
Expand Down
2 changes: 1 addition & 1 deletion .c3i/config_v2.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
id: 'conan-io/conan-center-index'

conan:
version: 2.2.2
version: 2.3.1
backup_sources:
upload_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/"
download_url: "https://c3i.jfrog.io/artifactory/conan-center-backup-sources/"
Expand Down
3 changes: 1 addition & 2 deletions recipes/artery-font-format/all/test_package/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,4 @@ def build(self):
def test(self):
if can_run(self):
bin_path = os.path.join(self.cpp.build.bindir, "test_package")
arfont = os.path.join(self.source_folder, "example.arfont")
self.run(f"{bin_path} {arfont}", env="conanrun")
self.run(bin_path, env="conanrun")
Binary file not shown.
29 changes: 3 additions & 26 deletions recipes/artery-font-format/all/test_package/test_package.cpp
Original file line number Diff line number Diff line change
@@ -1,32 +1,9 @@
#include <cstdio>
#include <cstdlib>
#include <iostream>

#include <artery-font/std-artery-font.h>
#include <artery-font/stdio-serialization.h>

int main(int argc, char *argv[]) {
if (argc < 2) {
std::cerr << "usage: test_package <arfont file>\n";
return EXIT_FAILURE;
}

FILE *const font_file = fopen(argv[1], "rb");
if (font_file == nullptr) {
std::cerr << "couldn't open font file" << std::endl;
return EXIT_FAILURE;
}

artery_font::StdArteryFont<float> font;
if (!artery_font::read(font, font_file)) {
std::cerr << "couldn't read artery font" << std::endl;
return EXIT_FAILURE;
}

if (fclose(font_file) != 0) {
std::cerr << "an error occured when closing font file" << std::endl;
return EXIT_FAILURE;
}

return EXIT_SUCCESS;
auto list = artery_font::StdList<int>(5);
std::cout << "There are " << list.length() << " elements in the list" << std::endl;
return EXIT_SUCCESS;
}
8 changes: 3 additions & 5 deletions recipes/assimp/5.x/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,16 @@
sources:
"5.4.1":
url: "https://github.com/assimp/assimp/archive/refs/tags/v5.4.1.tar.gz"
sha256: "a1bf71c4eb851ca336bba301730cd072b366403e98e3739d6a024f6313b8f954"
"5.3.1":
url: "https://github.com/assimp/assimp/archive/refs/tags/v5.3.1.tar.gz"
sha256: "a07666be71afe1ad4bc008c2336b7c688aca391271188eb9108d0c6db1be53f1"
"5.2.5":
url: "https://github.com/assimp/assimp/archive/refs/tags/v5.2.5.tar.gz"
sha256: "b5219e63ae31d895d60d98001ee5bb809fb2c7b2de1e7f78ceeb600063641e1a"
"5.2.2":
url: "https://github.com/assimp/assimp/archive/refs/tags/v5.2.2.tar.gz"
sha256: "ad76c5d86c380af65a9d9f64e8fc57af692ffd80a90f613dfc6bd945d0b80bb4"
"5.1.6":
url: "https://github.com/assimp/assimp/archive/refs/tags/v5.1.6.tar.gz"
sha256: "52ad3a3776ce320c8add531dbcb2d3b93f2e1f10fcff5ac30178b09ba934d084"
patches:
"5.2.2":
- patch_file: "patches/0005-fix-unzip.patch"
"5.1.6":
- patch_file: "patches/0005-fix-unzip.patch"
60 changes: 40 additions & 20 deletions recipes/assimp/5.x/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,9 @@
from conan.errors import ConanInvalidConfiguration
from conan.tools.build import stdcpp_library, check_min_cppstd
from conan.tools.cmake import CMake, CMakeDeps, CMakeToolchain, cmake_layout
from conan.tools.env import VirtualBuildEnv
from conan.tools.files import apply_conandata_patches, collect_libs, copy, export_conandata_patches, get, replace_in_file, rmdir, save
from conan.tools.microsoft import is_msvc
from conan.tools.microsoft import is_msvc, is_msvc_static_runtime
from conan.tools.scm import Version
import os

Expand Down Expand Up @@ -205,31 +206,47 @@ def validate(self):
if Version(self.version) < "5.3.0" and self._depends_on_clipper and Version(self.dependencies["clipper"].ref.version).major != "4":
raise ConanInvalidConfiguration("Only 'clipper/4.x' is supported")

def build_requirements(self):
if Version(self.version) >= "5.4.0":
self.tool_requires("cmake/[>=3.22 <4]")

def source(self):
get(self, **self.conan_data["sources"][self.version], strip_root=True)

def generate(self):
tc = CMakeToolchain(self)
tc.variables["ASSIMP_HUNTER_ENABLED"] = False
tc.variables["ASSIMP_IGNORE_GIT_HASH"] = True
tc.variables["ASSIMP_RAPIDJSON_NO_MEMBER_ITERATOR"] = False
tc.variables["ASSIMP_ANDROID_JNIIOSYSTEM"] = False
tc.variables["ASSIMP_BUILD_ALL_IMPORTERS_BY_DEFAULT"] = False
tc.variables["ASSIMP_BUILD_ALL_EXPORTERS_BY_DEFAULT"] = False
tc.variables["ASSIMP_BUILD_ASSIMP_TOOLS"] = False
tc.variables["ASSIMP_BUILD_DOCS"] = False
tc.variables["ASSIMP_BUILD_DRACO"] = False
tc.variables["ASSIMP_BUILD_FRAMEWORK"] = False
tc.variables["ASSIMP_BUILD_MINIZIP"] = False
tc.variables["ASSIMP_BUILD_SAMPLES"] = False
tc.variables["ASSIMP_BUILD_TESTS"] = False
tc.variables["ASSIMP_BUILD_ZLIB"] = False
tc.variables["ASSIMP_DOUBLE_PRECISION"] = self.options.double_precision
tc.variables["ASSIMP_HUNTER_ENABLED"] = False
tc.variables["ASSIMP_IGNORE_GIT_HASH"] = True
tc.variables["ASSIMP_INJECT_DEBUG_POSTFIX"] = False
tc.variables["ASSIMP_INSTALL"] = True
tc.variables["ASSIMP_INSTALL_PDB"] = False
tc.variables["ASSIMP_NO_EXPORT"] = False
tc.variables["ASSIMP_BUILD_MINIZIP"] = False
tc.variables["ASSIMP_OPT_BUILD_PACKAGES"] = False
tc.variables["ASSIMP_RAPIDJSON_NO_MEMBER_ITERATOR"] = False
tc.variables["ASSIMP_UBSAN"] = False
tc.variables["ASSIMP_WARNINGS_AS_ERRORS"] = False
tc.variables["USE_STATIC_CRT"] = is_msvc_static_runtime(self)

for option, (definition, _) in self._format_option_map.items():
value = self.options.get_safe(option)
if value is not None:
tc.variables[definition] = value
if self.settings.os == "Windows":
tc.preprocessor_definitions["NOMINMAX"] = 1
tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW" # to avoid warnings
if Version(self.version) < "5.4.0":
tc.cache_variables["CMAKE_POLICY_DEFAULT_CMP0077"] = "NEW"

tc.cache_variables["CMAKE_PROJECT_Assimp_INCLUDE"] = "conan_deps.cmake"
tc.cache_variables["WITH_CLIPPER"] = self._depends_on_clipper
Expand All @@ -246,24 +263,25 @@ def generate(self):
cd.set_property("utfcpp", "cmake_target_name", "utf8cpp::utf8cpp")
cd.generate()

venv = VirtualBuildEnv(self)
venv.generate()

def _patch_sources(self):
apply_conandata_patches(self)

# Don't force several compiler and linker flags
replace_mapping = [
("-fPIC", ""),
("-g ", ""),
("/WX", ""),
("-Werror", ""),
("SET(CMAKE_POSITION_INDEPENDENT_CODE ON)", ""),
('SET(CMAKE_CXX_FLAGS_DEBUG "/D_DEBUG /MDd /Ob2 /DEBUG:FULL /Zi")', ""),
('SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /D_DEBUG /Zi /Od")', ""),
('SET(CMAKE_CXX_FLAGS_RELEASE "${CMAKE_CXX_FLAGS_RELEASE} /Zi")', ""),
('SET(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /DEBUG:FULL /PDBALTPATH:%_PDB% /OPT:REF /OPT:ICF")', ""),
]
for before, after in replace_mapping:
replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), before, after, strict=False)
replace_in_file(self, os.path.join(self.source_folder, "code", "CMakeLists.txt"), before, after, strict=False)
for pattern in [
"-fPIC",
"-g ",
"SET(CMAKE_POSITION_INDEPENDENT_CODE ON)",
'SET(CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG} /D_DEBUG /Zi /Od")',
'SET(CMAKE_SHARED_LINKER_FLAGS_RELEASE "${CMAKE_SHARED_LINKER_FLAGS_RELEASE} /DEBUG:FULL /PDBALTPATH:%_PDB% /OPT:REF /OPT:ICF")',
]:
replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), pattern, "")

for pattern in ["-Werror", "/WX"]:
replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"), pattern, "")
replace_in_file(self, os.path.join(self.source_folder, "code", "CMakeLists.txt"), pattern, "")

# Make sure vendored libs are not used by accident by removing their subdirs
allow_vendored = ["Open3DGC"]
Expand Down Expand Up @@ -298,6 +316,8 @@ def _patch_sources(self):
]:
save(self, os.path.join(self.source_folder, "contrib", contrib_header),
f"#include <{include}>\n")
if Version(self.version) >= "5.4.0":
rmdir(self, self.source_path.joinpath("contrib", "utf8cpp"))

# minizip is provided via conan_deps.cmake, no need to use pkgconfig
replace_in_file(self, os.path.join(self.source_folder, "CMakeLists.txt"),
Expand Down
4 changes: 2 additions & 2 deletions recipes/assimp/config.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
versions:
"5.4.1":
folder: "5.x"
"5.3.1":
folder: "5.x"
"5.2.5":
folder: "5.x"
"5.2.2":
folder: "5.x"
"5.1.6":
folder: "5.x"
9 changes: 9 additions & 0 deletions recipes/async_simple/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,16 @@
sources:
"1.3":
url: "https://github.com/alibaba/async_simple/archive/refs/tags/v1.3.tar.gz"
sha256: "0BA0DC3397882611B538D04B8EE6668B1A04CE046128599205184C598B718743"
"1.2":
url: "https://github.com/alibaba/async_simple/archive/refs/tags/1.2.tar.gz"
sha256: "a59a2674ac2b0a3997b90873b2bf0fbe4d96fdedbe6a2628c16c92a65a3fa39a"
"1.0.0":
url: "https://github.com/alibaba/async_simple/archive/refs/tags/1.0.tar.gz"
sha256: "b243fb7af5d61b534fe18b662d16498392bbce1deffdc68e58829aa31db7badf"
patches:
"1.0.0":
- patch_file: "patches/disable-asan-1.0.patch"
patch_description: "Add option for disabling address sanitizer in root CMakeLists"
patch_type: "portability"
patch_source: "https://github.com/alibaba/async_simple/commit/ccb760356b9d7481ca73f0c58d15928bf8b0aa0b"
Loading

0 comments on commit a136177

Please sign in to comment.