diff options
author | Campbell Barton <ideasman42@gmail.com> | 2021-08-04 04:31:28 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2021-08-04 04:35:05 +0300 |
commit | 7389fd9a35a3c8911f2d502ea2c745d574a2de21 (patch) | |
tree | acd0fb795b2c9a1e6efd8ed91c28659cbf3bf1c1 /release/datafiles/blender_icons_geom_update.py | |
parent | 8a1c1279b3d9c5478d7e94c4875c141db750fbcb (diff) |
Icons: resolve various issues for generating icons
- INKSCAPE_BIN environment variable was ignored by
alert_icons_update & prvicons_update.
- `make icons` wasn't regenerating alert icons.
- Updating SVG icons failed using blender built with ASAN.
Diffstat (limited to 'release/datafiles/blender_icons_geom_update.py')
-rwxr-xr-x | release/datafiles/blender_icons_geom_update.py | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/release/datafiles/blender_icons_geom_update.py b/release/datafiles/blender_icons_geom_update.py index 5b95961ae6b..d5373d6b2e9 100755 --- a/release/datafiles/blender_icons_geom_update.py +++ b/release/datafiles/blender_icons_geom_update.py @@ -6,10 +6,9 @@ import subprocess import sys -def run(cmd): +def run(cmd, *, env=None): print(" ", " ".join(cmd)) - # Don't use check_call because asan causes nonzero exitcode :S - subprocess.call(cmd) + subprocess.check_call(cmd, env=env) def edit_text_file(filename, marker_begin, marker_end, content): @@ -73,7 +72,12 @@ for blend in icons_blend: "--group", "Export", "--output-dir", output_dir, ) - run(cmd) + + env = {} + # Developers may have ASAN enabled, avoid non-zero exit codes. + env["ASAN_OPTIONS"] = "exitcode=0:" + os.environ.get("ASAN_OPTIONS", "") + + run(cmd, env=env) files_new = set(names_and_time_from_path(output_dir)) icon_files.extend([ |