summaryrefslogtreecommitdiff
path: root/scripts/generate_rust_analyzer.py
diff options
context:
space:
mode:
authorThomas Zimmermann <tzimmermann@suse.de>2023-06-15 10:34:19 +0200
committerThomas Zimmermann <tzimmermann@suse.de>2023-06-15 10:34:19 +0200
commitdb6da59cf27b5661ced03754ae0550f8914eda9e (patch)
treeccb1851c8a71e776dbccf1ccae132dc9b5f093c6 /scripts/generate_rust_analyzer.py
parentcf03e2956af307dc25e8c41fd4cffe44482a6ec1 (diff)
parent901bdf5ea1a836400ee69aa32b04e9c209271ec7 (diff)
Merge drm/drm-next into drm-misc-next-fixes
Backmerging to sync drm-misc-next-fixes with drm-misc-next. Signed-off-by: Thomas Zimmermann <tzimmermann@suse.de>
Diffstat (limited to 'scripts/generate_rust_analyzer.py')
-rwxr-xr-xscripts/generate_rust_analyzer.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/scripts/generate_rust_analyzer.py b/scripts/generate_rust_analyzer.py
index ecc7ea9a4dcf..946e250c1b2a 100755
--- a/scripts/generate_rust_analyzer.py
+++ b/scripts/generate_rust_analyzer.py
@@ -104,7 +104,10 @@ def generate_crates(srctree, objtree, sysroot_src):
name = path.name.replace(".rs", "")
# Skip those that are not crate roots.
- if f"{name}.o" not in open(path.parent / "Makefile").read():
+ try:
+ if f"{name}.o" not in open(path.parent / "Makefile").read():
+ continue
+ except FileNotFoundError:
continue
logging.info("Adding %s", name)