mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-23 04:16:50 +01:00
27 lines
713 B
Plaintext
27 lines
713 B
Plaintext
|
#!/usr/bin/env python
|
||
|
|
||
|
Import("env")
|
||
|
|
||
|
import os
|
||
|
|
||
|
from platform_methods import run_in_subprocess
|
||
|
import editor_icons_builders
|
||
|
|
||
|
make_editor_icons_builder = Builder(
|
||
|
action=run_in_subprocess(editor_icons_builders.make_editor_icons_action), suffix=".h", src_suffix=".svg"
|
||
|
)
|
||
|
|
||
|
env["BUILDERS"]["MakeEditorIconsBuilder"] = make_editor_icons_builder
|
||
|
|
||
|
# Editor's own icons
|
||
|
icon_sources = Glob("*.svg")
|
||
|
|
||
|
# Module icons
|
||
|
for path in env.module_icons_paths:
|
||
|
if not os.path.isabs(path):
|
||
|
icon_sources += Glob("#" + path + "/*.svg") # Built-in.
|
||
|
else:
|
||
|
icon_sources += Glob(path + "/*.svg") # Custom.
|
||
|
|
||
|
env.Alias("editor_icons", [env.MakeEditorIconsBuilder("#editor/editor_icons.gen.h", icon_sources)])
|