Commit 0f8272571b for perl

commit 0f8272571b2f5cf3fbf5acaa08f9d5607f9fc70c
Author: Lukas Mai <lukasmai.403@gmail.com>
Date:   Wed Nov 25 15:57:44 2026 +0100

    perlapi: fix header names in I_* sample code

    Before: mach_cthreads.h, sys_dir.h, mallocmalloc.h, ...
    After: mach/cthreads.h, sys/dir.h, malloc/malloc.h, ...

diff --git a/autodoc.pl b/autodoc.pl
index 49017c5bc7..60dca7c74d 100644
--- a/autodoc.pl
+++ b/autodoc.pl
@@ -1616,8 +1616,26 @@ sub parse_config_h {

             # Symbols of the form I_FOO are for #include files.  They have
             # special usage information
-            if ($name =~ / ^ I_ ( .* ) /x) {
-                my $file = lc $1 . '.h';
+            if ($name eq 'I_SYS_TIME_KERNEL') {
+                # special case: define + include
+                $configs{$name}{usage} = <<~"EOT";
+                    #ifdef $name
+                        #define KERNEL
+                        #include <sys/time.h>
+                    #endif
+                    EOT
+            } elsif ($name =~ / ^ I_ ( .* ) /x) {
+                state %irregular_include_file = (
+                    FP_CLASS     => 'fp_class.h',
+                    GDBMNDBM     => 'gdbm/ndbm.h',
+                    GDBM_NDBM    => 'gdbm-ndbm.h',
+                    MALLOCMALLOC => 'malloc/malloc.h',
+                    SYSMODE      => 'sys/mode.h',
+                    SYSUIO       => 'sys/uio.h',
+                    SYSUTSNAME   => 'sys/utsname.h',
+                );
+                my $file = $irregular_include_file{$1}
+                    // lc($1) =~ tr[_][/]r . '.h';
                 $configs{$name}{usage} = <<~"EOT";
                     #ifdef $name
                         #include <$file>