Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

podofo/all: bump deps, use version range for OpenSSL #20725

Merged
merged 10 commits into from
Aug 19, 2024
19 changes: 13 additions & 6 deletions recipes/podofo/all/conanfile.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
from conan import ConanFile
from conan import ConanFile, conan_version
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 apply_conandata_patches, copy, export_conandata_patches, get, rmdir
Expand Down Expand Up @@ -62,26 +62,33 @@ def layout(self):
cmake_layout(self, src_folder="src")

def requirements(self):
self.requires("freetype/2.13.0")
self.requires("freetype/2.13.2")
self.requires("zlib/[>=1.2.11 <2]")
if self.settings.os != "Windows":
self.requires("fontconfig/2.14.2")
self.requires("fontconfig/2.15.0")
if self.options.with_openssl:
self.requires("openssl/1.1.1u")
self.requires("openssl/[>=1.1 <4]")
if self.options.with_libidn:
self.requires("libidn/1.36")
if self.options.with_jpeg:
self.requires("libjpeg/9e")
if self.options.with_tiff:
self.requires("libtiff/4.5.1")
self.requires("libtiff/4.6.0")
if self.options.with_png:
self.requires("libpng/1.6.40")
self.requires("libpng/[>=1.6 <2]")
if self.options.with_unistring:
self.requires("libunistring/0.9.10")

def validate(self):
if self.info.settings.compiler.get_safe("cppstd") and Version(self.version) >= "0.9.7":
check_min_cppstd(self, 11)
if conan_version.major >= 2 and Version(self.version) < "0.9.7":
# FIXME: linter complains, but function is there
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe we can remove the old version in a follow-up PR at some point :)

# 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')
# INFO: error: no template named 'auto_ptr' in namespace 'std'. Removed in C++17.
check_max_cppstd(self, 14)

def source(self):
get(self, **self.conan_data["sources"][self.version],
Expand Down
Loading