Skip to content

Commit 6b0d2e5

Browse files
zhmtNaros
authored andcommitted
binding_generator.py: Don't error if directory already exists
It should be ok when folders exist. Exception shouldn't be thrown. Update binding_generator.py It should be ok when folds exist. It will fail to build without this patch, in vs code on windows with compiler ( visual studio community 2022 amd 64) . Co-Authored-By: Chris Cranford <ccranfor@redhat.com> (cherry picked from commit d79959c)
1 parent 21fba89 commit 6b0d2e5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

binding_generator.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ def _generate_bindings(api, api_filepath, use_template_get_node, bits="64", prec
302302
target_dir = Path(output_dir) / "gen"
303303

304304
shutil.rmtree(target_dir, ignore_errors=True)
305-
target_dir.mkdir(parents=True)
305+
target_dir.mkdir(parents=True, exist_ok=True)
306306

307307
real_t = "double" if precision == "double" else "float"
308308
print("Built-in type config: " + real_t + "_" + bits)

0 commit comments

Comments
 (0)