[DTrace-devel] [PATCH 5/5] kbuild: generate modules.builtin.ranges when linking the kernel

Kris Van Hees kris.van.hees at oracle.com
Mon Oct 30 22:06:53 UTC 2023


Signed-off-by: Kris Van Hees <kris.van.hees at oracle.com>
---
 scripts/link-vmlinux.sh | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/scripts/link-vmlinux.sh b/scripts/link-vmlinux.sh
index a432b171be82..2c47a7e854c2 100755
--- a/scripts/link-vmlinux.sh
+++ b/scripts/link-vmlinux.sh
@@ -102,6 +102,12 @@ vmlinux_link()
 		${wl}--whole-archive ${objs} ${wl}--no-whole-archive	\
 		${wl}--start-group ${libs} ${wl}--end-group		\
 		$@ ${ldlibs}
+
+	if is_enabled CONFIG_BUILTIN_RANGES; then
+		"${srctree}/scripts/generate_builtin_ranges.awk" \
+			modules.builtin.objs ${output}.map vmlinux.o.map \
+			> modules.builtin.ranges
+	fi
 }
 
 # generate .BTF typeinfo from DWARF debuginfo
-- 
2.39.2




More information about the DTrace-devel mailing list