]> git.ipfire.org Git - thirdparty/ipxe.git/commitdiff
[efi] Allow for whitespace before #include in imported EDK2 header files
authorMichael Brown <mcb30@ipxe.org>
Sat, 28 Jan 2023 15:36:23 +0000 (15:36 +0000)
committerMichael Brown <mcb30@ipxe.org>
Sat, 28 Jan 2023 17:22:25 +0000 (17:22 +0000)
Signed-off-by: Michael Brown <mcb30@ipxe.org>
src/include/ipxe/efi/import.pl

index 7177768a7fe9bbc56da84173241cc9cf9865d5db..ec986025d67d6829905c2825c949b59e7c82a087 100755 (executable)
@@ -67,7 +67,7 @@ sub try_import_file {
        s/\s*$//g;
        chomp;
        # Update include lines, and record included files
-       if ( s/^\#include\s+[<\"](\S+)[>\"]/\#include <ipxe\/efi\/$1>/ ) {
+       if ( s/^(\s*\#include\s+)[<\"](\S+)[>\"]/$1<ipxe\/efi\/$2>/ ) {
          push @dependencies, $1;
        }
        # Check for BSD licence statement