Pull Rust fixes from Miguel Ojeda: "Most of these are straightforward. The last one is more complex, but it only touches Rust + GCC builds which are for the moment best-effort. - Code: Missing 'extern "C"' fix. - Scripts: 'is_rust_module.sh' and 'generate_rust_analyzer.py' fixes. - A couple trivial fixes - Build: Rust + GCC build fix and 'grep' warning fix" * tag 'rust-fixes-6.3' of https://github.com/Rust-for-Linux/linux: rust: allow to use INIT_STACK_ALL_ZERO rust: fix regexp in scripts/is_rust_module.sh rust: build: Fix grep warning scripts: generate_rust_analyzer: Handle sub-modules with no Makefile rust: kernel: Mark rust_fmt_argument as extern "C" rust: sort uml documentation arch support table rust: str: fix requierments->requirements typo
Showing the changes to scripts (2 of 6 files). Show all
Unified · Split
| @@ -104,7 +104,10 @@ def generate_crates(srctree, objtree, sysroot_src): · 103 unmodified lines | |||
| 104 | name = path.name.replace(".rs", "") | 104 | name = path.name.replace(".rs", "") |
| 105 | 105 | ||
| 106 | # Skip those that are not crate roots. | 106 | # Skip those that are not crate roots. |
| 107 | if f"{name}.o" not in open(path.parent / "Makefile").read(): | 107 | try: |
| 108 | if f"{name}.o" not in open(path.parent / "Makefile").read(): | ||
| 109 | continue | ||
| 110 | except FileNotFoundError: | ||
| 108 | continue | 111 | continue |
| 109 | 112 | ||
| 110 | logging.info("Adding %s", name) | 113 | logging.info("Adding %s", name) |
| @@ -13,4 +13,4 @@ set -e · 12 unmodified lines | |||
| 13 | # | 13 | # |
| 14 | # In the future, checking for the `.comment` section may be another | 14 | # In the future, checking for the `.comment` section may be another |
| 15 | # option, see https://github.com/rust-lang/rust/pull/97550. | 15 | # option, see https://github.com/rust-lang/rust/pull/97550. |
| 16 | ${NM} "$*" | grep -qE '^[0-9a-fA-F]+ r _R[^[:space:]]+16___IS_RUST_MODULE[^[:space:]]*$' | 16 | ${NM} "$*" | grep -qE '^[0-9a-fA-F]+ [Rr] _R[^[:space:]]+16___IS_RUST_MODULE[^[:space:]]*$' |