Skip to content

Commit

Permalink
libsvtav1: add new version 2.2.1 (#25038)
Browse files Browse the repository at this point in the history
* libsvtav1: add version 2.2.1

* fix missing options

* empty commit

---------

Co-authored-by: czoido <[email protected]>
  • Loading branch information
toge and czoido authored Nov 25, 2024
1 parent 9b60874 commit fc1e559
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 0 deletions.
3 changes: 3 additions & 0 deletions recipes/libsvtav1/all/conandata.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,7 @@
sources:
"2.2.1":
url: "https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v2.2.1/SVT-AV1-v2.2.1.tar.gz"
sha256: "d02b54685542de0236bce4be1b50912aba68aff997c43b350d84a518df0cf4e5"
"2.1.2":
url: "https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v2.1.2/SVT-AV1-v2.1.2.tar.gz"
sha256: "65e90af18f31f8c8d2e9febf909a7d61f36172536abb25a7089f152210847cd9"
Expand Down
32 changes: 32 additions & 0 deletions recipes/libsvtav1/all/conanfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,25 @@ class SVTAV1Conan(ConanFile):
"build_encoder": [True, False],
"build_decoder": [True, False],
"minimal_build": [True, False],
"with_neon": [True, False],
"with_arm_crc32": [True, False],
"with_neon_dotprod": [True, False],
"with_neon_i8mm": [True, False],
"with_neon_sve": [True, False],
"with_neon_sve2": [True, False],
}
default_options = {
"shared": False,
"fPIC": True,
"build_encoder": True,
"build_decoder": True,
"minimal_build": False,
"with_neon": True,
"with_arm_crc32": True,
"with_neon_dotprod": True,
"with_neon_i8mm": True,
"with_neon_sve": True,
"with_neon_sve2": True,
}

def export_sources(self):
Expand All @@ -43,6 +55,13 @@ def config_options(self):
if Version(self.version) >= "2.1.1":
# https://gitlab.com/AOMediaCodec/SVT-AV1/-/blob/c949fe4f14fe288a9b2b47aa3e61335422a83645/CHANGELOG.md#211---2024-06-25
del self.options.build_decoder
if Version(self.version) < "2.2.1" or self.settings.arch not in ("armv8", "armv8.3"):
del self.options.with_neon
del self.options.with_arm_crc32
del self.options.with_neon_dotprod
del self.options.with_neon_i8mm
del self.options.with_neon_sve
del self.options.with_neon_sve2

def configure(self):
if self.options.shared:
Expand Down Expand Up @@ -79,6 +98,19 @@ def generate(self):
if self.settings.arch in ("x86", "x86_64"):
tc.variables["ENABLE_NASM"] = True
tc.variables["MINIMAL_BUILD"] = self.options.get_safe("minimal_build", False)
if "with_neon" in self.options:
tc.variables["ENABLE_NEON"] = self.options.with_neon
if "with_arm_crc32" in self.options:
tc.variables["ENABLE_ARM_CRC32"] = self.options.with_arm_crc32
if "with_neon_dotprod" in self.options:
tc.variables["ENABLE_NEON_DOTPROD"] = self.options.with_neon_dotprod
if "with_neon_i8mm" in self.options:
tc.variables["ENABLE_NEON_i8MM"] = self.options.with_neon_i8mm
if "with_sve" in self.options:
tc.variables["ENABLE_SVE"] = self.options.with_sve
if "with_sve2" in self.options:
tc.variables["ENABLE_SVE2"] = self.options.with_sve2

tc.generate()
deps = CMakeDeps(self)
deps.generate()
Expand Down
2 changes: 2 additions & 0 deletions recipes/libsvtav1/config.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
versions:
"2.2.1":
folder: all
"2.1.2":
folder: all
"2.1.0":
Expand Down

0 comments on commit fc1e559

Please sign in to comment.