Skip to contentSkip to conversation

scripts/tags.sh: parse *.dts.tmp for compiled sources

PATCH In review Jialu Xu 2 participants 3 messages Feb 21, 2022 – Feb 22, 2022

lore
Share & tools
lore

Jialu Xu

author
#0 lore raw

PATCH 1/1 scripts/tags.sh: parse *.dts.tmp for compiled sources

There are files listed in *.dts.tmp, parse them as *.cmd for compiled sources.

---
 scripts/tags.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/tags.sh +2 -2
index 16d475b3e203..f64c33f4dabf 100755
@@ -97,8 +97,8 @@ all_compiled_sources()
 {
 	realpath -es $([ -z "$KBUILD_ABS_SRCTREE" ] && echo --relative-to=.) \
 		include/generated/autoconf.h $(find $ignore -name "*.cmd" -exec \
-		grep -Poh '(?(?=^source_.* \K).*|(?=^  \K\S).*(?= \\))' {} \+ |
-		awk '!a[$0]++') | sort -u
+		grep -Poh '(?(?=^source_.* \K).*|(?=^  \K\S).*(?= \\))' {} \+ | awk '!a[$0]++') \
+		$(find -name "*.dts.tmp" -exec grep -Poh '(?(?=^# \d+ "\K).*(?="))' {} \+) | sort -u
 }
 
 all_target_sources()
Signature · 1 line
2.30.2
#1 lore raw
Quoted 5 lines · Jialu Xu

There are files listed in *.dts.tmp, parse them as *.cmd for compiled sources.

---

Why?

Quoted 22 lines
 scripts/tags.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
scripts/tags.sh +2 -3
index 16d475b3e203..f64c33f4dabf 100755
@@ -97,8 +97,8 @@ all_compiled_sources()
 {
        realpath -es $([ -z "$KBUILD_ABS_SRCTREE" ] && echo --relative-to=.) \
                include/generated/autoconf.h $(find $ignore -name "*.cmd" -exec \
-               grep -Poh '(?(?=^source_.* \K).*|(?=^  \K\S).*(?= \\))' {} \+ |
-               awk '!a[$0]++') | sort -u
+               grep -Poh '(?(?=^source_.* \K).*|(?=^  \K\S).*(?= \\))' {} \+ | awk '!a[$0]++') \
+               $(find -name "*.dts.tmp" -exec grep -Poh '(?(?=^# \d+ "\K).*(?="))' {} \+) | sort -u
 }
 
 all_target_sources()
--

2.30.2

Signature · 2 lines
Best Regards
Masahiro Yamada
author
#2 lore raw
Quoted 7 lines
Quoted 5 lines

There are files listed in *.dts.tmp, parse them as *.cmd for compiled sources.

---

Why?

Seems that i had a misunderstanding of this, the purpose of this function is to generate tags but not a file list, and files that this patch can get additionally are some device tree sources, so this patch is probabily not necessary. Sorry.