mirror of
https://github.com/DarkFlippers/unleashed-firmware.git
synced 2025-12-13 05:06:30 +04:00
[FL-3174] Dolphin builder in ufbt; minor ufbt/fbt improvements (#2601)
* ufbt: added "dolphin_ext" target (expects "external" subfolder in cwd with dolphin assets); cleaned up unused code * ufbt: codestyle fixes * scripts: fixed style according to ruff linter * scripts: additional cleanup & codestyle fixes * github: pass target hw code when installing local SDK with ufbt * ufbt: added error message for missing folder in dolphin builder * scripts: more linter fixes * sdk: added flipper_format_stream; ufbt: support for --extra-define * fbt: reduced amount of global defines * scripts, fbt: rearranged imports Co-authored-by: Aleksandr Kutuzov <alleteam@gmail.com>
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
from dataclasses import dataclass, field
|
||||
from typing import List, Optional, Tuple, Callable
|
||||
from enum import Enum
|
||||
import os
|
||||
from dataclasses import dataclass, field
|
||||
from enum import Enum
|
||||
from typing import Callable, List, Optional, Tuple
|
||||
|
||||
|
||||
class FlipperManifestException(Exception):
|
||||
@@ -93,7 +93,7 @@ class AppManager:
|
||||
def get(self, appname: str):
|
||||
try:
|
||||
return self.known_apps[appname]
|
||||
except KeyError as _:
|
||||
except KeyError:
|
||||
raise FlipperManifestException(
|
||||
f"Missing application manifest for '{appname}'"
|
||||
)
|
||||
@@ -223,6 +223,7 @@ class AppBuildset:
|
||||
return self.appmgr.get(app_name).supports_hardware_target(self.hw_target)
|
||||
|
||||
def _get_app_depends(self, app_name: str) -> List[str]:
|
||||
app_def = self.appmgr.get(app_name)
|
||||
# Skip app if its target is not supported by the target we are building for
|
||||
if not self._check_if_app_target_supported(app_name):
|
||||
self._writer(
|
||||
@@ -230,7 +231,6 @@ class AppBuildset:
|
||||
)
|
||||
return []
|
||||
|
||||
app_def = self.appmgr.get(app_name)
|
||||
return list(
|
||||
filter(
|
||||
self._check_if_app_target_supported,
|
||||
@@ -296,7 +296,7 @@ class AppBuildset:
|
||||
try:
|
||||
parent_app = self.appmgr.get(parent_app_id)
|
||||
parent_app._plugins.append(extension_app)
|
||||
except FlipperManifestException as e:
|
||||
except FlipperManifestException:
|
||||
self._writer(
|
||||
f"Module {extension_app.appid} has unknown parent {parent_app_id}"
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user