From 47e053fb4770c3dce70242343fa7386b2735bb29 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Sun, 29 Nov 2020 13:22:45 +0200 Subject: [PATCH] build script: add vorbis target --- build.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/build.py b/build.py index 954926ba..2299fbb1 100755 --- a/build.py +++ b/build.py @@ -640,6 +640,19 @@ class OggTarget(ConfigureMakeStaticDependencyTarget): return os.path.exists(builder.source_path + 'ogg.pc.in') +class VorbisTarget(ConfigureMakeStaticDependencyTarget): + def __init__(self, name='vorbis'): + super().__init__(name) + + def prepare_source(self, builder: 'Builder'): + builder.download_source( + 'https://downloads.xiph.org/releases/vorbis/libvorbis-1.3.7.tar.xz', + 'b33cc4934322bcbf6efcbacf49e3ca01aadbea4114ec9589d1b1e9d20f72954b') + + def detect(self, builder: 'Builder') -> bool: + return os.path.exists(builder.source_path + 'vorbis.pc.in') + + # Case insensitive dictionary class from # https://github.com/psf/requests/blob/v2.25.0/requests/structures.py @@ -824,6 +837,7 @@ class Builder(object): JpegTurboTarget(), NasmTarget(), OggTarget(), + VorbisTarget(), ) self.targets = CaseInsensitiveDict({target.name: target for target in targets})