[PATCH] docs: Makefile: Sort Documentation targets case-insensitively in make help
From: Bhanu Seshu Kumar Valluri
Date: Tue Oct 14 2025 - 21:29:40 EST
Avoid case-sensitive sorting when listing Documentation targets in make help.
Previously, targets like PCI and RCU appeared ahead of others due to uppercase
names.
Normalize casing during _SPHINXDIRS generation to ensure consistent and
intuitive ordering.
Fixes: 965fc39f7393 ("Documentation: sort _SPHINXDIRS for 'make help'")
Signed-off-by: Bhanu Seshu Kumar Valluri <bhanuseshukumar@xxxxxxxxx>
---
Notes
- Patch is tested with make help command.
- Verified case-insensitive sorting.
Documentation/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/Makefile b/Documentation/Makefile
index 3609cb86137b..00c81e7947a9 100644
--- a/Documentation/Makefile
+++ b/Documentation/Makefile
@@ -23,7 +23,7 @@ SPHINXOPTS =
SPHINXDIRS = .
DOCS_THEME =
DOCS_CSS =
-_SPHINXDIRS = $(sort $(patsubst $(srctree)/Documentation/%/index.rst,%,$(wildcard $(srctree)/Documentation/*/index.rst)))
+_SPHINXDIRS = $(shell printf "%s\n" $(patsubst $(srctree)/Documentation/%/index.rst,%,$(wildcard $(srctree)/Documentation/*/index.rst)) | sort -f)
SPHINX_CONF = conf.py
PAPER =
BUILDDIR = $(obj)/output
--
2.34.1