From 0ad8a68b66406bcad6f3d86fd30b372d9e497040 Mon Sep 17 00:00:00 2001 From: "alexey.lysiuk" Date: Mon, 9 Jan 2023 16:04:03 +0200 Subject: [PATCH] aedi: add glslang target [skip build] --- aedi/target/__init__.py | 1 + aedi/target/tool_tier2.py | 18 ++++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/aedi/target/__init__.py b/aedi/target/__init__.py index c0fe68d7..24174358 100644 --- a/aedi/target/__init__.py +++ b/aedi/target/__init__.py @@ -122,6 +122,7 @@ def targets(): YasmTarget(), # Tools without binaries stored in the repo, can be outdated + GlslangTarget(), P7ZipTarget(), PbzxTarget(), UnrarTarget(), diff --git a/aedi/target/tool_tier2.py b/aedi/target/tool_tier2.py index 376aa406..1ad48e47 100644 --- a/aedi/target/tool_tier2.py +++ b/aedi/target/tool_tier2.py @@ -19,6 +19,24 @@ from .base import * +class GlslangTarget(CMakeStaticDependencyTarget): + def __init__(self, name='glslang'): + super().__init__(name) + + def prepare_source(self, state: BuildState): + state.download_source( + 'https://github.com/KhronosGroup/glslang/archive/refs/tags/11.13.0.tar.gz', + '592c98aeb03b3e81597ddaf83633c4e63068d14b18a766fd11033bad73127162') + + def configure(self, state: BuildState): + args = ('python3', 'update_glslang_sources.py') + subprocess.run(args, check=True, cwd=state.source, env=state.environment) + + state.options['ENABLE_CTEST'] = 'NO' + + super().configure(state) + + class P7ZipTarget(CMakeTarget): def __init__(self, name='p7zip'): super().__init__(name)