diff --git a/aedi/target/__init__.py b/aedi/target/__init__.py index 2058848a..f13fe60e 100644 --- a/aedi/target/__init__.py +++ b/aedi/target/__init__.py @@ -115,11 +115,11 @@ def targets(): MesonTarget(), NasmTarget(), NinjaTarget(), - P7ZipTarget(), PkgConfigTarget(), YasmTarget(), # Tools without binaries stored in the repo, can be outdated + P7ZipTarget(), PbzxTarget(), UnrarTarget(), ZipTarget(), diff --git a/aedi/target/tool_tier1.py b/aedi/target/tool_tier1.py index d23eb1a8..b0b97306 100644 --- a/aedi/target/tool_tier1.py +++ b/aedi/target/tool_tier1.py @@ -129,24 +129,6 @@ class NinjaTarget(CMakeStaticDependencyTarget): super().configure(state) -class P7ZipTarget(CMakeTarget): - def __init__(self, name='p7zip'): - super().__init__(name) - self.src_root = 'CPP/7zip/CMAKE/7za' - - def prepare_source(self, state: BuildState): - state.download_source( - 'https://github.com/jinfeihan57/p7zip/archive/refs/tags/v17.04.tar.gz', - 'ea029a2e21d2d6ad0a156f6679bd66836204aa78148a4c5e498fe682e77127ef') - - def detect(self, state: BuildState) -> bool: - return state.has_source_file('CPP/7zip/CMAKE/CMakeLists.txt') \ - and state.has_source_file('C/fast-lzma2/fast-lzma2.h') - - def post_build(self, state: BuildState): - self.copy_to_bin(state, '7za') - - class PkgConfigTarget(ConfigureMakeDependencyTarget): def __init__(self, name='pkg-config'): super().__init__(name) diff --git a/aedi/target/tool_tier2.py b/aedi/target/tool_tier2.py index c9e56b6e..8708ac95 100644 --- a/aedi/target/tool_tier2.py +++ b/aedi/target/tool_tier2.py @@ -19,6 +19,24 @@ from .base import * +class P7ZipTarget(CMakeTarget): + def __init__(self, name='p7zip'): + super().__init__(name) + self.src_root = 'CPP/7zip/CMAKE/7za' + + def prepare_source(self, state: BuildState): + state.download_source( + 'https://github.com/jinfeihan57/p7zip/archive/refs/tags/v17.04.tar.gz', + 'ea029a2e21d2d6ad0a156f6679bd66836204aa78148a4c5e498fe682e77127ef') + + def detect(self, state: BuildState) -> bool: + return state.has_source_file('CPP/7zip/CMAKE/CMakeLists.txt') \ + and state.has_source_file('C/fast-lzma2/fast-lzma2.h') + + def post_build(self, state: BuildState): + self.copy_to_bin(state, '7za') + + class PbzxTarget(SingleExeCTarget): def __init__(self, name='pbzx'): super().__init__(name)