mirror of
https://github.com/ZDoom/zdoom-macos-deps.git
synced 2025-02-19 18:12:15 +00:00
build script: add sdl2_ttf target
This commit is contained in:
parent
062b10169e
commit
1be1b79705
1 changed files with 18 additions and 0 deletions
18
build.py
18
build.py
|
@ -1349,6 +1349,23 @@ class Sdl2NetTarget(ConfigureMakeStaticDependencyTarget):
|
||||||
return os.path.exists(builder.source_path + 'SDL2_net.pc.in')
|
return os.path.exists(builder.source_path + 'SDL2_net.pc.in')
|
||||||
|
|
||||||
|
|
||||||
|
class Sdl2TtfTarget(ConfigureMakeStaticDependencyTarget):
|
||||||
|
def __init__(self, name='sdl2_ttf'):
|
||||||
|
super().__init__(name)
|
||||||
|
|
||||||
|
def prepare_source(self, builder: 'Builder'):
|
||||||
|
builder.download_source(
|
||||||
|
'https://www.libsdl.org/projects/SDL_ttf/release/SDL2_ttf-2.0.15.tar.gz',
|
||||||
|
'a9eceb1ad88c1f1545cd7bd28e7cbc0b2c14191d40238f531a15b01b1b22cd33')
|
||||||
|
|
||||||
|
def detect(self, builder: 'Builder') -> bool:
|
||||||
|
return os.path.exists(builder.source_path + 'SDL2_ttf.pc.in')
|
||||||
|
|
||||||
|
@staticmethod
|
||||||
|
def _process_pkg_config(pcfile: str, line: str) -> str:
|
||||||
|
return line + 'Requires.private: freetype2\n' if line.startswith('Requires:') else line
|
||||||
|
|
||||||
|
|
||||||
class SndFileTarget(CMakeStaticDependencyTarget):
|
class SndFileTarget(CMakeStaticDependencyTarget):
|
||||||
def __init__(self, name='sndfile'):
|
def __init__(self, name='sndfile'):
|
||||||
super().__init__(name)
|
super().__init__(name)
|
||||||
|
@ -1747,6 +1764,7 @@ class Builder(object):
|
||||||
Sdl2ImageTarget(),
|
Sdl2ImageTarget(),
|
||||||
Sdl2MixerTarget(),
|
Sdl2MixerTarget(),
|
||||||
Sdl2NetTarget(),
|
Sdl2NetTarget(),
|
||||||
|
Sdl2TtfTarget(),
|
||||||
SndFileTarget(),
|
SndFileTarget(),
|
||||||
VorbisTarget(),
|
VorbisTarget(),
|
||||||
VpxTarget(),
|
VpxTarget(),
|
||||||
|
|
Loading…
Reference in a new issue