22 lines
513 B
Python
22 lines
513 B
Python
# build/build_targets/base.py
|
|
from abc import ABC, abstractmethod
|
|
from pathlib import Path
|
|
from ..utils import mkdir
|
|
|
|
class BuildTarget(ABC):
|
|
def __init__(self, platform, config, utils):
|
|
self.platform = platform
|
|
self.config = config
|
|
self.utils = utils
|
|
|
|
@abstractmethod
|
|
def sources(self) -> list[Path]:
|
|
raise NotImplementedError
|
|
|
|
@abstractmethod
|
|
def output(self) -> Path:
|
|
raise NotImplementedError
|
|
|
|
def build(self):
|
|
raise NotImplementedError
|